Skip to content

Admit no protocol upgrade on a model route - #452

Merged
SaladDay merged 1 commit into
feature/agent-outside-sandboxfrom
aos/b4-model-route-websocket
Oct 6, 2026
Merged

SaladDay merged 1 commit into
feature/agent-outside-sandboxfrom
aos/b4-model-route-websocket

Conversation

@SaladDay

@SaladDay SaladDay commented Oct 6, 2026 •

Copy link
Copy Markdown
Collaborator

This is a Harness–Model provider protocol change from the B4 simplicity audit.

modelprovider.Route.WebSocket is deleted. No declared route set it, and its only reader was the gateway's upgrade check. The gateway now rejects every protocol upgrade on a model route. MCP and the proxy still relay upgrades.

The change touches:

  • internal/modelprovider/config.go;
  • apps/daemon/internal/gateway/model.go;
  • contracts/agents-api/model-execution.md and its zh translation, with a current source_hash.

TestModelRejectsUndeclaredRequests, which includes upgrade rejection, is unchanged and passes.


View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need. Autofix is disabled.

Every declared model route left Route.WebSocket false, and the gateway was its only reader. The field is gone: no model route admits a protocol upgrade, and the gateway rejects every upgrade on the model listener with 400 before it reaches the upstream. The Harness–Model provider protocol says so.
@SaladDay
SaladDay merged commit 6b74bcf into feature/agent-outside-sandbox Oct 6, 2026
20 checks passed
@SaladDay
SaladDay deleted the aos/b4-model-route-websocket branch October 6, 2026 23:44
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.

1 participant