MCP/Doc/How To/Set up with mise and Claude Code with Langgraph llms.txt
Properties
- tags
- Diataxis/How To
How To Serve LangGraph & LangChain llms-txt via MCP with mise and validate in Claude Code
Goal
Preconditions
- You have
mise≥ 2024.6 installed and configured. - Your
mise.tomlalready defines aclaudetask like:- toml
[tasks.claude] # run mise install && mise reshim before running this. description = "Run Claude Code CLI" run = "npx @anthropic-ai/claude-code $@" [tasks.claude.env] CLAUDE_CODE_USE_BEDROCK = "true" AWS_PROFILE = "bedrock" AWS_REGION = "us-east-1" ANTHROPIC_MODEL = "us.anthropic.claude-3-7-sonnet-20250219-v1:0" ANTHROPIC_SMALL_FAST_MODEL = "us.anthropic.claude-3-5-haiku-20241022-v1:0"
- You have
Node.js≥ 18 anduvxavailable (viamise'snodeplugin). - This guide assumes you already have the
uvandpythontools installed and shimmed via your home directorymise.toml, so thatuvxis available on your PATH.
- You have
Procedure
1. Add a YAML configuration for documentation sources
2. Extend
mise.tomlwith MCP tasks- Add the following to your
mise.toml:- toml
[tasks.mpc-docs] description = "Serve LangGraph & LangChain llms.txt via MCP" alias = "mcp" run = ''' uvx --from mcpdoc mcpdoc \ --yaml docs.yaml \ --transport sse \ --port ${MPCDOC_PORT:-8082} --host localhost ''' [tasks.mpc-inspect] description = "Launch MCP Inspector UI" run = "npx -y @modelcontextprotocol/inspector mise run mpc-docs"
- Add the following to your
3. (Optional) Add a local environment file
4. Other ways to customize the port for the mpc-docs task
- You can set the
MPCDOC_PORTenvironment variable for thempc-docstask in several mise-specific ways: - See mise: Setting EnvVars for more options.
- You can set the
5. Start the MCP server
6. Inspect and validate
7. Connect Claude Code to the project server
- 1. Add the MCP server to your project's
.mcp.jsonusing: - See: Claude Code Tutorials – Set up Model Context Protocol MCP (project scope)
- 2. Create a
CLAUDE.mdfile in the root of your repo with usage rules like: - 3. Run:
- 4. In Claude's terminal, run
/mcp statusand confirmlanggraph-docsis connected. Ask:
- 1. Add the MCP server to your project's
Troubleshooting
References