Kingcurve
An AI coding assistant for VS Code. Use local models (Ollama, LM Studio, any OpenAI-compatible server) or your own cloud API keys (OpenAI, Anthropic Claude, Google Gemini, OpenRouter). Kingcurve has no server of its own: requests go straight from VS Code to the provider you choose.
- Chat about your code with streaming answers, syntax highlighting and copy buttons.
- Attach context with
@file, @folder, @selection, @search, @problems, @git, @terminal and @workspace.
- Edit multiple files with a diff review: you choose which files and changes to keep, and you can roll back.
- Agent mode reads files, edits, runs commands and tests, and checks its own work, asking for your approval along the way.
- MCP servers: connect Model Context Protocol tools, resources and prompts.
- History, token usage and cost, commit messages from your staged changes, and optional inline autocomplete.
Getting started
- Install Kingcurve. It opens in the Secondary Side Bar on the right, next to other AI chats. Press
Cmd+Alt+M (macOS) / Ctrl+Alt+M (Windows, Linux) to open it, or toggle the Secondary Side Bar with Cmd+Alt+B / Ctrl+Alt+B. You can drag it to another place, such as the Activity Bar on the left.
- Connect a model (see below). Ollama and LM Studio running on your machine are detected automatically.
- Pick a mode and a model in the message box (bottom left) and start asking. Use Add context or type
@ to attach files, and paste images directly.
Requires VS Code 1.106 or newer.
Connecting a model
Open the Providers tab in the sidebar, or run Kingcurve: Manage Providers. You can add as many providers as you like, including several of the same type. Models are discovered from each provider; you can also type a model name.
Ollama
- Install Ollama and pull a model, for example
ollama pull qwen2.5-coder.
- The "Ollama" provider appears automatically (
http://127.0.0.1:11434/v1). Click Test, then choose a model.
The context length is adjusted automatically. Kingcurve starts at 8K tokens and grows the context (num_ctx) as the conversation gets longer: 16K, then 32K. Agent mode starts at the maximum, because it reads many files. The maximum is 32K by default (Settings → Maximum automatic context), and never more than the model supports. To use a fixed value instead, set it in the provider's advanced options or in Settings.
LM Studio
- In LM Studio, open the Developer tab and start the server (port 1234).
- The "LM Studio" provider appears automatically. Click Test and choose a model.
The context length is adjusted automatically. LM Studio sets a model's context when it loads it, often to only 4K tokens. When a conversation or Agent mode needs more, Kingcurve reloads the model with a larger context through LM Studio's API (up to the automatic maximum, 32K by default). The message box shows when this is happening. This needs LM Studio 0.4 or newer; with older versions, load the model with a larger Context Length yourself.
LM Studio on another computer: set the provider's Base URL to that machine, for example http://192.168.1.42:1234/v1, and turn on Serve on Local Network in LM Studio. If LM Studio has Require Authentication on, paste its API token into the API key field. Then tick Allow API key over http on the local network, because LM Studio uses plain http. Only private network addresses are accepted. Anyone on the same network could read the token, so use this only on a network you trust.
Cloud providers
Click Add provider, choose OpenAI, Anthropic Claude, Google Gemini or OpenRouter, paste your API key and save. Usage is billed by that provider to your account.
Other OpenAI-compatible servers
Choose OpenAI-compatible and enter the base URL that serves /chat/completions (usually ending in /v1). This works with vLLM, the llama.cpp server, LocalAI and hosted gateways.
Adding context
Type @ in the message box, or click @, to attach files, folders, your selection, search results, problems, git changes or terminal output. You can also write references inline:
Why does @file:src/cart.ts#L10-40 return NaN? See @problems and @git.
Where else is @search:checkoutTotal used?
Kingcurve also tells the model which project is open with every message: folder names, languages and the top of the file tree (names only, no file contents). So a question like "show me the project structure" works without attaching anything. To let the model read the code itself, attach files with @ or use Agent mode. You can turn the overview off in Settings → Context.
Before you send, the meter next to the send button (for example ≈7.3K / 16K) shows how big the next request will be compared with the model's context. Click it to see what takes the space and what Kingcurve will do: fit as is, give Ollama a larger context, reload LM Studio, or leave out older messages. Token counts are corrected per model from what the server reports, so they get closer to the model's real count after the first reply.
Chips under each message show what was attached and how many tokens it used. Large content is compressed or trimmed to fit the model. Kingcurve respects .gitignore and .mycodeignore, and never reads .env files, private keys or other credential files. Secret-looking values are hidden before anything is sent.
You can also right-click a selection or a file and choose Add Selection to Chat or Add File to Chat.
Images and files
Attach screenshots, mockups and design images (PNG, JPEG, WebP, GIF) or text files (code, Markdown, JSON, CSV, …) from anywhere on your computer:
- click the 📎 button next to the message box,
- paste an image (for example a screenshot) with
Cmd+V / Ctrl+V, or
- drag files onto the message box.
For example, attach a UI mockup and write "Build this page in Vue with Tailwind, following this layout". The model sees the image and can propose the code, which you review as diffs as usual.
- Images need a model with vision: GPT-4o or newer, Claude, Gemini, or a local vision model (for example
llava, qwen2.5vl or gemma3 in Ollama, or a VLM in LM Studio). Kingcurve warns you when the selected model cannot read images.
- Large images are scaled down to 1568 px on the long edge before sending. Up to 6 attachments per message; text files up to 200,000 characters.
- Images stay available for follow-up questions in the same conversation, including after a restart. When the conversation gets long, older images are left out first.
- Attached text files go through the same protections as workspace files: credential files (
.env, keys) are refused, and secret-looking values are hidden.
- SVG and PDF are not supported yet: attach a PNG export or a screenshot instead.
Editing code
Ask for a change, or select code and run Kingcurve: Edit Selection with AI…. A review card shows every proposed change; open any file in the VS Code diff editor and keep or drop individual files and change blocks.
- Nothing is written until you click Apply.
- Files you changed in the meantime are never overwritten.
- Roll back restores the previous content, even after restarting VS Code.
- Files that can run code (build scripts, CI, git hooks,
package.json) need an extra confirmation. .git/, node_modules/ and credential files are never changed.
Modes and the agent
Choose a mode under the message box:
| Mode |
What it does |
| Ask |
Answers questions. Read-only |
| Edit |
Proposes changes as diffs. Works with any model |
| Plan |
Investigates and writes a plan; approve it to run it in Agent mode |
| Agent |
Reads files, edits, runs commands and tests, and verifies the result |
Agent mode needs a model that supports tool calling; Kingcurve tells you if the selected model does not. For a model without it, set Tool calling → Text-based in its provider profile: the model then calls tools by writing JSON, which Kingcurve checks before running anything (less reliable than native tool calling, but it works with many local models). You stay in control:
- Every file change goes through the diff review.
- Every command asks for approval by default. Destructive commands are blocked, and installs or network commands always ask.
- Commands are shown in a Kingcurve Agent terminal.
- Deleting files always asks, even when edits are applied automatically. Database migrations and migration commands always ask too.
- When something is unclear, the agent can ask you in the chat. Answer, pick a suggestion, or skip and let it decide.
- An edit or command that already succeeded is not repeated. Continue from here resumes a run that stopped early.
- Task memory: the Task bar above the message box shows what the agent works on: request, plan, changed files, decisions and checks. The model gets it with every message, so long conversations, model switches and restarts don't make it lose track. Click Done when the task is finished.
Long conversations are summarized when they reach 80 % of the model's context: older messages become a summary that keeps your requirements, decisions and unfinished work, while recent messages are sent as they are. Agent runs that outgrow the context summarize their earlier steps and keep going.
Automatic model selection (optional): set a small, medium and large model in Agent team → Models by size and turn on Choose the model automatically in Settings. Short questions go to the small model, explanations and reviews to the medium one, and Agent work to the large one (only if it supports tool calling).
- Stop cancels everything at once.
- Show Agent Audit Log lists every action the agent took.
You can relax these defaults in Settings, for example to apply edits automatically or to run commands classified as safe without asking.
Agent team and models by role
Open the Agent team tab (people icon).
Models by role. Use different models for different jobs:
- Planner: answers in Plan mode, for example a strong cloud model.
- Reviewer: used by the Review button that appears under replies that changed files. The review runs in read-only Ask mode, so it can read files and diffs but not change them.
Leave a role on Same as chat model to use the model selected in the message box.
Team members. Add sub-agents, from templates (Frontend, Backend, Tests, Reviewer, Docs) or from scratch. For each, choose:
- what it does (the lead agent reads this to decide when to use it);
- its model;
- its tools: reading is always allowed; editing files, running commands and MCP tools are optional;
- the files it may change, as
.gitignore-style patterns.
In Agent mode, the lead agent can hand a self-contained part of the task to a member. The member works in its own run, with its own model and context, and reports back. Its steps appear nested under the lead's, with its own approvals. Every edit and command still needs your approval. Edits outside a member's file scope are refused. Members cannot delegate further. Their token usage counts toward the run. Members do not see the conversation, so the lead agent writes each one a complete task.
Share the team with your project: set Saved in → This project on a member to store it in .kingcurve/team.json and commit it. Your teammates see Review and use in their Agent team tab; the team is used only after each person approves it, and again after every change to the file.
Project folder and other AI agents
Kingcurve can share instructions and the state of your work through files in your project, which other AI agents (Codex, Claude Code, Cursor, Copilot, Gemini CLI…) can read too.
- Project instructions: write your conventions in
AGENTS.md at the project root, the file most AI coding tools read. Add more in .kingcurve/rules/*.md (one topic per file) and project decisions in .kingcurve/memory.md. Kingcurve follows them in every chat and agent run. Settings → Project folder shows which files are in use.
- Hand work to another agent: run Kingcurve: Write Handoff for Another Agent. It writes
.kingcurve/handoff.md: the goal, what is done, what remains, key files and how to verify. Then tell any agent "Read .kingcurve/handoff.md, check it against the code, then continue", or run Kingcurve: Continue from Handoff.
- Saved sessions (optional): turn on Save conversations in .kingcurve/sessions/ to also keep each conversation there as Markdown and JSON Lines. Secrets are redacted and the folder stays out of git unless you change
.kingcurve/.gitignore.
- Ignore file: list files Kingcurve should not index or add as context in
.kingcurve/ignore (.gitignore syntax).
Project files can't change your permissions: edits and commands still need your approval.
MCP servers
The MCP tab connects Model Context Protocol servers: local programs (stdio) or remote servers (Streamable HTTP). You can paste or import the usual mcpServers JSON.
- Server tools become available to the agent. Each tool can be set to allow, ask (the default) or deny.
- Resources can be attached to a message, and prompts inserted into the message box.
- A local server starts only after you approve its exact command. It gets a minimal environment.
- Remote servers must use https.
History, usage, git and autocomplete
- History: conversations are saved on your computer and the last one reopens with VS Code. You can search, rename, export (Markdown or JSON) and delete them.
- Usage: tokens and estimated cost by day, model and feature, plus a counter in the status bar. Cost is shown when the provider reports prices (OpenRouter) or when you add prices in
mycode.usage.modelPricing.
- Commit messages: the ✨ button in Source Control writes a message for your staged changes into the commit box for you to edit. Nothing is committed for you.
- Review Uncommitted Changes and Explain Last Terminal Command send your diff or your last command's output to chat.
- Autocomplete (off by default): inline suggestions from a model you choose. Ollama coder models use fast fill-in-the-middle. Autocomplete never runs on sensitive files.
Privacy
- Kingcurve has no backend and collects no telemetry.
- Your messages, and the context you attach or the agent reads, are sent only to the model provider you selected. MCP tool calls go only to that MCP server. With a local model, nothing leaves your computer.
- API keys and tokens are stored in your operating system's keychain (VS Code SecretStorage), never in settings files.
- Conversation history is stored locally in VS Code's storage for the extension, readable only by your user account.
Security and untrusted folders
- In folders you have not marked as trusted (Restricted Mode), Kingcurve offers chat only. It does not read files, edit, run commands, start MCP servers or autocomplete until you trust the folder. Click Trust this folder above the message box (or run Workspaces: Manage Workspace Trust) to trust it.
- Kingcurve's settings can only be set in your user settings. A repository cannot change them through
.vscode/settings.json.
- Model output is treated as untrusted: it cannot load remote images or run scripts in the chat view, and links open only through VS Code's own link confirmation.
- Attached files and tool results are marked as data for the model, which reduces (but cannot fully prevent) prompt injection. Always review diffs and commands before approving them.
- Project instructions (
AGENTS.md, .kingcurve/) are read only in trusted folders, are marked as coming from the repository, and cannot change permissions. A team shared in .kingcurve/team.json is used only after you approve it.
Commands
| Command |
Description |
Kingcurve: Open Chat (Cmd+Alt+M / Ctrl+Alt+M) |
Open the chat sidebar |
| Kingcurve: New Conversation |
Start a new conversation |
| Kingcurve: Stop Generation |
Cancel the current reply |
| Kingcurve: Select Model |
Choose a provider and model |
| Kingcurve: Manage Providers / Open Settings |
Open those tabs |
| Kingcurve: Set / Clear Provider API Key |
Manage stored API keys |
| Kingcurve: Test Provider Connection |
Check a provider and list its models |
| Kingcurve: Detect Local LLM Servers |
Look for Ollama and LM Studio |
| Kingcurve: Add Selection to Chat / Add File to Chat |
Attach code (also in the editor and Explorer context menus) |
| Kingcurve: Edit Selection with AI… |
Describe a change and review the proposed diff |
| Kingcurve: Roll Back Last Applied Changes |
Undo the most recent applied changes |
| Kingcurve: Rebuild Workspace Index |
Re-scan workspace files |
| Kingcurve: Show Agent Audit Log |
Every agent action with its approval and result |
| Kingcurve: Manage MCP Servers / Show MCP Server Logs |
MCP setup and logs |
| Kingcurve: Show Conversation History / Show Token Usage |
History and usage views |
| Kingcurve: Generate Commit Message |
Write a commit message for the staged changes |
| Kingcurve: Review Uncommitted Changes |
Ask for a review of your git changes |
| Kingcurve: Explain Last Terminal Command |
Explain the latest command and its output |
| Kingcurve: Toggle Inline Autocomplete |
Turn autocomplete on or off |
| Kingcurve: Write Handoff for Another Agent |
Summarize the open conversation into .kingcurve/handoff.md |
| Kingcurve: Continue from Handoff |
Continue the work in .kingcurve/handoff.md in a new conversation |
| Kingcurve: Open Project Folder (.kingcurve) |
Create or open the project folder |
| Kingcurve: Show Logs |
Open the Kingcurve output log (secrets hidden) |
In the message box: Enter sends, Shift+Enter adds a new line, Esc stops the reply, and ↑ / ↓ bring back messages you sent before (↑ from the first line, ↓ from the last line; ↓ past the newest returns to what you were typing).
Queue follow-ups while Kingcurve works. You can keep typing while a reply is being written: press Enter and the message joins a queue above the message box. Each queued message keeps the mode, @ context and attachments it was sent with. Queued messages are sent one after another when the current reply finishes. You can remove them from the queue. Stop pauses the queue; press Send next to continue. Starting a new conversation clears the queue.
Settings
Open the Settings tab in the sidebar, or search for mycode in VS Code settings. You can change:
- generation (temperature, maximum output, context length, extra instructions);
- timeouts and retries;
- workspace context (token budget, exclusions, indexing);
- file editing;
- agent limits and the read, write and terminal permissions;
- autocomplete, history retention and model prices;
- the project folder: following project instructions, and saving sessions in
.kingcurve/sessions/.
Known limitations
- Token counts are estimates for providers that do not report usage. Estimates are marked "≈". Kingcurve corrects its estimates per model with the counts servers report.
- Agent mode depends on the model: small local models often call tools unreliably.
- Remote MCP servers that require OAuth sign-in are not supported yet. Use a token instead.
License
Kingcurve is free software under the MIT License. Third-party components it bundles are listed in THIRD_PARTY_NOTICES.md.