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

@aparte/runner-ag-ui

v0.32.1

Published

Render an AG-UI agent in aparté — Agno, LangGraph, Mastra, CrewAI, Pydantic AI, TanStack AI: the agent runs on its server, aparté draws the chat, its tool calls and its approvals.

Readme

@aparte/runner-ag-ui

Render an agent served over AG-UI in aparté. The agent runs on its own server, with its own tools: Agno, LangGraph, Mastra, CrewAI, Pydantic AI, CopilotKit's runtime, or TanStack AI, whose chat route streams AG-UI. aparté draws its text, its reasoning, its tool calls and its approvals, exactly as it draws a loop it runs itself.

npm install @aparte/runner-ag-ui @aparte/core
import { AparteClient } from '@aparte/core';
import { createAgUiRunner } from '@aparte/runner-ag-ui';

const client = new AparteClient({
    streamRunner: createAgUiRunner({ endpoint: '/agui' }),
});
client.start();
  • Tools that need the page (an ask_user you register with registerTool) go to the agent as AG-UI frontend tools. When it calls one, the page runs it and the run resumes with the result.
  • Approvals. When the agent pauses on a call that needs a person (an AG-UI interrupt, such as TanStack AI's needsApproval), the page asks through its usual approval panel, and the answer resumes the run on the agent's server.
  • Its state (STATE_SNAPSHOT, STATE_DELTA) is kept for the thread and sent back as the next run's state. CUSTOM, activities and sub-agents are checked, not drawn, in this version.
  • AG-UI 1.0, held to its own corpus. The runner declares protocolVersion: "1.0", rejects the streams 1.0 tells a client to reject, drops what 1.0 does not describe (reported to onWarning), and passes the protocol's 68 conformance streams on every build.
  • TanStack AI frames its runs its own way — a RUN_FINISHED per model step — so its routes take createAgUiRunner({ endpoint: '/api/chat', relaxedRunFraming: true }).

No AG-UI SDK is pulled in: the wire is plain JSON over Server-Sent Events, parsed here, with @aparte/core as the only peer dependency.

Part of the aparté monorepo. ESM-only. See Providers → AG-UI agents and TanStack AI in the docs.