[KongchangAI]
Concept

CLAUDE.md

CLAUDE.md is a project-level context configuration file for the Claude AI coding assistant, typically placed in the root directory of a code repository. Written in Markdown format, the file is used to provide Claude with project background, technical specifications, coding conventions, and specific instructions, enabling it to follow project-specific rules and context during code generation and development assistance, thereby improving collaboration efficiency and output quality.

Core Facts

Timeline (last 90 days)

Oct 13

In herdr, the main Claude Code session can automatically hand mechanical work to Codex based on routing rules in CLAUDE.md, open a Codex pane, wait for its status without polling, and stop to ask the user when Codex hits an approval prompt.

Unverified50%
Oct 12

CLAUDE.md is a description file placed in the project root directory; the Agent automatically reads it at startup to inject the project structure, coding standards, and points to note.

Unverified50%
Oct 12

OpenCode V2 only reads AGENTS.md and is completely incompatible with CLAUDE.md; even putting CLAUDE.md into the instructions setting will not cause it to be loaded.

Unverified50%
Oct 11

Markdown files (such as CLAUDE.md) are loaded once at the start of a session and then frozen, making them snapshots rather than memory.

Unverified50%
Oct 11

Anthropic's official cost-reduction article recommends running a prompt audit command on instruction files (such as CLAUDE.md) and reports that removing redundant patterns reduces costs by an additional approximately 9%.

Unverified50%
Oct 11

The author's standing prefix (containing CLAUDE.md rules, skill descriptions, and tool instructions) has a median of 81,000 tokens, accounting for only 3.2% of the main thread's cache writes.

Unverified50%
Oct 11

Keeping CLAUDE.md concise and migrating large workflows to Skills can reduce the baseline context size for everyday conversations.

Unverified50%
Oct 11

A lean CLAUDE.md configuration sends 16,500 tokens, while a bloated version (356-line CLAUDE.md, 20 skills, 3 MCP servers) sends 21,500 tokens per message.

Unverified50%
Oct 7

In software engineering community practice, files such as agents.md or CLAUDE.md are placed in the root directory of a code repository to provide AI coding agents with project-level context and behavioral specifications.

Unverified50%
Oct 7

In the rules-guard hook, if Jev is at least 80% confident that a rule has been violated, the edit is directly blocked and Claude is informed which rule was violated.

Unverified50%

40 more timeline events

All Facts (20)

Verified

The core carrier of Claude Code's Skills is the CLAUDE.md file, placed in the project root directory or a specific directory.

90%
Verified

The design inspiration for CLAUDE.md comes from the concept of project-level configuration files such as .editorconfig and .eslintrc

80%
Verified

Claude Code supports multi-level CLAUDE.md instruction files, including three levels: global (~/.claude/CLAUDE.md), project root directory, and subdirectory.

80%
Verified

Claude Code's memory system is divided into three levels: session memory (short-term), project memory (via the CLAUDE.md configuration file), and global memory (cross-project user preferences).

80%
Verified

CLAUDE.md是Anthropic推出的Claude Code所支持的一种项目级配置文件

80%
Verified

CLAUDE.md supports multi-level configuration: the CLAUDE.md in the project root directory applies to the entire project, those in subdirectories can override or supplement higher-level configurations, and a global CLAUDE.md can be placed in the user's home directory.

80%
Verified

CLAUDE.md文件让Claude Code在每次启动时自动读取项目规范,实现跨会话的记忆功能

80%
Verified

Claude Code 的 /init 指令可以扫描当前项目的文件结构并自动生成一份适合该项目的 CLAUDE.md

80%
Verified

AGENTS.md is a common naming convention that has emerged in the AI programming tools ecosystem, and tools such as OpenAI Codex and Cursor also recognize this file to varying degrees.

80%
Verified

AI programming assistant configuration files (such as CLAUDE.md and .cursorrules) are essentially an engineering practice of prompt engineering, solidifying scattered prompts into standardized files that can be version-controlled and shared across teams.

75%
Verified

CLAUDE.md is Claude Code's persistent system prompt mechanism, which automatically injects the file's contents to the very front of the context at startup.

70%
Verified

The contents of CLAUDE.md are appended to the prompt, becoming the contextual foundation for every conversation.

65%
Verified

As a project file, CLAUDE.md can be incorporated into the Git version control system, allowing team members to review and iterate on specification content via Pull Requests.

65%
Verified

Claude Code uses the CLAUDE.md file as its memory file, and Cursor uses the .cursorrules file.

65%
Verified

Claude Code's command files can be incorporated into a Git repository for version management, allowing team members to share the same set of workflows.

65%
Verified

The claude.md file is the core configuration file for Claude Code projects and should include the tech stack, project structure, code style conventions, and prohibited items.

65%
Unverified

CLAUDE.md是Claude在每个会话开始时自动读取的上下文文件,根文件提供全局视图,子目录文件提供本地约定

95%
Unverified

文章提出 CLAUDE.md 的六段式结构包括:项目概述、功能要求、技术栈、项目目录结构、代码规范、约束条件

95%
Unverified

Anthropic设计了CLAUDE.md的分层配置体系,支持项目根目录、子目录和用户主目录三个层级

90%
Unverified

作者建议将 CLAUDE.md 控制在 500 字以内,只保留真正影响行为的核心规则

90%

Source Articles