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

ai-stocks-bridge

v0.3.1

Published

AI Stocks Bridge -- connects your browser to local AI CLI tools (Gemini, Claude, Codex)

Readme

AI Stocks Bridge

Connects your browser to local AI CLI tools (Gemini, Claude, Codex).

A minimal HTTP server that runs on localhost:7890 and forwards analysis prompts from the AI Stocks web app to your locally installed AI CLI tools.

Quick Start

# Option 1: Run directly (requires Node.js 18+)
npx ai-stocks-bridge

# Option 2: Install globally
npm install -g ai-stocks-bridge
ai-stocks-bridge

# Option 3: Download from GitHub Releases
# https://github.com/katelin013/ai-stocks-bridge/releases

Prerequisites

At least one AI CLI tool installed:

| CLI | Install | Docs | |-----|---------|------| | Gemini CLI | npm install -g @anthropic-ai/gemini-cli | gemini.google.com | | Claude CLI | npm install -g @anthropic-ai/claude-code | claude.ai | | Codex CLI | npm install -g @openai/codex | openai.com |

API

| Endpoint | Method | Description | |----------|--------|-------------| | /health | GET | Server status + detected CLIs + session token | | /analyze | POST | Single CLI analysis | | /multi-analyze | POST | Parallel multi-CLI analysis |

Examples

# Check health
curl http://localhost:7890/health

# Single analysis
curl -X POST http://localhost:7890/analyze \
  -H 'Content-Type: application/json' \
  -d '{"prompt": "Analyze AAPL stock", "cli": "gemini"}'

# Multi-brain analysis
curl -X POST http://localhost:7890/multi-analyze \
  -H 'Content-Type: application/json' \
  -d '{"prompt": "Analyze AAPL stock", "clis": ["claude", "gemini"]}'

Security

  • Localhost only -- Listens on 127.0.0.1, no external connections accepted
  • Zero network requests -- Bridge never connects to any external server
  • Zero dependencies -- Uses only Node.js built-in modules
  • Fully open source -- Core code under 100 lines, review it yourself
  • CORS restricted -- Only allows requests from specified origins
  • Token persistence -- Session token is saved to ~/.ai-stocks/bridge.token (mode 0600) and reused across restarts. The /health endpoint returns the current token so the frontend can auto-sync without manual re-entry.

Prompt Encryption

All prompts and AI responses are encrypted with AES-256-GCM before transmission between browser and Bridge. The encryption key is derived from the session token using HKDF (SHA-256).

Important: This encryption prevents casual inspection via browser DevTools. It is not a substitute for TLS in non-localhost environments. The key derivation is deterministic from the session token -- anyone with access to the token can derive the same key.

How It Works

Browser (AI Stocks SaaS)       Your Machine
+-------------+  fetch        +------------------+
| React App   | -----------> | AI Stocks Bridge  |
| :5173       | <----------- | localhost:7890    |
+-------------+  JSON         |                  |
                               | -> gemini CLI    |
                               | -> claude CLI    |
                               | -> codex CLI     |
                               +------------------+

The Bridge acts as a thin proxy: it receives prompts from the browser, passes them to your locally installed CLI tools via subprocess, and returns the results as JSON. Your API keys and data never leave your machine.

License

MIT