Skip to content

Configurable providers for the PR and Issues board agents - #377

Open
chrisbewz wants to merge 1 commit into
AgentSystemLabs:mainfrom
chrisbewz:office/pixel-35ec
Open

chrisbewz wants to merge 1 commit into
AgentSystemLabs:mainfrom
chrisbewz:office/pixel-35ec

Conversation

@chrisbewz

Copy link
Copy Markdown

What

The Issues agent and the PR agent can now each run on a provider of their own. An admin picks a provider, model and effort for either in ⚙️ Settings → 🤖 Workers (a line per agent under the Default worker, with ✏️ Edit and ↺ Use the default). The Queue agent, and the tasks it adds, always run on the office's default worker, as before.

How

  • PromptsState.stations (protocol): what the issues and pulls agents start on, by station kind, kept in .agent-office/prompts.json beside the default worker. A new prompts.station admin message sets one or puts it back on the default (ConfigurableStation = Exclude<StationKind, 'queue'> makes the queue agent unaddressable by type).
  • OfficePrompts.station/setStation validate a choice exactly as setAgent does (provider known, custom only when configured, model and effort checked); one the office can no longer start is forgotten on restore.
  • WorkerManager.station() spawns the board agent on stationChoice(kind, prompts, officeDefault) (src/server/stations.ts) — its own pick, else the office default. The station.prompt sign-in gate follows the resolved provider.
  • Client: ui/settings-boards.ts (reuses the agentFields picker), wired into the Workers pane; settings.ts grew 8 lines (547/600), and the size guard holds — workers/manager.ts stayed at exactly its 1029-line ceiling (the spawn change swaps one line for one).
  • Docs: docs/agents.md and docs/features.md updated.

Verification

  • npm run typecheck — clean (server + client).
  • Targeted suites: tests/prompts.test.ts (station choice validation, persistence, forgotten entries), tests/stations.test.ts, tests/server-dispatch.test.ts (new prompts.station handler coverage: admin gating, toasts, state), tests/size.test.ts, client-structure/help/store — 35/35 green.
  • New workers.test.ts case: the Issues agent spawns on its station's pick (claude/sonnet/low), the PR agent on another provider (codex), the Queue agent on the office default. Green.
  • Note: most of tests/workers.test.ts fails on this Windows machine for pre-existing environment reasons (fake-agent timeouts, office-queue bin ENOENT, git signing); the same test fails identically on a clean worktree at 852e2ab without this diff, and server-dispatch passes once commit signing is disabled. Not caused by this change.
  • npm run build — clean (vite + tsc).
  • Headless screenshot of ⚙️ Settings → 🤖 Workers showing the new Issues agent / PR agent rows (no console errors).

An admin can now give the Issues agent and the PR agent a provider, model
and effort of their own, in Settings - Workers, instead of always starting
on the office's default worker. The Queue agent keeps running on the
default, as do the tasks it adds. Choices are validated the way the
default worker's are, kept in .agent-office/prompts.json, and one the
office can no longer start is forgotten on the next boot. The first
prompt at a board hires its agent on the choice made for that station,
and the sign-in gate follows the provider picked.
dextah added a commit to dextah/agent-office that referenced this pull request Oct 22, 2026
… approvals) for workers (#2)

* Configurable providers for the PR and Issues board agents

An admin can now give the Issues agent and the PR agent a provider, model
and effort of their own, in Settings - Workers, instead of always starting
on the office's default worker. The Queue agent keeps running on the
default, as do the tasks it adds. Choices are validated the way the
default worker's are, kept in .agent-office/prompts.json, and one the
office can no longer start is forgotten on the next boot. The first
prompt at a board hires its agent on the choice made for that station,
and the sign-in gate follows the provider picked.

* Yolo (skip approvals) for hired workers, the default worker and the board agents

A "Yolo (skip approvals)" box under the provider in the hire dialog, the
default worker and the Issues/PR agents' rows in Settings - Workers. Each
provider's row in shared/providers.ts names its CLI's flag, and its
adapter puts it on the command line through server/yolo.ts, on resume too:
Claude Code --dangerously-skip-permissions, Codex
--dangerously-bypass-approvals-and-sandbox (any -a/--ask-for-approval
dropped, which Codex refuses alongside it), Cursor --force, Muse --yolo.
A flag --agent-args already has, or an alias of it, isn't added twice.
Providers without one grey the box out, and the server rejects it there.

It's validated with the model and effort (prompts.json, workers.json, the
spawn), admin-only where those settings are, toasted to everyone, and a
worker in yolo wears a "Yolo" badge on its card, the workers list and its
terminal title. A Claude worker in yolo gets hook settings with
skipDangerousModePermissionPrompt, so Claude's first-run Bypass Permissions
screen doesn't hold it up; if it shows anyway the desk says so.

Also folds the copies of a pick in prompts.ts into one helper, and the two
settings handlers' parsing of a pick into one.

Co-authored-by: chrisbewz <crisbewz@gmail.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* Keep the yolo box's label on one line with its flag

base.css's .modal label made it a block, so the flag ran into the label.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

---------

Co-authored-by: chrisbewz <crisbewz@gmail.com>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
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