rhachet-brains-xai 0.1.2 → 0.1.3
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/package.json +1 -1
- package/readme.md +2 -2
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "rhachet-brains-xai",
|
|
3
3
|
"author": "ehmpathy",
|
|
4
4
|
"description": "rhachet brain.atom adapter for xai grok models",
|
|
5
|
-
"version": "0.1.
|
|
5
|
+
"version": "0.1.3",
|
|
6
6
|
"repository": "ehmpathy/rhachet-brains-xai",
|
|
7
7
|
"homepage": "https://github.com/ehmpathy/rhachet-brains-xai",
|
|
8
8
|
"keywords": [
|
package/readme.md
CHANGED
|
@@ -18,14 +18,14 @@ import { z } from 'zod';
|
|
|
18
18
|
const brainAtom = genBrainAtom({ slug: 'xai/grok-code-fast-1' });
|
|
19
19
|
|
|
20
20
|
// simple string output
|
|
21
|
-
const
|
|
21
|
+
const explanation = await brainAtom.ask({
|
|
22
22
|
role: { briefs: [] },
|
|
23
23
|
prompt: 'explain this code',
|
|
24
24
|
schema: { output: z.string() },
|
|
25
25
|
});
|
|
26
26
|
|
|
27
27
|
// structured object output
|
|
28
|
-
const
|
|
28
|
+
const { summary, issues } = await brainAtom.ask({
|
|
29
29
|
role: { briefs: [] },
|
|
30
30
|
prompt: 'analyze this code',
|
|
31
31
|
schema: { output: z.object({ summary: z.string(), issues: z.array(z.string()) }) },
|