Coder Agents client tools: $ref in tool input schemas is not resolved
I maintainer di solito rispondono entro 1 giorno
@ThomasK33 ci sta già lavorando.
Dal 12/10/2026.
Valutazione
Questa issue non è ancora stata valutata.
Descrizione
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
- Lingua principale
- TypeScript
- Stelle
- 3
- Fork
- 0
- Merge medio
- 50m
- PR unite (30g)
- 136
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Nessun modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di coder/ai-sdk
-
chore: adopt pnpm 12Apertaaccepted dependencies
Difficoltà 5/5 Più di una settimana Idoneità per principianti 35/100
coder/ai-sdk#176 · 2 commenti ·
I maintainer di solito rispondono entro 1 giorno
-
accepted enhancement
Difficoltà 5/5 Più di una settimana Idoneità per principianti 35/100
coder/ai-sdk#144 · 8 commenti ·
I maintainer di solito rispondono entro 1 giorno
-
chore: adopt TypeScript 7Apertaaccepted dependencies
Difficoltà 5/5 Più di una settimana Idoneità per principianti 25/100
coder/ai-sdk#99 · 3 commenti ·
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di coder/ai-sdk
Issue simili
-
agent/scanner help wanted hive/claimed-by-scanner kind/bug stage/020-claimed
Difficoltà 2/5 1-3 ore Idoneità per principianti 90/100
hivecommons/rationguard#315 ·
I maintainer di solito rispondono entro 1 giorno
-
agent-ready area: ui-sdk priority: p3 type: chore
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
schlessera/brain-kit#2534 ·
I maintainer di solito rispondono entro 1 giorno
-
bug lane:gh-5
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
LLM-4-People/bridlewise-testing#122 ·
I maintainer di solito rispondono entro 1 giorno
-
bug priority: P2
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 78/100
I maintainer di solito rispondono entro 1 giorno
-
enhancement priority:low ready-for-dev
Difficoltà 2/5 1-3 ore Idoneità per principianti 67/100
I maintainer di solito rispondono entro 1 giorno