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

@critiquedotsh/harness

v0.1.14

Published

CritiqueCode author agent — implement, then forced review and verified repair. Same org as @critiquedotsh/cli; not the sidecar.

Readme

CritiqueCode (@critiquedotsh/harness)

CritiqueCode is an author agent for a local git repository. It implements in an interactive terminal session, then the controller forces independent review and verified repair. It is a Claude Code / Codex-style coding loop, not a PR comment bot.

| Product | npm package | Binary | Job | | --- | --- | --- | --- | | CritiqueCode (this package) | @critiquedotsh/harness | critique-code | Author: write the change, then survive review | | Critique CLI | @critiquedotsh/cli | critique | Sidecar reviewer for agents you already run |

Same npm org. Different products. Do not install CritiqueCode by swapping @critiquedotsh/cli. Native evidence stays on /review. /critique and critique_cli spawn the installed critique sidecar when you want that binary.

Docs: CritiqueCode · Inference API · Critique CLI

Requirements

  • Node.js 20.19 or newer
  • A git repository (run the binary in the project you want to edit)
  • A model route: Critique Inference (website login, no pasted key) or a BYOK provider key

Optional:

  • The live author kernel (installed automatically as an optional dependency)
  • ffmpeg-static (optional dependency; bundled microphone recorder for /voice)

Install

npm install --global @critiquedotsh/harness

Confirm the binary:

critique-code help

Always cd into the repository you intend to change. CritiqueCode uses the current working directory.

cd /path/to/your-project
critique-code

From a Critique platform checkout (not the published install):

cd /path/to/your-project
node /path/to/critique/packages/critique-code/bin/critique-code.mjs

pnpm critique-code from the Critique checkout uses that checkout as cwd unless you pass --cwd. That is the wrong default when you are trying the agent on another project.

Quick start (no API key paste)

  1. Install the package.
  2. Enter your repo.
  3. Connect Critique Inference in the browser:
cd /path/to/your-project
critique-code login

The terminal prints a URL and a short code, opens the browser when it can, and waits. Approve on critique.sh/device. CritiqueCode stores a machine key under ~/.critique/code/ and sets the default route to Critique Inference with model critique/auto.

Same flow from an already-open session: type /login.

Then:

critique-code

Or skip the TTY and open a local browser UI (still the same author kernel in this process, bound to 127.0.0.1 only):

critique-code web

Pair a phone to that same laptop process (Wi-Fi PIN, Slack/Telegram DM, or --anywhere with your own tunnel). The kernel never moves to Critique Cloud:

critique-code remote
critique-code remote --slack --anywhere
critique-code slack

Drive it from the website instead. Open critique.sh/connect, click Connect this PC, then paste the printed code on this machine:

critique-code connect K7M2-9QWX

The site is a remote, not a runner: prompts, approvals, and event output relay through critique.sh, but the kernel and every file write stay on this laptop. It needs critique-code login (a crt_ key) so the laptop can claim the code outbound.

Describe the change. Slash lines (/review, /ship, …) are never sent to the model.

What a session does

  1. Author implements in the working tree (writes go through a content-addressed apply path).
  2. You can ask the model to run a workspace command via critique_run. You approve or deny each request. Denied means nothing runs. Networked runs are disabled unless a controller explicitly provides an enforced sandbox. Output is not Evidence.
  3. /review or /ship starts the evidence harness. Author chat is withheld from the reviewer.
  4. /repair runs verified repair on promoted findings. It is not auto-applied chatter.
  5. none_promoted means nothing was promoted. It is not a correctness proof.

EOF attempts to review dirty work, while /exit records an incomplete session without claiming completion. The session store keeps only the task contract, review handoff, capsule digest, and bounded status—not the author transcript. A later invocation resumes only when the repository still matches that digest; stale state is surfaced explicitly. Partial or failed reports cannot satisfy /done or /ship without an auditable user override.

The author can fan out critique_task workers (explore is read-only; general / implement can write through the same CAS path). Independent native review is still /review, not a worker. critique_cli spawns the installed Critique CLI sidecar when you ask for that binary. critique_run still needs your approval. Workers cannot nest critique_task or critique_cli.

