Skip to content

[MODEL] Instructions in @-included files acknowledged but not reliably followed #34043

@clouatre

Description

@clouatre

Preflight Checklist

  • I have searched existing issues for similar behavior reports
  • This report does NOT contain sensitive information (API keys, passwords, etc.)

Type of Behavior Issue

Claude ignored my instructions or configuration

What You Asked Claude to Do

~/.claude/CLAUDE.md includes @~/.claude/AGENTS.md and states "Follow all rules in AGENTS.md above." The model confirms it sees AGENTS.md content when asked.

What Claude Actually Did

Instructions defined inline in CLAUDE.md are consistently followed. Identical instructions in @-included files are selectively ignored under the same conditions. Moving an instruction verbatim from AGENTS.md into CLAUDE.md improves compliance immediately, with no other change.

Observed examples (both instructions were already in AGENTS.md before being added to CLAUDE.md):

  • "Always branch from origin/<target>" — ignored from AGENTS.md; followed after adding to CLAUDE.md
  • "NEVER add Co-Authored-By trailers referencing Claude or Anthropic" — ignored from AGENTS.md; followed after adding to CLAUDE.md

Expected Behavior

Instructions in @-included files should carry the same authority as inline instructions, especially when the including file explicitly states they must be followed.

Permission Mode

Accept Edits was ON (auto-accepting changes)

Can You Reproduce This?

Yes, every time with the same prompt

Claude Model

Sonnet 4.6

Claude Code Version

2.1.74 (Claude Code)

Platform

AWS Bedrock

Additional Context

Related: #28158, #29236, #19471

Metadata

Metadata

Assignees

No one assigned

    Labels

    duplicateThis issue or pull request already exists

    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