Skip to content

fix(opencode): detect Copilot PDF input support - #41522

Merged
rekram1-node merged 1 commit into
anomalyco:devfrom
stevenao:issue-41521
Aug 11, 2026
Merged

fix(opencode): detect Copilot PDF input support#41522
rekram1-node merged 1 commit into
anomalyco:devfrom
stevenao:issue-41521

Conversation

@stevenao

@stevenao stevenao commented Aug 10, 2026

Copy link
Copy Markdown
Contributor

Issue for this PR

Closes #41521

Type of change

  • Bug fix
  • New feature
  • Refactor / code improvement
  • Documentation

What does this PR do?

Some GitHub Copilot models support PDF input, but OpenCode was not exposing that capability in their model metadata.

This change marks PDF input as supported only when Copilot advertises both vision support and application/pdf in its supported media types. Models with vision support but without PDF in their advertised media types remain marked as not accepting PDF input.

How did you verify your code works?

Ran:

cd packages/opencode && bun test test/plugin/github-copilot-models.test.ts

All 7 tests pass, including cases for PDF support when both capabilities are advertised and vision-only support without PDF support.

Screenshots / recordings

Not applicable; this is a non-UI logic change.

Checklist

  • I have tested my changes locally
  • I have not included unrelated changes in this PR

@github-actions github-actions Bot added needs:compliance This means the issue will auto-close after 2 hours. and removed needs:compliance This means the issue will auto-close after 2 hours. labels Aug 10, 2026
@github-actions

Copy link
Copy Markdown
Contributor

Thanks for updating your PR! It now meets our contributing guidelines. 👍

@stevenao
stevenao force-pushed the issue-41521 branch 2 times, most recently from e9d2b92 to 2c6dd73 Compare August 10, 2026 10:06
@rekram1-node
rekram1-node merged commit 561afb4 into anomalyco:dev Aug 11, 2026
10 checks passed
@stevenao
stevenao deleted the issue-41521 branch August 11, 2026 22:16
HQ123-BOOP pushed a commit to HQ123-BOOP/LibreCode that referenced this pull request Aug 12, 2026
sepo-eng added a commit to Draugur-AI/opencode that referenced this pull request Aug 13, 2026
…alyco/dev (#56)

* fix(ui): correct OC-2 weak icon color (anomalyco#41504)

(cherry picked from commit 3a90639)

* fix(provider): scope DeepSeek V4 Flash sampling defaults (anomalyco#41620)

Co-authored-by: Aiden Cline <63023139+rekram1-node@users.noreply.github.com>
Co-authored-by: 侯秀凯 <9627034+hoooou@users.noreply.github.com>
(cherry picked from commit 5d95348)

* fix(opencode): detect Copilot PDF input support (anomalyco#41522)

(cherry picked from commit 561afb4)

* fix(opencode): cap session retries with jitter (anomalyco#41939)

(cherry picked from commit c789868)

* fix(provider): add Merge Gateway reasoning variants (anomalyco#41867)

(cherry picked from commit 8571a92)

* docs: fix broken DigitalOcean and Daytona links (anomalyco#42048)

Co-authored-by: skyzhao1223 <skyzhao1223@users.noreply.github.com>
(cherry picked from commit ca3df21)

* docs: fix provider display name and PAT typos (anomalyco#42034)

Co-authored-by: skyzhao1223 <skyzhao1223@users.noreply.github.com>
(cherry picked from commit 959c8bd)

* fix(xai): pass through reasoning effort (anomalyco#42160)

Co-authored-by: Aiden Cline <rekram1-node@users.noreply.github.com>
(cherry picked from commit 502310f)

* fix(mistral): pass through reasoning effort (anomalyco#42164)

Co-authored-by: Aiden Cline <rekram1-node@users.noreply.github.com>
(cherry picked from commit beeabe2)

* fix(groq): pass through reasoning effort (anomalyco#42166)

Co-authored-by: Aiden Cline <rekram1-node@users.noreply.github.com>
(cherry picked from commit 6fea419)

* fix(opencode): select Kimi prompt by provider (anomalyco#42161)

Co-authored-by: Aiden Cline <rekram1-node@users.noreply.github.com>
(cherry picked from commit 91df883)

---------

Co-authored-by: OpeOginni <107570612+OpeOginni@users.noreply.github.com>
Co-authored-by: opencode-agent[bot] <219766164+opencode-agent[bot]@users.noreply.github.com>
Co-authored-by: Aiden Cline <63023139+rekram1-node@users.noreply.github.com>
Co-authored-by: 侯秀凯 <9627034+hoooou@users.noreply.github.com>
Co-authored-by: Steven Ao <stevenao@users.noreply.github.com>
Co-authored-by: Matthew Feroz <136640686+MatthewFeroz@users.noreply.github.com>
Co-authored-by: SKY ZHAO <boyzhaotian@hotmail.com>
Co-authored-by: skyzhao1223 <skyzhao1223@users.noreply.github.com>
Co-authored-by: Aiden Cline <rekram1-node@users.noreply.github.com>
Qiiks added a commit to Qiiks/opencode that referenced this pull request Aug 15, 2026
…hydration-fix

Sync 86 upstream commits (Aug 6-14) including:
- ID-wrap/chronological message ordering fixes (anomalyco#40987-anomalyco#41006) — upstream
  independently fixed the same bug class as our 07889a1/21964da41;
  adopted upstream versions (parentID === user.id for prompt exit, same
  findIndex boundaries for revert/session, isAfter helper in latest())
- v1.18.18 release (4 releases: v1.18.15-18)
- v1 database compatibility preservation (anomalyco#42444)
- ignore unknown config fields (anomalyco#41312)
- session retry cap with jitter (anomalyco#41939)
- compaction instructions for smaller models (anomalyco#42045)
- DeepSeek V4 Flash sampling defaults (anomalyco#41620)
- Copilot PDF input support detection (anomalyco#41522)
- web search for opencode-go (anomalyco#42630)
- compaction plugin hooks (experimental.session.compacting, messages.transform)
- New models: GLM 5.3, Gemini 3.7 Flash, Grok 4.6, Zen updates

Fork-only changes preserved:
- Synthetic web search backend (synthetic flag in webSearchEnabled)
- Config npm propagation to inherited models
- Tool-result media extraction for models without attachment capability
- packageManager pin to bun 1.4.-canary.1 (Rust runtime)

Conflicts resolved: message-v2, prompt, revert, session, server-session
(adopted upstream), compaction (adopted upstream), registry + websearch
test (merged both synthetic + opencode-go).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

PDF attachments are not available with some GitHub Copilot models

2 participants