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

peerline-cli

v1.0.2

Published

Peerline CLI — run buyer, seller, and registry nodes from the command line

Readme

peerline-cli

The official command-line interface for the Peerline decentralized peer-to-peer AI inference marketplace.

The Peerline CLI (peerline-cli) is a comprehensive tool designed to orchestrate, configure, and monitor decentralized AI services. With it, you can become an AI resource provider (Seller) by hosting local models, run an autonomous gateway client (Buyer) with cryptographic micro-payment channels, spin up a central discovery registry, or control onchain smart contract operations (DIEM locking and ANTS incentives) directly from your terminal.


🛠️ Installation

Ensure you have Node.js (v18 or higher) installed on your system.

Install globally via NPM:

npm install -g peerline-cli

Or run directly using npx:

npx peerline-cli [command]

🚀 Quick Start (Run All Nodes)

To boot up a local test environment, including a Hardhat EVM Node, Registry Directory, Buyer Proxy, and 50-node P2P seller network simulator simultaneously, run:

peerline start

📋 Command Directory

🟢 peerline seller (Become an AI Provider)

Monetize your computing power or upstream API keys by exposing Peerline endpoints.

  • Setup Configuration Wizard:

    peerline seller setup

    An interactive CLI wizard that helps you specify your onchain merchant address, configure your models/services list, set pricing parameters (USDC rates per million tokens), and hook up LLM backend providers (Ollama, vLLM, OpenRouter, Together). Creates ~/.peerline/config.json.

  • Start Node:

    peerline seller start

    Loads your local configuration, establishes optional secure public tunnels (via localtunnel), registers your node endpoint with the discovery registry, and starts serving incoming buyer inferences.

  • View Earnings & Statistics:

    peerline seller status

    Displays real-time uptime, aggregated latency percentiles, input/output token volume served, and total USDC earned & ready to settle.

  • Check Metrics:

    peerline seller metrics

    Outputs live, raw Prometheus text format metrics for integration with monitoring stacks (e.g. Grafana).


🔵 peerline buyer (API Client Gateway)

Route inference requests to the best available sellers and sign off-chain micro-payments dynamically.

  • Start Local Buyer Proxy:

    peerline buyer start

    Launches a local gateway on Port 8377. You can redirect your existing OpenAI or Anthropic API tools here (e.g., export OPENAI_BASE_URL=http://localhost:8377/v1) to automatically access the decentralized network.

  • Manage Pin Connections: Choose to route all requests to a specific peer rather than relying on automated reputation scores.

    peerline buyer connection set --peer <peerId>
    peerline buyer connection clear
  • Check Proxy Status & Escrow Budgets:

    peerline buyer status

    Displays your proxy stats, reputation metrics, connected signer wallets, and active channel details (escrow allocations, cumulative spends).

  • Review Peer Reputation Scores:

    peerline buyer reputation

    Lists all peers that you have transacted with, along with their success rate, P95 latency response, and derived reliability scores.


🟣 peerline registry (Peer Directory)

Manage the discovery network directories.

  • Start Registry Server:

    peerline registry start

    Spawns the liveness lookup hub on Port 9000 mapping Peer IDs to URLs and offerings.

  • Registry Metrics:

    peerline registry metrics

    Check the total count of registered nodes, active heartbeats, and pruning counts.


💎 peerline diem (Onchain Escrow Capacity)

Participate in the DIEM Provider Capacity Program by locking tokens to secure your node slot and claiming incentives.

  • Check Onchain ESCROW status:

    peerline diem status

    Displays your DIEM token address, total locked capacity, and queued withdrawals.

  • Lock Capacity Tokens: Lock your DIEM tokens to increase your provider reputation and capacity score:

    peerline diem lock <amount>
  • Claim Network Incentives: Claim accumulated $ANTS native network rewards for your active hosting capacity:

    peerline diem claim

🔍 peerline network (Discovery & Exploration)

  • Browse Registered Offerings:

    peerline network browse [--model <model_name>]

    Lists all active seller nodes registered in the network, sorted by recency and filtered by specific model capabilities.

  • Examine Peer Metadata:

    peerline network peer <peerId>

    Fetches raw registration metadata, endpoint routes, supported models, and merchant wallet addresses for any individual Peer ID.


🔒 Security & Payments

The Peerline CLI relies on standard Ethereum signatures (EIP-712 typed structured data). All payment requests utilize EIP-402 micro-payment headers (x-402-payment-auth and x-402-channel-id). The CLI signs payment envelopes completely local on your machine, ensuring your private keys never leave your terminal environment.

📄 License

Peerline CLI is distributed under the ISC License.