Skip to content

feat(tui): defer model warmup until after TUI interface loads - #222

Merged
bug-ops merged 2 commits into
mainfrom
feat/m18/defer-tui-warmup
Feb 13, 2026
Merged

feat(tui): defer model warmup until after TUI interface loads#222
bug-ops merged 2 commits into
mainfrom
feat/m18/defer-tui-warmup

Conversation

@bug-ops

@bug-ops bug-ops commented Feb 13, 2026

Copy link
Copy Markdown
Owner

Summary

  • Split health_check() into connectivity-only check and separate warmup_provider() function
  • In TUI mode, warmup runs as background tokio task after interface renders, sending status via AgentEvent::Status
  • Agent loop awaits warmup completion through watch::channel<bool> before processing messages
  • Non-TUI modes (CLI, Telegram) retain synchronous warmup behavior

Test plan

  • cargo nextest run — 1235 tests pass
  • cargo clippy --workspace -- -D warnings — 0 warnings
  • cargo +nightly fmt --check — clean
  • Manual: cargo run -- --tui shows interface immediately, then "warming up model..." status

Closes #220

Split health_check into connectivity-only check and separate
warmup_provider function. In TUI mode, warmup runs as a background
tokio task after the interface renders, sending status events via
existing AgentEvent::Status channel. Agent loop awaits warmup
completion through a watch::channel before processing messages.
Non-TUI modes retain synchronous warmup behavior.

Closes #220
@github-actions github-actions Bot added rust Rust code changes core zeph-core crate enhancement New feature or request size/M Medium PR (51-200 lines) labels Feb 13, 2026
@github-actions github-actions Bot added the documentation Improvements or additions to documentation label Feb 13, 2026
@bug-ops
bug-ops enabled auto-merge (squash) February 13, 2026 21:41
@codecov-commenter

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 19.23077% with 21 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
src/main.rs 14.28% 12 Missing ⚠️
crates/zeph-core/src/agent.rs 25.00% 9 Missing ⚠️

❌ Your patch status has failed because the patch coverage (19.23%) is below the target coverage (60.00%). You can increase the patch coverage or adjust the target coverage.

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #222      +/-   ##
==========================================
- Coverage   81.33%   81.25%   -0.08%     
==========================================
  Files          78       78              
  Lines       21935    21955      +20     
==========================================
- Hits        17840    17839       -1     
- Misses       4095     4116      +21     
Files with missing lines Coverage Δ
crates/zeph-core/src/agent.rs 66.15% <25.00%> (-0.19%) ⬇️
src/main.rs 72.83% <14.28%> (-0.82%) ⬇️
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@bug-ops
bug-ops merged commit 4ed18e2 into main Feb 13, 2026
19 checks passed
@bug-ops
bug-ops deleted the feat/m18/defer-tui-warmup branch February 13, 2026 21:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

core zeph-core crate documentation Improvements or additions to documentation enhancement New feature or request rust Rust code changes size/M Medium PR (51-200 lines)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat(tui): defer model warmup until after TUI interface loads

2 participants