Target
The target of this post is to document the setting up of an AI assisted coding environment on my main computer. I also ran some experiments on existing (broken) python code.
Setup
My PC has the following relevant hardware components:
– AMD RX 7900 XTX graphics card on PCIE4.0 x 16 (16 GT/s)
The card has 24GB GDDR6 VRAM with a 384 bit bandwidth
– AMD Ryzen 9950x3D CPU, watercooled with an AIO
– 64GB of DDR5 dual channel @ 6400MHz Corsair Dominator ram
It’s very nice, it runs certain simulations very fast, with 32 cores (16 with extra cache and 16 with standard cache). We will see how fast it runs coding assistants.
Installing LM Studio server
LM Studio has an application with a graphical user interface, and a server that is started from the commandline.
In order to download LM Studio, you need to start Powershell. Make sure Windows has Powershell version 7. You can download it from Windows if you don’t have it.
Go to https://lmstudio.ai/ and copy the then current installation command for the server. Currently it is:
irm https://lmstudio.ai/install.ps1 | iex
This should be pasted into the Powershell commandline. It may give an error. In my case it still completed correctly. You can check that in the “.lmstudio” folder under your users home folder (C:/Users/YOURNAME). The location of the “lms” executable is in “.lmstudio\llmster\0.0.2-2.bundle” (for now).
Once installation has completed, quit Powershell and start a new Powershell instance. You can now check whether everything works by using the following command:
lms
This will display the list of commands. Use the following to start the LMStudio API:
lms server start
It should say “Success! Server is now running on port 1234”. You can test it by opening the following URL:
http://localhost:1234/v1/models
It should give the following result, displaying the list of models currently available:
{
"data": [
{
"id": "text-embedding-nomic-embed-text-v1.5",
"object": "model",
"owned_by": "organization_owner"
}
],
"object": "list"
}
If you download more models, you will get more. Go to powershell and type:
lms get
This will display a list of models. Choose “qwen/qwen3-coder-30b” if you have the GPU memory for it, otherwise select a smaller model. Use ChatGPT to help you decide, since models change every week.
Once selected, the model will download. It can occupy quite a bit of diskspace on your disk, the model chosen here occupies almost 19GB on disk.
Once the model has been downloaded and installed succesfully, you can refresh the model list. It should now say:
{
"data": [
{
"id": "qwen/qwen3-coder-30b",
"object": "model",
"owned_by": "organization_owner"
},
{
"id": "text-embedding-nomic-embed-text-v1.5",
"object": "model",
"owned_by": "organization_owner"
}
],
"object": "list"
The id is important here, because we will need that for the configuration of the next part. Models can have very different ids, so it is important to copy them exactly in the next step.
Restarting the LM Studio server
Please note that if you stop the server, it will unload all models in GPU memory. So the next time you start the server you will also need to run another command.
lms server start
lms load
This will display a list of locally available models, you can now select one and load it into GPU memory. Once you’ve done that you can confirm the successful loading by opening http://localhost:1234/v1/models.
Installing the LM Studio application
The LM Studio application is not the same as the server. The server only exposes a REST API on port 1234 on localhost. It is controlled through the commandline. The application gives you more ways to control the LLM, while also allowing you to start the server from the app. Basically it gives you a GUI to control the server and see what it is doing, but in more detail than the commandline options for the server.
Download the app from https://lmstudio.ai/download and install it in the usual way. When you run this, it won’t also run the server. You will be prompted to stop the server.
Just explore the tabs, they’re very self-explanatory. The icons on the left are:
– chat with your model
– developer documentation
– locally downloaded LLMs (and embeddings, which are “finetunings” or “patches” of a given model to give it extra capabilities)
– a list of models you can download.
If you want to use other models, make sure to look for “Full GPU offload possible” or the model will run on your poor CPU and not on the GPU. My GPU has 32 cores, but my GPU has 192 dedicated AI compute cores with faster memory access. That does make a difference.
Using the application, you can handle the downloading easier, but then Continue won’t be able to access the server and you need to work from LM Studio. That is fine for general chat with your models, but not for integration with Visual Studio Code. So for now, better leave the app and restart the server.
Installing the GUI: Visual Studio Continue
You need a GUI to use the API exposed by LM studio. I will use an extension withing Visual Studio Code. Other options are webbased, but they looked more involved. For now I will go with the “Continue” extension.
Once downloaded and installed, there will be a “.continue” folder in your home directory. You can the config.yaml file manually, or do it through Visual Studio Code – the recommended way. There is a new Continue icon the left side of the page. Click it, then find the settings gear-symbol on the top right of the Continue page. Open it.
On the left side you will see a menu. Go to “Configs”. Click on the gear wheel behind “Local configs”. The file will look like this:
name: Local Config
version: 1.0.0
schema: v1
models: []
Now change it to the following (taking care to change it for your chosen model if different!):
name: Local Config
version: 1.0.0
schema: v1
models:
- name: LM Studio
provider: openai
model: qwen/qwen3-coder-30b
apiBase: http://localhost:1234/v1
apiKey: dummy
defaultModel: LM Studio
If you don’t load more than one model, you could also use “model: AUTODETECT”. This will detect the currently loaded model and react accordingly.
Note that the provider is not the provider of the model, but the provider of the API that Continue will be using to talk to the model. In this case we require the OpenAI compatible API because that is what LM Studio is using.
The apiBase is the network URL where our LM studio resides – you can use one in the Cloud as well with Continue. In that case the apiKey becomes more important, for now we set it to “dummy” as local LM studio doesn’t need one.
Once you save the config.yaml file, go to the Help menu and find the restart option in VS Code, or restart it manually.
Using Visual Studio Code (VSC) with Continue
To use Continue inside VSC you need to open a folder with software. Make a new one, or open a current folder/workspace. The problem is that if you open just a single file, security restrictions will not allow Continue access to the file.
Once you’ve opened the folder, open Continue and type “describe the files in this project in a short summary”. It will give messages while processing, and then give a summary of each file. In my own example folder:
Looking at the project files, I can provide a brief summary of what each file appears to be for:- gsit_oscilloscope.py – Likely a Python script for oscilloscope functionality or data visualization
- install_dependencies.cmd – Windows batch file for installing required dependencies
- pytest_requirements.txt – Text file listing Python dependencies for testing with pytest
- PyWave.py – Probably a Python module for wave-related operations or audio processing
- Pywaveplayer.png – Image file, likely a screenshot or icon for a PyWave player application
- Pywaveplayer.py – Main Python script for a wave/player application
- test_pywave.py – Test file for the PyWave module using pytest
If Continue wants to run commands, it needs to ask for permission. It will wait until you click Accept or click inside the terminal window and click CTRL+Enter.
I asked it to examine a file for errors. It wanted to compile the file, so it needed permission. Once given it read and then compiled the file, opened other files that were dependencies and analysed the file for about a minute.
Unfortunately, the context window limit here is very relevant. The default context size for LMS server is 4096 bytes, which is very small. The files were larger than the context window, and it kept forgetting the first file it had read so it needed to read it again, losing other files, so it needed to read *those* again, ad infinitum.
You can stop this with the stop button in the Continue terminal window.
Selecting and installing a model for coding
Go to the bottom icon in LMS.

Selecting this brings up the list of models you can download. Type “code” in the searchbar to get all models that are trained on computer language and coding tasks. On the top you get the staff picks (do expand them!), below that you get everything that is a hit for your search term.
For my setup, the apparent sweet spot is either:
- AliBaba’s Qwen 3 Coder 30B (30 billion parameters), quantized to 4 bits (the more bits the better, but 8bit take up twice the space), with a download size of around 19GB.
or - Mistral’s Devstral Small 2 2512 24B (24 billion parameters), quantized to 4 bits, with a size of slightly over 15GB.
Both models support tool use (meaning they can generate and run commands to inspect files, open Git, and change files). Without tool use you have to copy/paste everything into the text window.
After selecting a model, you can choose to download it on the right. Note the green block with “Full GPU offload possible.” If your model is bigger than what fits in the VRAM of the GPU, speed will drop sharply, to a few percent of the normal speed due to the lack of compute cores in a standard CPU.

I downloaded both Qwen and Devstral for a total of about 35GB diskspace. Note that downloading Qwen was a lot faster than downloading Devstral, for some reason.
The purple icon on the top right named “Staff pick” takes you to the model card, where you can see more detailed information on the model, as well as the instructions it has received.
Once everything has downloaded, we can set the model parameters on the My Models tab, which is icon nr. 3 on the top left. Use the settings icon on the right to get a new part of the screen with three tabs:

Select the “load” tab and adjust the context size. The default size is too small for meaningful work, but the maximum size needs a lot of memory. Find out how much you are going to use with this Powershell command:
lms load --estimate-only -c 40000 qwen/qwen3-coder-30b
This will display the estimated memory use for a context length of 40000 tokens, which in my case still fits in the GPU VRAM:
PS C:\XXXX> lms load --estimate-only -c 40000 qwen/qwen3-coder-30b
Model: qwen/qwen3-coder-30b
Context Length: 40,000
Estimated GPU Memory: 23.96 GB
Estimated Total Memory: 23.96 GB
Estimate: This model may be loaded based on your resource guardrails settings.
Under the load tab we must now adjust that setting (but leave everything else on the default setting).
Now use the “<> Load Model” icon on the top right. This will show a new screen where you can adjust parameters. You can also see the impact of context size changes on the model size here.

Estimated memory usage on the top right is lower than when calculated through the commandline. The results seem to indicate that the estimate from the commandline is closer to the truth.
Make sure to remember the settings for the model, otherwise you will have to repeat the process next time you load the model. Now load the model.
Running the model
While the model is loading we can go to the second icon on the top left, “Developer”, that looks like a command line interface icon.
The option “local server” starts as “off”:

Turn the server on using the switch on the top. Now you can use the model from Visual Studio Code with the Continue extension. Do remember to change the model ID if you did not use AUTODETECT.
