SuperAPI AI 工具集

thesys-generative-ui

前端与建站

查看项目

更新于 10-15 22:32

技能介绍

用途:该技能面向使用 Thesys SDK 的开发者,帮助通过自然语言描述来生成、修改和设置 React 组件样式,侧重模式驱动的界面生成、主题定制和工具调用。主要能力:支持用自然语言描述 UI;提供类型安全的组件生成;产出可用于生产的 React 组件;由大语言模型辅助设计。快速开始示例:import { generateUI } from 'thesys'; const ui = await generateUI({ prompt: 'Create a user profile card with avatar, name, and email', schema: { type: 'component', props: ['name', 'email', 'avatar'] } }); 主题示例:const form = await generateUI({ prompt: 'Create a contact form with name, email, and message fields', theme: 'modern' }); 使用方式与参考:仓库包含 references 下的核心文档(what-is-thesys、use-cases-examples、tool-calling、integration-guide)、组件 API、AI 提供商设置、主题定制与常见错误等;并提供 15 个以上模板,覆盖 Vite + React(basic-chat.tsx、custom-component.tsx、tool-calling.tsx、theme-dark-mode.tsx)、Next.js(app/page.tsx、app/api/chat/route.ts、tool-calling-route.ts)、Cloudflare Workers(worker-backend.ts、frontend-setup.tsx)以及 theme-config.ts、tool-schemas.ts、streaming-utils.ts 等工具文件。适用场景:需要在 React 项目中快速生成界面组件、配置主题或接入工具调用的开发场景。限制:资料未提供收费、价格、平台支持范围及具体使用效果等信息;官方文档见 https://docs.thesys.dev,演练场见 https://console.thesys.dev/playground。