Skip to main content
MCP server CX Codex

lm — Claude Code MCP server: what it does, how to install

This MCP server routes selected coding tasks to a local or hosted model through an OpenAI-compatible endpoint. Use it for reviews, drafts, and bounded background work.

Install into Claude Code · Platform CLI All methods and platforms ↓
claude mcp add --env HOUTINI_LM_ENDPOINT_URL=<HOUTINI_LM_ENDPOINT_URL> --env HOUTINI_LM_API_KEY=<HOUTINI_LM_API_KEY> --env HOUTINI_LM_MODEL=<HOUTINI_LM_MODEL> --env HOUTINI_LM_PROVIDER=<HOUTINI_LM_PROVIDER> --transport stdio lm -- npx -y @houtini/lm
Open on GitHub

What lm does

lm gives Claude Code and other MCP clients a path to local models, OpenAI, LiteLLM, OpenRouter, or another endpoint that follows the OpenAI API shape. The main agent can keep planning and tool use while the server sends a chosen task elsewhere. When code_task_files is used, the houtini-lm process reads the files and returns the other model’s result without placing those files in the main agent’s context.

Typical delegated jobs include code review, test scaffolding, docstrings, commit messages, format conversion, and regex checks. Configuration uses HOUTINI_LM_ENDPOINT_URL, HOUTINI_LM_API_KEY, HOUTINI_LM_MODEL, and HOUTINI_LM_PROVIDER, with the server started by npx -y @houtini/lm. Local inference can take 3-30 times longer than a frontier model, so the setup fits contained jobs better than every turn of a coding session.

What it helps with

  • send selected files to a second model for review
  • draft test stubs and type definitions
  • prepare commit messages or changelog text
  • convert content between formats
  • sanity-check a regular expression

Example prompts for the agent

  • Send src/auth.ts and src/session.ts to the MCP server for a code review, then list the issues found.
  • Ask the delegated model to draft tests for src/parser.ts and show me the result.
  • Have the other model inspect this regular expression and explain the edge cases it finds.

How to install lm

Platform CLI

claude mcp add --env HOUTINI_LM_ENDPOINT_URL=<HOUTINI_LM_ENDPOINT_URL> --env HOUTINI_LM_API_KEY=<HOUTINI_LM_API_KEY> --env HOUTINI_LM_MODEL=<HOUTINI_LM_MODEL> --env HOUTINI_LM_PROVIDER=<HOUTINI_LM_PROVIDER> --transport stdio lm -- npx -y @houtini/lm

Replace <…> with your own values

Step by step, with commands for each platform: How to add an MCP server to Claude Code, Codex, Cursor, VS Code, Gemini CLI and more

Questions about lm

How do I install lm in Claude Code?

Run claude mcp add lm -e HOUTINI_LM_API_KEY=<HOUTINI_LM_API_KEY> -- npx -y @houtini/lm. This registers the MCP server with an API key.

What does lm do?

It routes bounded work from Claude Code or another MCP client to a selected local or hosted model. The main agent receives the response and continues the task.

What does the model connection require?

A full setup uses HOUTINI_LM_ENDPOINT_URL, HOUTINI_LM_API_KEY, HOUTINI_LM_MODEL, and HOUTINI_LM_PROVIDER. The endpoint needs an OpenAI-compatible API.

Similar MCP servers

All MCP servers for Agent setup: memory, context, orchestration →

Project sponsors

Companies that keep this analytics open
Gold sponsor

Impressions, clicks and code copies — open statistics. We keep the numbers public for the same reason NeBlask itself is public. Become a sponsor