Skip to content

feat(mobile): show BYOK badges for CLI models - #5138

Merged
iscekic merged 4 commits into
mainfrom
byok-model-picker-5bd1
Aug 7, 2026
Merged

feat(mobile): show BYOK badges for CLI models#5138
iscekic merged 4 commits into
mainfrom
byok-model-picker-5bd1

Conversation

@iscekic

@iscekic iscekic commented Aug 7, 2026

Copy link
Copy Markdown
Contributor

Users now see a BYOK badge for eligible remote CLI models in the mobile picker row and selected-model pill. Cloud-agent model badges remain unchanged, and CLI free, data-collection, and cost metadata stay suppressed.

The change makes BYOK model selection visible before a remote CLI run and adds seed topics that provide repeatable BYOK fixture and usage evidence for verification.

The mobile selector uses one pure badge predicate that separates the user BYOK flag from gateway metadata. The seed topics encrypt a placeholder key, atomically replace marked catalog fixture data, and read usage rows through a bounded, read-only query.

Human steps: before merge, a repository administrator must enable Code Security under Kilo-Org/cloud Settings → Code Security so the CodeQL checks can upload SARIF results. No product deployment step is needed after merge.

E2E: bot-e2e — fresh iOS verification passed the remote CLI badge, cloud-agent badge regression, BYOK usage rows, and non-BYOK control evidence.

Visual Changes:

Remote CLI picker row:
cli-picker-row.png

Remote CLI selected-model pill:
cli-pill.png

Cloud-agent picker row:
cloud-agent-picker-row.png

Cloud-agent selected-model pill:
cloud-agent-pill.png

Checks: repository typecheck, repository lint, mobile model-selector tests, mobile unused-export checks, format, and diff checks passed locally. Current CodeQL checks fail only because Code Security is disabled on the private repository.

@iscekic iscekic self-assigned this Aug 7, 2026
@iscekic
iscekic requested review from RSO and jeanduplessis August 7, 2026 14:56
@kilo-code-bot

kilo-code-bot Bot commented Aug 7, 2026

Copy link
Copy Markdown
Contributor

Code Review Summary

Status: No Issues Found | Recommendation: Merge

Executive Summary

Incremental review of the latest commits: the seed user-resolution helpers were extracted into shared dev/seed/lib/users.ts with identical lookup/ambiguity logic, usage-evidence dropped only select fields that are not referenced downstream, and the badge predicate's unused unavailable input was removed with both call sites passing variables (no excess-property breakage) — all behavior-preserving, verified against current HEAD with high confidence.

Files Reviewed (10 files)
  • apps/mobile/src/components/agents/model-selector-badges.ts
  • apps/mobile/src/components/agents/model-selector-badges.test.ts
  • apps/mobile/src/components/agents/model-selector.mounted.test.tsx
  • apps/mobile/src/components/agents/model-selector.tsx
  • apps/mobile/src/lib/free-model-data-disclosure.ts
  • dev/seed/app/byok-e2e-fixture.ts
  • dev/seed/app/usage-evidence.ts
  • dev/seed/coding-plans/occupied-minimax-byok.ts
  • dev/seed/lib/byok.ts
  • dev/seed/lib/users.ts
Previous Review Summary (commit 0887634)

Current summary above is authoritative. Previous snapshots are kept for context only.

Previous review (commit 0887634)

Status: No Issues Found | Recommendation: Merge

Executive Summary

Reviewed the mobile BYOK badge predicate extraction (ungating BYOK from showGatewayMetadata for CLI-catalog options while keeping free/data-collection gated) and the new BYOK E2E seed topics; badge semantics, schema usage, encryption format, snapshot merge/delete SQL, and runner contract all verified against current HEAD with high confidence.

Files Reviewed (9 files)
  • apps/mobile/src/components/agents/model-selector-badges.ts
  • apps/mobile/src/components/agents/model-selector-badges.test.ts
  • apps/mobile/src/components/agents/model-selector.mounted.test.tsx
  • apps/mobile/src/components/agents/model-selector.tsx
  • apps/mobile/src/lib/free-model-data-disclosure.ts
  • dev/seed/app/byok-e2e-fixture.ts
  • dev/seed/app/usage-evidence.ts
  • dev/seed/coding-plans/occupied-minimax-byok.ts
  • dev/seed/lib/byok.ts

Reviewed by kimi-k3 · Input: 44.3K · Output: 6.9K · Cached: 354.4K

Review guidance: REVIEW.md from base branch main

@iscekic
iscekic requested a review from jeanduplessis August 7, 2026 16:49
@iscekic
iscekic merged commit 6a4dede into main Aug 7, 2026
18 of 20 checks passed
@iscekic
iscekic deleted the byok-model-picker-5bd1 branch August 7, 2026 17:04
@iscekic
iscekic restored the byok-model-picker-5bd1 branch August 7, 2026 18:57
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.

2 participants