Skip to content

Split ucode setup into per-section commands + apply diff + wizard UX - #341

Open
rohita5l wants to merge 2 commits into
mainfrom
split-ucode-setup
Open

Split ucode setup into per-section commands + apply diff + wizard UX#341
rohita5l wants to merge 2 commits into
mainfrom
split-ucode-setup

Conversation

@rohita5l

Copy link
Copy Markdown
Collaborator

What

Breaks the monolithic ucode setup into focused commands and polishes the interactive wizard.

Command surface

ucode setup now configures agents and models only, then prints a checklist of what's left. Each other section is its own command:

Command Does
ucode setup Agents, per-agent models/provider service, settings scope
ucode setup mcp Managed MCP servers
ucode setup skills [--location a.b,c.d] Managed skills
ucode setup budget-policy Spend-based routing policy
ucode setup help Walkthrough of the whole sequence, marking what's configured
  • A re-run of ucode setup carries the other sections forward instead of clearing them (a re-run after ucode revert/fresh machine falls back to the workspace's published config). A carried budget policy that no longer fits the enabled agents is dropped with a warning rather than blocking the save.
  • The section commands require ucode setup to have run first; they validate structurally (no model-inventory re-check, since they don't touch models).

ucode apply diff

Before the confirmation prompt, apply shows a human-readable ADD / DELETE / CHANGE diff against the published config (normalized the same way it will be sent, so no phantom changes), and does nothing when the two already match.

Wizard UX

  • Step banners (step 2 of 3 · Models & settings), per-agent progress counters, and a uniform ✔ <agent> configured — <model> · <scope> line per agent.
  • "Selected so far" recap before the default-agent pick; Claude family-slot recap before its overall-default pick.
  • Boxed "What is a budget policy?" explanation (shown only once a usable budget exists); budgets are checked first, with a boxed warning and no blurb when none can attach.
  • Budget tiers shown as spend ranges (under 50%, 50–90%, 90%+) anchored by the manifest default; a duplicate agent/model re-asks only the agent/model, keeping the percentage.
  • Codex model lists sort newest-first (matching Gemini); Gemini dropped from the setup picker (still launchable via ucode gemini).

Testing

  • uv run pytest (non-e2e): 1856 pass. The one failure, test_mcp.py::TestConfigureMcpCommand::test_registers_discovered_external_server, is pre-existing on main (verified on a clean checkout) and unrelated to this change.
  • uv run ruff check . clean.

This pull request and its description were written by Isaac.

…zard UX

Split the monolithic `ucode setup` into `ucode setup` (agents + models) plus
`ucode setup mcp` / `skills` / `budget-policy` / `help`, each editing one section
of the same managed config. `ucode setup` now carries the other sections forward
on a re-run instead of clearing them.

`ucode apply` shows a human-readable ADD/DELETE/CHANGE diff against the published
config before confirming, and does nothing when they already match.

Wizard UX: step banners, per-agent progress and a uniform per-agent confirmation,
a "Selected so far" recap, a Claude family-slot recap, a boxed "What is a budget
policy?" explanation, spend-range budget tiers with an anchored default, and a
boxed warning when no attachable budget exists. Codex model lists now sort
newest-first. Gemini is dropped from the setup picker (still launchable).

Co-authored-by: Isaac
Make clear the MCP / skills / budget-policy commands aren't required to publish,
so a config with none configured doesn't read as unfinished.

Co-authored-by: Isaac
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