Skip to content
Docs

Coding agents

Use Libremodel in DeepSeek Harness

DeepSeek Harness runs in your browser and takes extra providers from a YAML patch file. One entry adds all our models to its picker.

1. Set your API key

Create a key in API keys and save it as LIBREMODEL_API_KEY. On macOS and Linux, add the line to ~/.zshrc or ~/.bashrc so every new terminal has it.

export LIBREMODEL_API_KEY="sk-libremodel-..."

2. Start DeepSeek Harness

It needs Node.js. Start it from the terminal where you saved the key; it opens in your browser.

Shell
npx @deepseek-ai/dsh web

3. Add Libremodel

Add this to ~/.dsh/profiles/web/cordis.patch.yml. If the file already has an llm-pi-ai entry, add libremodel to its providers and leave the rest as is. It applies without a restart.

~/.dsh/profiles/web/cordis.patch.yml
- id: llm-pi-ai
  config:
    providers:
      libremodel:
        displayName: Libremodel
        apiKeyEnv: LIBREMODEL_API_KEY
        api: openai-completions
        baseURL: https://api.libremodel.ai/v1
        defaultContextWindow: 1048576
        compat:
          supportsDeveloperRole: false
          maxTokensField: max_tokens
        models:
          - id: kimi-k3.1-pro-uncensored
            name: Kimi K3.1 Pro Uncensored
            input: [text, image]
            reasoningEfforts: {off: none, low: low, high: high, max: max}
          - id: deepseek-v4.1-flash-1017-uncensored
            name: DeepSeek V4.1 Flash Uncensored
            input: [text, image]
            reasoningEfforts: {off: none, low: low, high: high, max: max}
          - id: glm-5.3-flash-uncensored
            name: GLM 5.3 Flash Uncensored
            input: [text, image]
            reasoningEfforts: {off: none, low: low, high: high, max: max}
          - id: kimi-k3.1-pro
            name: Kimi K3.1 Pro
            input: [text, image]
            reasoningEfforts: {off: none, low: low, high: high, max: max}
          - id: deepseek-v4.1-flash-1017
            name: DeepSeek V4.1 Flash
            input: [text, image]
            reasoningEfforts: {off: none, low: low, high: high, max: max}
          - id: minimax-m3.1-flash
            name: MiniMax M3.1 Flash
            input: [text, image]
            reasoningEfforts: {off: none, low: low, high: high, max: max}

4. Pick a model

Choose a workspace, then Libremodel and a model in the model picker. Set the effort in the Effort menu.

Troubleshooting

Run this in the same terminal you start the tool from. It costs nothing. A list of models means the key is fine. A 401 means LIBREMODEL_API_KEY is empty or wrong in that terminal; open a new one after saving it.

curl -s https://api.libremodel.ai/v1/models -H "Authorization: Bearer $LIBREMODEL_API_KEY"

If the key is fine and the tool gets a 402, your balance does not cover the request. See Billing and credits.

Notes

DeepSeek Harness is in developer preview and its config format can change. If it rejects a field, check its own guide to configuring models.