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

@nvdigitalsolutions/nvoos-client-tools

v0.1.0-alpha.3

Published

Browser-native AI tool registry (summarize, sentiment, translate, embed, image, audio) using Transformers.js - Extracted from NV Open Operator System

Readme

@nvdigitalsolutions/nvoos-client-tools

Browser-native AI tool registry powered by Transformers.js — extracted from the NV Open Operator System (oOS) WordPress plugin.

Ship a single, OpenAI-style tool registry with seven privacy-first AI tools that run entirely in the browser:

| Tool | Task | Default Model | |------|------|---------------| | client_summarize | Summarisation | Xenova/distilbart-cnn-12-6 | | client_sentiment | Sentiment analysis | default sentiment model | | client_translate | Translation (NLLB-200) | Xenova/nllb-200-distilled-600M | | client_embed | Sentence embeddings | Xenova/all-MiniLM-L6-v2 | | client_describe_image | Image captioning | Xenova/vit-gpt2-image-captioning | | client_detect_objects | Object detection (DETR) | Xenova/detr-resnet-50 | | client_transcribe_audio | Speech-to-text (Whisper) | Xenova/whisper-tiny.en |

Each tool exposes a JSON-schema parameters block compatible with OpenAI/Anthropic-style tool calling, plus an execute(args) method that returns a Promise.

Installation

npm install @nvdigitalsolutions/nvoos-client-tools
# Optional — bundle Transformers.js, or load it from the CDN
npm install @huggingface/transformers

Quick Start

import { configure, executeTool } from '@nvdigitalsolutions/nvoos-client-tools';
import { pipeline } from '@huggingface/transformers';

// Inject the pipeline factory once at boot.
configure({ pipeline });

const summary = await executeTool('client_summarize', {
  text: '... long article text ...',
  max_length: 120,
});
console.log(summary);

CDN fallback

If you load Transformers.js from a CDN (so globalThis.pipeline is defined), you can skip the configure() call entirely — the package falls back to globalThis.pipeline automatically.

API

configure(options)

Inject a Transformers.js pipeline factory. Call once at boot.

configure({
  pipeline, // typeof pipeline (from @huggingface/transformers)
});

getTools()

Returns the full tool registry as an object keyed by tool name. Useful for surfacing the OpenAI-style schemas to a model.

const tools = getTools();
// tools.client_summarize.parameters → JSON schema

getTool(name)

Returns a single tool definition (or null).

executeTool(name, args)

Convenience wrapper that resolves the tool and runs execute(args).

CLIENT_TOOLS

Direct access to the underlying registry object (the same object returned by getTools()).

Why this package?

NV oOS originally embedded these seven tools as a global WP_MCP_AI_ClientTools object, registered automatically when the plugin was loaded. Outside WordPress that pattern doesn't compose well, so this package:

  • Removes the global side-effect on import
  • Makes the Transformers.js dependency injectable (CDN, ESM, or custom factory)
  • Adds a small executeTool() helper for ergonomics
  • Ships TypeScript types

License

MIT — see LICENSE.