The TTY shows a wordmark, a compact live status (thinking / write path / task explore …), then a one-line summary before the reply. It does not stream thinking paragraphs.

Interactive TTY sessions keep stdout quiet. Pass --json for the session envelope. review, repair, and capabilities still print JSON on stdout. Live chrome goes to stderr.

CLI

critique-code
critique-code chat [--intent <text>] [--models provider/model,...] [--cwd <dir>] [--store <dir>] [--voice] [--json]
critique-code web [--port <n>] [--cwd <dir>] [--store <dir>] [--models ...]
critique-code remote [--anywhere] [--site] [--slack] [--telegram] [--port <n>] [--cwd <dir>]
critique-code connect [CODE] [--cwd <dir>]
critique-code slack [--port <n>] [--cwd <dir>]
critique-code telegram [--port <n>] [--cwd <dir>]
critique-code login
critique-code settings | keys | models
critique-code review [--depth quick|standard|paranoid] [--focus general,security] [--models ...] [--base <ref>] [--intent <text>] [--cwd <dir>] [--store <dir>]
critique-code repair <review-run-id> [--store <dir>] [--cwd <dir>] [--models ...]
critique-code critique [sidecar argv...] [--cwd <dir>]
critique-code capabilities [--cwd <dir>]
critique-code skills [--cwd <dir>]
critique-code import-skills [--cwd <dir>]
critique-code help

| Command | Purpose | | --- | --- | | critique-code / chat | Interactive author session | | web | Local browser UI on 127.0.0.1 (same author kernel; no TTY required) | | remote | Phone pairing to this laptop: LAN PIN, optional --anywhere tunnel. Not Critique Cloud. | | connect [CODE] | Register this PC on critique.sh/connect. The website is a remote; the kernel stays here. | | slack / telegram | Outbound bots. DM the agent from those apps; the kernel stays in this process. | | login | Browser device approval; connect Critique Inference | | settings / keys / models | TUI for route, stored keys, and model ids | | review | Evidence harness (JSON on stdout) | | repair <id> | Verified repair for a stored review run | | critique [argv…] | Spawn the installed Critique CLI sidecar (critique review --json by default) | | capabilities | Discovered local check tools | | skills | Built-in plus imported Claude Code / Codex / Cursor SKILL.md folders | | import-skills | Copy discovered skills into ~/.critique/code/skills |

Flags

| Flag | Meaning | | --- | --- | | --cwd <dir> | Repository to edit (default: process cwd) | | --store <dir> | Where review/repair artifacts are stored | | --models <list> | Comma-separated provider/model or provider:family:model_id, or a JSON array | | --intent <text> | Starting author or review intent | | --depth quick\|standard\|paranoid | Review depth | | --focus general,security,... | Review lenses: general, stress, security, performance, reliability | | --base <ref> | Review against a git base ref (not a checkout) | | --voice | Start the author session in voice mode | | --json | Print the session envelope on stdout even on a TTY | | --port <n> | Loopback port for critique-code web (0 = ephemeral) | | --anywhere | For remote: publish an outbound cloudflared or ngrok URL. Still this laptop. | | --slack / --telegram | Attach those portals to web / remote | | -h / help | Help |

critique-code review is read-only. Use critique-code repair <review-run-id> for explicit repair. --repair apply on review is rejected.

Interactive commands

Type / or /help for a selectable picker. Lines that start with / never go to the model.

| Command | Effect | | --- | --- | | / /help | Picker / help | | /login | Connect Critique Inference in the browser | | /remote | Pair a phone; this laptop stays the agent | | /slack | Attach Slack Socket Mode | | /telegram | Attach a Telegram bot | | /voice | Record one spoken prompt (Qwen3 ASR) | | /voice on | Keep listening after each reply | | /voice off | Return to the keyboard | | /goal <objective> | Set one durable author objective; include the intended end state and proof loop | | /goal / /goal status | Show the objective, lifecycle, and latest native review state | | /goal edit <objective> | Change and resume the current objective | | /goal pause / /goal resume / /goal clear | Control or remove the durable objective | | /review | Evidence harness since the last review checkpoint | | /review all | Evidence harness on the current tree even if unchanged | | /critique | Spawn the Critique CLI sidecar (critique review --json) | | /critique finish | Sidecar finish --repair pack; apply stays an explicit slash | | /repair | Verified repair of promoted findings | | /ship | Review, then end if the controller allows | | /settings | Keys, route, models | | /models | Pick author/review model | | /keys | Store BYOK keys | | /skills | List built-in and imported skills | | /done | End after a review | | /exit | Leave |

