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

@disclosureos/scoring

v1.0.0

Published

Reference scoring for the DisclosureOS ecosystem — record completeness and case compellingness across the Observables and Origin layers

Readme

@disclosureos/scoring

License: MIT

Reference scoring for the DisclosureOS ecosystem — the Scoring layer. It turns an enriched Observation into two orthogonal measures:

  • Completenessis it well-documented? What fraction of the record's fields are present.
  • Compellingnessis it anomalous / non-mundane? Derived from the observable assessments and origin classification.

The DisclosureOS model

DisclosureOS is a five-part standard. Each part answers one question about an observation; @disclosureos/schema binds the package-owned pieces into one portable contract (a single TS type + JSON Schema + non-stripping parse).

| Part | Package surface | Question it answers | |---|---|---| | Records | @disclosureos/records | What was observed? | | Observables | @disclosureos/observables | What anomalous characteristics did it show? | | Origins | @disclosureos/origins | What might explain it? | | Claims | @disclosureos/records/shared | Who assessed it, why, and on what evidence? | | Scoring | @disclosureos/scoring | How complete / compelling is the case? |

Supporting packages: @disclosureos/schema (the portable contract that composes the package-owned pieces), @disclosureos/cli (tooling), and @disclosureos/examples (the runnable golden path). (You are here: Scoring.)

Consumes the foundation (does not augment it)

Unlike observables and origins, scoring only consumes the foundation — it reads observableAssessments and origin but adds no slot to Observation. It depends on @disclosureos/records, @disclosureos/observables, and @disclosureos/origins, so importing it gives you those slots typed automatically.

See it end to end. examples/golden-path.ts takes one observation through every layer — records → observables → origins → scoring, validated as a whole by @disclosureos/schema — in a single type-checked file. Run it with pnpm --filter @disclosureos/examples golden-path.

Migrating an existing dataset? See examples/migration-path.ts and the onboarding workspace.

Install

pnpm add @disclosureos/scoring @disclosureos/records @disclosureos/observables @disclosureos/origins zod

Quick start

import { score, getCompleteness, rankByCompellingness } from '@disclosureos/scoring';

const result = score(observation);
// { score, range: { low, high }, contested, ... }

const completeness = getCompleteness(observation);
// { percentage, requiredPercentage, missing, ... }

const ranked = rankByCompellingness([obsA, obsB, obsC]); // most-compelling first

Because evaluative slots hold arrays of competing claims, score() reports a range (the spread across claims) and a contested flag when evaluators disagree — not just a single point estimate.

Subpath exports

| Subpath | Contents | |---|---| | @disclosureos/scoring | score, rankByCompellingness, getCompleteness, DEFAULT_WEIGHTS | | @disclosureos/scoring/completeness | Completeness scoring + deriveFieldPaths | | @disclosureos/scoring/compellingness | Compellingness scoring + weights | | @disclosureos/scoring/schema | The committed JSON Schema (scoring.schema.json) |

Standard Schema

The Zod schemas here (ScoreResultSchema, CompletenessResultSchema, …) implement Standard Schema v1 via their ~standard property — a guarantee of Zod 4. Any Standard-Schema-compatible validator or framework can consume them directly, with no DisclosureOS-specific adapter.

License

MIT © Disclosure Foundation