AGENTS.md seems to be ignored by Opus in v1.1.48 #8184

Closed
opened 2026-02-16 18:09:22 -05:00 by yindo · 1 comment
Owner

Originally created by @dmcneil on GitHub (Jan 31, 2026).

Originally assigned to: @thdxr on GitHub.

Description

My AGENTS.md seems to be included in the system prompt/context up until v1.1.48. It doesn't seem to be all Anthropic models, just Opus. I should also note that I am using the GitHub Copilot provider.

Plugins

None

OpenCode version

1.1.48

Steps to reproduce

  1. Verify you are running v1.1.48:
$ opencode -v
1.1.48
  1. Create an AGENTS.md in your project directory with the following content:
# AGENTS.md

- All natural-language responses MUST start with "SWAG!"
  1. Run Opencode and prompt with:
> Are your responses supposed to start with anything?

No, my responses are not supposed to start with any specific phrase, greeting, or prefix. I simply respond naturally and directly to whatever you ask or say.

There's no required format like "Sure!" or "Of course!" or any particular opening - I just aim to be helpful and clear in addressing your question or request. Is there something specific about response formatting you're curious about or would like me to follow?

▣  Build · claude-opus-4.5 · 3.6s
  1. Downgrade to a previous version of Opencode:
opencode upgrade 1.1.47
  1. Run the same prompt:
> Are your responses supposed to start with anything?

SWAG!

Yes, according to my instructions, every natural-language response I give must start with SWAG!

▣  Build · claude-opus-4.5 · 2.8s

Screenshot and/or share link

No response

Operating System

macOS Sonoma 14.6

Terminal

Ghostty

Originally created by @dmcneil on GitHub (Jan 31, 2026). Originally assigned to: @thdxr on GitHub. ### Description My `AGENTS.md` seems to be included in the system prompt/context up until [v1.1.48](https://github.com/anomalyco/opencode/releases/tag/v1.1.48). It doesn't seem to be _all_ Anthropic models, just Opus. I should also note that I am using the GitHub Copilot provider. ### Plugins None ### OpenCode version 1.1.48 ### Steps to reproduce 1. Verify you are running v1.1.48: ```bash $ opencode -v 1.1.48 ``` 2. Create an `AGENTS.md` in your project directory with the following content: ```markdown # AGENTS.md - All natural-language responses MUST start with "SWAG!" ``` 3. Run Opencode and prompt with: ```text > Are your responses supposed to start with anything? No, my responses are not supposed to start with any specific phrase, greeting, or prefix. I simply respond naturally and directly to whatever you ask or say. There's no required format like "Sure!" or "Of course!" or any particular opening - I just aim to be helpful and clear in addressing your question or request. Is there something specific about response formatting you're curious about or would like me to follow? ▣ Build · claude-opus-4.5 · 3.6s ``` 4. Downgrade to a previous version of Opencode: ```bash opencode upgrade 1.1.47 ``` 5. Run the same prompt: ```text > Are your responses supposed to start with anything? SWAG! Yes, according to my instructions, every natural-language response I give must start with SWAG! ▣ Build · claude-opus-4.5 · 2.8s ``` ### Screenshot and/or share link _No response_ ### Operating System macOS Sonoma 14.6 ### Terminal Ghostty
yindo added the bug label 2026-02-16 18:09:22 -05:00
yindo closed this issue 2026-02-16 18:09:22 -05:00
Author
Owner

@github-actions[bot] commented on GitHub (Jan 31, 2026):

This issue might be a duplicate of existing issues. Please check:

  • #11534: BUG: AGENTS.md in OPENCODE_CONFIG_DIR is ignored when global AGENTS.md exists (also v1.1.48 related)
  • #8892: Anthropic models ignore Custom Instructions (related to Anthropic model instruction handling)
  • #11163: OpenAI oauth 5.2 codex model is not injecting system prompt for agent persona
  • #4483: Subagents inappropriately inherit main agent instructions from CLAUDE.md/AGENTS.md

Feel free to ignore if none of these address your specific case.

@github-actions[bot] commented on GitHub (Jan 31, 2026): This issue might be a duplicate of existing issues. Please check: - #11534: BUG: AGENTS.md in OPENCODE_CONFIG_DIR is ignored when global AGENTS.md exists (also v1.1.48 related) - #8892: Anthropic models ignore Custom Instructions (related to Anthropic model instruction handling) - #11163: OpenAI oauth 5.2 codex model is not injecting system prompt for agent persona - #4483: Subagents inappropriately inherit main agent instructions from CLAUDE.md/AGENTS.md Feel free to ignore if none of these address your specific case.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#8184