Claude ignores CLAUDE.md and memory files — generates responses before reading stored instructions
Preflight Checklist
- [x] I have searched existing issues for similar behavior reports
- [x] This report does NOT contain sensitive information (API keys, passwords, etc.)
Type of Behavior Issue
Claude modified files I didn't ask it to modify
What You Asked Claude to Do
Problem
When a specific string (e.g., a launch command) is stored in CLAUDE.md, auto-memory files, AND a custom skill file, Claude still generates the answer from its own reasoning instead of reading the file first. This has been corrected 50+ times across many sessions — the same mistake repeats every time.
What I stored
The exact bot launch command in three places:
CLAUDE.mdin the project root- Auto-memory file
feedback_bot_path.md(marked as CRITICAL, ABSOLUTE RULE) - A custom skill
bot-launch/SKILL.md
What Claude does
Every time I ask "give me the launch command" or "restart the bot":
- Claude generates a WRONG command from memory (e.g.
~/sui-arb-botinstead of the correct path) - I correct it
- Claude apologizes, reads the file, gives the right answer
- Next message or next session — same wrong answer again
Root cause
Claude does not read CLAUDE.md or memory files BEFORE generating a response. It generates first, then (only if prompted) reads the file and self-corrects. Writing the instruction to more places does not help because Claude doesn't consult them before answering.
Additional issues
- Session context is very short — Claude forgets instructions given 20 minutes earlier within the same conversation
- Even after I asked Claude to fix this, it wrote the command to CLAUDE.md, memory, and a skill — then immediately output the wrong command in the very next message
- This makes persistent configuration completely unreliable for any workflow that depends on exact strings
Expected behavior
When a user asks for something that matches a stored instruction in CLAUDE.md or memory, Claude should READ the file first, then respond — not the other way around.
Environment
- Claude Desktop / Cowork mode
- Claude Opus 4.6
- macOS
What Claude Actually Did
- I stored the exact bot launch command in CLAUDE.md, auto-memory file, and a custom skill
- I asked Claude "give me the command to restart the bot"
- Claude generated a wrong command from its own reasoning (wrong path: ~/sui-arb-bot)
- I corrected it — Claude apologized, read the file, gave the right answer
- Next message — same wrong command again
- This repeated 50+ times across multiple sessions
- Even within a single session, Claude forgot the command given 20 minutes earlier
- Claude itself wrote the command to CLAUDE.md, then immediately output the wrong version
Expected Behavior
Claude should have:
- Read CLAUDE.md BEFORE generating any response
- Found the stored launch command
- Output the exact string verbatim: cd ~/Documents/Claude/Projects/Arbitrage\ bot/sui-arb-bot && python3 -m bot.main
- Not attempted to reconstruct or shorten the path from its own reasoning
Files Affected
Files that contain the correct command (all ignored by Claude before responding):
- CLAUDE.md (project root — loaded automatically)
- .auto-memory/feedback_bot_path.md (persistent memory — marked CRITICAL)
- .claude/skills/bot-launch/SKILL.md (custom skill)
No files were modified incorrectly — the problem is that Claude does not READ these files before generating a response.
Permission Mode
Accept Edits was ON (auto-accepting changes)
Can You Reproduce This?
Yes, every time with the same prompt
Steps to Reproduce
- Create a project with CLAUDE.md containing an exact command string (e.g. a specific launch path)
- Open a new Cowork session in that project
- Ask Claude "give me the launch command"
- Claude will generate its own version instead of reading CLAUDE.md first
- Correct Claude — it will read the file and apologize
- Wait 10-20 minutes, ask again — Claude will output the wrong command again
Claude Model
Sonnet
Relevant Conversation
The memory file literally says:
"CRITICAL — the ONLY correct launch command for the arb bot. User corrected this 25+ times. NEVER deviate."
"ALWAYS copy the command above VERBATIM — no changes, no shortcuts"
Despite this, Claude generated: "cd ~/sui-arb-bot && python -m bot.main" and "pkill -f python && cd ~/sui-arb-bot && python -m bot.main" — completely ignoring the stored instruction.
Core issue: CLAUDE.md and memory files are not consulted BEFORE response generation. Claude generates first, reads later (only if user pushes back). This architectural pattern makes all persistent instructions unreliable.
Impact
Critical - Data loss or corrupted project
Claude Code Version
Opus 4.6
Platform
Anthropic API
Additional Context
_No response_
This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