thinkwell 0.1.0 → 0.1.2

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.
Files changed (2) hide show
  1. package/README.md +15 -9
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -1,5 +1,5 @@
1
1
  <p>
2
- <img src="assets/logo.jpg" alt="Thinkwell Logo" width="200">
2
+ <img src="https://raw.githubusercontent.com/dherman/thinkwell/refs/heads/main/packages/thinkwell/assets/logo.jpg" alt="Thinkwell Logo" width="200">
3
3
  </p>
4
4
 
5
5
  A TypeScript library for easy scripting of AI agents. Thinkwell provides a fluent API for blending deterministic code with LLM-powered reasoning.
@@ -7,24 +7,30 @@ A TypeScript library for easy scripting of AI agents. Thinkwell provides a fluen
7
7
  ## Quick Start
8
8
 
9
9
  ```typescript
10
- import { Agent, schemaOf } from "thinkwell";
10
+ import { Agent } from "thinkwell";
11
+ import { GreetingSchema } from "./schemas.js";
12
+
13
+ /**
14
+ * A greeting response.
15
+ * @JSONSchema
16
+ */
17
+ export interface Greeting {
18
+ /** The greeting message */
19
+ message: string;
20
+ }
11
21
 
12
22
  const agent = await Agent.connect("npx -y @zed-industries/claude-code-acp");
13
23
 
14
24
  const result = await agent
15
- .think(schemaOf<{ greeting: string }>({
16
- type: "object",
17
- properties: { greeting: { type: "string" } },
18
- required: ["greeting"]
19
- }))
25
+ .think(GreetingSchema)
20
26
  .text("Say hello!")
21
27
  .run();
22
28
 
23
- console.log(result.greeting);
29
+ console.log(result.message);
24
30
 
25
31
  agent.close();
26
32
  ```
27
33
 
28
- # License
34
+ ## License
29
35
 
30
36
  MIT
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "thinkwell",
3
- "version": "0.1.0",
3
+ "version": "0.1.2",
4
4
  "description": "TypeScript library for blending deterministic code with LLM-powered reasoning",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",