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

@orangecheck/agent-vercel

v0.2.0

Published

Wrap Vercel AI SDK tool() invocations with OC Agent scope enforcement and emit a signed agent-action envelope per tool execution. Provider-agnostic — works under Anthropic, OpenAI, Cohere, etc.

Readme

@orangecheck/agent-vercel

Wrap Vercel AI SDK tool() invocations with OC Agent scope enforcement and emit a signed agent-action envelope per tool execution. Provider-agnostic — works under Anthropic, OpenAI, Cohere, or any other model the AI SDK speaks.

Why

The Vercel AI SDK has converged on a clean tool({description, parameters, execute}) primitive that serializes naturally across providers. A single adapter at this layer covers a large fraction of teams shipping production agents.

This module wraps execute so every successful call produces a signed agent-action envelope citing the active delegation:

  • Pre-call: scope check (vercel:tool(verb=<verb>) against the delegation; refuses if not admissible).
  • Canonicalize the (verb, args, callId) tuple, BIP-322 sign as the agent address, emit envelope.
  • Run the real handler.
  • Return both the result (back to the model via the SDK) and the envelope (for your audit pipeline).

Status

v0.0.1 · in design. API shape is stable; the canonicalization layout ({args, call_id, verb} lexicographic, RFC 8785 canonical JSON, trailing LF) is locked. Production wiring with specific AI-SDK releases is intentionally not baked in — ocTool() is provider/SDK-agnostic so you can call it from any release of ai you're already on.

Install

npm i @orangecheck/agent-vercel
# peer deps:
npm i @orangecheck/agent-core @orangecheck/agent-signer

Quickstart

import { tool } from 'ai';
import { ocTool } from '@orangecheck/agent-vercel';

const invoiceCreate = ocTool({
    verb:        'invoice.create',
    description: 'create a new invoice',
    parameters:  invoiceSchema,
    execute:     async (args) => myInvoiceCreateImpl(args),
});

const tools = {
    'invoice.create': tool({
        description: invoiceCreate.description,
        parameters:  invoiceCreate.parameters as never,
        execute: async (args, { toolCallId }) => {
            const { result, action } = await invoiceCreate.execute(args, {
                agent, delegation, callId: toolCallId,
            });
            await yourAuditPipeline.append(action);
            return result;
        },
    }),
};

const { text } = await generateText({
    model: anthropic('claude-sonnet-4-6'),
    tools,
    prompt: 'invoice acme for $14.20',
});

The pattern: ocTool defines the OC-Agent-shaped wrapper; the AI SDK's tool() calls into that wrapper plus your audit pipeline.

What gets stamped

Stamp's content.hash is a SHA-256 of:

{
  "args":    <canonical JSON of args>,
  "call_id": "<sdk-assigned tool call id>",
  "verb":    "<verb>"
}

Default scope_exercised is vercel:tool(verb=<verb>). Override via scopeExercised.

API

  • canonicalizeToolCall(call) — RFC 8785 canonical bytes.
  • toolCallHash(call)sha256:<64-hex>.
  • stampToolCall(input) — sign without executing.
  • ocTool({verb, parameters, description, execute}) — provider-agnostic wrapped tool.

License

MIT.

Related