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

@wundero/klarify-opus-processing

v1.4.0

Published

Template project for writing node package with napi-rs

Readme

klarify-opus-processing

Klarify small window silence detection

Setup

Make sure you have Rust installed first.

Once rust is installed, run bun install to install dependencies & bun run build to build the project for testing+benching.

Modifications

Make any modifications in src/lib.rs, and if the API signature changes, be sure to update the benchmark/bench.ts and __test__/index.spec.ts files accordingly.

Audio censorship

This package can also rewrite WebM/Opus audio into deterministic synthetic audio for privacy-safe service testing. The sanitizer does not use voice activity detection as its privacy boundary: every Opus audio packet it can parse is decoded, summarized by loudness/peak statistics, and replaced with generated noise. Non-audio WebM bytes are preserved, and Opus packets are padded back to their original byte length when possible.

import { censorAudio, censorAudioChunk, censorAudioFile } from '@wundero/klarify-opus-processing'

const censoredChunk = await censorAudioChunk(webmHeader, webmClusterChunk, {
  mimeType: 'audio/webm',
  seed: 123,
})

const censoredFile = await censorAudio(fullWebmBuffer, { mimeType: 'audio/webm' })

const result = await censorAudioFile('/tmp/input.webm', '/tmp/censored.webm', {
  mimeType: 'audio/webm',
})

The v1 sanitizer only supports WebM/Opus with unlaced Opus blocks. It rejects unsupported, malformed, or non-Opus inputs rather than returning original bytes. Passing strictByteLength: true makes size preservation mandatory; otherwise the sanitizer preserves byte length where packet padding fits and rewrites WebM element sizes when the replacement packet has to change length.

This is an audio-content sanitizer, not a general metadata scrubber. Container metadata is intentionally kept mostly unchanged so upload and ffmpeg processing edge cases remain reproducible.

Publishing

Preparing to publish

Commit any changes without changing the version number first, and make sure to run bun format to improve code style.

Once ready to publish, increment the version number in package.json (if you break the API spec, make sure to use a major version increase) and then run bun version. Once the command finishes, commit the staged changes with the same version number as you put in the package json file.

Example flow:

# ...make changes to lib.rs
bun run build # Regenerate index.d.ts
# ...update api usages as needed
bun run test # Run tests. Note: the "run test" instead of just "test" here is important!
# set package.json version to 1.2.3
bun version
git commit -m "1.2.3"
git push

This will trigger a deployment and publish the new version to npm.

Importantly, we currently only use main so its a bit unstable, but we can improve this if further work is needed here. At some point, having this flow be fully automated would be ideal, but that's not really necessary at the moment.