Feature hasn't been suggested before.
Describe the enhancement you want to request
Why this is needed (developer pain point)
Developers using or contributing to MiMo Code often want to add their own
instructions — personal preferences, temporary experiments, or local/sensitive
config (API quirks, local paths) — without modifying the project's AGENTS.md.
Editing AGENTS.md pollutes PRs and affects the whole team; maintaining a fork
just for personal instructions is overkill.
Today MiMo Code has no mechanism for personal local overrides — any custom
instruction must go into the shared AGENTS.md / CLAUDE.md. This proposes a
.local.md layer (typically gitignored) that stacks personal instructions on top
of the project's instructions without touching the original repo.
Proposed loading logic
Add a .local.md override layer in systemPaths
(packages/opencode/src/session/instruction.ts), stacked on top of the existing
main instructions (AGENTS.md / CLAUDE.md, unchanged):
- Candidates, in order:
AGENTS.local.md, CLAUDE.local.md.
- First-match-wins — only ONE is loaded: if
AGENTS.local.md exists anywhere
up the directory tree, it wins and CLAUDE.local.md is NOT loaded (mirrors
AGENTS.md > CLAUDE.md for the main files). The two never stack together.
- All ancestor matches of the winning candidate within the worktree are loaded
(via the existing fs.findUp), then the candidate loop stops.
- Gated behind the existing
MIMOCODE_DISABLE_CLAUDE_CODE_PROMPT flag.
This aligns with Claude Code's four-tier memory model, where the personal local
tier is .local.md.
tier is .local.md.
Details
- Location:
packages/opencode/src/session/instruction.ts (systemPaths).
- Draft implementation + tests ready as a PR if there's interest.
Searched open issues — none found for .local.md / AGENTS.local.md.
为什么需要(开发者刚需)
开发者在使用或向上游贡献 MiMo Code 时,经常想加入自己的指令——个人偏好、
临时实验、或本地/敏感配置(API 怪癖、本地路径)——又不想修改项目的
AGENTS.md。改 AGENTS.md 会污染 PR、影响整个团队;为个人指令单独维护 fork
又太重。
目前 MiMo Code 没有任何个人本地覆盖机制——任何自定义指令都得写进共享的
AGENTS.md / CLAUDE.md。本提议增加一个 .local.md 层(通常 gitignored),把
个人指令叠加在项目指令之上,不碰原仓库。
提议的加载逻辑
在 systemPaths(packages/opencode/src/session/instruction.ts)新增 .local.md
覆盖层,叠加在既有主指令(AGENTS.md / CLAUDE.md,不变)之上:
- 候选顺序:
AGENTS.local.md、CLAUDE.local.md。
- first-match-wins,只加载其中一个:若树上任意位置存在
AGENTS.local.md,它
胜出,CLAUDE.local.md 不加载(镜像主指令的 AGENTS.md > CLAUDE.md)。
两者不会同时叠加。
- 胜出候选在 worktree 内的所有祖先匹配都加载(复用既有
fs.findUp),随后候选
循环停止。
- 受既有
MIMOCODE_DISABLE_CLAUDE_CODE_PROMPT flag 门控。
这与 Claude Code 四层记忆模型对齐(个人本地层即 .local.md)。
实测效果
- 根目录仅有 CLAUDE.local.md
- 新增 AGENTS.local.md ,与CLAUDE.local.md同时存在

Feature hasn't been suggested before.
Describe the enhancement you want to request
Why this is needed (developer pain point)
Developers using or contributing to MiMo Code often want to add their own
instructions — personal preferences, temporary experiments, or local/sensitive
config (API quirks, local paths) — without modifying the project's
AGENTS.md.Editing
AGENTS.mdpollutes PRs and affects the whole team; maintaining a forkjust for personal instructions is overkill.
Today MiMo Code has no mechanism for personal local overrides — any custom
instruction must go into the shared
AGENTS.md/CLAUDE.md. This proposes a.local.mdlayer (typically gitignored) that stacks personal instructions on topof the project's instructions without touching the original repo.
Proposed loading logic
Add a
.local.mdoverride layer insystemPaths(
packages/opencode/src/session/instruction.ts), stacked on top of the existingmain instructions (
AGENTS.md/CLAUDE.md, unchanged):AGENTS.local.md,CLAUDE.local.md.AGENTS.local.mdexists anywhereup the directory tree, it wins and
CLAUDE.local.mdis NOT loaded (mirrorsAGENTS.md>CLAUDE.mdfor the main files). The two never stack together.(via the existing
fs.findUp), then the candidate loop stops.MIMOCODE_DISABLE_CLAUDE_CODE_PROMPTflag.This aligns with Claude Code's four-tier memory model, where the personal local
tier is
.local.md.tier is
.local.md.Details
packages/opencode/src/session/instruction.ts(systemPaths).Searched open issues — none found for
.local.md/AGENTS.local.md.为什么需要(开发者刚需)
开发者在使用或向上游贡献 MiMo Code 时,经常想加入自己的指令——个人偏好、
临时实验、或本地/敏感配置(API 怪癖、本地路径)——又不想修改项目的
AGENTS.md。改AGENTS.md会污染 PR、影响整个团队;为个人指令单独维护 fork又太重。
目前 MiMo Code 没有任何个人本地覆盖机制——任何自定义指令都得写进共享的
AGENTS.md/CLAUDE.md。本提议增加一个.local.md层(通常 gitignored),把个人指令叠加在项目指令之上,不碰原仓库。
提议的加载逻辑
在
systemPaths(packages/opencode/src/session/instruction.ts)新增.local.md覆盖层,叠加在既有主指令(
AGENTS.md/CLAUDE.md,不变)之上:AGENTS.local.md、CLAUDE.local.md。AGENTS.local.md,它胜出,
CLAUDE.local.md不加载(镜像主指令的AGENTS.md>CLAUDE.md)。两者不会同时叠加。
fs.findUp),随后候选循环停止。
MIMOCODE_DISABLE_CLAUDE_CODE_PROMPTflag 门控。这与 Claude Code 四层记忆模型对齐(个人本地层即
.local.md)。实测效果