mirror of
https://github.com/RooVetGit/Roo-Code.git
synced 2026-09-05 08:10:14 +00:00
docs: Document Claude Code Provider CLAUDE.md injection behavior
- Add detailed documentation explaining CLAUDE.md auto-injection - Update README with Known Issues section - Clarify this is Claude CLI behavior, not Roo-Code - Provide guidance for users about this feature Fixes #6604
This commit is contained in:
parent
8513263a67
commit
188c3d4955
2 changed files with 49 additions and 0 deletions
12
README.md
12
README.md
|
|
@ -122,6 +122,18 @@ Make Roo Code work your way with:
|
|||
|
||||
---
|
||||
|
||||
## Known Issues
|
||||
|
||||
### Claude Code Provider - CLAUDE.md Injection
|
||||
|
||||
When using the Claude Code Provider, the Claude CLI tool (as of version 1.0.62) automatically injects content from `CLAUDE.md` files if they exist in your repository root. This is a behavior of the Claude CLI tool itself, not Roo Code.
|
||||
|
||||
**Important:** If you have a `CLAUDE.md` file in your repository and are using the Claude Code Provider, its contents will be automatically included in the context sent to Claude, even without explicitly reading the file.
|
||||
|
||||
For more details, see [docs/claude-code-provider-notes.md](docs/claude-code-provider-notes.md).
|
||||
|
||||
---
|
||||
|
||||
## Local Setup & Development
|
||||
|
||||
1. **Clone** the repo:
|
||||
|
|
|
|||
37
docs/claude-code-provider-notes.md
Normal file
37
docs/claude-code-provider-notes.md
Normal file
|
|
@ -0,0 +1,37 @@
|
|||
# Claude Code Provider - CLAUDE.md Injection Notice
|
||||
|
||||
## Overview
|
||||
|
||||
When using the Claude Code Provider in Roo-Code, users may notice that the Claude CLI tool automatically injects content from `CLAUDE.md` files if they exist in the repository root. This is a behavior of the Claude CLI tool itself (as of version 1.0.62), not a feature implemented by Roo-Code.
|
||||
|
||||
## How It Works
|
||||
|
||||
1. Roo-Code integrates with the Claude CLI tool by executing it as a subprocess
|
||||
2. The system prompt is passed to the Claude CLI via:
|
||||
- `--system-prompt` flag on non-Windows systems
|
||||
- stdin on Windows systems (to avoid command length limitations)
|
||||
3. The Claude CLI tool independently checks for and injects `CLAUDE.md` content
|
||||
|
||||
## Important Notes
|
||||
|
||||
- This injection happens at the Claude CLI level, before Roo-Code receives any response
|
||||
- Roo-Code does not read or inject `CLAUDE.md` files - this is entirely handled by the Claude CLI
|
||||
- The behavior may change in future versions of the Claude CLI tool
|
||||
|
||||
## Implications
|
||||
|
||||
If you have a `CLAUDE.md` file in your repository root and are using the Claude Code Provider:
|
||||
|
||||
- The contents will be automatically included in the context sent to Claude
|
||||
- This happens transparently without explicit indication in the Roo-Code interface
|
||||
- The AI will be aware of the `CLAUDE.md` contents even without using file reading tools
|
||||
|
||||
## Recommendations
|
||||
|
||||
- Be aware that `CLAUDE.md` files are automatically injected when using Claude Code Provider
|
||||
- If you don't want this behavior, avoid naming files `CLAUDE.md` in your repository root
|
||||
- This behavior is specific to the Claude Code Provider and does not affect other API providers
|
||||
|
||||
## Reference
|
||||
|
||||
This behavior was reported in [Issue #6604](https://github.com/RooCodeInc/Roo-Code/issues/6604).
|
||||
Loading…
Add table
Reference in a new issue