59 Commits
Author SHA1 Message Date
ciregenz 05cd0f1990 [eric] agents: drop an unused import from the aging recap 2026-08-21 11:51:14 -07:00
ciregenz df31e8d5d2 [eric] tests: the suite can never resume real chats with live credentials (ENG-388) 2026-08-21 11:51:14 -07:00
ciregenzandClaude Fable 5 a4be8c469f [eric] agents: the recap carries no model text, nudges are short and unlabeled (ENG-358)
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01En8dRGsJPLrJCQBEkTH4Mp
2026-08-21 00:20:04 -07:00
ciregenzandClaude Fable 5 295a7b52e2 [eric] agents: a policy block ratchets the recap down instead of bricking the chat (ENG-358)
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01En8dRGsJPLrJCQBEkTH4Mp
2026-08-20 23:44:44 -07:00
ciregenzandClaude Fable 5 e90abb7bfc [eric] system: watchdog deaths blame no workflow, card tails not owed, 20s probe (ENG-366)
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01En8dRGsJPLrJCQBEkTH4Mp
2026-08-20 22:22:49 -07:00
ciregenz 3235324122 [eric] agents: a user's Stop or Close is final; no watchdog resend, disk reload, read, or late-booting child revives the card 2026-08-20 19:39:33 -07:00
ciregenzandClaude Opus 5 0f2543db65 [eric] agents: a finished turn always leaves the user something to read
Every silent-stop fix so far was a detector for a shape somebody had already
found in the field, which is why the class kept coming back wearing a new hat.
turn_spoke.py moves the question down a tier: at the one exit every terminal
path passes through, ask whether anything readable appeared since the user last
spoke, and if not, say the honest line. Cause no longer has to be enumerated for
the user to be answered.

proactive_prune.py is the hermes trigger we were missing. Their own tests say
our bug out loud: on a large window, a percentage-of-window compaction check
almost never fires, so aged tool output rides in history and is re-sent verbatim
every turn. Measured here, our shaping cut 0.0% at every session size; with a
fixed 60K-token cost trigger it cuts 88% at 12 turns, 93% at 30, 94% at 60. The
prompt-cache contract is load-bearing rather than optional, because our prune is
a rebuild: it commits only when it reclaims enough to pay for the busted prefix,
then disarms until history has regrown a full runway.

