10 agents 路 all agents
Connect Oh My Pi
Oh My Pi talks to Mimir over the Model Context Protocol at https://mimir.johansen.foo/mcp. The token is an API key from your Profile page in the Mimir app; export it as MIMIR_TOKEN before starting the agent.
1. Add the server
File: ~/.omp/agent/mcp.json, or .omp/mcp.json in the project
json
{ "$schema": "https://raw.githubusercontent.com/can1357/oh-my-pi/main/packages/coding-agent/src/config/mcp-schema.json", "mcpServers": { "mimir": { "type": "http", "url": "https://mimir.johansen.foo/mcp", "headers": { "Authorization": "Bearer ${MIMIR_TOKEN}" } } }}2. Verify
Ask the agent to run memory_tree. It should list the projects your token can see, or nothing at all on a fresh install - either answer proves the connection works.
3. Tell it how to behave
Paste this into the agent's rules or instructions file, once per machine.
text
You have a long-term memory store called Mimir.
At the start of a session, call memory_digest with the current repository to load what is already known.
Before answering a question about this project's conventions, call memory_search with a path_prefix (for example "conventions").
When you learn something durable - a decision, a convention, a gotcha - call memory_write with a path that says where it belongs.
One memory is one outcome: what changed, why, and the trap you hit. Not a log of what you did.
Do not store secrets, tokens or customer data.Notes
- Oh My Pi is a fork of Pi with its own plugin loader. Install the Mimir plugin with omp plugin install @mojoaar/omp-mimir to get the digest at the start of every session and the four memory tools.
- It imports MCP servers from OpenCode, Claude Code and Codex when it starts, so a machine already set up for one of those may reach Mimir without this file. Run /mcp test mimir to check.
- MCP tools appear as mcp__mimir__memory_write. The plugin adds mimir_digest, mimir_remember, mimir_search and mimir_learn, and reads MIMIR_URL, MIMIR_TOKEN and MIMIR_REPO.