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

@traceweave/trf

v0.1.0

Published

Unified CLI for TRF (Traceability Report Framework) - validates, builds, analyzes, and queries .twpack files

Readme

@traceweave/trf

Unified CLI for TRF (Traceability Report Framework) - validates, builds, analyzes, and queries .twpack files

Installation

npm install -g @traceweave/trf

Usage

The trf command provides a unified interface to all Track 2 packages:

Validate

Validate .twpack files against TRF 2.1 schemas:

# Validate a single file
trf validate my-pack.twpack

# Validate multiple files
trf validate pack1.twpack pack2.twpack pack3.twpack

# Verbose mode
trf validate my-pack.twpack --verbose

# Quiet mode (only errors)
trf validate my-pack.twpack --quiet

Build

Create .twpack files from JSON sources:

trf build create \
  --id "automotive:brake-system:v1.0" \
  --title "Brake System Traceability" \
  --artifacts ./artifacts.json \
  --links ./links.json \
  --output ./brake-system.twpack \
  --profile "automotive-safety-iso26262"

Analyze

Perform graph analytics:

# Show graph statistics
trf analyze stats -f my-pack.twpack

# Impact analysis
trf analyze impact -f my-pack.twpack -a req:BRAKE-001

# Coverage analysis
trf analyze coverage -f my-pack.twpack -k requirement
trf analyze coverage -f my-pack.twpack -k requirement -r verified_by

Query

Execute SQL queries:

# Raw SQL query
trf query sql -f my-pack.twpack \
  -q "SELECT kind, COUNT(*) as count FROM artifacts GROUP BY kind"

# Query artifacts
trf query artifacts -f my-pack.twpack -k requirement

# JSON output
trf query artifacts -f my-pack.twpack -k test --json

Features

  • Unified Interface - Single CLI for all TRF operations
  • Validate - Schema validation with detailed error reporting
  • Build - Create packs from JSON sources
  • Analyze - Impact analysis, coverage metrics, graph statistics
  • Query - SQL queries and filtered searches
  • JSON Output - Machine-readable output for automation

Programmatic API

The package also exports all underlying libraries:

import {
  // Validator
  validateTwpack,

  // Builder
  TwpackBuilder,

  // Analyzer
  TwpackAnalyzer,

  // Query
  TwpackQuery,

  // Types
  Artifact,
  Link
} from '@traceweave/trf';

// Use any package programmatically
const builder = new TwpackBuilder({
  id: 'my-pack',
  title: 'My Pack'
});

Examples

Complete Workflow

# 1. Create a pack
trf build create \
  -i "demo:test" \
  -t "Test Pack" \
  -a artifacts.json \
  -l links.json \
  -o test.twpack

# 2. Validate it
trf validate test.twpack

# 3. Analyze it
trf analyze stats -f test.twpack
trf analyze coverage -f test.twpack -k requirement

# 4. Query it
trf query sql -f test.twpack \
  -q "SELECT * FROM artifacts WHERE kind='requirement'"

CI/CD Integration

# .github/workflows/traceability.yml
- name: Validate Traceability Pack
  run: trf validate ./traceability.twpack --verbose

- name: Check Coverage
  run: |
    trf analyze coverage -f ./traceability.twpack -k requirement -r verified_by

Documentation

License

MIT