Loading...
Loading...
Query cross-project usage analytics. Use when reviewing agent, skill, hook, or team performance across OrchestKit projects. Also replay sessions, estimate costs, and view model delegation trends.
npx skill4agent add yonatangross/orchestkit analytics~/.claude/analytics/| Subcommand | Description | Data Source | Reference |
|---|---|---|---|
| Top agents by frequency, duration, model breakdown | | |
| Model delegation breakdown (opus/sonnet/haiku) | | |
| Top skills by invocation count | | |
| Slowest hooks and failure rates | | |
| Team spawn counts, idle time, task completions | | |
| Replay a session timeline with tools, tokens, timing | CC session JSONL | |
| Token cost estimation with cache savings | | |
| Daily activity, model delegation, peak hours | | |
| Unified view of all categories | All files | |
# Top agents with model breakdown
jq -s 'group_by(.agent) | map({agent: .[0].agent, count: length}) | sort_by(-.count)' ~/.claude/analytics/agent-usage.jsonl
# All-time token costs
jq '.modelUsage | to_entries | map({model: .key, input: .value.inputTokens, output: .value.outputTokens})' ~/.claude/stats-cache.jsonagentsmodelsskillshooksteamssummaryreferences/jq-queries.mdsessionreferences/session-replay.mdcostreferences/cost-estimation.mdtrendsreferences/trends-analysis.mdsummaryreferences/data-locations.md| File | Contents |
|---|---|
| Agent spawn events with model, duration, success |
| Skill invocations |
| Hook execution timing and failure rates |
| Session end summaries |
| Task completions |
| Team spawns and idle events |
rules/| Category | Rule | Impact | Key Pattern |
|---|---|---|---|
| Data Integrity | | CRITICAL | Hash project IDs, never log PII, local-only |
| Cost & Tokens | | HIGH | Separate pricing per token type, cache savings |
| Performance | | HIGH | Streaming jq for >50MB, rotation-aware queries |
| Visualization | | HIGH | Recharts charts, ResponsiveContainer, tooltips |
| Visualization | | HIGH | Dashboard grids, stat cards, widget registry |
| Reference | Contents |
|---|---|
| Ready-to-run jq queries for all JSONL subcommands |
| Session JSONL parsing, timeline extraction, presentation |
| Pricing table, cost formula, daily cost queries |
| Daily activity, model delegation, peak hours queries |
| All data sources, file formats, CC session structure |
jq-srules/large-file-streaming.md<name>.<YYYY-MM>.jsonlteampidork:exploreork:feedbackork:rememberork:doctor