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

@crewhaus/continuity-store

v0.4.0

Published

v0.3.0 Goal 1 — focus/plans/goals/handoff stores under .crewhaus/state/ with the claimed→proven proof ladder verified against session event logs, trash/restore clearing, advisory locking, and tenant path fencing.

Readme

@crewhaus/continuity-store

v0.3.0 Goal 1 (design §2.2–§2.7): the continuity substrate. Human-readable, user-clearable focus/plans/goals/handoff artifacts under .crewhaus/state/<specName>/, with the claimed → proven proof ladder machine-checked against session event logs. No model call anywhere in this package — everything is deterministic infrastructure.

Storage layout

.crewhaus/state/<spec>/
  focus.md                  # marker-gated (<!-- crewhaus:focus -->), body capped
                            # at focusMaxChars; carries the REQ-nnn requirements
                            # ledger and the active-plan pointer
  plans/plan-NNNN-<slug>.md # YAML frontmatter + numbered steps with ladder
                            # statuses and frozen proof excerpts
  goals.yaml                # {id, title, status, target?, current?, unit?}
  handoff.md                # deterministic teardown render (same inputs →
                            # identical bytes)
  .lock                     # advisory single-writer lock

Why files + markers: matches project-memory's LESSONS.md precedent — a user-authored focus.md/handoff.md without the crewhaus marker is never overwritten. Why JSONL-adjacent formats: everything is inspectable with cat/git diff, and every write is tmp+rename atomic.

import { createContinuityStore } from "@crewhaus/continuity-store";

const store = createContinuityStore({ specName: "support-bot" });
await store.writeFocus("Ship CSV export");
await store.createPlan({ title: "Ship CSV export", steps: ["Parse", "Export"] });
await store.setStepStatus("plan-0001", 1, "claimed");            // always free
await store.proveStep("plan-0001", 1, [{ toolUseId: "tu_…" }]);  // machine-checked
await store.writeHandoff({ lastSessionId: "sess_…" });

The proof ladder (§2.4)

Statuses: open → in_progress → claimed → proven.

  • claimed never requires anything — zero friction, no gaming pressure.
  • proven is earned: proveStep / updateGoal({status: "proven"}) resolve each cited toolUseId against the append-only session JSONLs — including sub-agent child sessions, discovered by walking the sub_agent_start bracket events (childSessionId). Missing ids and isError: true results reject with instructive errors (no verified evidence for tu_…: run the action first, then complete the step with its toolUseId.).

Proof lifetime: session transcripts are TTL-evicted, so on every proven transition the store (a) appends a retention pin for the cited session to .crewhaus/retention.json (the pin contract session-store and crewhaus retention honor) and (b) freezes a {toolName, inputHash, resultDigest} excerpt into the plan/goal record — evidence outlives the transcript.

Requirements ledger (§2.3)

appendRequirement({text, source: {sessionId, turn}, status?}) records the user's words verbatim (there is deliberately no paraphrase field) as REQ-nnn entries with (user, sess_…, turn N) attribution inside focus.md. Updating an existing id requires the identical text — paraphrase attempts are rejected. The ledger is byte-capped (16 KB) with oldest-first eviction and a [ledger truncated] marker.

Clearing (§2.6): trash + undo, never hard-delete

clear("focus" | "plans" | "goals" | "all") moves files to .crewhaus/trash/<ISO-ts>/… preserving relative paths; restore(ts) puts them back (fail-closed on conflicts); listTrash() enumerates snapshots. The moveToTrash(paths, crewhausDir) helper is exported for other .crewhaus stores to adopt the same clearing story.

Locking (§7.6)

Mutations take an advisory .lock (O_EXCL create): wait up to 2 s → steal if the lock's mtime is >30 s stale (a lock_stolen warning is recorded) → fail with an error naming the holder pid. Reads never lock; atomic writes keep readers consistent regardless.

Scoping + tenancy (§2.7)

  • scope: {kind: "spec"} (default) — one store per spec.
  • scope: {kind: "session", sessionId} — nests under <spec>/sessions/<sessionId>/ for per-conversation state (channel daemons).
  • Tenant contexts (ambient withTenant or an explicit tenant option) apply the same fail-closed path fencing session-store enforces: any resolved path outside the tenant's root throws (CWE-1230).

Consumers

@crewhaus/tool-plan wraps this store as RegisteredTools (FocusRead/Write, PlanRead/Update/Complete, Goal*, MemoryClear). Runtime wiring (the mutable tail block, context_evicted externalization, handoff-at-teardown) lands in the runtime-core continuity PR; CLI verbs (crewhaus memory clear|restore|show) in the apps-cli PR.