MoonshotAI / MoonshotAI/kimi-cli

Feature Request: Support loading CLAUDE.md alongside AGENTS.md for Claude Code compatibility

Open Beginner friendly
#2,401 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
11.4k
Forks
1.3k
Avg merge
9h 47m
Merged PRs (30d)
2

Description

Motivation

Many developers use both Claude Code and Kimi Code CLI in their workflow. Projects that have been working with Claude Code often already contain a CLAUDE.md file (or .claude/CLAUDE.md) with project-specific instructions, coding styles, and context.

Currently, Kimi CLI only discovers AGENTS.md files. This means users must either:

  • Duplicate their CLAUDE.md content into AGENTS.md, or
  • Maintain two separate config files that can easily drift out of sync.

Request

Please extend load_agents_md() in kimi_cli/soul/agent.py to also discover and merge CLAUDE.md files, using the same discovery logic as AGENTS.md:

Priority Path
1 .claude/CLAUDE.md
2 CLAUDE.md
3 claude.md

Within a single directory, CLAUDE.md and claude.md should be mutually exclusive (uppercase wins), and co-exist with any AGENTS.md in the same directory. This ensures Kimi-native configs always take precedence while still picking up existing Claude configs.

Proposed Implementation

The change is localized to kimi_cli/soul/agent.py::load_agents_md():

# Inside the directory loop, after collecting AGENTS.md candidates:
claude_dir_path = d / ".claude" / "CLAUDE.md"
claude_candidates = [d / "CLAUDE.md", d / "claude.md"]

if await claude_dir_path.is_file():
    candidates.append(claude_dir_path)
for cc in claude_candidates:
    if await cc.is_file():
        candidates.append(cc)
        break

And update the docstring + log messages accordingly.

Benefits

  • Zero-friction migration from Claude Code to Kimi CLI.
  • No breaking changes: existing AGENTS.md-only projects behave exactly the same.
  • Low effort, high compatibility value.

I have already tested this patch locally by editing the installed package, and it works as expected — CLAUDE.md content is correctly injected into the system prompt alongside AGENTS.md.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in kimi_cli/soul/agent.py at load_agents_md() and read its existing AGENTS.md discovery loop. Add the listed .claude/CLAUDE.md, CLAUDE.md, and claude.md handling while preserving uppercase precedence and coexistence with AGENTS.md, then update the docstring and log messages. Done means all supported files are merged in the stated priority order without changing AGENTS.md-only behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
cli
Issue type
Feature
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Quiet
Clarity
Clearly specified
Newbie friendliness
82/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.