@chai-ui/react 0.9.0 → 0.10.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/DESIGN.md +1 -1
- package/README.md +4 -3
- package/package.json +3 -3
package/DESIGN.md
CHANGED
|
@@ -44,7 +44,7 @@ use these names: `Results`, `Compare`, `ModelPicker`,
|
|
|
44
44
|
5. **API keys never reach the browser.** Engines call one same-origin
|
|
45
45
|
route, `/api/chai/*`, served by `createChaiHandler` from
|
|
46
46
|
`@chai-ui/core/server`, which adds the key. Never pass a key to
|
|
47
|
-
`createFalEngine` or `
|
|
47
|
+
`createFalEngine`, `createOpenRouterEngine` or `createVercelEngine`. In production, set the
|
|
48
48
|
handler's `authorize` and `allowedModels`.
|
|
49
49
|
6. **Media generation and reasoning are separate choices.** `engine`
|
|
50
50
|
generates media and defaults to Fal.ai. `ChaiProvider`'s
|
package/README.md
CHANGED
|
@@ -308,9 +308,10 @@ Pass `ResultCard` the results of every run, as above: it pages through
|
|
|
308
308
|
them, and each page shows its own kind (image, video, audio or text).
|
|
309
309
|
Passing only `run.results` would hide every use case after the first.
|
|
310
310
|
|
|
311
|
-
**The server route.** `createFalEngine()` and the
|
|
312
|
-
engine call `/api/chai/*` on your server, which adds
|
|
313
|
-
with one file, then set `FAL_KEY
|
|
311
|
+
**The server route.** `createFalEngine()`, `createVercelEngine()` and the
|
|
312
|
+
OpenRouter reasoning engine call `/api/chai/*` on your server, which adds
|
|
313
|
+
the API keys. Add it with one file, then set `FAL_KEY`, `OPENROUTER_API_KEY`
|
|
314
|
+
or `AI_GATEWAY_API_KEY`:
|
|
314
315
|
|
|
315
316
|
```ts
|
|
316
317
|
// Next.js: app/api/chai/[...path]/route.ts
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@chai-ui/react",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.10.0",
|
|
4
4
|
"description": "CHAI UI React components — smart, drop-in UI for AI apps: Composer, Media Analyzer, Result Card, and the useComposer hook.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "kazarazat",
|
|
@@ -48,8 +48,8 @@
|
|
|
48
48
|
"@fontsource/roboto": "^5.3.0",
|
|
49
49
|
"@lit/react": "^1.0.8",
|
|
50
50
|
"@material/web": "^2.5.0",
|
|
51
|
-
"@chai-ui/core": "0.
|
|
52
|
-
"@chai-ui/tokens": "0.
|
|
51
|
+
"@chai-ui/core": "0.10.0",
|
|
52
|
+
"@chai-ui/tokens": "0.10.0"
|
|
53
53
|
},
|
|
54
54
|
"devDependencies": {
|
|
55
55
|
"@material-symbols/svg-400": "^0.47.5",
|