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

@delentia/delentia-os

v1.4.0

Published

TypeScript SDK + CLI for Delentia OS — FDIA scoring, JITNA packets, SignedAI tier selection, npx delentia CLI

Readme

@delentia/delentia-os

npm License TypeScript

TypeScript / JavaScript SDK for RCT Platform — the world's first Intent-Centric AI Operating System with constitutional architecture.


What is RCT Platform?

RCT Platform provides:

  • FDIA FormulaF = D^I × A — constitutional scoring that governs AI freedom to act
  • JITNA Packets — Just-In-Time Need Analysis structured intent envelopes
  • SignedAI Tiers — HexaCore role assignment based on user tier and risk profile
  • REST Client — typed Axios wrapper for the delentia-os FastAPI backend

Installation

npm install @delentia/delentia-os
# or
yarn add @delentia/delentia-os
# or
pnpm add @delentia/delentia-os

CLI — npx rct

The package ships a full command-line interface. Run without installing:

npx @delentia/delentia-os --help

Or install globally for the rct command:

npm install -g @delentia/delentia-os
rct --help

Commands

| Command | Description | |---------|-------------| | rct compile "<intent>" | Compile intent → FDIA + JITNA + policy evaluation | | rct status | Show control plane metrics (requires running server) | | rct init | Interactive wizard → writes .rct.json config | | rct fdia <d> <i> <a> | Offline constitutional gate check |

Examples

# Check constitutional gate offline
npx @delentia/delentia-os fdia 0.9 0.95 1.0
# ╭────── FDIA — Constitutional Gate PASSED ──────╮
# │  F Score:  0.9048  Risk: LOW  Gate: 0.75 PASS ✔ │
# ╰───────────────────────────────────────────────╯

# Compile intent (requires delentia-os server running)
npx @delentia/delentia-os compile "Refactor the authentication module" --url http://localhost:8000

# Interactive project setup
npx @delentia/delentia-os init

# Server health + metrics
npx @delentia/delentia-os status

rct fdia — Offline Mode

rct fdia <d> <i> <a> [--gate <threshold>] [--no-banner]

| Arg | Range | Description | |-----|-------|-------------| | d | 0.0–1.0 | Delta — change vector magnitude | | i | 0.0–1.0 | Identity — role confidence | | a | 0.0–1.0 | Architect gate (0=blocked, 1=approved) | | --gate | 0.0–1.0 | Minimum pass threshold (default: 0.75) |


Quick Start

FDIA Constitutional Formula

import { computeFDIA, meetsThreshold } from "@delentia/delentia-os";

// Compute F = D^I × A
const result = computeFDIA(0.7, 0.9, 1.0);
console.log(result);
// {
//   f: 0.667,
//   d: 0.7, i: 0.9, a: 1.0,
//   riskLevel: "LOW",
//   isBlocked: false,
//   explanation: "F=0.667 = D^I × A = 0.70^0.90 × 1.00 → Risk=LOW"
// }

// Check against governance threshold
const allowed = meetsThreshold(result, 0.5);
console.log(allowed); // true

JITNA Packet Construction

import { constructJITNA, serializeJITNA } from "@delentia/delentia-os";

const packet = constructJITNA({
  intent: "Refactor the authentication module",
  userTier: "PRO",
  region: "ASEAN",
});

console.log(packet.packetId);     // "jitna_<uuid>"
console.log(packet.scope.region); // "ASEAN"

const json = serializeJITNA(packet);

SignedAI Tier Selection

import { selectSignedAITier } from "@delentia/delentia-os";

const selection = selectSignedAITier("PRO", "STRUCTURAL");
console.log(selection.roles);
// ["SUPREME_ARCHITECT", "LEAD_BUILDER", "JUNIOR_BUILDER",
//  "SPECIALIST", "LIBRARIAN", "HUMANIZER"]
console.log(selection.maxParallelAgents); // 4

REST Client (requires running delentia-os server)

import { RCTClient } from "@delentia/delentia-os";

const client = new RCTClient({
  baseURL: "https://your-rct-instance.com",
  apiKey: "your-api-key",
});

// Compile an intent
const compiled = await client.compile("Optimize database queries");
console.log(compiled.intent_id);
console.log(compiled.risk_profile);

// Evaluate against governance policies
const evaluation = await client.evaluatePolicy(compiled.intent_id);
console.log(evaluation.decision); // "approve" | "reject" | "require_approval"

// Get system metrics
const metrics = await client.getMetrics();
console.log(metrics.total_intents);

API Reference

computeFDIA(d, i, a): FDIAResult

Compute the constitutional FDIA score using F = D^I × A.

| Parameter | Type | Description | |-----------|------|-------------| | d | number (0.0–1.0) | Delta — change vector magnitude | | i | number (0.0–1.0) | Identity — role confidence | | a | number (0.0–1.0) | Architect gate (0=blocked, 1=approved) |

Returns FDIAResult with: f, d, i, a, riskLevel, isBlocked, explanation.


meetsThreshold(result, threshold): boolean

Check if an FDIAResult meets the minimum freedom threshold.


constructJITNA(options): JITNAPacket

Build a structured JITNA intent packet.

| Option | Type | Default | |--------|------|---------| | intent | string | required | | userTier | "FREE" \| "PRO" \| "ENTERPRISE" | "FREE" | | region | string | "GLOBAL" | | budgetTokens | number | 4096 |


selectSignedAITier(tier, riskProfile): TierSelection

Map user tier + risk profile to HexaCore role assignments.

| Tier | Roles | Max Parallel Agents | |------|-------|-------------------| | FREE | 4 roles | 2 | | PRO | 6 roles | 4 | | ENTERPRISE | 8 roles (full HexaCore) | 8 |


RCTClient

Typed Axios client for the delentia-os REST API.

const client = new RCTClient(config?: RCTClientConfig);
await client.compile(intentText: string): Promise<CompileResponse>
await client.evaluatePolicy(intentId: string): Promise<PolicyEvalResponse>
await client.getMetrics(): Promise<MetricsResponse>

TypeScript Support

Full TypeScript support with bundled type declarations (dist/index.d.ts).

import type {
  FDIAResult, FDIAScores, RiskLevel,
  JITNAPacket, JITNAMeta,
  TierSelection, UserTier, HexaCoreRole,
  RCTClientConfig, CompileResponse,
} from "@delentia/delentia-os";

Links


License

Apache 2.0 © Delentia Labs