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

@lapxo/obligations

v0.5.2

Published

The algebra of a cell: two poles, origins with phase, eight acts.

Readme


What it does

The operative object is the obligatory cell over a declared lattice. It retains attributed declarations and an epoch; its floor (what must hold) and ceiling (what may hold) are derived views. Its operations include:

  • Meet — what several origins hold together, or a visible conflict if they don't.
  • Exact withdrawal — take back one origin's claim without touching anyone else's.
  • Alterity — diversity and evidence readings under a declared similarity or probability model; origin names alone do not establish independence.
  • Replay — the same history gives the same answer, at any epoch.

No database, no network, no signing. Zero runtime dependencies. Lean proofs for what is proven, countermodels for what is refuted.

Quick start

npm install @lapxo/[email protected]
import { intervals, point, meetAt, origins } from '@lapxo/obligations';

const scale = intervals(0, 20);
const price = point('price', 0, [
  { origin: 'seller', span: { lo: 2, hi: 9 } },
  { origin: 'buyer',  span: { lo: 5, hi: 12 } },
]);

scale.show(meetAt(price)); // '5..9'  — what both hold
origins(price);            // 2       — named origins (not proof of two people)

Change the buyer to { lo: 10, hi: 12 } and the intersection is empty. The two declarations remain attributable; the algebra does not invent 9.5.

What you have today vs. what you get

| Today | With Obligations | | --- | --- | | Two sources disagree → last write wins, or an average | Conflict is a state; both claims stay, with who | | "Delete the value 7" | Withdraw seller's 7; buyer's 7 is untouched | | "10 sources agree" | "10 names; alterity 2.3 under this similarity model" | | Logs you reconstruct by hand | Replay the declared history to an epoch | | Trust the vendor's audit trail | Verify the algebra; proofs are in the repo |

Why this is different

1. Disagreement is a value, not an error. (u₁,w₁) ∧ (u₂,w₂) = (u₁∨u₂, w₁∧w₂): combining declarations strengthens the demand and tightens the limit. When they cannot both hold, the cell is in CONFLICT — observable, attributable, resolvable. Nothing invents a number in between.

2. Who is kept per declaration, not per count. Under a declared finite probability model, replacing a configuration X by its count K loses V = I(Y; X | K) bits about Y. V = 0 exactly when Y and X are conditionally independent given K. Different reliabilities can make attribution informative; they do not alone prove positive loss. This is why withdrawal names a declaration and why copies are grouped for measurement but never merged.

3. Measures declare what they measure. D_max (Leinster–Meckes) reads diversity from a declared symmetric similarity matrix in [0,1], with diagonal 1. N reads normalized evidence from supplied conditional laws and a named, oriented reference divergence. Their hypotheses, units and numerical policies remain explicit. Neither is a probability of being right, a count of authenticated people or authority to change a cell. A second-order approximation and shared-cause identifiability require their own model and conditions; finite evidence does not establish a universal guarantee.

4. Every result keeps its hypotheses. A proof names its theorem and axioms. A refutation is one finite counterexample. A measurement keeps its model and its status. Nothing is promoted by a metadata field.

Concepts in 60 seconds

cell      = coordinate, epoch, attributed declarations and support on a lattice
floor     = R ∧ H      R: meet of requirements, H: meet of live claims
ceiling   = S ∧ H      S: active signed limit
state     ∈ { FREE, REQUIRED, FORBIDDEN, CONFLICT }
withdraw  : names a declaration; equal content is never the target
alterity  : D_max from similarity · N from conditional laws · L from a copy model

Lattices can be intervals, finite alphabets, information partitions or any domain with the required order laws. Coordinates are supplied by the application.

Entry points

| Import | Purpose | | --- | --- | | @lapxo/obligations | cell algebra, declarations, forms, regions | | /measures | diversity, evidence, region measures, projection loss | | /field /encounter /present | regions, observations, epochs, encounters | | /lattice /forms | orders, intervals, alphabets | | /debit /packed /price | constraint operations, packed states, price | | /signatures /replay | projection of signed declarations, replay | | /views/field /views/product | declared views |

ESM · Node.js ≥ 22.12 · TypeScript declarations included.

What it does not do

It does not fetch evidence, choose trusted origins, sign declarations or decide who may change what. Authentication, admission, storage and application policy belong to the consumer. The algebra has no dependency on a particular host, verifier or product.

Evidence

Ochoa, N. (2026). Two-Sided Constraints on a Valued Lattice (1.0.0). Zenodo. 10.5281/zenodo.21858428. Used under its published hypotheses (Remark 1.1, Definitions 2.4 and 2.6, Proposition 2.5, Theorem 2.8, Corollary 2.10).

MIT.