> Analyze Claude Code usage trends over time using the Agent Monitor's analytics API — daily session counts, daily event counts, token volumes by type, model distribution, tool usage rankings, and agent/event type distributions across 365-day retention windows.
npx skills add https://github.com/hoangsonww/Claude-Code-Agent-Monitor --skill usage-trends
Analyze usage patterns and trends from the Agent Monitor analytics data.
The user provides: $ARGUMENTS
Options: "last 7 days", "last 30 days", "last quarter", "peak hours", "tool trends", "model usage".
| Endpoint | Returns |
|----------|---------|
| GET /api/analytics | Comprehensive analytics object (see schema below) |
| GET /api/stats | { total_sessions, active_sessions, active_agents, total_agents, total_events, events_today, ws_connections, agents_by_status, sessions_by_status } |
| GET /api/sessions?limit=200 | Full session records with timestamps and metadata |
GET /api/analytics){
"overview": { "total_sessions", "active_sessions", "active_agents", "total_agents", "total_events" },
"tokens": {
"total_input": N, "total_output": N,
"total_cache_read": N, "total_cache_write": N
},
"tool_usage": [{ "tool_name": "...", "count": N }], // top 20
"daily_events": [{ "date": "YYYY-MM-DD", "count": N }], // 365 days
"daily_sessions": [{ "date": "YYYY-MM-DD", "count": N }], // 365 days
"agent_types": [{ "subagent_type": "task"|"explore"|null, "count": N }],
"event_types": [{ "event_type": "PreToolUse"|"PostToolUse"|..., "count": N }],
"avg_events_per_session": N,
"total_subagents": N,
"sessions_by_status": { "active": N, "completed": N, "error": N, "abandoned": N },
"agents_by_status": { "working": N, "completed": N, "error": N, ... }
}
Plot daily_sessions and daily_events for the requested period. Compute:
From analytics tokens (baselines are pre-summed into totals at the DB level):
total_input, total_output, total_cache_read, total_cache_writetotal_cache_read / (total_cache_read + total_input) — trending up = improvingtotal_output / total_input ratio — high = Claude is verboseFrom tool_usage (top 20 tools by event count):
From agent_types + per-session model field:
From sessions_by_status:
completed / total × 100error / total × 100abandoned / total × 100From event_types:
Markdown with tables and ASCII trend indicators (▲▼→). Include period comparison when applicable.
Create new skills, modify and improve existing skills, and measure skill performance. Use when users want to create a skill from scratch, edit, or optimize an existing skill, run evals to test a skill, benchmark skill performance with variance analysis, or optimize a skill's description for better triggering accuracy.
Guide for creating effective skills. This skill should be used when users want to create a new skill (or update an existing skill) that extends Claude's capabilities with specialized knowledge, workflows, or tool integrations.
Guide for creating effective skills. This skill should be used when users want to create a new skill (or update an existing skill) that extends Claude's capabilities with specialized knowledge, workflows, or tool integrations.
Replace with description of the skill and when Claude should use it.
Use when facing 2+ independent tasks that can be worked on without shared state or sequential dependencies
This skill should be used when the user wants to "create a skill", "add a skill to plugin", "write a new skill", "improve skill description", "organize skill content", or needs guidance on skill structure, progressive disclosure, or skill development best practices for Claude Code plugins.
Helps users discover and install agent skills when they ask questions like "how do I do X", "find a skill for X", "is there a skill that can...", or express interest in extending capabilities. This skill should be used when the user is looking for functionality that might exist as an installable skill.
Use when creating new skills, editing existing skills, or verifying skills work before deployment
Take hoangsonww/usage-trends from the repository into ~/.claude/skills for personal
use, or into .claude/skills inside a project.
The agent identifies a skill by the name field in its header. Two skills with the
same name cannot sit side by side — one of them will be ignored.