chohra-med/wireai-rn(新しいタブで開きます)
主要言語: TypeScript
Open-source React Native SDK for generative UI: render native components from LLM responses, validated by Zod. No WebView, no HTML.
- star 数
- 13
- watcher 数
- 0
- fork 数
- 1
- issue 数
- 0
- 最終更新
- 2026/08/20
主要言語: TypeScript
Open-source React Native SDK for generative UI: render native components from LLM responses, validated by Zod. No WebView, no HTML.
Wire your AI agent to native mobile UI.
Open-source React Native SDK for generative UI: render interactive native components from LLM responses. No WebView, no HTML, no hand-written parser.
Your agent speaks JSON. Mobile users expect native UI. Wire RN closes that gap: register your React Native components with a description and a Zod schema, the LLM picks which one to show, and Wire RN validates the props and renders it natively.
import { WireAIProvider } from "wireai-rn"; import { defaultComponents } from "wireai-rn/components"; // The provider key stays on your server. The device talks to your endpoint, // your endpoint talks to the model. const config = { provider: "webhook" as const, baseUrl: "https://api.yourdomain.com/ai/chat", model: "gpt-4o-mini", }; export default function App() { return ( <WireAIProvider llm={config} components={defaultComponents}> <ChatScreen /> </WireAIProvider> ); }
The agent returns { action, component, props }, Wire RN validates props against the component's Zod schema, and a native component renders. Output that fails validation never reaches the screen: the turn is dropped and useWireAIThread surfaces it as an error string, so nothing crashes and no broken UI renders.
Local development only. You can also point the SDK straight at a provider with
{ provider: "openai", model: "gpt-4o-mini", apiKey: "..." }. A cloud key in a React Native bundle is plain text and can be pulled out of any.apkor.ipa, so that config is for your machine, not for a build you ship. The SDK logs a warning in__DEV__when it sees anapiKey. For a keyless local setup, use the Ollama or LM Studio adapter instead. Details: SECURITY.md.
Part of Wire AI, the AI growth engineer for mobile apps.
Created by Malik Chohra · Code Meet AI newsletter
Sponsored by AI Mobile Launcher and CasaInnov
fetch).npm install wireai-rn zod
# or
yarn add wireai-rn zodFull documentation, step-by-step guide, and API reference: packages/core/README.md
wireai-rn/
├── packages/core/ ← the wireai-rn SDK (published to npm)
├── examples/
│ ├── mental-coach/ ← streaming demo app
│ └── langchain-multistep/ ← Express + LangChain LCEL server + RN client
├── apps/boilerplate/ ← demo Expo app
└── .github/ ← CI workflows
WebhookAdapteryarn install yarn build # build all packages (turbo) yarn test # run the test suites yarn typecheck
This system is not intended to be put into service as, or changed into, a high-risk AI system. Do not build Wire-powered surfaces into an Annex III high-risk area: biometrics, critical infrastructure, education and vocational training, employment, access to essential services and benefits, law enforcement, migration, or administration of justice.
The app that ships a Wire-powered surface is the deployer of it. One consequence is worth reading before you build rather than after: if you use this SDK for a chat-like or free-text-responding surface, the Article 50(1) disclosure that a user is interacting with an AI system is your app's to place, not the SDK's.
Our full reading, dated and with the reasoning visible, covering Article 50, Article 25 and what the MIT licence changes: EU-AI-ACT.md. It is a position, not legal advice.
Wire AI is the AI growth engineer for mobile apps: one agent that runs four versions of every step of your users' journey, live at once, and keeps what makes them stay. This project is one piece of that ecosystem:
wireai-rn): this repo. The open-source React Native SDK that renders Wire's AI-driven flows as native components in your app.https://wireai-mcp.fly.dev/mcp with an Authorization: Bearer <key> header to read your funnel and run the improve loop. Nothing runs from your repo.The activation kit ships as @wireai/activation on npm.
Wire RN is open source and free. Its development is backed by:
Want your product here? Open an issue or reach out at getwireai.com.
MIT. See LICENSE.
Created by Malik Chohra, React Native engineer and AI-native founder.
Website · Newsletter · X / @malik_chohra
Sponsored by AI Mobile Launcher and CasaInnov