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

@tell-ai/sdk

v0.2.1

Published

Browser-safe AI provider layer for tell-ai: model resolution, vendor dispatch, RUN/think tag handling and context summarization

Readme

@tell-ai/sdk

Browser-safe AI provider layer for tell-ai: model resolution, multi-vendor dispatch, RUN/think tag handling, and context summarization.

The SDK has zero node:* imports and zero process.env reads. All environment concerns (API keys, base URLs, platform info) are injected via SDKConfig, so the same code runs in Node, Bun, and the browser.

Features

  • MODELS / resolve_model_spec(model) — 70+ short aliases (e.g. gopenai:gpt-5.6-sol:medium) resolving to vendor:model:thinking_budget specs, with dot-prefix fast mode (.g).
  • create_ask_ai(spec, config) — returns an AskInstance with an ask() method backed by generateText() over openai, anthropic, google, xai, deepseek, fireworks, cerebras, and moonshotai providers.
  • tell(message, options) — one-shot tell --no-exec as a library call: builds the tell system prompt (execution disabled by default), calls the model, and returns the answer with thinking/<RUN> tags stripped.
  • get_system_prompt(options) — the shared tell system prompt (PromptOptions { chain?, exec?, cwd?, platform? }); exec: false emits the no-command-execution variant.
  • Tag helpersextract_runs, strip_run_tags, strip_think_tags, strip_markdown_code_blocks for <RUN>/reasoning/markdown handling.
  • summarize_context(ai, text) — AI-driven conversation history compression.

Install

bun add @tell-ai/sdk or npm add @tell-ai/sdk

Usage (Node / Bun)

import { create_ask_ai, tell } from '@tell-ai/sdk';

const ai = create_ask_ai('openai:gpt-5.6-sol', { keys: { openai: process.env.OPENAI_API_KEY } });
const { text } = await ai.ask('explain this repository in one paragraph');

One-shot no-exec call (tag stripping included):

import { tell } from '@tell-ai/sdk';

const answer = await tell('summarize the uncommitted changes', {
  keys: { anthropic: process.env.ANTHROPIC_API_KEY },
});

All providers honor SDKConfig.urls via baseURL, enabling CORS proxies:

create_ask_ai('openai:gpt-5.6-sol', {
  keys: { openai: 'sk-...' },
  urls: { openai: 'https://my-proxy.example/v1' },
});

Usage (browser)

Two self-contained bundles ship with the package — ai and all providers are bundled inline, so no build step or module server is required.

ESM (bundlers, import maps):

import { tell, MODELS } from '@tell-ai/sdk/browser';

const answer = await tell('what is in this repo?', {
  keys: { openai: localStorage.getItem('openai_key') },
});

Script tag (no bundler): load the IIFE global from a CDN, then use window.TellSDK:

<script src="https://unpkg.com/@tell-ai/sdk"></script>
<script>
  TellSDK.tell('hello', { keys: { openai: localStorage.getItem('openai_key') } });
</script>

See examples/web/ in the repository for a no-build demo page and an optional Bun CORS proxy.

Build variants

| Subpath | Format | File | Use for | |---|---|---|---| | . | ESM / CJS + types | dist/index.js, dist/index.cjs | Node / Bun | | ./browser | ESM, bundled | dist/browser.js | Bundlers / browsers | | ./browser-global | IIFE global | dist/browser-global.global.js | <script> tags (CDN: unpkg, jsdelivr) |

License

MIT — see LICENSE.