ai
🤖 Type-safe, provider-agnostic TypeScript AI SDK for streaming chat, tool calling, agents, and multimodal apps across OpenAI, Anthropic, Gemini, React, Vue, Svelte, and Solid.
- 3.2k estrellas
- 371 forks
- 35 issues abiertos
- Lenguaje: TypeScript
- Licencia: MIT
- actualizado
Instalación
git clone https://github.com/TanStack/ai && cp ai/*.md ~/.claude/agents/- Clone the repository and copy the agent .md definitions into ~/.claude/agents (or .claude/agents inside a project).
- Start a new Claude Code session to load the agents.
- Delegate work to them with the Task/Agent tool or by name.
Nota editorial
TanStack AI is a TypeScript SDK that provides a unified, provider-agnostic interface for building AI-powered applications across React, Vue, Svelte, Solid, and Preact, as well as server-side and headless environments. It connects to Anthropic's API (alongside OpenAI, Gemini, and OpenRouter) through provider adapters like `@tanstack/ai-openai`, enabling streaming chat, type-safe tool calling via `toolDefinition()`, structured outputs validated with Zod, ArkType, or Valibot, and multimodal workflows covering images, audio, video, speech, and transcription. A standout feature called Code Mode lets a language model write and execute TypeScript in an isolated sandbox to orchestrate tools with loops, branches, and parallel calls. Built-in devtools expose message streams, tool calls, errors, usage metrics, and OpenTelemetry traces for observability. The library is designed for frontend developers and backend engineers who want consistent AI primitives across multiple frameworks and providers without being locked into a single vendor.
24 items en este repositorio
Use when a Cloudflare Worker needs TanStack AI chat persistence — writes a chat-persistence.ts into the app against its D1 binding (raw or via Drizzle), plus a Durable Object LockStore. Covers per-request bindings, wrangler config, D1 migrations, and lease-based locks.
Use when a Cloudflare Worker needs durable byte storage for TanStack AI generated media (images, audio, video, transcripts) — writes a BlobStore backed by R2 and an ArtifactStore backed by D1, composes them onto the generation persistence so withGenerationPersistence persists artifact bytes, and serves them back from a Worker GET route. Includes one-line sketches for S3, GCS, Vercel Blob, Supabase, and a dev filesystem BlobStore.
Use when an app needs TanStack AI chat persistence on a database with no dedicated recipe — raw Postgres (pg/postgres.js), Kysely, node:sqlite, MongoDB, Supabase, Redis. Writes a chat-persistence.ts against the app's existing client, covering the four stores, the idempotency invariants, and the conformance gate. Route to the Drizzle, Prisma, or Cloudflare skills instead when one of those matches.
Use when an app already runs Drizzle ORM and needs TanStack AI chat persistence — writes a chat-persistence.ts into the app against its existing db handle, schema file, and drizzle-kit journal. Covers the four tables (SQLite/Postgres/MySQL), the onConflict idempotency rules, JSON columns, and per-request bindings like D1.
Use when an app already runs Prisma and needs TanStack AI chat persistence — writes a chat-persistence.ts into the app against its existing PrismaClient and schema.prisma. Covers the four models, BigInt timestamps, JSON-as-string columns, upsert-with-empty-update idempotency, and model renaming.
Resumen de Subagents
Lo que la gente pregunta sobre ai
¿Qué es TanStack/ai?
TanStack/ai es subagents para el ecosistema de Claude AI. 🤖 Type-safe, provider-agnostic TypeScript AI SDK for streaming chat, tool calling, agents, and multimodal apps across OpenAI, Anthropic, Gemini, React, Vue, Svelte, and Solid. Tiene 3.2k estrellas en GitHub y su última actualización registrada es del 2026-10-23.
¿Cómo se instala ai?
Puedes instalar ai clonando el repositorio (https://github.com/TanStack/ai) o siguiendo las instrucciones del README en GitHub. ClaudeWave también te ofrece bloques de instalación rápida en esta misma página.
¿Es seguro usar TanStack/ai?
Nuestro agente de seguridad ha analizado TanStack/ai y le ha asignado un Trust Score de 100/100 (tier: Verified). Revisa el desglose completo de comprobaciones superadas y flags en esta página.
¿Quién mantiene TanStack/ai?
TanStack/ai es mantenido por TanStack. La última actividad registrada en GitHub es del 2026-10-23, con 35 issues abiertos.
¿Hay alternativas a ai?
Sí. En ClaudeWave puedes explorar subagents similares en /categories/agents, ordenados por popularidad o actividad reciente.