agentd logs currently dumps the entire conversation history as one blob. No filtering by recency, no tail-N, no way to get 'just the last message.' Piping through tail sometimes cuts mid-message.
Needs careful design — should be fast and intuitive. Some options to consider:
agentd logs <name> --last N (last N messages)agentd logs <name> --since TIMESTAMP agentd logs <name> --tail (last message only)This is a UX-sensitive tool — worth thinking about what the most common access patterns are before implementing. The primary consumer right now is ava checking on agent progress during heartbeats.
Follow-up (clean comment):
Implemented log filtering for persistent session JSONL logs. Added flags: , (RFC3339), , , , while keeping . Persistent logs now stream via JSONL with filters applied (including follow mode). Added validation for invalid and non-positive . Added pure filter logic + unit tests in Omni/Agentd/Daemon.hs for --last/--since/type+role and invalid timestamp handling. Updated SPEC logging docs to describe persistent session log path and filtering flags. Verified with typecheck/lint and bild tests (, 7[10000;10000H) and manual CLI checks on sd-coder.