Repolode
Tsuev

Tsuev/opencode-deepseek

A local OpenAI-compatible bridge that lets opencode use the free DeepSeek web chat as a model provider, with no API key.

Stars
71
Forks
10
Open issues
3
Last commit
18 days ago

What is it?

This project runs a local FastAPI server that exposes an OpenAI-compatible /v1 API and forwards requests to the free DeepSeek web chat at chat.deepseek.com, using your own DeepSeek account. Once connected, opencode can use DeepSeek as a regular model provider and run as a full agent that reads and edits files, runs bash commands and searches code. No API key or payment is required.

The bridge handles the browser login through Playwright, solves the proof-of-work challenge by running a WASM module under wasmtime, and keeps the session refreshed in the background. Because the web chat has no native function calling, tool calls are emulated by injecting instructions into the prompt and parsing the model's text output back into structured tool calls. A command-line chat client (ds) is also included for talking to DeepSeek directly from the terminal.

The server processes upstream requests one at a time because it shares a single account, and most OpenAI parameters such as temperature are ignored. Token usage is only estimated. The project is unofficial and not affiliated with DeepSeek.

Key features

  • 01Exposes an OpenAI-compatible /v1 chat completions and models API on localhost.
  • 02Plugs into opencode as a provider, with agent tools for file editing, bash and code search.
  • 03Emulates tool calling through prompt instructions and response parsing.
  • 04Logs in once through a browser and refreshes the session automatically.
  • 05Includes a terminal chat client with DeepThink and web search toggles.

Use cases

  • Using opencode as a coding agent without paying for an API key.
  • Calling DeepSeek from OpenAI SDK code on a local machine for experiments.
  • Chatting with DeepSeek from the terminal through the bundled client.

Topics

FAQ

What is opencode-deepseek?
A local OpenAI-compatible bridge that lets opencode use the free DeepSeek web chat as a model provider, with no API key. This project runs a local FastAPI server that exposes an OpenAI-compatible /v1 API and forwards requests to the free DeepSeek web chat at chat.deepseek.com, using your own DeepSeek account. Once connected, opencode can use DeepSeek as a regular model provider and run as a full agent that reads and edits files, runs bash commands and searches code. No API key or payment is required.
Is opencode-deepseek free to use? What license does it have?
opencode-deepseek is open source under the MIT license. Check the license terms before using it in commercial products.
Is opencode-deepseek still maintained?
Actively maintained. The last commit to opencode-deepseek was on Sep 30, 2026.
What can I use opencode-deepseek for?
Using opencode as a coding agent without paying for an API key. Calling DeepSeek from OpenAI SDK code on a local machine for experiments. Chatting with DeepSeek from the terminal through the bundled client.
Where can I get opencode-deepseek?
The source code and installation instructions are on GitHub: https://github.com/Tsuev/opencode-deepseek

Summary generated by AI from the project's README. GitHub stats refresh daily.

Related projects