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

@roshanclearlane/clearlane-mcp

v0.1.0

Published

Audit-ready bus reliability investigations from MTA, NYC Open Data, 311, and optional vision evidence.

Readme

ClearLane MCP

Audit-ready bus reliability investigations from MTA + NYC Open Data + optional vision evidence.

ClearLane MCP is an npm-installable CLI and MCP stdio server for civic technologists, agency analysts, and hackathon teams investigating slow NYC bus corridors. It combines MTA route speed data, NYC Open Data, 311 complaints, optional image/video evidence, transparent scoring, and an append-only hash-chained audit ledger.

ClearLane is not a generic chatbot. It is an MCP-enabled investigation workflow for transit reliability.

Government Problem

Bus speeds and reliability are hurt by traffic, curb conflicts, double parking, blocked stops, delivery activity, and lane encroachment. Agencies often have relevant APIs, open datasets, 311 complaints, field photos, and analyst knowledge, but the evidence is scattered. ClearLane turns that evidence into a single operational report that answers:

Why is this route or corridor slow, where are the bottlenecks, what evidence supports the finding, and what operational actions should DOT/MTA consider?

Why Auditability Matters

Every ClearLane run writes audit-log.ndjson, an append-only ledger where each event includes source references, query context, timestamps, claims, confidence, output references, and a SHA-256 hash chain. The companion audit-manifest.json records artifact hashes and the final ledger hash so a reviewer can detect tampering.

Installation

npm install
npm run build

Or use the package through npx after publishing:

npx @roshanclearlane/clearlane-mcp init --client cursor

Quickstart

npx @roshanclearlane/clearlane-mcp init --client cursor
npx @roshanclearlane/clearlane-mcp audit --route M15 --borough Manhattan --period weekday_am --mock --out ./output

Local development:

npm run build
node dist/cli/index.js init --client cursor --local
node dist/cli/index.js audit --route M15 --borough Manhattan --period weekday_am --mock --out ./output
node dist/cli/index.js verify-ledger ./output/audit-log.ndjson

MCP Setup

Cursor:

npx @roshanclearlane/clearlane-mcp init --client cursor

Codex:

npx @roshanclearlane/clearlane-mcp init --client codex

OpenCode:

npx @roshanclearlane/clearlane-mcp init --client opencode

All clients:

npx @roshanclearlane/clearlane-mcp init --client all

Local MCP configs use:

node ./dist/mcp/server.js

MCP Prompt Example

Use ClearLane to audit the M15 route for weekday AM reliability. Use mock mode if live APIs are unavailable. Generate the report and verify the audit ledger.

CLI Examples

clearlane doctor
clearlane audit --route M15 --borough Manhattan --period weekday_am --mock --out ./output
clearlane analyze-evidence ./input/evidence --out ./output --mock
clearlane report --from ./output/route-health.json --out ./output
clearlane verify-ledger ./output/audit-log.ndjson
clearlane inspect-source --dataset kufs-yh3x --limit 5

Environment Variables

OPENAI_API_KEY=
MTA_API_KEY=
NYC_OPEN_DATA_APP_TOKEN=

Behavior:

  • Missing MTA_API_KEY: real-time MTA Bus Time calls are skipped.
  • Missing NYC_OPEN_DATA_APP_TOKEN: anonymous Socrata requests still work, but may be throttled.
  • Missing OPENAI_API_KEY: optional vision analysis is skipped unless --mock is used.

clearlane doctor reports presence only and never prints secret values.

Output Artifacts

output/
  report.md
  report.pdf
  metrics.json
  route-health.json
  slow-segments.geojson
  recommendations.json
  audit-log.ndjson
  audit-manifest.json
  evidence/
    analyzed-frame-001.jpg
    analyzed-frame-002.jpg

Privacy Posture

ClearLane does not identify people, read or report license plates, track individuals, infer protected attributes, perform biometric analysis, or make legal/enforcement determinations. Evidence findings are operational and always marked for human review.

Every report states:

ClearLane is a decision-support tool. Findings are based on available data and optional visual evidence. They require human review before operational, enforcement, or policy action.

Demo Mode

The demo never requires API keys:

npm run demo

Mock M15 output includes 12 segments analyzed, 3 priority bottlenecks, 5.8 mph lowest observed average speed, 42 relevant 311 complaints, 2 optional vision findings, and 4 recommendations.

Limitations

  • Live public dataset schemas may change; ClearLane uses schema-flexible adapters and falls back to mock data when needed.
  • Geo matching is intentionally lightweight for hackathon use.
  • Vision evidence is decision support only and requires human review.
  • The package is published under the maintainer-owned @roshanclearlane npm scope.

Publishing

Do not publish unless the repo owner explicitly authorizes it and npm credentials are available.

Maintainer local flow:

npm login
npm whoami
npm run typecheck
npm run lint
npm test
npm run build
npm run pack:dry
npm run publish:dry
npm publish --access public

If npm Trusted Publishing is connected to this GitHub repository, use the Release workflow from GitHub Actions. The workflow publishes with provenance using GitHub OIDC and does not require an NPM_TOKEN secret.

License

MIT