npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

copilot-lens

v1.0.8

Published

A local dashboard to visualize and analyze your GitHub Copilot CLI sessions

Readme

Copilot Lens 👓

A local web dashboard to visualize, explore, and analyze your GitHub Copilot CLI terminal sessions. See your full conversation history, tool usage patterns, and usage analytics — all without leaving your machine.

Why Copilot Lens?

GitHub Copilot CLI stores session data locally, but there's no built-in way to browse or analyze it. Copilot Lens gives you a clean, interactive dashboard to:

  • Review past sessions — What did you ask? What did Copilot do?
  • Understand your usage patterns — Which repos, branches, and tools do you use most?
  • Track your productivity — How much active time are you spending with Copilot?

Everything runs locally. No data leaves your machine. No cloud. No sign-in.

Install

npm install -g copilot-lens

Usage

# Start the dashboard
copilot-lens

# Auto-open in browser
copilot-lens --open

# Custom port
copilot-lens --port 8080

# Or use npx (no install needed)
npx copilot-lens --open

CLI Options

| Flag | Default | Description | |------|---------|-------------| | --port | 3000 | Port number | | --host | localhost | Host address | | --open | off | Auto-open browser |

Features

📋 Session Browser

  • Browse all your Copilot CLI sessions in a searchable, filterable list
  • Color-coded by directory — each project gets a unique accent color
  • Status detection — see which sessions are Running, Completed, or Error
  • Three filter dimensions — filter by time range, status, and directory
  • Click any session to view full details

copilot-lens sessions list

💬 Conversation View

  • Chat-style layout with your prompts on the right and Copilot responses on the left
  • View tool calls made during the session
  • See any errors that occurred
  • Read session plans (if created)

copilot-lens session view

📊 Analytics Dashboard

Eight interactive charts powered by Chart.js, arranged in a 2-column grid:

| Chart | Type | What It Shows | |-------|------|---------------| | Sessions Per Day | Bar (compact) | Daily session activity over time | | Activity by Hour of Day | Bar (compact) | When during the day you use Copilot most | | Tool Usage | Doughnut | Most-used tools (grep, edit, powershell, etc.) | | Model Usage | Doughnut | Which AI models you've used (Claude, GPT, etc.) | | Top Working Directories | Horizontal bar (full-width) | Which project folders you use Copilot in most | | Time Per Branch | Horizontal bar | Active Copilot time spent on each git branch | | Time Per Repo | Horizontal bar | Active Copilot time per repository | | MCP Servers Used | Doughnut | Which MCP servers are configured across sessions |

Doughnut chart legends are interactive — click a label to toggle that segment's visibility.

Glimpse of Analytics Dashboard

copilot-lens demo

🎨 UI Features

  • Dark & Light mode — toggle with one click, preference is saved
  • Manual refresh — refresh button to reload data on demand
  • Responsive layout — works on any screen size
  • 2-column grid layout — compact charts with no wasted space

🏆 Copilot Effectiveness Score

Per-repo scoring (0-100) that measures how effectively you use Copilot CLI, with actionable improvement tips.

| Category | What It Measures | |----------|-----------------| | Prompt Quality | Average prompt length, how often Copilot needs clarification | | Tool Utilization | Diversity of tools used (grep, glob, edit, task, etc.) | | Efficiency | Tool success rate and turns per session | | MCP Utilization | Configured MCP servers vs actually used (reads repo's mcp.json) | | Engagement | Session duration sweet spot and usage consistency |

copilot-lens effectiveness score

How It Works

Copilot Lens reads session data from ~/.copilot/session-state/, where GitHub Copilot CLI stores:

  • workspace.yaml — Session metadata (directory, git branch, timestamps)
  • events.jsonl — Full event log (messages, tool calls, errors)
  • plan.md — Session plans (if created)

A local Express server parses these files and serves a static frontend dashboard.

Duration Calculation

Session durations are calculated from actual event activity, not wall-clock time. Gaps longer than 5 minutes between events are excluded, so resumed sessions don't show inflated durations.

Status Detection

| Status | How It's Detected | |--------|-------------------| | Running | session.db exists and was modified within 10 min, or events.jsonl modified within 5 min | | Completed | Has an abort event with "user initiated" reason, or no recent activity | | Error | Has an abort event with a non-user-initiated reason |

Tech Stack

  • Backend: Node.js + Express + TypeScript
  • Frontend: Vanilla HTML/CSS/JavaScript
  • Charts: Chart.js
  • Data: YAML + JSONL parsing (no database required)

Development

git clone https://github.com/pavanvamsi3/copilot-lens.git
cd copilot-lens
npm install
npm run dev        # Start with tsx (no build needed)
npm run build      # Compile TypeScript
npm start          # Run compiled version

License

MIT

Optional: Custom Local Hostname

If you'd like a prettier URL like http://copilot.lens:3000, add this to your hosts file:

  • Windows (run as Admin): echo 127.0.0.1 copilot.lens >> C:\Windows\System32\drivers\etc\hosts
  • macOS/Linux: echo "127.0.0.1 copilot.lens" | sudo tee -a /etc/hosts

Then run: copilot-lens --host copilot.lens