Spoken review, repair, ship, and exit match the typed commands when voice is on. An empty clip after /voice on returns to the keyboard.

Unknown /foo is rejected in the TUI. It is not forwarded as chat.

Durable goals

/goal keeps one controller-owned objective with the resumable author session; it is restored after a process restart without retaining the raw author transcript. An active goal autonomously takes bounded checkpoint turns until it pauses, requests final verification, or becomes genuinely blocked. Every eight autonomous turns, CritiqueCode compacts the author context and opens a fresh author kernel with the durable task, live workspace state, controller evidence, and the active goal—so a long run does not depend on an ever-growing transcript. There is no implicit one-day ceiling for an interactive goal.

The author cannot mark a goal complete. It can only request final verification through critique_goal; the controller then runs validation and native /review on the current workspace. A qualifying clean result records the goal as complete; an unresolved completion decision records it as blocked. Pausing a goal preserves it but stops autonomous turns and goal injection.

Voice mode

Talk to the author and the reviewer. /voice records one clip (Enter to stop). /voice on keeps listening after each reply. /voice off returns to the keyboard. critique-code --voice starts already listening.

Transcription uses Qwen3 ASR 0.6B (qwen/qwen3-asr-0.6b) on Critique Inference, billed at $0.000003 per second of audio. An OpenRouter key works if you are not on Inference. The recorder is bundled ffmpeg-static; you do not need a system sox or ffmpeg install.

Needs a microphone and an interactive TTY. Voice is dictation in. Replies stay on screen. Docs: CritiqueCode voice mode.

Skills

Built-in author skills cover code review, Critique /review, and TDD. Sessions also load SKILL.md from Claude Code, Codex, Cursor, OpenCode, and Agents folders in the repo and your home directory. No export step required. Built-in names win on collision. critique-code import-skills copies them into ~/.critique/code/skills.

Models and billing

Default: Critique Inference

After critique-code login or a crt_ / CRITIQUE_API_KEY, the default route is Critique Inference and the default model is critique/auto.

critique/auto is a session coding selector over Critique-resold models: efficient specialists first, sticky while the loop is healthy, one escalate onto a frontier rung if tools keep failing. It does not search the full OpenRouter catalogue.

Managed Inference traffic bills raw USD:

inputUsd  = (prompt_tokens      / 1_000_000) × input_rate_per_M
outputUsd = (completion_tokens  / 1_000_000) × output_rate_per_M

That spend does not consume the PR review credit pool. Rate cards and critique/auto live on critique.sh/inference-api.

Voice transcription uses Qwen3 ASR 0.6B (POST /api/v1/audio/transcriptions) at $0.000003 per second of audio.

Bring your own key

/keys and environment variables still accept other providers. If Critique Inference is connected, it stays the default until you change the route in /settings.

| Provider | Environment | | --- | --- | | Critique Inference | CRITIQUE_API_KEY or CRITIQUE_INFERENCE_API_KEY | | OpenRouter | OPENROUTER_API_KEY | | OpenAI | OPENAI_API_KEY | | Anthropic | ANTHROPIC_API_KEY or ANTHROPIC_AUTH_TOKEN | | Google Gemini | GEMINI_API_KEY or GOOGLE_API_KEY | | xAI | XAI_API_KEY | | Groq | GROQ_API_KEY | | DeepSeek | DEEPSEEK_API_KEY | | LLM Gateway | LLM_GATEWAY_API_KEY or LLMGATEWAY_API_KEY | | Vercel AI Gateway | AI_GATEWAY_API_KEY | | Custom OpenAI-compatible | CUSTOM_OPENAI_API_KEY plus base URL in settings |

OpenRouter default when that route is selected: deepseek/deepseek-v4-flash-0731.

