Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions src/kimi_cli/soul/agent.py
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,10 @@ async def load_agents_md(work_dir: KaosPath) -> str | None:
kimi_path = d / ".kimi" / "AGENTS.md"
# AGENTS.md and agents.md are mutually exclusive (uppercase wins)
root_candidates = [d / "AGENTS.md", d / "agents.md"]
# .claude/CLAUDE.md — Claude project-local config (for Claude Code compatibility, #2401)
claude_kimi_path = d / ".claude" / "CLAUDE.md"
# CLAUDE.md and claude.md are mutually exclusive (uppercase wins)
claude_candidates = [d / "CLAUDE.md", d / "claude.md"]

candidates: list[KaosPath] = []
if await kimi_path.is_file():
Expand All @@ -120,6 +124,12 @@ async def load_agents_md(work_dir: KaosPath) -> str | None:
if await rc.is_file():
candidates.append(rc)
break
if await claude_kimi_path.is_file():
candidates.append(claude_kimi_path)
for cc in claude_candidates:
if await cc.is_file():
candidates.append(cc)
break

for path in candidates:
content = (await path.read_text()).strip()
Expand Down
Loading