Also: lane preflight now treats only 401/403 as a dead credential, since
testStatus=="unavailable" conflated a throttled lane with a revoked one and told
users to reconnect a merely rate-limited Gemini; and awaiting_reconnect is
cleared when the retry budget is spent, so a stale flag can no longer muzzle the
floor and end an ask in total silence.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014wtspwSFzZmjCx9UNPAorQ
2026-08-20 11:36:34 -07:00
ciregenzandClaude Opus 5 58e376496e [eric] agents: an outage parks the turn and resumes when the provider answers; OAuth connects survive a backend restart
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014wtspwSFzZmjCx9UNPAorQ
2026-08-20 08:39:41 -07:00
ciregenz 7a4af2c419 [eric] workflows: the restart-loop-guard pause notice called a nonexistent broadcast; it never reached the user (linter catch) 2026-08-19 17:24:23 -07:00
ciregenz 7e3a98e315 [eric] agents: a turn cut off by a dirty exit auto-resumes at boot, gated by a consecutive-crash breaker; a clean Cmd+Q keeps the manual chip (hermes #30719 pairing) 2026-08-19 15:36:01 -07:00
ciregenz 108287eda4 [eric] agents: provider content-policy blocks are terminal (no snag flicker), recap-bearing sessions get ONE recap-free retry, and the recap reads first-person instead of a User:/Assistant: transcript that trips distillation filters (Alex's bricked chats) 2026-08-19 14:07:29 -07:00
ciregenz 6a1dbc4212 [eric] agents: recap ages history hermes-style instead of dropping it; stubs keep the re-runnable command, duplicates collapse, newest results survive verbatim (ENG-354 endgame) 2026-08-19 13:40:47 -07:00
ciregenz 182409c2ac [eric] agents: every git exec rides a non-prompting availability check; the CLT shim's install dialog fired at session start on clean Macs (ENG-344) 2026-08-18 19:04:56 -07:00
ciregenz 0f29b9a7bb [eric] agents: a session reaches disk the moment you send, so a backend death can no longer erase the conversation (ENG-313) 2026-08-15 22:13:52 -07:00
ciregenz df32505aca [eric] compounding-growth pass: zOrders is pruned on every card removal, a model switch persists so the notice heals once, orphaned app workspaces are listable and deletable, and two browsers opened in the same millisecond no longer collide into one 2026-08-12 11:17:46 -07:00
ciregenz 0b0a5d78ca [eric] agents: a garbled dashboard file can no longer wipe the board; the sessions list fails loud instead of answering empty, and an unscoped fetch loses its delete authority 2026-08-12 02:10:41 -07:00
ciregenz 86e323cbce [eric] telemetry: per-session flight recorder, error envelopes name cause+lane+phase+crumbs, silent recoveries hit the ledger 2026-08-06 22:39:30 -07:00
ciregenz 7399076906 [eric] boot: only mid-turn sessions hydrate at startup, 2269 settled ones lazy-load, agents lifespan 850 to 537ms median 2026-08-06 16:08:30 -07:00
ciregenz b29c75d5e0 [eric] agents: crossing the compact threshold now actually trims next turn, and a pasted log can't ride the recap back over the wall 2026-08-03 15:47:18 -07:00
ciregenz b5d0461828 [eric] backend: queue messages typed mid-turn and replay them when the turn ends 2026-07-31 14:21:47 -07:00
ciregenz 61d79ce5d0 [eric] backend: boot restore keeps session files on disk instead of unlinking them 2026-07-31 14:13:01 -07:00
ciregenz b8a9793b65 [eric] distill: pin the touched file paths back onto a summary that paraphrased them away 2026-07-31 01:21:49 -07:00
ciregenz e10bd2ed9d [eric] tool-results: middle-elide oversized spills so the tail (where the verdict lives) survives 2026-07-31 01:17:14 -07:00
ciregenz 600c04dd02 [eric] history: stop losing chats (merge live sessions, drop agent-spawned children, sort by last activity, never render a blank row) 2026-07-30 12:59:45 -07:00
ciregenz 68b079cc5e [eric] ws: slim status frames, cross-socket dedupe, REST-seeded resume cursor, closed-only history 2026-07-17 11:11:35 -07:00
ciregenz 95f1996c19 [eric] distill: use the reliable cheap aux tier, not the chat's family (gemini/codex sessions 404'd/401'd the same-family aux) 2026-07-06 18:09:34 -07:00
ciregenz 9da027a948 [eric] context: distill dropped history via aux LLM on rebuild + model-aware compaction threshold 2026-07-06 15:25:58 -07:00
ciregenz 3e0c4811e2 [eric] agents: wire persistent client behind OSW_TTFT_PERSISTENT_CLIENT (warm TTFT 535ms -> 6ms) 2026-07-03 02:48:16 -07:00
ciregenz ed40d9dc72 [eric] agents: backfill pending_approvals + validate disk browser-agent children (undefined .some() crash) 2026-06-25 23:10:41 -07:00
ciregenz bb31d359ee [eric] analytics: retire the old session-snapshot cloud path (sync_session_close); full transcript + classification now come from Haik's per-message product-analytics bridge, and it was 413ing the 100KB /sync edge 2026-06-25 03:40:35 -07:00
ciregenz 36626be089 [eric] backend: one-line comments + collapse blank runs across backend root + tests (AST-verified, 1 test skipped: embedded #-lines) 2026-06-25 03:04:16 -07:00
ciregenz 7564f9c301 [eric] agents: on restart, a session whose last message is a finished assistant reply restores as completed not stopped (kills the spurious Resume button on done chats) 2026-06-25 02:42:20 -07:00
ciregenz 8d01452e24 [eric] agents: collapse per-session startup/shutdown logs into one summary line (hundreds of sessions flooded the console) 2026-06-25 02:36:12 -07:00
ciregenz d5cd4db026 [eric] agents: one-line every comment + collapse 3+ blank runs across manager/ surface (33 files, -550 lines, code byte-identical) 2026-06-25 02:16:14 -07:00
ciregenz 448c0deafd [eric] agents: rename cryptic names — LivePartial->PartialReply, session/lifecycle.py->resume_and_duplicate.py (it held resume/duplicate, and collided with SessionLifecycle) 2026-06-25 00:58:57 -07:00
ciregenz b9cea6c647 [eric] agents: drop the Mixin suffix, name the 9 manager classes by domain (Messaging, SessionLifecycle, ...) + AgentManagerState -> AgentManagerProtocol 2026-06-25 00:50:47 -07:00
ciregenz d0dd5e799b [eric] agents: typed AgentManagerState mixin base re-enables pyright attr-access + fixes 2 broken outputs imports (pyright caught them) 2026-06-25 00:32:16 -07:00
ciregenz dc53394e55 [eric] agents: drop dead typing.Dict imports + dangling _conns ref (caught by ruff/pyright audit, behavior-preserving) 2026-06-24 23:26:37 -07:00
ciregenz 0f4dbd5769 [eric] agents: @typechecked the 4 history_compaction helpers (close audit gap, surface 90->93%) 2026-06-24 22:59:06 -07:00
ciregenz 6561dd6743 [eric] agents: convention fixes on merge surface (public cross-file helpers, pydantic approval memory, resolve_ask @typechecked) 2026-06-24 22:36:17 -07:00
ab6037267c [aidan] fix/agent-chat: stop agents reading the recap as spoofed tool output (#104)
* [aidan] fix/agent-chat: ground fresh-session recap and label platform notes as trusted

* [aidan] fix/mcp-activate: fork on activate instead of fresh-session restart

* [eric] agents: add strip_forged_sentinels, defang spoofed platform-note/recap tags in untrusted text

* [eric] agents: sanitize untrusted tool output in post_tool_hook before trusted notes append

---------

Co-authored-by: cire <134991075+ciregenz@users.noreply.github.com>
2026-06-24 18:40:15 -07:00
ciregenz 755862b7b5 [eric] backend: rename single-export modules to match their export (naming convention sweep) 2026-06-24 01:30:04 -07:00
ciregenz 6ab6217ac7 [eric] backend: final leading-_ cleanup, file-local shorts + move session cancel-event to manager-side table (off the pydantic model, kills the last underscore); naming linter now 0/0 2026-06-23 21:57:20 -07:00
ciregenz 751bb77032 [eric] agents: publicize cross-mixin members (p_run_agent_loop, p_build_mcp_servers, etc.) + safe_resp_text so the decomposition passes p-private 2026-06-23 16:44:41 -07:00
ciregenz 8c0a5010e1 [eric] agents: split bulk startup/shutdown persistence into SessionPersistenceMixin (one-session vs all-sessions) 2026-06-23 14:40:20 -07:00
ciregenz 9b0116ca41 [eric] agents: session_store convention-clean (5 funcs off leading-_) + FIX auth/signout _save_session import bug 2026-06-23 12:16:38 -07:00
ciregenz 027c6ac311 [eric] agents: history_compaction convention-clean (4 funcs off leading-_, typing, @typechecked) 2026-06-23 12:08:05 -07:00
ciregenz 79bc62bca5 [eric] agents: remove 38 dead imports (autoflake) + restore the 3 dynamic re-exports + repoint a test 2026-06-23 12:03:25 -07:00
ciregenz 75db4d7ded [eric] agents: FIX latent NameError on cwd sessions (ensure_cwd_git_repo import mismatch) + clean workspace_git + regression test 2026-06-23 11:55:39 -07:00
ciregenz 68beb599c9 [eric] agents: cloud_sync convention-clean (sync_session_close off leading-_, @typechecked, typed) 2026-06-23 11:51:29 -07:00