ocmonitor-share  by Shlomob

AI coding usage analytics CLI

Created 6 months ago
264 stars

Top 96.6% on SourcePulse

GitHubView on GitHub
Project Summary

OpenCode Monitor is a CLI tool designed to analyze and visualize OpenCode AI coding session data. It empowers individual developers and teams to track AI usage costs, monitor performance, and gain actionable insights through comprehensive reports and a real-time dashboard. The tool aims to provide professional analytics and cost management capabilities for OpenCode users.

How It Works

The tool ingests OpenCode usage data directly from its SQLite database (v1.2.0+) or legacy JSON files. It employs a service-oriented architecture to process this data, enabling features like workflow grouping (main sessions with sub-agents), detailed model and project analytics, and performance metrics such as output tokens per second. A rich terminal UI provides interactive dashboards and reports, with options for data export and Prometheus integration.

Quick Start & Requirements

  • Installation: Recommended via pip install opencode-monitor. Alternative methods include uvx, uv tool install, pipx, source, and Docker.
  • Prerequisites: Python 3.8+ and pip are required for development. OpenCode AI v1.2.0+ is needed for native SQLite support.
  • Documentation: Quick Start Guide and Manual Test Guide are mentioned but not directly linked.

Highlighted Details

  • Professional Analytics: Offers daily, weekly, and monthly usage breakdowns, accurate cost tracking with multi-currency support (including live exchange rates), and detailed model/project analytics.
  • Rich Terminal UI: Features a professional, customizable interface with progress bars, color-coded status indicators, and a live dashboard for real-time monitoring of sessions, costs, and tool usage.
  • Data Export & Integration: Supports CSV and JSON exports for further analysis and integrates with Prometheus for metrics scraping, enabling visualization in tools like Grafana.
  • Workflow Grouping: Automatically aggregates main sessions with their associated sub-agent sessions (e.g., explore) to provide a holistic view of AI activity.

Maintenance & Community

The project is currently in a "Beta Testing" phase. Specific details on active maintenance, community channels (like Discord/Slack), or a public roadmap are not provided in the README.

Licensing & Compatibility

The project is licensed under the permissive MIT License, allowing for broad compatibility with commercial use and closed-source projects.

Limitations & Caveats

The application is explicitly stated as an independent community tool, not affiliated with OpenCode AI. It is currently in beta testing, indicating potential for ongoing development and undiscovered issues.

Health Check
Last Commit

4 days ago

Responsiveness

Inactive

Pull Requests (30d)
5
Issues (30d)
8
Star History
95 stars in the last 30 days

Explore Similar Projects

Starred by Dan Guido Dan Guido(Cofounder of Trail of Bits), Joe Walnes Joe Walnes(Head of Experimental Projects at Stripe), and
4 more.

opcode by winfunc

0.6%
21k
GUI for Claude Code
Created 9 months ago
Updated 5 months ago
Feedback? Help us improve.