Skip to content

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

@JIRBOY

Description

@JIRBOY

Motivation

Many developers use both Claude Code and Kimi Code 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 Code 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 the project config discovery logic 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 the config loading logic (previously kimi_cli/soul/agent.py::load_agents_md() in the old repo). In the new codebase, the equivalent discovery loop should be extended:

# 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 Code.
  • No breaking changes: existing AGENTS.md-only projects behave exactly the same.
  • Low effort, high compatibility value.

I have already tested a similar patch on the legacy kimi-cli package by editing the installed source, and it worked as expected — CLAUDE.md content was correctly injected into the system prompt alongside AGENTS.md.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions