What problem does it solve?
Fixed-interval automation for Codex threads either interrupts active work or leaves dead time after tasks finish, and blindly running codex exec resume can race with the Codex App when a thread is still active. This Skill adds an idle guard that inspects local Codex thread state before sending any heartbeat prompt.
Core Features & Use Cases
- Idle-guarded heartbeats: Reads
~/.codex/state_5.sqlite and the target rollout JSONL to check for recent final_answer, unresolved tool calls, and cooldown before sending via codex exec resume.
- Launchd preset management: Install, enable, disable, kick, inspect, and uninstall named heartbeat presets (agent-harness, cs-notes, cs-notes-test) as macOS LaunchAgents.
- Transport selection guidance: Prefers Codex App-native heartbeat automations for App-visible threads, with launchd +
codex exec resume as a documented headless fallback.
- Use Case: You run a long-lived CS-Notes controller thread and want it nudged every two hours to make one small verifiable improvement, but only when it has been idle for at least 120 seconds.
Quick Start
Ask the agent to install the cs-notes heartbeat preset and then report the launchd status, target thread, and idle-guard result.