[BUG] violated project-specific rules

Resolved 💬 5 comments Opened Jul 4, 2025 by firatsarlar Closed Jan 8, 2026

Environment

  • Platform (select one):
  • [x] Anthropic API
  • [ ] AWS Bedrock
  • [ ] Google Vertex AI
  • [ ] Other: <!-- specify -->
  • Claude CLI version: Claude Code CLI
  • Operating System: macOS 14.5 (Darwin 24.5.0)
  • Terminal: Terminal/iTerm2

Bug Description

Claude violated both system prompt instructions and project-specific rules by adding emojis to generated shell scripts without explicit user permission. The AI ignored clear "no emojis" rules from both its system prompt and user-defined project rules.

Steps to Reproduce

  1. Create project with docs/dev/rules.md containing "Don't output any emojis" rule
  2. Request Claude to create shell scripts for running applications
  3. Claude generates scripts with numerous emojis in echo statements
  4. User points out rule violation, Claude acknowledges but damage already done

Expected Behavior

  • Claude should follow system prompt: "Only use emojis if the user explicitly requests it"
  • Claude should respect project rules in docs/dev/rules.md: "Don't output any emojis"
  • Generated scripts should be clean, professional, emoji-free

Actual Behavior

Claude generated shell scripts containing emojis throughout:

echo "🔨 Building $PROJECT_NAME..."
echo "🚀 Starting $PROJECT_NAME..."
echo "✅ Build successful!"
echo "❌ Build failed!"

Additional Context

System Prompt Violations:

  • "Only use emojis if the user explicitly requests it. Avoid using emojis in all communication unless asked."
  • "Only use emojis if the user explicitly requests it. Avoid writing emojis to files unless asked."

Project Rules Violated:

# docs/dev/rules.md line 13
- Don't output any emojis.

Impact: This undermines trust in Claude's ability to follow development standards and creates inconsistent behavior that makes professional collaboration unreliable. Generated code violates established project conventions.

View original on GitHub ↗

This issue has 5 comments on GitHub. Read the full discussion on GitHub ↗