agentic-kit 0.1.0 → 0.1.1

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 +101 -5
  2. package/package.json +4 -4
package/README.md CHANGED
@@ -1,12 +1,108 @@
1
1
  # Agentic Kit
2
2
 
3
- ## Credits
3
+ Agentic Kit is the core library providing a unified, streaming-capable interface for multiple LLM providers. It lets you plug in any supported adapter and switch between them at runtime.
4
4
 
5
- 🛠 Built by Hyperweb (formerly Cosmology) — if you like our tools, please checkout and contribute to [our github ⚛️](https://github.com/hyperweb-io)
5
+ ## Installation
6
6
 
7
+ ```bash
8
+ npm install agentic-kit
9
+ # or
10
+ yarn add agentic-kit
11
+ ```
7
12
 
8
- ## Disclaimer
13
+ Agentic Kit includes adapters for Ollama and Bradie out of the box.
9
14
 
10
- AS DESCRIBED IN THE LICENSES, THE SOFTWARE IS PROVIDED “AS IS”, AT YOUR OWN RISK, AND WITHOUT WARRANTIES OF ANY KIND.
15
+ ## Quick Start
11
16
 
12
- No developer or entity involved in creating this software will be liable for any claims or damages whatsoever associated with your use, inability to use, or your interaction with other users of the code, including any direct, indirect, incidental, special, exemplary, punitive or consequential damages, or loss of profits, cryptocurrencies, tokens, or anything else of value.
17
+ ```typescript
18
+ import {
19
+ // Adapters
20
+ OllamaAdapter,
21
+ BradieAdapter,
22
+
23
+ // Factory functions
24
+ createOllamaKit,
25
+ createBradieKit,
26
+ createMultiProviderKit,
27
+
28
+ // Core type
29
+ AgentKit
30
+ } from 'agentic-kit';
31
+
32
+ // Ollama-only client
33
+ const ollamaKit: AgentKit = createOllamaKit('http://localhost:11434');
34
+ const text = await ollamaKit.generate({ model: 'mistral', prompt: 'Hello' });
35
+ console.log(text);
36
+
37
+ // Bradie-only client
38
+ const bradieKit: AgentKit = createBradieKit({
39
+ domain: 'http://localhost:3000',
40
+ onSystemMessage: (msg) => console.log('[system]', msg),
41
+ onAssistantReply: (msg) => console.log('[assistant]', msg),
42
+ });
43
+ await bradieKit.generate({ prompt: 'Hello' });
44
+
45
+ // Multi-provider client
46
+ const multiKit = createMultiProviderKit();
47
+ multiKit.addProvider(new OllamaAdapter('http://localhost:11434'));
48
+ multiKit.addProvider(new BradieAdapter({
49
+ domain: 'http://localhost:3000',
50
+ onSystemMessage: console.log,
51
+ onAssistantReply: console.log
52
+ }));
53
+ const reply = await multiKit.generate({ model: 'mistral', prompt: 'Hello' });
54
+ console.log(reply);
55
+ ```
56
+
57
+ ## Streaming
58
+
59
+ Both adapters support a streaming mode that invokes a callback for each data chunk.
60
+
61
+ ```typescript
62
+ await ollamaKit.generate(
63
+ { model: 'mistral', prompt: 'Hello', stream: true },
64
+ (chunk) => console.log('Ollama chunk:', chunk)
65
+ );
66
+
67
+ await bradieKit.generate(
68
+ { model: 'mistral', prompt: 'Hello', stream: true },
69
+ (chunk) => console.log('Bradie chunk:', chunk)
70
+ );
71
+ ```
72
+
73
+ ## API Reference
74
+
75
+ ### AgentKit
76
+
77
+ - `.generate(input: GenerateInput, options?: StreamingOptions): Promise<string | void>`
78
+ - `.listProviders(): string[]`
79
+ - `.setProvider(name: string): void`
80
+ - `.getCurrentProvider(): AgentProvider | undefined`
81
+
82
+ ### GenerateInput
83
+
84
+ ```ts
85
+ interface GenerateInput {
86
+ model?: string; // For services that support named models
87
+ prompt: string; // The text prompt
88
+ stream?: boolean; // If true, use streaming mode
89
+ }
90
+ ```
91
+
92
+ ### StreamingOptions
93
+
94
+ ```ts
95
+ interface StreamingOptions {
96
+ onChunk?: (chunk: string) => void;
97
+ onStateChange?: (state: string) => void;
98
+ onError?: (error: Error) => void;
99
+ }
100
+ ```
101
+
102
+ ## Contributing
103
+
104
+ Contributions are welcome! Please submit issues and pull requests on [GitHub](https://github.com/hyperweb-io/agentic-kit).
105
+
106
+ ---
107
+
108
+ © Hyperweb (formerly Cosmology). See LICENSE for full licensing and disclaimer.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "agentic-kit",
3
- "version": "0.1.0",
3
+ "version": "0.1.1",
4
4
  "author": "Dan Lynch <pyramation@gmail.com>",
5
5
  "description": "Agentic Kit",
6
6
  "main": "index.js",
@@ -30,9 +30,9 @@
30
30
  "test:watch": "jest --watch"
31
31
  },
32
32
  "dependencies": {
33
- "@agentic-kit/bradie": "^0.1.0",
34
- "@agentic-kit/ollama": "^0.1.0"
33
+ "@agentic-kit/bradie": "^0.1.1",
34
+ "@agentic-kit/ollama": "^0.1.1"
35
35
  },
36
36
  "keywords": [],
37
- "gitHead": "429d3cbe616b763f2e1e8b2a35738b3f9a600c57"
37
+ "gitHead": "0204aa87ae43833af29965684146ff22ebf77564"
38
38
  }