Skip to content

feat(onboarding,familiars): enhance first-run and familiar management - #126

Merged
BunsDev merged 1 commit into
mainfrom
feat/onboarding-familiars
Jul 3, 2026
Merged

feat(onboarding,familiars): enhance first-run and familiar management#126
BunsDev merged 1 commit into
mainfrom
feat/onboarding-familiars

Conversation

@BunsDev

@BunsDev BunsDev commented Jul 2, 2026

Copy link
Copy Markdown
Member

Summary

Enhancements to the onboarding and familiar management experience, spanning a first-run pass and standalone familiar administration. Grew out of an /ultraplan opportunity scan; implemented across all identified items.

Onboarding

  • Esc = skip persists — dismissing onboarding with Esc now marks it complete, so it no longer reappears every launch.
  • Live keybinding hints — the onboarding shortcuts page derives the submit / openHelp keys from the user's actual keybindings.json instead of hardcoded labels that could drift.
  • No-credential empty state — the welcome box leads with a prominent /connect call-to-action when no provider is configured.
  • Retry-After — Codex 429 responses now honor the server's Retry-After header.

Familiars

  • No more silent roster loss — a malformed ~/.coven/familiars.toml (and non-fatal issues like unknown access tiers or duplicate/reserved ids) surface as a startup status message instead of the whole roster vanishing. Stale explicitly-selected familiars are flagged too.
  • First-run bootstrap — pressing F2 with an empty roster in standalone mode writes a starter familiars.toml (a read-only guide + a full-access builder) and opens the switcher.
  • Better F2 switcher — incremental type-to-filter and a — none — row to clear the active familiar without /familiar reset.
  • Reset disambiguation/familiar clear (alias reset) steps back to no active familiar; the destructive /familiar wipe-roster (alias reset-roster) now requires confirm.
  • Standalone-only writes — new core API (create/upsert/remove/rename), /familiar new|rename|remove commands, and visual-menu deletion. All refuse when the Coven daemon owns the file (daemon socket present).
  • Per-familiar model override — optional model field in familiars.toml.

Docs: docs/familiars.md updated with the new fields, commands, and standalone-write behavior.

Testing

cargo test green across touched crates:

  • core 96, api 35, commands 96, tui 645 — 0 failures

New coverage: roster write API (create/remove/rename/upsert, daemon-owned refusal), roster load/warnings (malformed vs empty vs absent), F2 switcher entries + filter, Retry-After parsing, and both standalone-removal and daemon-owned-refusal deletion paths.

Notes

  • Based on 6178c13 (v0.2.2) — clean of the unrelated feat/steer-command work.
  • Standalone vs daemon mode is detected via the ~/.coven/coven.sock socket; the daemon remains the source of truth whenever it's running.

🤖 Generated with Claude Code

Copilot AI review requested due to automatic review settings July 2, 2026 04:44
@vercel

vercel Bot commented Jul 2, 2026

Copy link
Copy Markdown

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

Project Deployment Actions Updated (UTC)
docs Ready Ready Preview Jul 3, 2026 10:35am

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Pull request overview

This PR improves first-run onboarding and familiar roster management across the TUI, core familiar storage APIs, and slash commands, and adds Codex rate-limit handling that respects Retry-After.

Changes:

  • TUI onboarding now reflects user-configured keybindings for shortcut hints and persists “Esc = skip” so onboarding doesn’t reappear every launch.
  • Familiar UX improvements: startup roster warnings for malformed/non-fatal roster issues, F2 switcher filtering + “clear active familiar” row, and first-run standalone bootstrap of ~/.coven/familiars.toml.
  • Standalone roster write support (create/rename/remove/upsert + daemon-owned refusal) and Codex 429 errors now thread Retry-After into rate-limit errors.

Reviewed changes

Copilot reviewed 11 out of 11 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
src-rust/crates/tui/src/render.rs Updates welcome empty-state messaging and enhances the F2 familiar switcher UI (filter footer + clear row).
src-rust/crates/tui/src/onboarding_dialog.rs Uses keybindings.json-derived labels for onboarding shortcut hints.
src-rust/crates/tui/src/familiar_theme.rs Threads the new per-familiar model field through theme defaults/tests.
src-rust/crates/tui/src/app.rs Adds switcher filter state, roster warning surfacing, switcher behavior changes, and onboarding completion persistence on Esc.
src-rust/crates/tui/src/agents_view.rs Enables deleting coven familiars from the agents menu in standalone mode; refuses when daemon-owned.
src-rust/crates/core/src/keybindings.rs Adds display helpers to surface the active binding for an action (user override or default).
src-rust/crates/core/src/coven_shared.rs Adds per-familiar model, distinguishes absent vs malformed roster loads, and implements standalone roster write APIs + bootstrap roster.
src-rust/crates/commands/src/lib.rs Adds `/familiar new
src-rust/crates/api/src/providers/codex.rs Extracts Retry-After header and threads it into provider errors for non-2xx responses.
src-rust/crates/api/src/error_handling.rs Adds Retry-After parsing and extends rate-limit errors to carry an optional delay.
docs/familiars.md Documents the new model field, standalone write behavior, new commands, and wipe/clear semantics.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +514 to +516
return Err(FamiliarWriteError::Duplicate(
"roster already exists".to_string(),
));
Comment on lines +1563 to +1567
if !present {
self.status_message = Some(format!(
"Selected familiar '{active}' is not in the roster — using none.",
));
}
Comment on lines +1575 to +1579
if let Some(active) = self.config.familiar.as_deref() {
self.status_message = Some(format!(
"Selected familiar '{active}' has no roster (~/.coven/familiars.toml) — using none.",
));
}
Comment on lines +393 to +397
let user_kb = claurst_core::keybindings::UserKeybindings::load(
&claurst_core::config::Settings::config_dir(),
);
let submit_key = claurst_core::keybindings::display_binding_for(&user_kb, "submit")
.unwrap_or_else(|| "Enter".to_string());
Comment on lines +3379 to 3381
let pink = Color::Rgb(139, 92, 246);
let daemon_familiars = claurst_core::coven_shared::load_familiars().unwrap_or_default();
let interior_w = popup_w.saturating_sub(2);
Onboarding:
- Persist onboarding completion on Esc (skip) so it doesn't re-nag
- Derive submit/openHelp keybinding hints from real keybindings.json
- Lead the no-credential welcome box with a prominent /connect CTA
- Honor Retry-After on Codex 429s

Familiars:
- Surface malformed familiars.toml + roster warnings at startup instead
  of the roster silently vanishing (load_familiars_result / warnings)
- F2 empty-state bootstraps a starter ~/.coven/familiars.toml (standalone)
- F2 switcher: incremental filter + "none" clear row
- Disambiguate /familiar clear vs wipe-roster (destructive, needs confirm)
- Standalone-only roster writes: create/upsert/remove/rename core API,
  /familiar new|rename|remove commands, and menu deletion; all refuse
  when the Coven daemon owns the file
- Per-familiar model override (model field in familiars.toml)

All crates green: core 96, api 35, commands 96, tui 645.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@BunsDev
BunsDev force-pushed the feat/onboarding-familiars branch from 95f3562 to 5ffebc5 Compare July 3, 2026 10:35
@BunsDev
BunsDev merged commit f667ba3 into main Jul 3, 2026
2 checks passed
@BunsDev
BunsDev deleted the feat/onboarding-familiars branch July 3, 2026 12:18
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