Skip to content

Anthropic models ignore Custom Instructions #8892

@dvpadmin

Description

@dvpadmin

Description

The Custom Instructions feature documented at https://opencode.ai/docs/rules/#custom-instructions does not work with Anthropic models.
From docs:

"You can specify custom instruction files in your opencode.json [...] This allows you and your team to reuse existing rules rather than having to duplicate them to AGENTS.md."

"All instruction files are combined with your AGENTS.md files."

Expected behavior

Files specified in instructions array are automatically combined with AGENTS.md and included in the LLM context. The model should follow these rules.

Actual behavior

Anthropic models (Claude Sonnet 4.5, Opus 4.5, Haiku 4.5) completely ignore content from instructions array. The same configuration works correctly with OpenAI and Groq models.

Reproduction

// opencode.json
{
  "$schema": "https://opencode.ai/config.json",
  "instructions": ["my-rules.md"]
}
  1. Add any rule to my-rules.md
  2. Start opencode, select Anthropic model
  3. Ask a question where the rule should apply
  4. Rule is ignored
    Switch to OpenAI/Groq → rule is applied.
    Environment
  • opencode v1.1.21
  • macOS
  • Tested with multiple Anthropic models

Metadata

Metadata

Assignees

Labels

No labels
No labels

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