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

blablador-core

v0.1.3

Published

Shared Blablador (Helmholtz / JSC) catalog contract: fallback catalog, family/effort maps, live /v1/models merge, token normalization

Readme

blablador-core

Shared Blablador (Helmholtz / JSC) catalog contract for the two host plugins:

  • pi-blablador — the Pi provider
  • opencode-blablador — the OpenCode plugin

Before this package both hosts carried their own copy of the model catalog, the family/effort maps, the /v1/models merge and the fetch. One new alias or effort change meant editing two repos, two test suites and two releases, and they could drift silently. This package is the single place those rules live.

What lives here (and what does not)

Pure catalog logic only:

| Export | Role | |---|---| | FALLBACK_MODELS, VISION, EXTRA_CHAT, NOT_CHAT | the verified offline catalog and its allow/block rules | | EFFORT, familyOf | per-family reasoning_effort vocabularies (a wrong word is an HTTP 400) | | displayName | picker row label: the alias with the deployment root, alias-first by default (rootFirst flips it for OpenCode), or the alias alone | | mergeLiveModels, fetchLiveModels | live /v1/models filtering and root/window merge | | resolveToken | normalize a stored or env token the same way in both hosts | | outputCap | keep the output limit under the window so the prompt has room |

Host policy stays in each adapter, on purpose. Caches, TTLs, allowNetwork, force, last-good retention and fallback-on-failure differ between Pi and OpenCode and must not be unified here — that would make one host silently inherit the other's behaviour. Each adapter imports these pure functions and keeps its own refresh logic on top.

Usage

import { FALLBACK_MODELS, fetchLiveModels, resolveToken, outputCap } from "blablador-core";

Plain ESM with no build step and no dependencies, so Pi's jiti extension loader and OpenCode's plugin loader both import index.js directly. index.d.ts is the type surface for TypeScript hosts.

Tests

npm test          # network-free catalog contract — what CI and prepublish run
npm run test:live # direct /v1/models contract, needs BLABLADOR_API_TOKEN, skips when absent

The offline suite is the shared invariants. The live suite is the only test that proves discovery and auth work against the real gateway — the host suites can pass on the bundled fallback when /v1/models is broken, so the direct API assertions live here and nowhere else.

Relationship to the hosts

Both host adapters live beside this package in the blablador monorepo and pin an exact version ("blablador-core": "0.1.0"), so npm install at the repo root links this package into them — no symlinks. Published hosts resolve this package from the npm registry, so the publish order when the catalog changes is: this package first, then the hosts that want the change, with both host pins bumped in the same commit as the version bump.

What was checked

npm test: 14 offline checks — catalog invariants (unique, chat-only, window > output, >= MIN_CATALOG), required ids, the none/off level spelling both hosts depend on, the merge fixture, resolveToken trimming and precedence, and outputCap on shrunken windows. The live contract runs weekly (and on demand) via .github/workflows/live.yml once a BLABLADOR_API_TOKEN repo secret is set. Note the gateway's bad-token answer is not assertable (it varies by edge-cache state), so test/api.mjs treats that path as a NOTE and proves auth only through checks that do hold.