subforge-mcp
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@subforge-mcpWhich models are currently loaded in LM Studio?"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
subforge-mcp
An MCP (Model Context Protocol) server that lets AI clients talk to models running locally in LM Studio — list what's loaded, chat with per-session history, and (with user consent) load a downloaded model into memory.
Install
Requires LM Studio running locally with its local server started (LM Studio → Developer → Start Server).
Claude Code:
claude mcp add subforge -- npx -y subforge-mcpClaude Desktop / VS Code (mcp.json):
{
"mcpServers": {
"subforge": {
"type": "stdio",
"command": "npx",
"args": ["-y", "subforge-mcp"]
}
}
}Related MCP server: LM Studio MCP Server
Configuration
Variable | Default | Notes |
|
| Base URL of the LM Studio local server (REST + WebSocket) |
MCP Tools
Tool | Description |
| List models currently loaded into memory in LM Studio |
| Send a message to a loaded model; keeps per- |
| Load a downloaded-but-unloaded model into memory — requires client elicitation support and explicit user consent |
| Unload a currently-loaded model from memory — the counterpart to |
| Clear conversation history for a session (or all sessions) |
| Delegate a mechanical, bounded coding task (rename, find/replace) to a local model running its own read/list/edit-file loop against |
chat and load_model never implicitly load a model: chat refuses if the
requested model isn't already loaded, and load_model is the only tool that
can bring one into memory, gated behind an MCP elicitation prompt. unload_model
is exempt from that gate by design — freeing memory is low-risk and reversible
(load the model again any time), so it doesn't ask for consent.
Delegating tasks to a local model
delegate_task hands a small, mechanical, multi-step coding task (a variable
rename, a boring find/replace, a boilerplate first draft) to a local LM
Studio model, which runs its own read → edit → read → done loop directly
against the filesystem. File contents and the tool back-and-forth never enter
the calling conversation — only a short final summary does — which is what
makes this worth using: rote, bounded edits that would otherwise burn context
reading and re-writing file contents happen entirely on the local model's
side.
Safety model. The local model gets exactly three tools — list_dir,
read_file, edit_file — all resolved through safeResolvePath, which
refuses any path that would resolve outside the caller-supplied dir. There
is no shell/Bash tool in its loop, ever. edit_file is a search-and-replace
(exactly one match of old_string required), not a whole-file overwrite, so
a bad or ambiguous edit fails loudly and leaves the file untouched instead of
silently clobbering it. It also cannot create new files.
Reliability caveat. Local models are much weaker than Claude — think "fast and free but low-reliability," not a peer. They're fine for boilerplate, renames, and simple mechanical transforms; they are not a good fit for anything requiring cross-file understanding, nuanced judgment, or high-stakes/hard-to-verify correctness. Always review the returned summary before trusting it.
Speed tip. For reasoning models (e.g. Qwen3) doing simple mechanical
tasks, the "thinking" pass before each tool call adds latency with little
quality benefit. The think: false input tries a best-effort
chat_template_kwargs: { enable_thinking: false } passthrough on each
request, but this isn't guaranteed to be honored — the reliable lever is
disabling it directly in LM Studio's Jinja prompt template (add
{%- set enable_thinking = false %} at the top of the template, editable
under that model's settings in LM Studio).
Development
pnpm install
pnpm run build # compile TypeScript to dist/
pnpm test # run the test suite (node:test)
pnpm run typecheck # type-check src/ + tests/
pnpm run lint # oxlint (type-aware)Project structure
subforge-mcp/
├── src/
│ └── index.ts # server + tool registrations
└── tests/
├── helpers.ts # fetch/extra mocks shared by tests
└── *.test.tsReleases
This project is trunk-based: every change lands on main via a squash-merged
pull request titled as a Conventional Commit
(feat: ..., fix: ..., feat!: ..., etc.). Merging to main triggers
semantic-release,
which determines the next version from commit history, updates
CHANGELOG.md, tags a GitHub release, and publishes to npm.
License
This server cannot be deployed
Maintenance
Related MCP Connectors
LLM chat, text tools, image generation, editing, batch image jobs, and asynchronous video generation
- QuallaaOAuthcom.quallaa
Talk to your public-facing AI from any MCP client — Claude, ChatGPT, Cursor, Cline, Windsurf.
A comprehensive Model Context Protocol (MCP) server that enables AI assistants to interact with yo…
List, configure, chat with, analyse and embed your Echo AI assistants.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceEnables interaction with locally running Ollama models through chat, generation, and model management operations. Supports listing, downloading, and deleting models while maintaining conversation history for interactive sessions.407 npmMIT
- AlicenseAqualityDmaintenanceEnables AI assistants to manage LM Studio models, including listing, loading, and unloading models through the LM Studio API.614 npm4ISC
- AlicenseAqualityDmaintenanceEnables listing, loading, unloading, and configuring models in LM Studio via MCP tools, with support for TTL and draft model settings.56MIT
- FlicenseCqualityDmaintenanceEnables MCP clients to interact with local LLMs via LM Studio, supporting dynamic chat, vision, RAG, file interaction, and model orchestration.28-