Coder Agents client tools: $ref in tool input schemas is not resolved
メンテナーはふだん 1 日以内に返信
@ThomasK33 がすでに取り組んでいます。
2026年10月12日 から。
評価
この issue はまだ評価されていません。
説明
Client tools registered through Coder Agents (chatd) lose any $ref in their input schema. The model then guesses the referenced shape.
Evidence (live, dogfood.cdr.dev v2.38.0-devel, 2026-10-12)
I registered one client tool, create_reminder, through @coder/ai-sdk-agent's CoderLanguageModel, with delay behind a reference. I tried two forms:
| Schema form | chatd response | Model's delay argument |
|---|---|---|
draft-07: { "$ref": "#/definitions/Delay" } + definitions |
accepted | "10m" |
2020-12: { "$ref": "#/$defs/Delay" } + $defs |
accepted | "10m" |
inline { "type": "object", "properties": { "minutes": { "type": "integer" } } } |
accepted | { "minutes": 10 } |
The dialect makes no difference, so the reference most likely never reaches the model resolved. I did not verify where it is dropped (chatd's schema handling or the upstream provider call).
Impact
@coder/ai-sdk-effect derives tool schemas from Effect Schema. Any schema with an identifier annotation is emitted as a $ref (on Effect 3 and Effect 4), so such tools do not work as Coder Agents client tools. The AI Gateway path (CoderLanguageModel) is not affected by this observation (not tested live).
Options
- A. Find and fix where chatd drops or fails to resolve
$ref(coder/coder). - B. Inline (dereference) local references in the agent package before registering client tools.
- C. Document the limitation and inline only in
@coder/ai-sdk-effect.
Found during the Effect 4 migration (#144, #320). The live test there uses an inline schema.
Generated with xum • Model: anthropic:claude-opus-5-5 • Thinking: high
- 主要言語
- TypeScript
- スター
- 3
- フォーク
- 0
- 平均マージ
- 50分
- マージ済み PR(30日)
- 136
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートなし
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
coder/ai-sdk のほかの issue
-
chore: adopt pnpm 12オープンaccepted dependencies
難易度 5/5 1週間以上 初心者へのやさしさ 35/100
メンテナーはふだん 1 日以内に返信
-
accepted enhancement
難易度 5/5 1週間以上 初心者へのやさしさ 35/100
メンテナーはふだん 1 日以内に返信
-
accepted dependencies
難易度 5/5 1週間以上 初心者へのやさしさ 25/100
メンテナーはふだん 1 日以内に返信
似ている issue
-
bug P3 UI/UX
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
StellarState/SS-backend#712 ·
メンテナーはふだん 1 日以内に返信
-
area: backend bug
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
snapotter-hq/SnapOtter#3473 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
gitroomhq/postiz-app#2304 ·
メンテナーはふだん 1 日以内に返信
-
harlan-agent-ready-to-implement routine:ci-review
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
harlan-zw/unlighthouse#454 · コメント 2 件 ·
メンテナーはふだん 1 日以内に返信