@orkestrel/ollama 0.0.13 → 0.0.14

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/README.md CHANGED
@@ -15,8 +15,9 @@ npm install @orkestrel/ollama
15
15
 
16
16
  - Node.js >= 22
17
17
  - A running Ollama daemon (default `http://localhost:11434`) with a pulled
18
- model — required at runtime by any consumer, and by this repo's live-only
19
- `src:server` test suite
18
+ model — required at runtime by any consumer, and by this repository's live
19
+ `service` test project; the `src:server` project is hermetic and passes with
20
+ the daemon down
20
21
  - ESM + CJS (dual-format build)
21
22
 
22
23
  ## Usage
@@ -30,7 +31,7 @@ const abort = createAbort()
30
31
  const messages = [{ id: '1', role: 'user', content: 'Reply with exactly: ok' }] as const
31
32
 
32
33
  const result = await provider.generate(messages, abort.signal)
33
- result.content // 'ok'
34
+ result.content // the assistant's answer text
34
35
  result.usage // { prompt, completion, total }
35
36
  ```
36
37
 
@@ -43,7 +44,7 @@ assembled result when the stream completes:
43
44
  const generator = provider.stream(messages, abort.signal)
44
45
  let step = await generator.next()
45
46
  while (!step.done) {
46
- if (step.value.type === 'content') process.stdout.write(step.value.text)
47
+ if (step.value.channel === 'content') process.stdout.write(step.value.text)
47
48
  step = await generator.next()
48
49
  }
49
50
  const streamed = step.value // the assembled ProviderResult
@@ -54,7 +55,7 @@ const streamed = step.value // the assembled ProviderResult
54
55
  For the full surface — `createOllama`, `OllamaProvider`, `OllamaOptions`,
55
56
  tool calls (`ToolDefinition` / `ToolCall` from `@orkestrel/tool`), thinking,
56
57
  and the context-framing default — see
57
- [`guides/src/ollama.md`](guides/src/ollama.md).
58
+ [`guides/ollama.md`](guides/ollama.md).
58
59
 
59
60
  ## Package
60
61