How to use LM Studio locally
Watch on YouTube · Watch the Short
What you will build
LM Studio includes a command line tool for working with local models. Its documented commands inspect the application, list models, and load a model.
What you need
Use LM Studio version zero point two point twenty two or newer. The command line tool ships with that application.
Step by step
Step 1. Set up the official tool
Use the installation instructions for your system.
npx lmstudio install-cliThe documented tool is available for the usage steps.
Step 2. Check application status
Check the status of the local application. This operation reports its current state before you move on to working with models.
lms statusCheck the status of the local application.
Step 3. List downloaded models
List the models that have already been downloaded. The list shows which models are available locally before you choose one to load.
lms lsList the models that have already been downloaded.
Step 4. Load a model
Load a model for inference. Use the documented loading operation for the model you want to make available in the local application.
lms loadLoad a model for inference.
Check that it works
List all loaded models available for inference. Compare the list of loaded models with the model selected during the loading step.
lms psNext steps
Start the local API server. This is the interface described in the guide for using the application through its local server.
Limits
Read the documented requirements before running the commands.
Security check
Commands were checked against official documentation. This guide does not include a repository security certification.