Skip to content

feat(j5): personas choose from an ordered model list - #922

Merged
bryantderosier merged 4 commits into
j5/777-personas-upgrade-compatibilityfrom
feat/persona-ordered-models
Nov 6, 2026
Merged

bryantderosier merged 4 commits into
j5/777-personas-upgrade-compatibilityfrom
feat/persona-ordered-models

Conversation

@bryantderosier

@bryantderosier bryantderosier commented Nov 3, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

Persona editors still offer fixed primary/fallback slots, and new launches lack consistent per-entry diagnostics and quota checks. I added ordered model editing on web, desktop, and mobile, exact-instance selection, and reasons for every unavailable entry. Closes #778.

New launches select the first eligible provider instance and preserve the chosen entry in their assignment. I use known account-wide provider quota windows to skip exhausted choices. Existing workers keep their model and continuation behavior.

This is layer 3 of stack pingdotgg#921 (#914 → #920 → #922 → #923), which merges as one.

Evidence

  • I reproduced each regression in a test before fixing it:

    • blocked instance entries broke the legacy catalog decoder;
    • a Claude Fable quota window blocked an unrelated Opus model;
    • new assignments wrote two entry indices;
    • an old-format entry was labelled with whichever provider instance came first (Codex · remote), while the server launches it on the default instance.

    All four tests pass now. The Claude test uses real claudeUsageResponseToLimits output.
    vp test run apps/server/src/j5/agents/agentPersonaRouting.test.ts packages/client-runtime/src/j5/agentPersonas.test.ts -t 'legacy catalog decoder|Claude model-scoped|selected entry index|non-default instance'

  • Every model label now follows one rule: the picker, blocked reasons and mobile Details all show the provider name, add the instance ID only when that provider has more than one instance, and show reasoning as just its value (Claude · claude-haiku-5-5 · low). Tests cover one instance, two instances, an unknown instance and old-format entries.
    vp test run packages/client-runtime/src/j5/agentPersonas.test.ts apps/mobile/src/j5/agents/personaDetails.test.ts

  • Disabled Up, Down, Remove and Add model buttons on mobile now look muted instead of tappable. That's a visual change, so it has no test.

  • I deleted resolvedRouteIndex completely. Nothing on j5/main has it, and this stack merges as one, so no released build ever wrote it. Assignments now only carry resolvedEntryIndex.

  • The changed-file check is fully green: 383 tests across 16 files, format, lint, GraphQL, all 32 affected-package typechecks, and both Knip passes.
    vp run check:changed origin/j5/777-personas-upgrade-compatibility

  • The PR only touches J5-owned files. I removed the stored worker-limit lookup and its upstream forwarding hooks, and FORK.md matches the parent.

Not verified: the muted mobile buttons on a device (the panel's iOS run will cover them), the usage-limit skip on a live server (there's no safe way to fake quota windows), iOS, and launching a fully blocked persona from the UI picker, which hides it. The panel's live run happened before the label fixes, the resolvedRouteIndex removal and the muted buttons. None of those change the launch path.

Live testing

Jackson's panel cross-checked the stack tip, then live-tested it on isolated servers (results are on #923). The real-client checks they ran:

  • an older web client loads the catalog against this server;
  • the web editor (instance labels, Add model, old definitions keeping order and options across an edit);
  • Android create, edit, reorder and save;
  • a disabled provider is skipped and the persona launches on entry 2.

Merge Danger

Door: one-way. New-format definitions, snapshots, and indexed assignment records remain after a revert. Servers older than the #777 compatibility layer cannot read the new definitions; retain a compatible server until those definitions and workers have been handled.

Blast Radius: persona creation, selection, catalogues, and editors across all clients.

The selection and editing changes live in J5-owned files.

After merge: release this stack with #779 before #780 changes the shared team library. Keep the coordinated client/server rollout.

Checklist

  • One concern: the description has no "also"
  • Tests cover the changed behavior (backend changes ship with focused tests)
  • UI changes: before/after screenshots above, and a video for motion or interaction
  • Live testing: the section above says what ran live and what did not
  • Upstream-owned files: each one is recorded in FORK.md (case text and file-table row) in this PR
  • Upstream product: any change to what upstream's product does has a human decision linked above and a register entry in docs/j5/product/upstream.md
  • Surfaces: entry points, clients, providers, contracts, reverse states, connection modes (see AGENTS.md)
  • Docs: definitions under docs/j5/product/ and user docs rewritten where this changes them

Screenshots and video for the editors are on #923, from the panel's live re-test of the whole stack. The upstream-owned-file and upstream-product items are inapplicable: this PR now touches only J5-owned files.

Model: GPT-6.1-Sol (high). Harness: Codex.

@vercel

vercel Bot commented Nov 3, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
j5-code Ready Ready Preview Nov 5, 2026 7:05pm UTC

Request Review

@coderabbitai

coderabbitai Bot commented Nov 3, 2026 •

Copy link
Copy Markdown

Important

  • Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

Run configuration

  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

@github-actions github-actions Bot added the vouch:trusted Author is trusted by repo permissions or the VOUCHED list. label Nov 3, 2026
@github-actions github-actions Bot added the size:XXL 1,000+ effective changed lines (test files excluded in mixed PRs). label Nov 3, 2026
@bryantderosier bryantderosier self-assigned this Nov 3, 2026

@BastiHu BastiHu left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved as layer 3 of stack pingdotgg#921, which merges as one. Verified the reported stack review fixes against stack tip 08297aea7d02bcb07ab5d8ebac80601cfa1a5584; 145 focused tests passed across four files at that tip.

The integrated live retest of the reworked stack remains outstanding, including the previously omitted mobile, upgrade, and provider-enforcement cases.

@Jacksondr5 Jacksondr5 left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved as part of the persona stack (#914 → #920 → #922 → #923), which merges as one, at this layer's head bd653b5b65 (stack tip d11efb049e).

  • Panel review: Claude Opus 5.5 and GPT-6.1-Sol. All findings are fixed and cross-checked.
  • Live tests: web, the upgrade on a single test home, an old client against the new server, Android, and iOS on Jackson's iPhone. The results and screenshots are on #923.
  • Jackson: approved the docs and the UI.
  • Still unproven, by choice: a real Codex or Claude write refusal (startup policy and tool restrictions were confirmed) and the usage-limit skip (covered by unit tests).
  • Not this stack: follow-ups found on the base commit are #929 and #930.

Approved by Claude Opus 5.5 for Jackson.

@bryantderosier
bryantderosier merged commit 77a9b7a into j5/main Nov 6, 2026
33 checks passed
@bryantderosier
bryantderosier deleted the feat/persona-ordered-models branch November 6, 2026 12:25

This branch was successfully deployed

1 active deployment
Preview — bd653b5b Deployed Nov 5, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:XXL 1,000+ effective changed lines (test files excluded in mixed PRs). vouch:trusted Author is trusted by repo permissions or the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Personas: an ordered model list

3 participants