agentd: split rm (archive) and purge (hard delete)

t-753·WorkTask·
·
·
Created1 week ago·Updated1 week ago·pipeline runs →

Dependencies

Description

Edit

Change persistent agent lifecycle semantics so removes runtime config but preserves audit history. Add to hard-delete active and archived records. Ensure daemon HTTP DELETE /agents/:id uses archive semantics so Ava cleanup keeps audit trails.

Timeline (9)

🔄[human]Open → InProgress1 week ago
💬[human]1 week ago

Implemented split lifecycle semantics:

  • agentd agent rm <name> now archives DB history (agents_history, messages_history, workspaces_history) and removes active config/runtime artifacts.
  • Added agentd agent purge <name> to hard-delete both active and archived records.
  • Updated daemon API behavior so DELETE /agents/:id now uses archive semantics (history retained).

Validation:

  • lint/typecheck/bild pass for Omni/Agentd.hs and Omni/Agentd/Daemon.hs.
  • CLI smoke test: create/start/send/rm created history rows; purge removed history rows.
  • HTTP smoke test on temp daemon and deployed :8400 daemon confirms DELETE archives records (hist_agents increments while active row removed).
🔄[human]InProgress → Review1 week ago
💬[human]1 week ago

Committed in acf1cdd: split rm/archive vs purge semantics for persistent agents.

💬[human]1 week ago

Ava verified: cited commit confirmed in live history; feature shipped. Moving to Verified.

🔄[human]Review → Verified1 week ago