How to use Blablador with Visual Studio Code or Sublime text¶
Helmholtz Blablador is not only the most useful and private Chat Robot out there. You can also connect it to your Visual Studio Code or Sublime Text, to get the best of both worlds. Imagine Github Copilot, but entirely open source and PRIVATE!
Visual Studio Code (VSCode)¶
Prerequisites¶
- Visual Studio Code
- A Blablador Token
- The Continue.Dev extension for Visual Studio Code (https://continue.dev)
Important Warning: This process is currently subject to a known issue in the Continue.Dev extension regarding using jupyter notebooks on remote machines: https://github.com/continuedev/continue/issues/1463. Please be cautious and test thoroughly before using in production.
Steps¶
- Install the Continue.Dev extension for Visual Studio Code. Just click on the link above and follow the instructions.
- Open Visual Studio Code and click on the Continue.Dev icon on the left side.
- On continue area, there is a "Gear", which opens configuration options. Click on it.
- Find the option "Open Config file". Click on it.
As soon as the "config.yaml" file appears, fill the file with the following lines:
name: Blablador Helmholtz
version: 1.0.0
schema: v1
models:
- name: Blablador
provider: openai
model: AUTODETECT
apiKey: ADD_BLABLADOR_TOKEN_HERE
apiBase: https://api.helmholtz-blablador.fz-juelich.de/v1
context:
- provider: code
- provider: docs
- provider: diff
- provider: terminal
- provider: problems
- provider: folder
- provider: codebase
Mind the apiKey field. You need to replace ADD_BLABLADOR_TOKEN_HERE with your actual Blablador Token.
The list of models are on the Blablador's API Access page
All Blablador models are subject to change without further notice - but we are keeping aliases. So as soon as one model is updated, you will get the new model without changing your configuration.
Sublime Text¶
Another popular option for coding is Sublime Text. It is a lightweight and fast editor that is also highly customizable. You can use Blablador with Sublime Text by installing the OpenAI Sublime Text plugin.
Prerequisites¶
Steps¶
- Install the OpenAI Sublime Text plugin via Package Control (or other means)
- Open the plugin's settings to add the Blablador service: Sublime Text menu bar entry → Settings… → Package Settings → OpenAI completion → Settings
- In the override pane (right), add a snippet like the following
{
"url": "https://api.helmholtz-blablador.fz-juelich.de/",
"token": "ADD_BLABLADOR_TOKEN_HERE",
"assistants": [
{
"name": "Blablador Code",
"prompt_mode": "append",
"chat_model": "alias-code",
"assistant_role": "You are a senior code assistant",
"placeholder": "[PLACEHOLDER]",
}
]
}
Info
These parameters work for the author of these lines, albeit not always perfectly. Keep us informed if you find better parameters
Some notes
- You may add multiple
assistants, for example for different models or prompt modes prompt_mode: This can either bepanel(to open the output in a dedicated panel),append(to append selected text),insert(to replace a selected placeholder calledPLACEHOLDERwith the output), orreplace(to overwrite selected text).assistant_role: Gives context to the AI assistant; copied from the help- There are more parameters, check the left reference pane of the configuration‚