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

@wzrd_sol/attestation-writer

v0.1.0

Published

Write TWZRD reputation scores as on-chain Solana attestations (SAS) in an ERC-8004 / SATI-compatible shape. TWZRD as the canonical Solana scoring provider for the agent-registry standard.

Readme

@wzrd_sol/attestation-writer

Write TWZRD reputation scores as on-chain Solana attestations, in a shape compatible with the ERC-8004 Reputation Registry and the SATI / Solana Agent Registry standard.

Why

ERC-8004 and its Solana port (SATI) ship their Reputation Registry empty — the standards deliberately store only the raw feedback primitive and defer score aggregation to off-chain third parties. TWZRD already runs the only cross-facilitator payment-behavior corpus on Solana (with wash-fleet detection). This package writes those scores into the canonical on-chain registry, so a TWZRD score is portable, verifiable, and reads back through any ERC-8004/SATI-aware tool — making TWZRD the scoring provider the standard left blank.

Two layers

1. Pure mapping core (no chain dependencies)

mapScoreToAttestation() converts a TWZRD corpus reputation record into ERC-8004/SATI attestation fields. Deterministic, dependency-free, fully unit-tested offline.

import { mapScoreToAttestation, Outcome } from "@wzrd_sol/attestation-writer";

const mapped = mapScoreToAttestation({
  reputation_score: 87,                       // 0-100
  reputation_confidence_bps: 9000,            // or `confidence: 0.9`
  reputation_score_version: "intel_renorm_v1",
  reputation_data_quality: "cross_facilitator",
  wash_flagged: false,
});
// → { value: 87, valueDecimals: 0, tag1: "trust", tag2: "intel_renorm_v1",
//     outcome: Outcome.Positive, score: 87, confidenceBps: 9000, content: "{...}" }

2. On-chain writer (optional peer dep sas-lib)

Issues a raw Solana Attestation Service (SAS) attestation under a TWZRD-owned Credential + Schema — full control, no dependency on SATI's SDK. sas-lib is an optional peer dependency: the mapping core works without it; install sas-lib@^1.0.10 only to write on-chain.

import { buildSetupInstructions, buildAttestationInstruction } from "@wzrd_sol/attestation-writer";

// One-time per issuer: create the TWZRD credential + twzrd.reputation.v1 schema
const { createCredentialInstruction, createSchemaInstruction, credentialPda, schemaPda } =
  await buildSetupInstructions({ authority, payer, authorityAddress });

// Per subject: build the attestation instruction (caller sends the tx)
const { instruction, attestationPda, mapped } = await buildAttestationInstruction({
  reputation, subject, authority, payer, schemaAccount, schemaPda, credentialPda,
});

The writer returns instructions + derived PDAs; the caller assembles and sends the transaction (lets you batch and own RPC/signing).

Field mapping (TWZRD → ERC-8004 / SATI)

| TWZRD corpus field | ERC-8004 / SATI field | Notes | |---|---|---| | reputation_score (0-100) | value (int128) + valueDecimals (=0) | Spec example: 87 → value 87, decimals 0 | | derived from score + wash_flagged | outcome (0=Neg, 1=Neutral, 2=Pos) | wash-flagged → always Negative | | reputation_confidence_bps / confidence | confidence (0-10000 bps) | bps preferred; fraction ×10000; default 8000 | | reputation_score_version | tag2 (string) | e.g. intel_renorm_v1 | | (fixed) | tag1 (string) | default "trust" | | score + provenance | SATI content (JSON) | score, confidence, version, data_quality, window, wash flag |

Key addresses

| Item | Value | Source | |---|---|---| | SAS program (mainnet) | 22zoJMtdu4tQc2PzL74ZUT7FrwgB1Udec8DdW4yw4BdG | CONFIRMED (program lib.rs + generated client) | | SATI program (mainnet) | satiRkxEiwZ51cv8PRu8UMzuaqeaNU9jABo6oAFMsLe | Cascade Protocol docs | | TWZRD receipt pubkey | 9V6Pn19kiUA5Rn6JpQfNduanvGt2aXGwsarosNfa2Ldf | intel.twzrd.xyz/.well-known/x402 |

Unverified / before-mainnet checklist

This is a spike. The pure mapping core is tested and final; the on-chain leg is wired against the verified sas-lib API but not yet executed against devnet. Resolve before production:

  1. SAS devnet program ID — the program declares one address with no network branching (same-as-mainnet expected) but confirm on-chain.
  2. Raw-SAS cost — the ~$0.002/attestation figure is SATI's compressed (Light Protocol) number, not raw SAS. A raw SAS attestation pays Solana rent (~a few cents). Use SATI's compressed path for high volume.
  3. ReputationScoreV3 exact layout — SATI's aggregate-score schema layout beyond its 131-byte base is not published; this package writes a self-owned schema, not ReputationScoreV3, until that lands.
  4. Which ERC-8004 draft SATI mirrors — SATI's structured outcome u8 + JSON score matches neither current ERC-8004 (int128 value+valueDecimals) nor the older uint8 score draft cleanly. We map onto current ERC-8004 (value/valueDecimals) and carry the raw score in content.
  5. Devnet end-to-end — issue one attestation about a subject wallet and read it back (fetchAttestation + deserializeAttestationData).

Develop

npm install
npm test          # offline core tests (no chain deps)
npm run typecheck
npm run build

License

MIT