Repository navigation
feat(agent-providers): Goose as an agent provider - #1438
Closed
RajdeepKushwaha5 wants to merge 3 commits into
Closed
RajdeepKushwaha5 wants to merge 3 commits into
RajdeepKushwaha5 wants to merge 3 commits into
Conversation
RajdeepKushwaha5
requested review from
abeldantas,
agent-runner353,
amaudruz,
christian-mcdermott,
lbangalosbt,
massimo-sandboxaq,
niall-sandboxaq,
petr-sandbox,
raullopez-sandbox and
simonflk-sb
as code owners
November 4, 2026 03:47
# Conflicts: # console/packages/agent-providers/README.md
Author
|
Hi @petr-sandbox, the Goose provider is ready. It passes the real-CLI conformance run (9/10, |
Collaborator
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #780
What this changes
Goose becomes an agent provider. A Switch agent can run on Goose (
goose acp): it is created in Switch Console with a model, talks in rooms, and asks for approvals like the other ACP agents. It is an ACP hooks file on the generic adapter, a plugin, and one line in each registry, asadd-an-agent-provider.mddescribes.Everything below was checked against Goose v1.57.0's own source.
Sign-in, without signing in. Goose has no account; it signs in to the model provider chosen with
goose configure. The check first opensgoose acpand readsagentInfofrominitialize(about a quarter of a second), because another tool, pressly/goose (a database migration CLI), also installs asgoose; anything that does not answer as Goose reads as unknown with that hint, instead of as signed in. It then reads the provider choice the way Goose resolves it (GOOSE_PROVIDER, elseactive_provider, elseGOOSE_PROVIDERinconfig.yaml; the model fromGOOSE_MODEL, elseproviders.<p>.model), honoursGOOSE_PATH_ROOTand each platform's config directory, and never touches the keyring or calls a model. An empty or comment-onlyconfig.yamlreads as not configured, and an unreadable one as unknown without its contents. A wrong key shows on the first turn. Noauthenticateis ever sent.Modes. approval-required and auto-accept-edits run in
approve, auto insmart_approve(Goose's own reviewer) and full-access inauto. Goose is launched withGOOSE_MODE=approveso it is safe before the session's mode is set.Approvals are never saved for good. Goose offers
allow_alwaysandreject_always, and writes them to itspermission.yaml, so one click would stop it asking about that tool in every later session, approval-required ones included. The hooks offer only allow once and reject, and give them readable names (Goose names its options after their ids, so the card would readallow_once).Session naming is off. Goose names each session with a model call of its own. Switch never shows those names, so
GOOSE_DISABLE_SESSION_NAMINGdefaults totrue(a machine that sets it keeps its value). This saves a call per session, and on a local model the naming calls ran for hours and starved the turns.Tool calls. Goose sends every tool call with no ACP
kind, and its permission requests with no_meta. Without help, auto-accept-edits would ask about every edit and the activity card would not tell a command from a file change. The hooks:developertools from_meta.goose.toolCall(shellas a command,writeandeditas file changes) and itssummonextension'sdelegatetool as a subagent;shell · ls,write · notes.txt), so auto-accept-edits allows edits and the approval card has the right type. Only Goose's unprefixed built-in names match, so a session MCP server can never be taken for one;extensionName, leaving out Goose's built-in extensions, so the session's own servers are allowed and Goose's tools are not shown as connector calls.Install. The plugin offers Goose's install script on macOS and Linux, Homebrew (
block-goose-cli) on macOS and the PowerShell script on Windows, all withCONFIGURE=false: the scripts otherwise end by runninggoose configure, which waits for answers Console's installer cannot give. Updates usegoose update.Environment.
GOOSE_PROVIDER,GOOSE_MODEL,GOOSE_PATH_ROOT,GOOSE_DISABLE_KEYRING,GOOSE_DISABLE_SESSION_NAMING,GOOSE_ADDITIONAL_CONFIG_FILESandGROQ_API_KEYare passed through; the other common provider keys already are.Core. One entry in the provider table: label
Goose, connector typeGoose CLIlike the other providers, sign-ingoose configure, and Goose's built-in tools.Outside the files the guide lists, each a list of every provider that Goose had to join:
switch-buddy/template.yamlandtemplate_guide.py: the providers a template may name.chats/views.py: the provider shown for an agent registered by hand.test_provider_registry.py,test_advanced_config.py,test_gateway_routes.py,test_known_agents.py,test_offline_owner_reply.py,known-agent-type.test.tsandsession-launch.test.ts. Without these the suite fails as soon as a provider is added.agent-controller/src/status.test.tscounted five providers by hand; it now counts them fromPROVIDERS, so the next provider does not break it.js-yaml, already used by the desktop app, to readconfig.yaml.Not changed: giving a remote machine a login from Console (out of scope in the issue). For Goose it refuses with a clear message.
The issue's "Done when", and where each is shown:
goose configure" hint: the check above (it also tells Block's Goose from anothergoose),precheckansweringprovider_login_missingwith an emptyGOOSE_PATH_ROOT, and the unit tests for every outcome.gemini-2.5-flash). Advanced settings are empty.approval-requiredandapproval-declinedscenarios.!interruptstops a turn, the conversation resumes after a restart: real-CLIsteer-mid-turn,interruptandresume.file-write-full-access, and the runs on the models named in the summary below.user-inputskipped with its reason, summary below.How it was tested
Unit tests: 33 for the hooks: launch and environment, session naming, the mode map, a
goosethat is not Block's (no ACP answer, or another agent's), every sign-in outcome (environment, both config layouts, a mix, empty and comment-only files, unreadable config, each platform's directory,GOOSE_PATH_ROOT), MCP server identity, item typing, subagents, the permission kinds, including titles that must not match, and the options offered.Console packages (on the current
main): build, typecheck, lint and format check pass. In agent-providers (921 passed), plugins (135) and agent-controller (360), and the desktop agent tests (294), the only failures on this Windows machine are 14 tests that fail the same way on an untouchedmain: symlinks without the privilege (hosted-provider,control-port,self-update), POSIX shell scripts (release-keys, the Antigravity launcher) and process handling (stdio-json-rpc,claude-sdk-spawn,attachments,opencode-console).Core:
ruff format --check,ruff checkandmypyclean. The provider registry, advanced config, known agents, offline reply, template and gateway route tests pass with Goose; four controller tests intest_gateway_routes.py(owner isolation, working directory, machine rename) time out the same way onmainhere.Headless controller:
switch-agent-controller precheckreports{"provider":"goose","installed":true,"version":"1.57.0","auth":"ok","auth_source":"local"}, and with an emptyGOOSE_PATH_ROOTit reports"auth":"missing","reason":"provider_login_missing"with thegoose configurehint.On a headless agent controller, built from this branch and enrolled on Windows as
windows-goosewithswitch-agent-controller enroll, 2026-11-09:doctorreportsok goose Installed 1.57.0, authenticated: Goose has a model provider configured. Credentials are checked on the first turn., with the enrollment, credential, server and shared host checksok. Withrungoing, an agent placed on that controller through the management API (provider: goose, Googlegemini-3.5-flashthroughGOOSE_PROVIDERandGOOSE_MODEL, approvals on) came uprunningand, asked in a Switch chat "What is 17 times 3? Reply with just the number.", answered51.Adding or changing an agent CLI
CLI and version: Goose 1.57.0 (official Windows build), Windows 11. The suite ran on Gemini (Goose's
googleprovider) and earlier on a local model, Qwen 3.5 9B in LM Studio; the video usesgemini-2.5-flash.Real-CLI test summary (
pnpm exec vitest run src/goose/goose.integration.test.ts):Every scenario passed against the real CLI. The free Gemini tier allows 5 requests a minute and 20 a day per model, which a full run goes past:
approval-requiredandsubagentfailed on429rate limits (in Goose's request log) and were rerun alone.approval-declinedtimed out on Gemini 3 Flash and on the local Qwen 3.5 9B (whose event log shows it asking for the declined tool again), and passes on Gemini 2.5 Flash-Lite. On Qwen every other scenario passed too.user-inputis skipped: Goose 1.57.0 asks questions only through ACP form elicitation, which the generic adapter does not advertise. The deadline is 600 s because Goose runs whatever model it is set to, a local one included.Video (recorded from this branch in Switch Console on Windows, Goose 1.57.0 on
gemini-2.5-flash). It shows:One thing in the video is not from this change: on Windows the model picker says Goose "is not installed or its selected executable cannot be found" while the provider list shows it ready.
getProviderReadinesspasses the full executable path towhere, which rejects a path ("Invalid pattern"); typing the model works, as the video shows.demo.mp4