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

oira666_pi-browser-agent

v0.0.4

Published

Pi browser agent broker skeleton with lazy browser tool registration

Readme

pi-browser-agent

pi-browser-agent is a pi extension that starts a local WebSocket broker and registers a browser-driving tool suite for browser-agent-ext.

What it does

  • starts a loopback-only broker on ws://127.0.0.1:7878 by default
  • registers the full browser_* tool suite at session start when the broker starts listening
  • exposes activate_browser_agent_tools as a self-check / status tool
  • forwards tool calls to browser-agent-ext
  • keeps browser-task history on disk for local inspection

Install

Add the extension to pi from this repo checkout or package it as an npm pi extension.

Local checkout

{
  "extensions": ["./pi-browser-agent/src/index.ts"]
}

npm package form

When this package is published, the install shape is:

pi install npm:oira666_pi-browser-agent

For the current in-repo state, use the local-checkout form above.

Runtime requirements

  1. A pi session with this extension enabled.
  2. Chrome with browser-agent-ext loaded unpacked.
  3. In the extension options, Enable pi bridge must be on.
  4. The bridge URL must point at the broker, usually ws://127.0.0.1:7878.

First use in a pi session

All browser_* tools are registered at session start when the broker starts listening. activate_browser_agent_tools remains available as a self-check / status tool:

activate_browser_agent_tools

The full toolkit registered for the session is:

  • browser_run_task
  • browser_get_task_history
  • browser_list_tasks
  • browser_get_screenshot
  • browser_get_html
  • browser_get_dom_info
  • browser_get_computed_styles
  • browser_get_console_logs
  • browser_get_network
  • browser_get_accessibility_tree
  • browser_get_performance_metrics
  • browser_evaluate_js
  • browser_run_js
  • browser_list_tabs
  • browser_switch_tab
  • browser_close_tab
  • browser_navigate
  • browser_reload
  • browser_wait_for
  • browser_clear_site_data

Configuration

Environment variables:

  • PI_BA_HOST — broker bind host, default 127.0.0.1
  • PI_BA_PORT — broker port, default 7878
  • PI_BA_TASK_TTL_DAYS — task-history retention

If port 7878 is busy, the broker fails fast and asks you to set PI_BA_PORT.

WSL → Windows Chrome

Loopback usually works with modern WSL setups. If your Windows Chrome cannot reach the broker on 127.0.0.1:

  1. start pi with PI_BA_HOST=0.0.0.0
  2. find the WSL IP
  3. set the extension bridge URL to ws://<wsl-ip>:7878

Example:

PI_BA_HOST=0.0.0.0 pi

Notes

  • The broker never synthesizes browser input. Browser actions still go through the extension runtime and its configured input backend.
  • Large text results are truncated and the full payload is spilled to a temp file.
  • Large screenshots are spilled to a temp file instead of being inlined.