OpenRouter Activity attributes CritiqueCode traffic to critique.sh (HTTP-Referer: https://critique.sh, title critique.sh), not to the underlying agent kernel.

Also:

  • CRITIQUE_CODE_HOME — override ~/.critique/code
  • CRITIQUE_CODE_MODELS — same model list syntax as --models
  • CRITIQUE_INFERENCE_BASE_URL — override https://critique.sh/api/v1
  • CRITIQUE_SITE_URL — site origin for device login (default derived from the inference URL)
  • CRITIQUE_CODE_PI_DRIVER=off — disable the live author kernel (sessions stay kernel_required)
  • SLACK_BOT_TOKEN + SLACK_APP_TOKEN — Slack Socket Mode (outbound). Optional CRITIQUE_CODE_PORTAL_USERS
  • TELEGRAM_BOT_TOKEN — Telegram long poll (outbound). Optional CRITIQUE_CODE_PORTAL_CHATS
  • CRITIQUE_CODE_PORTAL_SECRET — shared secret for POST /api/portal/inbound from other portals
  • CRITIQUE_CODE_TUNNEL — prefer cloudflared or ngrok for --anywhere

Remote phone and portals

The agent is this process on this laptop. Phone, Slack, Telegram, and the website are remotes. They are not Critique Cloud.

  1. Leave the machine awake with the session running.
  2. Same Wi-Fi: critique-code remote, open the LAN URL on the phone, enter the PIN from the terminal.
  3. Anywhere: DM the Slack or Telegram bot (critique-code slack / critique-code telegram / --slack). Those open outbound sockets. No inbound port.
  4. Website: critique-code connect CODE after critique-code login claims the PC from critique.sh/connect. The site relays prompts and approvals; the kernel stays here.
  5. Optional --anywhere uses your cloudflared or ngrok. The tunnel is a pipe. Writes still happen in this working tree.

Slack Socket Mode needs SLACK_BOT_TOKEN (xoxb-) and SLACK_APP_TOKEN (xapp-) with message events. Telegram needs TELEGRAM_BOT_TOKEN. Optional allowlists: CRITIQUE_CODE_PORTAL_USERS, CRITIQUE_CODE_PORTAL_CHATS.

From an already-open TTY: /remote, /slack, /telegram.

Files on disk

Nothing secret is written into the repository.

| Path | Contents | | --- | --- | | ~/.critique/code/auth.json | Stored API keys (mode 0600) | | ~/.critique/code/settings.json | Route and model selection | | ~/.critique/code/portals.json | Slack / Telegram / webhook portal tokens (mode 0600) | | Review/repair store | Outcomes and repair artifacts (--store or the default store root) |

Project REVIEW_GUIDELINES.md is loaded as a review constraint. AGENTS.md, CRITIQUE.md, and CLAUDE.md can seed author instructions.

Safety

  • The model cannot pick a working directory, open a network path, or run a process on its own.
  • critique_run is the only workspace exec path. You approve or deny each call; networked commands require an enforced controller sandbox and are disabled by default. Output is not Evidence.
  • Promotion of findings stays on /review and /ship.
  • Named checks are controller-owned. Author check output is not Evidence.
  • none_promoted is not a proof that the tree is correct.

Exit codes

| Code | Meaning | | --- | --- | | 0 | OK | | 2 | Usage error | | 3 | kernel_required (no live driver and/or no model route) | | 4 | Blocked (review/repair ineligible, stale capsule, …) | | 5 | Infrastructure error |

Runtime

The live author kernel installs automatically with the package and runs in this process. Default models go through Critique Inference after critique-code login. An OpenRouter key is optional BYOK for power models outside Inference.

If the optional kernel dependency failed to install, reinstall the package. Set CRITIQUE_CODE_PI_DRIVER=off only when you want to disable the kernel on purpose.

License

MIT

Links

  • npm: https://www.npmjs.com/package/@critiquedotsh/harness
  • Docs: https://critique.sh/docs/platform/critique-code
  • Inference API: https://critique.sh/inference-api
  • Issues: https://github.com/repath500/critique/issues
  • Sidecar CLI: https://www.npmjs.com/package/@critiquedotsh/cli