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

opencode-session-log

v0.1.8

Published

OpenCode plugin that writes human-readable and detailed session logs under .agents-log

Readme

opencode-session-log

opencode-session-log is an OpenCode plugin that writes session artifacts to ./.agents-log with a structure aligned to the Claude-side session logger.

It generates:

.agents-log/
├── summary/<yyyy-mm-dd_hh-mm-ss>/
│   ├── summary.md
│   ├── usage.json
│   └── agents/
│       ├── main/
│       │   ├── summary.md
│       │   └── usage.json
│       └── <agentKey>/
│           ├── summary.md
│           └── usage.json
└── meta/
    ├── index.md
    ├── state/<session_id>.json
    └── sessions/YYYY/MM/<session_id>/
        ├── index.md
        ├── merged/session.md
        ├── agents/<agentKey>/session.md
        └── artifacts/

Install

Add the npm package name to your OpenCode config:

{
  "plugin": ["opencode-session-log"]
}

OpenCode installs npm plugins automatically on startup.

Project-level config:

  • .opencode/opencode.json

Global config:

  • ~/.config/opencode/opencode.json

Automated npm Publishing

This repo is configured to publish from GitHub Actions. You do not need your own server.

The publish workflow runs when you push a tag like:

git tag v0.1.7
git push origin v0.1.7

Before the publish step, GitHub Actions will:

  • install dependencies
  • run npm test
  • verify that the tag version matches package.json

One-time GitHub setup

Add this repository secret:

  • NPM_TOKEN

The token should be an npm publish token with permission to publish this package. If your npm account enforces 2FA for publishing, use a token that supports publish without interactive OTP.

Release flow

  1. Update package.json version
  2. Commit and push main
  3. Create and push a matching tag:
git tag v0.1.7
git push origin main --tags

GitHub Actions will publish that exact version to npm.

What It Captures

  • Session-level summary and usage
  • Per-agent summaries for main and child sessions
  • Merged detailed timeline
  • Per-agent detailed logs
  • Tool calls, tool results, reasoning, assistant output
  • Session state and rendered sidecar artifacts

Output Root

The plugin always writes into:

./.agents-log

This keeps OpenCode logs separate from Claude-side .claude-log output.

Notes

  • Child sessions are emitted as separate agent directories.
  • When the live SDK snapshot is incomplete, the plugin falls back to the local OpenCode SQLite database to keep output stable.
  • The session root summary.md is an overview page; full detail lives under agents/* and meta/.../merged/session.md.

Development

npm test