mirror of
https://github.com/TanStack/ai.git
synced 2026-11-16 19:38:41 +00:00
feat: add generateWorld() and generateLiveVideo() for prompt-steerable sessions (#1321)
* feat: add generateWorld() activity and Reactor adapter Add a session-based world generation activity, a first-party @tanstack/ai-reactor adapter that mints scoped tokens for Orbis and other Reactor world models, and a ts-react-world example app. * feat: add reactorVideo adapter for live generateVideo sessions Mint a scoped Reactor token from generateVideo() for Helios, FastH3, Orbis, LongLive, and LTX. Live sessions return a token instead of a download URL, so the browser connects with the js-sdk. * feat: use BYOK in the ts-react-world example Paste a Reactor key in the browser. The relay reads x-byok-reactor, then REACTOR_API_KEY, and mints the session token. * fix: unlock saved BYOK keys in the world example Passkey storage locks the keyring after a reload. Show Unlock, treat locked keys as saved, and call byok.prepare() before minting. * fix: load Reactor wasm in the world example Vite was pre-bundling @reactor-team/js-sdk, which broke the relative import of dist/wasm/reactor_wasm.js. Exclude the SDK from optimizeDeps and resolve that glue file from the package. * fix: hydrate BYOK env and passkey peek like ts-react-chat Call byok.ready() and getEnvKeyStatus() on mount so a refresh shows a locked passkey key or REACTOR_API_KEY on the relay. * fix: pre-bundle awaitqueue when the Reactor SDK is unbundled Excluding @reactor-team/js-sdk from optimizeDeps left its CJS dependency awaitqueue as a raw named import. Include it so Vite converts AwaitQueue. * feat: add generateLive() and fold world into the media example Mint live session tokens with generateLive(). reactorVideo and falLive (H3 Max Director) use that activity. generateVideo stays the job path. The media example now has Live and World tabs. The ts-react-world example is removed. * fix: play live video and open the key dialog on a missing key Helios uses set_sr_scale, not set_resolution. Mute the video and re-attach on unmute so Chrome shows frames. A missing key now returns byokMissing and opens the header dialog. Seedance is a tab on the media example. Sherif ignores the dual @fal-ai/client versions. * fix: proxy fal Director auth and keep Orbis on World WMA rejects a /tokens/ JWT as Key credentials. The media example opens H3 Max Director through /api/fal/proxy with the real FAL_KEY. Orbis stays on generateWorld only. Live and World share seed-image upload. * ci: apply automated fixes * fix: return the WMA app id from falLive and lock the proxy generateLive() now puts fal-ai/minimax-h3-max-director on result.model so wma(live.model) works. The example proxy only forwards WMA session paths and Director /ice. Doc snippets type-check under kiira. * refactor: rename generateLive to generateLiveVideo The activity, adapter kind, fal factory, and createLive method now use the LiveVideo name so they match generateLiveVideo(). * ci: apply automated fixes --------- Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
This commit is contained in:
parent
c92223adad
commit
c17bc951ca
80 changed files with 5992 additions and 275 deletions
31
README.md
31
README.md
175
pnpm-lock.yaml
generated
175
pnpm-lock.yaml
generated
Loading…
Add table
Add a link
Reference in a new issue