惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

N
Netflix TechBlog - Medium
月光博客
月光博客
Y
Y Combinator Blog
WordPress大学
WordPress大学
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
雷峰网
雷峰网
美团技术团队
T
Tailwind CSS Blog
小众软件
小众软件
量子位
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
有赞技术团队
有赞技术团队
P
Proofpoint News Feed
G
Google Developers Blog
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
Recent Announcements
Recent Announcements
The GitHub Blog
The GitHub Blog
博客园 - 三生石上(FineUI控件)
云风的 BLOG
云风的 BLOG
Vercel News
Vercel News
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
爱范儿
爱范儿
V
Visual Studio Blog
H
Hackread – Cybersecurity News, Data Breaches, AI and More

shadcn/ui Changelog

September 2026 - cn August 2026 - Private GitHub Registries August 2026 - Questionnaire July 2026 - Dynamic Search July 2026 - Toast July 2026 - React Aria July 2026 - Introducing @shadcn/helpers July 2026 - Introducing shadcn/typeset July 2026 - Base UI as the Default June 2026 - Components for Chat Interfaces June 2026 - GitHub Registries May 2026 - shadcn eject May 2026 - Introducing Rhea May 2026 - Registry Include and Validate May 2026 - Package Imports and Target Aliases April 2026 - shadcn preset April 2026 - Pointer Cursor April 2026 - Partial Preset Apply April 2026 - Introducing Sera April 2026 - shadcn apply April 2026 - Component Composition March 2026 - Introducing Luma March 2026 - shadcn/cli v4 February 2026 - Blocks for Radix and Base UI February 2026 - Unified Radix UI Package January 2026 - RTL Support January 2026 - Inline Start and End Styles January 2026 - Base UI Documentation December 2025 - npx shadcn create October 2025 - Registry Directory
August 2026 - Human in the Loop
shadcn · 2026-08-12 · via shadcn/ui Changelog

Mock paused tool calls, approvals, and continuations for the AI SDK with @shadcn/helpers.

@shadcn/helpers can now mock human-in-the-loop flows for the AI SDK. A scripted conversation can pause for real user input, wait for an approval, and continue with whatever the user decided.

Everything streams through the real useChat lifecycle, so your tool cards, approval prompts, and question flows behave exactly as they would in production.

import { createChat } from "@shadcn/helpers/ai-sdk"
 
const chat = createChat<ChatMessage>()
  .user("Help me plan the next prototype.")
  .assistant(({ writer }) => {
    writer.text("A couple of questions before I start.")
    writer.tool("askQuestions", { input: { questions } })
  })
  .assistant(({ writer, toolCall }) => {
    writer.text(
      toolCall?.name === "askQuestions" && toolCall.output
        ? `Starting with ${toolCall.output.answers.direction}.`
        : "Starting now."
    )
  })

Pass needsApproval to pause behind the user's decision. The scripted output streams after approval, and denial streams automatically.

chat
  .assistant(({ writer }) => {
    writer.text("That will archive 3 drafts. I need your approval.")
    writer.tool("archiveDrafts", {
      input: { count: 3 },
      needsApproval: true,
      output: { archived: 3 },
    })
  })
  .assistant(({ writer, toolCall }) => {
    writer.text(
      toolCall?.approved ? "Archived 3 drafts." : "Okay, leaving them in place."
    )
  })