Skip to main content

Observability Commands

Genie provides seven command groups for observability: events for the audit log, sessions for Claude Code session history, metrics for machine state, schedule for cron triggers, qa for self-testing, log for a unified real-time feed, and brief for session startup context.

Events

The genie events command group queries the PostgreSQL audit event log. Events are structured as OTel-compatible records covering API costs, tool usage, task transitions, and errors.

genie events list

List recent audit events.
genie events list [options]
OptionDescription
--type <type>Filter by event type
--entity <entity>Filter by entity type or entity ID
--since <duration>Time window, e.g., 1h, 30m, 2d (default: 1h)
--errors-onlyShow only error events
--limit <n>Max rows (default: 50)
--jsonOutput as JSON

genie events errors

Show aggregated error patterns.
genie events errors [--since <duration>] [--json]

genie events costs

Cost breakdown from OTel API request events.
genie events costs [options]
OptionDescription
--todayShow costs from the last 24h
--since <duration>Time window (default: 24h)
--by-agentGroup by agent
--by-wishGroup by wish
--by-modelGroup by model
--jsonOutput as JSON
genie events costs --today --by-agent
genie events costs --since 7d --by-model

genie events tools

Tool usage analytics from OTel tool events.
genie events tools [options]
OptionDescription
--since <duration>Time window (default: 24h)
--by-toolGroup by tool name (default)
--by-agentGroup by agent
--jsonOutput as JSON

genie events timeline

Full event timeline for a task, agent, wish, or trace ID. Shows all events associated with a specific entity in chronological order.
genie events timeline <entity-id> [--json]
genie events timeline task-6c3a2cf2
genie events timeline engineer-1

genie events summary

High-level stats: agents spawned, tasks moved, costs, errors.
genie events summary [--today] [--since <duration>] [--json]

genie events scan

Full server cost scan via ccusage. Scans all Claude Code sessions on the machine, not just genie-spawned ones.
genie events scan [options]
genie events scan

Log

The genie log command provides a unified observability feed that aggregates transcripts, DMs, team chat, tool calls, and system events into a single stream.

genie log

Unified observability feed for an agent or team.
genie log [agent] [options]
OptionDescription
--team <name>Show interleaved feed for all agents in a team
--type <kind>Filter by event kind: transcript, message, tool_call, state, system
--since <timestamp>Only events after ISO timestamp
--last <n>Show last N events
--ndjsonOutput as newline-delimited JSON (pipeable to jq)
--jsonOutput as pretty JSON
-f, --followFollow mode — real-time streaming
# Follow an agent's live feed
genie log engineer -f

# Show last 20 events for the whole team
genie log --team auth-rewrite --last 20

# Stream tool calls as NDJSON
genie log engineer --type tool_call --ndjson -f

Brief

genie brief shows an aggregated startup brief with context since the last session — useful for agents resuming work or operators reviewing what happened overnight.

genie brief

genie brief [options]
OptionDescription
--team <name>Team name (default: GENIE_TEAM env var)
--agent <name>Agent name (default: GENIE_AGENT_NAME env var)
--since <iso>Start timestamp (default: last executor end)
# Show brief for the current agent
genie brief

# Show brief for a specific team since midnight
genie brief --team auth-rewrite --since 2026-03-30T00:00:00Z

Sessions

The genie sessions command group provides history and search across Claude Code sessions. Session metadata and content are stored in PostgreSQL.

genie sessions list

List Claude Code sessions.
genie sessions list [options]
OptionDescription
--activeShow only active sessions
--orphanedShow only orphaned sessions
--agent <name>Filter by agent
--jsonOutput as JSON

genie sessions replay

Replay a session — interleaves content and events in chronological order.
genie sessions replay <session-id> [--json]
Full-text search across session content.
genie sessions search <query> [--limit <n>] [--json]

genie sessions ingest

Manual batch import of JSONL session files.
genie sessions ingest [--backfill]
The --backfill flag imports all existing JSONL files that haven’t been ingested yet.

Metrics

The genie metrics command group provides machine-level state snapshots and agent heartbeat data.

genie metrics now

Current machine state — CPU, memory, active workers, teams.
genie metrics now [--json]

genie metrics history

Machine snapshot history over time.
genie metrics history [--since <duration>] [--json]
Default time window is 1h. Supports durations like 6h, 1d.

genie metrics agents

Per-agent heartbeat summary — shows each agent’s last heartbeat, state, and uptime.
genie metrics agents [--json]

Schedule

The genie schedule command group manages cron-based scheduled triggers.

genie schedule create

Create a new schedule.
genie schedule create <name> [options]

genie schedule list

List schedules with next due trigger.
genie schedule list [options]

genie schedule cancel

Cancel a schedule and skip pending triggers.
genie schedule cancel <name> [options]

genie schedule retry

Reset a failed trigger to pending.
genie schedule retry <name>

genie schedule history

Show past executions for a schedule.
genie schedule history <name> [options]

QA

The genie qa command group runs self-testing specs against the Genie CLI itself.

genie qa run

Run QA specs — all, a domain, or a single spec.
genie qa run [target] [options]

genie qa status

Show QA dashboard with last results per spec.
genie qa status [options]

genie qa history

Show recent QA runs.
genie qa history

genie qa check

Evaluate a QA spec against current team logs and publish a qa-report.
genie qa check <specFile> [options]
genie qa check specs/messaging.yaml

genie qa-report

Publish a QA result to the PostgreSQL event log. Called internally by the QA team-lead.
genie qa-report <json>