
Loki Mode MCP Server: Setup for Claude, Cursor and Other Apps
Lets Claude or Cursor start and track autonomous Loki coding runs, and search the project memory and code Loki builds up.
Loki Mode is a command-line tool that builds software from a spec with several AI agents. Its built-in MCP server lets Claude, Cursor and other assistants start a run, follow its status, verify its receipt, and search the memory and code index Loki keeps in your project. It runs on your computer and needs no account. The tools that start runs can edit your files and run commands, so point them at a repo you can roll back. The license is BUSL-1.1, which is source-available and not open source.
Good for
- Developers who want an assistant to hand a task or issue to Loki and check on it later
- Teams that want a signed receipt proving what a coding run changed
- People who want assistant memory and code search that persist in the repo
Works in
12 should work
Tap an app to see how to set it up and any known problems.
Supports local MCP servers.
Supports local MCP servers.
Supports local MCP servers.
Supports local MCP servers.
Supports local MCP servers.
Supports local MCP servers.
Supports local MCP servers.
Supports local MCP servers.
Supports local MCP servers.
Supports local MCP servers.
Supports local MCP servers.
Supports local MCP servers.
Client does not support this transport.
Client does not support this transport.
Install loki-mode MCP
Claude Code
- 1
Copy this prompt.
Add the loki-mode MCP server to Claude Code. Run this command: claude mcp add loki-mode -- npx -y loki-mode mcp Then check that it loaded and tell me if I need to sign in or restart.
- 2
Paste it into Claude Code. It shows the change and asks before running it.
Requires Node.js, Python 3 (first run builds a venv).
Read-only mode: Add --read-only after mcp in the command (or set LOKI_MCP_READ_ONLY=1). Only 24 read tools stay.
The command needs the mcp subcommand after the package name. The first run offers to create a .loki/mcp-venv folder and pip install the Python packages; run npx -y loki-mode mcp once in a terminal and say yes, or set LOKI_MCP_AUTO_BOOTSTRAP=1 for apps with no terminal. The README gives the Cursor and VS Code one-click links; other apps use the same command, adapted by us.
Built from the package data we hold. Not yet tested by us.
Tools
Shows project progress, agent activity and task counts
Gives the broad picture of the current Loki project: where it is in its work cycle, what the agents are doing and how many tasks are done.
Try: “How far along is the Loki project?”
Read ·
loki_project_statusShows the current phase and whether Loki is running
Reads the .loki folder for the current phase, autonomy state and whether project memory exists.
Try: “What phase is Loki in right now?”
Files ·
loki_state_getChecks how a background Loki run is going
Reads a run's event log and reports its phase, verdict and cost so far. Use it after starting a run.
Try: “Check the status of the latest Loki run in this repo.”
Files ·
loki_v10_statusShows review scores, verdicts and test coverage
Returns the quality gate results for the project, including blind review scores, council verdicts and test coverage.
Try: “Show the quality report for this project.”
Read ·
loki_quality_reportLists the code-review findings from one round
Reads the structured review findings for one iteration, newest by default.
Try: “List the review findings from the last iteration.”
Read ·
loki_findingsLists lessons Loki recorded earlier
Reads the most recent entries from the learnings file, newest first, so past mistakes are not repeated.
Try: “What did Loki learn recently?”
Read ·
loki_learningsStarts a Loki build run in the background
Starts the same engine as the loki command for a task text or issue reference, inside a repo you name. It runs in the background and can change files in that repo.
Try: “Use Loki to implement issue 42 in /Users/me/app.”
Runs code ·
loki_v10_runRe-checks the receipt of a finished run
Runs loki verify on a receipt file, or on the newest run in a repo, to confirm the run's proof still holds.
Try: “Verify the receipt of the last Loki run.”
Runs code ·
loki_v10_verifyTurns your own edits into a signed Loki receipt
Takes changes you already made in a repo and a short statement of intent, then produces the same verified receipt a Loki run gives. It starts a Loki process that can take up to 30 minutes by default.
Try: “Seal my current diff in /Users/me/app with the intent "fix login redirect".”
Runs code ·
loki_seal_diffChecks a repo or diff in milliseconds, no AI call
Runs Loki's built-in deterministic checks on a repo or on its changes against a git ref. The tool says it makes no model call and no network call.
Try: “Run the fast verify on my changes against main.”
Runs code ·
loki_verify_fastStarts a Loki project from a product spec
Initializes a Loki project from a PRD you paste in or point to by path, and begins the work.
Try: “Start a Loki project from docs/prd.md.”
Runs code ·
loki_start_projectLists queued tasks with status and priority
Shows every task in Loki's task queue before you add or change one.
Try: “What tasks are in the Loki queue?”
Read ·
loki_task_queue_listAdds a task to the queue
Queues new work with a title, description, priority and phase of the software cycle.
Try: “Queue a task to add rate limiting, high priority.”
Write ·
loki_task_queue_addChanges a task's status or priority
Updates the status or priority of a task that is already queued.
Try: “Mark task 7 as in progress.”
Write ·
loki_task_queue_updateDeclares the whole task or spec finished
Tells the orchestrator the PRD or task is done and verified, so it stops looping.
Try: “Mark the project complete.”
Write ·
loki_complete_taskLists checkpoints or rolls the project back to one
With no ID it lists checkpoints. With an ID it restores project state from that checkpoint, which changes the project.
Try: “List Loki checkpoints, then restore the second one.”
Write ·
loki_checkpoint_restorePulls memories relevant to the task at hand
Finds stored memories ranked for the type of task you are about to do. Use it at the start of work.
Try: “Fetch the memories relevant to fixing a flaky test.”
Read ·
loki_memory_retrieveSearches stored memory by keyword
Fast full-text search across all memory types with AND, OR, NOT and prefix matching.
Try: “Search memory for "oauth redirect".”
Read ·
mem_searchShows recent memory in time order
Lists recent actions, decisions and episodes, or the entries around one memory item.
Try: “What happened in the last few sessions?”
Read ·
mem_timelineOpens full memory entries by ID
Fetches the complete details of entries you found through search or the timeline.
Try: “Open memory entries a12 and b34.”
Read ·
mem_getSaves a lesson for later sessions
Stores a reusable pattern with its correct and incorrect approach so later sessions can retrieve it.
Try: “Remember: always run migrations before seeding.”
Write ·
loki_memory_store_patternRecords what this session did
Stores an episode for the current agent session in project memory. It is meant to be called once when an iteration ends.
Try: “Save a summary of this session to memory.”
Write ·
loki_memory_capture_session_summaryDistills recent episodes into patterns
Runs memory consolidation to extract lasting patterns from recent episodes.
Try: “Consolidate the last 48 hours of memory.”
Write ·
loki_consolidate_memoryFinds code by what it does
Searches the code index by meaning, for when you know what the code does but not its name. Its description says it searches the loki-mode codebase.
Try: “Find where retries are handled.”
Files ·
loki_code_searchShows how big and fresh the code index is
Returns counts of indexed chunks and files, by language and type, so you can tell whether the index is up to date.
Try: “Is the code search index up to date?”
Read ·
loki_code_search_statsAnswers structure questions from a knowledge graph
Answers questions such as what calls what or what depends on what, without reading every file.
Try: “What depends on the billing module?”
Files ·
loki_graph_queryLists the files that change most often
Uses git history to find the most frequently changed files, where extra care is useful.
Try: “Which files change the most in this repo?”
Runs code ·
loki_get_hotspotsFinds files that change together with a given file
Uses git history to show which files usually change in the same commits as the one you name.
Try: “What usually changes together with src/auth.ts?”
Runs code ·
loki_get_co_changesShows which files lack or have stale docs
Reads the docs manifest and reports documented, undocumented and stale files.
Try: “Where is documentation missing?”
Read ·
loki_get_doc_coverageShows token use and efficiency for this session
Reports how many tokens and tool calls this session has used, with ratios that show how efficiently it is working.
Try: “How many tokens has this session used?”
Read ·
loki_metrics_efficiencyCompares agents on tokens, completion and time
Breaks down tokens, finished tasks and timing for each Loki agent so you can see which ones cost the most.
Try: “Which Loki agent is the most expensive?”
Read ·
loki_agent_metricsMakes a template to dispute review findings
Generates a pre-filled file for one iteration so you can argue against Critical and High findings.
Try: “Make a counter-evidence template for iteration 3.”
Write ·
loki_counter_evidence_templateSearches runs across all repos in the Control Plane
Finds runs by verdict, repo, date range or group. It only reads, and needs a Loki Control Plane URL set in the environment.
Try: “Find failed runs from last week.”
Network ·
cp_runs_searchShows one run's verdict, cost and stages
Returns a single run's verdict, cost, stages and receipt summary from the Control Plane.
Try: “Show details of run e10-abc.”
Network ·
cp_run_getPages through a run's event log
Reads a run's events in order, page by page. The text is treated as untrusted data.
Try: “Show the first 50 events of run e10-abc.”
Network ·
cp_run_eventsReads a file saved by a run
Reads one allowed run file, such as receipt.json or diff.patch.
Try: “Open the diff.patch from run e10-abc.”
Network ·
cp_run_artifactCompares two runs side by side
Shows verdicts, costs, tokens and the cost difference between two runs.
Try: “Compare run A and run B.”
Network ·
cp_runs_compareShows run totals across all repos
Returns counts and verdict totals for every repo the Control Plane knows.
Try: “Give me run stats since October 1.”
Network ·
cp_statsShows spend grouped by day or repo
Returns cost grouped by a dimension the Control Plane supports, such as day or repo.
Try: “Show Loki cost per repo this month.”
Network ·
cp_costLists repo names the Control Plane knows
Returns display names only, no paths, so you can filter other searches.
Try: “Which repos does the Control Plane track?”
Network ·
cp_repos_listRedacts secrets from managed memory
Overwrites stored managed-memory versions whose content matches a pattern you give. It only works when managed memory is enabled.
Try: “Redact anything matching "sk-live-.*" from managed memory.”
Delete ·
loki_memory_redactCreates a UI component from a description
Generates a new React or web component from a plain-language description and can place it at a path you give.
Try: “Generate a pricing-card component for React.”
Runs code ·
loki_magic_generateLists or searches generated components
Lists registered components, filtered by name, tags or target.
Try: “List my React components tagged "form".”
Read ·
loki_magic_listShows details of one component
Fetches the details of a named component from the registry.
Try: “Show the pricing-card component.”
Read ·
loki_magic_getRegenerates a component after its spec changed
Updates a component, regenerating it when the spec has changed or when you force it.
Try: “Regenerate pricing-card with the new spec.”
Runs code ·
loki_magic_updateHas several personas critique a component
Runs a multi-round debate between personas on an existing component and returns critiques and any refined version.
Try: “Run a 3-round debate on pricing-card.”
Runs code ·
loki_magic_debatePulls design tokens from your code
Reads the codebase for colors, spacing and typography without changing the component registry.
Try: “Extract the design tokens from this codebase.”
Files ·
loki_magic_tokens_extractShows component registry numbers
Returns total components, counts per target and the debate pass rate.
Try: “How many components are registered?”
Read ·
loki_magic_stats
Read from the source code
Permissions
high risk · 4 things to watch
High risk
It can start autonomous coding runs that change files in your repo, restore checkpoints and redact memory. Use a clean git branch, or start the server read-only so only 24 read tools stay.
What it can do
- Read your data
- Create and change things
- Delete things
- Read-only modeHow to turn it on
Watch out for
It can start coding runs that edit your repo
The run and project tools launch Loki, which builds software and runs commands in the repo you name. Use a clean git branch, or turn on read-only mode. github.com
It can roll back state and redact memory
Restoring a checkpoint changes project state, and the redact tool overwrites matching managed-memory versions. Check the ID or pattern before approving. github.com
First run installs Python packages
On first launch Loki offers to create a .loki/mcp-venv folder and pip install the packages in requirements.txt. Apps without a terminal need LOKI_MCP_AUTO_BOOTSTRAP=1 to allow it. github.com
HTTP mode has no password by default
The optional HTTP mode listens only on 127.0.0.1, with no sign-in unless LOKI_MCP_AUTH_TOKEN is set. Stdio, the default, opens no port. github.com
Security advisories
No published security advisories as of Nov 1, 2026.
Technical details
| Turning on read-only | Start the server with --read-only (or set LOKI_MCP_READ_ONLY=1). Only 24 read tools stay: 16 for memory, status, search and review data, plus 8 Control Plane read tools. |
|---|---|
| Talks to | Loki Control Plane URL, only if you set LOKI_CP_URL or LOKI_CONTROL_URL |
| Sign-in and keys | No sign-in. The server reads the environment of the app that starts it. |
Questions
Is the Loki Mode MCP server official?
It is the project's own server, built into Loki Mode and published in the same npm package, not a third-party wrapper. Autonomi, Inc. holds the license. We do not mark it as an official vendor listing because the repository sits under a personal GitHub account.
Is Loki Mode open source?
No. It uses the Business Source License 1.1, which is source-available. Personal, non-commercial, internal-business and academic use are allowed, and offering it to third parties as a product needs a different license. Read the license file before commercial use.
Does it need an API key?
No key is needed for the MCP server itself. Loki runs on your machine and may call AI services with credentials already in your environment. The Control Plane tools also need a URL, and usually a token, in the environment.
Can I run it read-only?
Yes. Add --read-only after the mcp subcommand, or set LOKI_MCP_READ_ONLY=1. That leaves 24 read tools and removes everything that starts runs or writes.
Does it run locally or in the cloud?
Locally. It starts as a local process over stdio, and an optional HTTP mode binds only to 127.0.0.1.
Why does it ask to install Python packages?
The server is written in Python. On first run Loki offers to create a project-local virtual environment and install the packages it needs. In an app with no terminal, set LOKI_MCP_AUTO_BOOTSTRAP=1 or run the command once in a terminal first.
How many tools does it have?
48 in the published package: 32 core tools, 8 for the Control Plane, 7 for UI components and 1 for memory redaction. The tool list above shows all of them.
Information
updated Nov 2, 2026
- Publisher
- Community
- Package
loki-mode- Registry
- npm
- Transport
- stdio, Streamable HTTP
- Auth
- None
- Version
- 10.9.1
- License
- BUSL-1.1
- Last commit
- Oct 31, 2026
- Open issues
- 184
- Listed in
- Official MCP registry
Sources
Docs, issue trackers and discussions this page is built from. Issues, quotes and findings above link to their own source.
Show all 6Hide
- github.com · github.com
- github.com · github.com
- github.com · github.com
- github.com · github.com
- github.com · github.com
- github.com · github.com