@j-o-r/hello-dave 0.0.2 → 0.0.4
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/CHANGELOG.md +21 -0
- package/README.md +445 -160
- package/README.md.backup +269 -0
- package/README.md.bak +481 -0
- package/README.md.bak.1774780058 +338 -0
- package/README.md.bak2 +455 -0
- package/bin/dave.js +165 -0
- package/docs.bak.1774780058/agent-manager.md +167 -0
- package/docs.bak.1774780058/agent-manager.md.bak +137 -0
- package/docs.bak.1774780058/agent-manager.md.bak2 +157 -0
- package/docs.bak.1774780058/codeserver-pattern.md +191 -0
- package/docs.bak.1774780058/path-resolution-best-practices.md +104 -0
- package/docs.bak.1774780058/project-overview.md +67 -0
- package/docs.bak.1774780058/project-overview.md.bak +67 -0
- package/docs.bak.1774780058/prompt-class.md +141 -0
- package/docs.bak.1774780058/prompt-class.md.bak +142 -0
- package/docs.bak.1774780058/tools-syntax-validation.md +121 -0
- package/docs.bak.1774780058/tools-syntax-validation.md.bak2 +125 -0
- package/docs.bak.1774780058/tools-syntax-validation.md.bak3 +125 -0
- package/docs.bak.1774780058/tools-syntax-validation.md.bak4 +106 -0
- package/docs.bak.1774780058/tools-syntax-validation.md.bak_path +106 -0
- package/docs.bak.1774780058/toolset.md +164 -0
- package/docs.bak.1774780058/toolset.md.bak +94 -0
- package/docs.bak.1774780058/toolset.md.bak3 +161 -0
- package/docs.bak.1774780058/toolset.md.bak4 +161 -0
- package/docs.bak.1774780058/toolset.md.bak5 +161 -0
- package/docs.bak.1774780058/toolset.md.bak6 +163 -0
- package/docs.bak.1774780058/toolset.md.bak_path +163 -0
- package/docs.bak.1774780058/toolset.md.bak_syntax +161 -0
- package/docs.bak.1774780058/xai-responses.md +111 -0
- package/docs.bak.1774780058/xai-responses.md.bak +107 -0
- package/docs.bak.1774780058/xai-responses.md.bak2 +107 -0
- package/docs.bak.1774780058/xai_collections.md +106 -0
- package/examples/ask_agent.js +137 -0
- package/examples/code_agent.js +149 -0
- package/examples/coderev_agent.js +136 -0
- package/examples/codeserver.sh +47 -0
- package/examples/daisy_agent.js +170 -0
- package/examples/docs_agent.js +148 -0
- package/examples/gpt_agent.js +125 -0
- package/examples/grok_agent.js +132 -0
- package/examples/grok_agent.js.bak +98 -0
- package/examples/grok_agent.js.bak.2 +99 -0
- package/examples/grok_agent.js.bak.3 +1 -0
- package/examples/grok_agent.js.bak.4 +124 -0
- package/examples/grok_agent.js.bak.5 +1 -0
- package/examples/grok_agent.js.bak.6 +1 -0
- package/examples/memory_agent.js +152 -0
- package/examples/npm_agent.js +202 -0
- package/examples/npm_agent.js.bak.3 +2 -0
- package/examples/npm_agent.js.bak.4 +205 -0
- package/examples/npm_agent.js.bak.5 +1 -0
- package/examples/npm_agent.js.bak.6 +1 -0
- package/examples/prompt_agent.js +133 -0
- package/examples/readme_agent.js +148 -0
- package/examples/spawn_agent.js +293 -0
- package/examples/test_agent.js +187 -0
- package/examples/todo_agent.js +175 -0
- package/examples.bak.1774780058/ask_agent.js +114 -0
- package/examples.bak.1774780058/code_agent.js +149 -0
- package/examples.bak.1774780058/coderev_agent.js +72 -0
- package/examples.bak.1774780058/codeserver.sh +47 -0
- package/examples.bak.1774780058/daisy_agent.js +177 -0
- package/examples.bak.1774780058/docs_agent.js +119 -0
- package/{bin/hdAsk.js → examples.bak.1774780058/gpt_agent.js} +46 -40
- package/examples.bak.1774780058/grok_agent.js +98 -0
- package/examples.bak.1774780058/memory_agent.js +112 -0
- package/examples.bak.1774780058/npm_agent.js +175 -0
- package/examples.bak.1774780058/prompt_agent.js +112 -0
- package/examples.bak.1774780058/readme_agent.js +144 -0
- package/examples.bak.1774780058/spawn_agent.js +263 -0
- package/examples.bak.1774780058/test_agent.js +162 -0
- package/examples.bak.1774780058/todo_agent.js +138 -0
- package/lib/API/openai.com/reponses/text.js +12 -18
- package/lib/API/x.ai/collections.js +354 -0
- package/lib/API/x.ai/files.js +218 -0
- package/lib/API/x.ai/responses.js +492 -0
- package/lib/API/x.ai/text.js +1 -1
- package/lib/AgentClient.js +13 -6
- package/lib/AgentManager.js +80 -10
- package/lib/AgentServer.js +50 -22
- package/lib/Cli.js +7 -1
- package/lib/Prompt.js +4 -2
- package/lib/ToolSet.js +2 -1
- package/lib/genericToolset.js +258 -88
- package/lib/genericToolset.js.bak_syntax +402 -0
- package/lib/index.js +4 -2
- package/lib/wsCli.js +256 -0
- package/lib/wsIO.js +96 -0
- package/package.json +26 -21
- package/scenarios.bak.1774780058/data/eval_node_message.json +9 -0
- package/scenarios.bak.1774780058/data/hist_oa.json +66 -0
- package/scenarios.bak.1774780058/data/o3_response1.json +96 -0
- package/scenarios.bak.1774780058/data/oa_reasoning_parse.json +112 -0
- package/scenarios.bak.1774780058/data/tool_oa.json +96 -0
- package/scenarios.bak.1774780058/data/tool_xai.json +59 -0
- package/scenarios.bak.1774780058/data/tool_xai2.json +40 -0
- package/scenarios.bak.1774780058/data/xai-response-1.json +59 -0
- package/scenarios.bak.1774780058/data/xai-response-2.json +10 -0
- package/scenarios.bak.1774780058/data/xai_reasoning_tools_resp.json +59 -0
- package/scenarios.bak.1774780058/data/xai_search_response.json +58 -0
- package/scenarios.bak.1774780058/environment.js +10 -0
- package/scenarios.bak.1774780058/example.js +17 -0
- package/scenarios.bak.1774780058/genericToolset.test.js +182 -0
- package/scenarios.bak.1774780058/grok.js +113 -0
- package/scenarios.bak.1774780058/memory-tools.js +51 -0
- package/scenarios.bak.1774780058/openai-o3.js +137 -0
- package/scenarios.bak.1774780058/openai-prompt.js +155 -0
- package/scenarios.bak.1774780058/openai-session.js +148 -0
- package/scenarios.bak.1774780058/openai.js +102 -0
- package/scenarios.bak.1774780058/prompt.js +118 -0
- package/scenarios.bak.1774780058/promptFishbowl.js +76 -0
- package/scenarios.bak.1774780058/search.brave.com.js +25 -0
- package/scenarios.bak.1774780058/sh.js +15 -0
- package/scenarios.bak.1774780058/test-wsio.js +26 -0
- package/scenarios.bak.1774780058/testToolset.js +42 -0
- package/scenarios.bak.1774780058/toolset.js +16 -0
- package/scenarios.bak.1774780058/toolset.test.js +141 -0
- package/scenarios.bak.1774780058/write_file_syntax.test.js +145 -0
- package/scenarios.bak.1774780058/write_file_validation/README.md +30 -0
- package/scenarios.bak.1774780058/write_file_validation/bad.js +3 -0
- package/scenarios.bak.1774780058/write_file_validation/good.js +4 -0
- package/scenarios.bak.1774780058/write_file_validation/test.sh +43 -0
- package/scenarios.bak.1774780058/wsClient.js +69 -0
- package/scenarios.bak.1774780058/xai_responses.integration.test.js +57 -0
- package/scenarios.bak.1774780058/xai_responses.test.js +154 -0
- package/scenarios.bak.1774780058/xaicoll.js +50 -0
- package/scenarios.bak.1774780058/xaifiles.js +48 -0
- package/types/API/openai.com/reponses/text.d.ts +17 -3
- package/types/API/x.ai/collections.d.ts +167 -0
- package/types/API/x.ai/files.d.ts +84 -0
- package/types/API/x.ai/responses.d.ts +379 -0
- package/types/AgentClient.d.ts +5 -0
- package/types/AgentManager.d.ts +25 -31
- package/types/AgentServer.d.ts +5 -1
- package/types/Prompt.d.ts +4 -2
- package/types/ToolSet.d.ts +1 -0
- package/types/index.d.ts +4 -3
- package/types/wsCli.d.ts +3 -0
- package/types/wsIO.d.ts +26 -0
- package/utils/bars.js +40 -0
- package/utils/clear_sessions.sh +54 -0
- package/{bin/hdInspect.js → utils/format_log.js} +5 -0
- package/utils/list_sessions.sh +46 -0
- package/utils/search_sessions.sh +73 -0
- package/utils/syntax_check.sh +61 -0
- package/utils/test.sh +46 -0
- package/bin/hdClear.js +0 -13
- package/bin/hdCode.js +0 -115
- package/bin/hdConnect.js +0 -230
- package/bin/hdNpm.js +0 -114
- package/bin/hdPrompt.js +0 -108
- package/examples/claude-test.js +0 -89
- package/examples/claude.js +0 -143
- package/examples/gpt.js +0 -127
- package/examples/gpt_code.js +0 -125
- package/examples/gpt_note_keeping.js +0 -117
- package/examples/grok.js +0 -119
- package/examples/grok_code.js +0 -114
- package/examples/grok_note_keeping.js +0 -111
- package/module.md +0 -189
package/README.md.backup
ADDED
|
@@ -0,0 +1,269 @@
|
|
|
1
|
+
# @j-o-r/hello-dave
|
|
2
|
+
|
|
3
|
+
[](https://www.npmjs.com/package/%40j-o-r%2Fhello-dave)
|
|
4
|
+
[](https://opensource.org/licenses/Apache-2.0)
|
|
5
|
+
[](https://nodejs.org/)
|
|
6
|
+
|
|
7
|
+
## Table of Contents
|
|
8
|
+
|
|
9
|
+
- [Description](#description)
|
|
10
|
+
- [Features](#features)
|
|
11
|
+
- [Installation](#installation)
|
|
12
|
+
- [Quick Start](#quick-start)
|
|
13
|
+
- [Usage](#usage)
|
|
14
|
+
- [Examples](#examples)
|
|
15
|
+
- [Development](#development)
|
|
16
|
+
- [Changelog](#changelog)
|
|
17
|
+
- [Contributing](#contributing)
|
|
18
|
+
- [License](#license)
|
|
19
|
+
- [TODO Alignment](#todo-alignment)
|
|
20
|
+
|
|
21
|
+
## Description
|
|
22
|
+
|
|
23
|
+
**@j-o-r/hello-dave** is a lightweight, ESM-only Node.js framework for building intelligent AI agents powered by large language models (LLMs) such as xAI Grok, Anthropic Claude, or OpenAI GPT. It simplifies the creation of custom agents with features like the central `AgentManager` class, WebSocket-based client/server support for networked agents, seamless tool integration (e.g., bash execution, web search), customizable system prompts, and robust session management supporting large context windows (up to millions of tokens).
|
|
24
|
+
|
|
25
|
+
The framework emphasizes ease of use, allowing developers and non-experts alike to rapidly prototype and deploy specialized agents. Core integrations include unified xAI Grok API access, WebSocket (WS) networking with secret-based authentication, and direct CLI/cron messaging (no heartbeat/ping mechanism required). Example scripts like `readmeDave`, `todoDave`, and others have been reorganized into the `examples/` folder for clarity.
|
|
26
|
+
|
|
27
|
+
Whether you're building a code reviewer, a research assistant, or a creative collaborator, `@j-o-r/hello-dave` abstracts away API complexities, providing a unified interface across providers. It's alpha-stage but production-ready for personal projects, with persistence for sessions and logs in NDJSON format.
|
|
28
|
+
|
|
29
|
+
## Features
|
|
30
|
+
|
|
31
|
+
- **Unified LLM Access**: Seamless integration with xAI Grok API, Anthropic Claude, and OpenAI GPT via a single API.
|
|
32
|
+
- **AgentManager Class**: Core orchestrator for prompts, tools, sessions, and interactions (CLI, direct calls, WebSocket).
|
|
33
|
+
- **Tool Integration**: Built-in tools for bash scripting, web search, JavaScript execution, and more; easily extensible.
|
|
34
|
+
- **WebSocket Networking with Secrets**: Agents can act as servers or clients with optional secret authentication, enabling secure distributed agent networks across machines.
|
|
35
|
+
- **Direct CLI/Cron Messaging**: Simplified interactions without needing heartbeat mechanisms—ideal for scheduled tasks.
|
|
36
|
+
- **Customizable Prompts**: Tailor agent behavior with system prompts for specialized tasks (e.g., music production, code analysis).
|
|
37
|
+
- **Session Management**: Persistent conversations with large context windows; automatic truncation and history search.
|
|
38
|
+
- **CLI Utilities**: Core tool at `bin/dave.js` for cache management, WS connections, and interactive queries; plus agent generator.
|
|
39
|
+
- **Lightweight & TypeScript-Friendly**: ESM-only, no heavy deps; full types included.
|
|
40
|
+
|
|
41
|
+
## Installation
|
|
42
|
+
|
|
43
|
+
Install as a dependency in your Node.js project (requires Node.js >= 20 with `"type": "module"` in `package.json`):
|
|
44
|
+
|
|
45
|
+
```bash
|
|
46
|
+
npm install @j-o-r/hello-dave
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
For global access to CLI tools (including `dave` from `bin/dave.js`):
|
|
50
|
+
|
|
51
|
+
```bash
|
|
52
|
+
npm install -g @j-o-r/hello-dave
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
Set your API keys via environment variables (only set what you need):
|
|
56
|
+
- `XAIKEY` for xAI Grok
|
|
57
|
+
- `ANTHKEY` for Anthropic Claude
|
|
58
|
+
- `OPENAIKEY` for OpenAI GPT
|
|
59
|
+
- `BRAVESEARCHKEY` for web search (optional)
|
|
60
|
+
|
|
61
|
+
Create a cache directory for sessions:
|
|
62
|
+
```bash
|
|
63
|
+
mkdir .cache
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
## Quick Start
|
|
67
|
+
|
|
68
|
+
1. Set an API key (e.g., for Grok):
|
|
69
|
+
```bash
|
|
70
|
+
export XAIKEY=your_xai_api_key
|
|
71
|
+
```
|
|
72
|
+
|
|
73
|
+
2. Use the core CLI utility `bin/dave.js` for interactive queries or management:
|
|
74
|
+
```bash
|
|
75
|
+
npx @j-o-r/hello-dave dave --ask
|
|
76
|
+
```
|
|
77
|
+
- Launches an interactive agent session. Use `Alt+d` to exit, `Alt+r` to reset.
|
|
78
|
+
- Example: Ask questions about anything; it uses xAI Grok by default with web search and X search tools.
|
|
79
|
+
|
|
80
|
+
3. For one-shot queries via piped input:
|
|
81
|
+
```bash
|
|
82
|
+
echo "Explain quantum computing" | npx @j-o-r/hello-dave dave --ask --model grok-4
|
|
83
|
+
```
|
|
84
|
+
- Provides a direct response using the specified model (e.g., `--model grok-4`).
|
|
85
|
+
|
|
86
|
+
4. Connect to a WebSocket server (e.g., for networked agents):
|
|
87
|
+
```bash
|
|
88
|
+
npx @j-o-r/hello-dave dave --connect ws://localhost:8080 --secret your_secret
|
|
89
|
+
```
|
|
90
|
+
|
|
91
|
+
5. Generate a custom agent using the spawner (snippet from `bin/dave.js` integration):
|
|
92
|
+
```bash
|
|
93
|
+
npx @j-o-r/hello-dave spawnDave
|
|
94
|
+
```
|
|
95
|
+
- Interactive: Follow prompts to create a new agent script in `bin/`.
|
|
96
|
+
|
|
97
|
+
`bin/dave.js` also supports cache operations like `--list` (list sessions), `--search "query"`, `--clear`, and `--inspect path/to/log.ndjson`.
|
|
98
|
+
|
|
99
|
+
## Usage
|
|
100
|
+
|
|
101
|
+
### Core CLI via `bin/dave.js`
|
|
102
|
+
|
|
103
|
+
`bin/dave.js` provides essential utilities and examples for agent spawning, WS interactions, and basic querying. Key commands:
|
|
104
|
+
|
|
105
|
+
- **Ask Mode** (Interactive or Piped One-Shot):
|
|
106
|
+
```bash
|
|
107
|
+
# Interactive
|
|
108
|
+
npx @j-o-r/hello-dave dave --ask --model grok-4 --temperature 0.2
|
|
109
|
+
|
|
110
|
+
# Piped one-shot
|
|
111
|
+
echo "What is quantum computing?" | npx @j-o-r/hello-dave dave --ask --model grok-4
|
|
112
|
+
```
|
|
113
|
+
- Note: Piped input triggers a direct response via `directCall`; without pipe, it launches an interactive CLI session.
|
|
114
|
+
- `--model` option works for both modes (e.g., `grok-4`, `grok-4-1-fast-reasoning`).
|
|
115
|
+
- Uses `AgentManager` with xAI Grok API integration, adds tools like `web_search`, `x_search`, `open_link`, `send_email`, `history_search`.
|
|
116
|
+
- System prompt emphasizes brief, direct responses with step-by-step reasoning.
|
|
117
|
+
|
|
118
|
+
- **WebSocket Client Mode** (with secrets for secure networking):
|
|
119
|
+
```bash
|
|
120
|
+
# Interactive connection
|
|
121
|
+
npx @j-o-r/hello-dave dave --connect ws://localhost:8080 --secret "mysecret"
|
|
122
|
+
|
|
123
|
+
# Piped one-shot (direct CLI/cron messaging, no heartbeat needed)
|
|
124
|
+
echo "Predict the weather" | npx @j-o-r/hello-dave dave --connect ws://localhost:8080 --secret "mysecret"
|
|
125
|
+
echo "user_reset" | npx @j-o-r/hello-dave dave --connect ws://localhost:8080 --secret "mysecret"
|
|
126
|
+
```
|
|
127
|
+
|
|
128
|
+
- **Cache Management**:
|
|
129
|
+
```bash
|
|
130
|
+
npx @j-o-r/hello-dave dave --list # List sessions
|
|
131
|
+
npx @j-o-r/hello-dave dave --search "AI agents" # Search history
|
|
132
|
+
npx @j-o-r/hello-dave dave --clear # Clear cache
|
|
133
|
+
```
|
|
134
|
+
|
|
135
|
+
For custom agents, use `AgentManager` programmatically (see Examples).
|
|
136
|
+
|
|
137
|
+
### Programmatic Usage with AgentManager
|
|
138
|
+
|
|
139
|
+
```javascript
|
|
140
|
+
import AgentManager from '@j-o-r/hello-dave';
|
|
141
|
+
|
|
142
|
+
const agent = new AgentManager({ name: 'MyAgent', secret: 'optional_secret' });
|
|
143
|
+
agent.setup({
|
|
144
|
+
prompt: 'You are a helpful assistant...',
|
|
145
|
+
api: 'xai', // Uses unified xAI Grok API access
|
|
146
|
+
options: { model: 'grok-4', temperature: 0.7, tools: [{ type: 'web_search' }] },
|
|
147
|
+
toolsetMode: 'auto',
|
|
148
|
+
contextWindow: 500000
|
|
149
|
+
});
|
|
150
|
+
|
|
151
|
+
agent.addGenericToolcall('execute_bash_script'); // Post-setup generics
|
|
152
|
+
agent.addGenericToolcall('read_file');
|
|
153
|
+
agent.addGenericToolcall('write_file');
|
|
154
|
+
|
|
155
|
+
await agent.start(); // Interactive CLI
|
|
156
|
+
// Or: await agent.start(undefined, 8000, undefined, 'Intro', 'toolName', 'desc'); // WS server
|
|
157
|
+
// Or: const response = await agent.directCall('Query'); // One-shot
|
|
158
|
+
```
|
|
159
|
+
|
|
160
|
+
Direct CLI/cron: Pipe inputs to custom scripts for non-interactive use. WS supports secrets for authentication; no heartbeat required due to event-driven messaging.
|
|
161
|
+
|
|
162
|
+
## Examples
|
|
163
|
+
|
|
164
|
+
Example scripts (e.g., `readmeDave.js` for README management, `todoDave.js` for task handling, `spawnDave.js` for agent creation) are now organized in the `examples/` folder. These demonstrate specialized agents using `AgentManager`, xAI Grok API integration, and tools.
|
|
165
|
+
|
|
166
|
+
- **Link to Examples Folder**: Explore [examples/](examples/) for full scripts like `daisy.js` (music agent), `codeDave.js` (code review), `npmDave.js` (NPM inspector).
|
|
167
|
+
|
|
168
|
+
### Snippet: Spawning Agents (from `examples/spawnDave.js` integration via `bin/dave.js`)
|
|
169
|
+
|
|
170
|
+
`spawnDave` uses `AgentManager` to interactively generate new agent scripts:
|
|
171
|
+
|
|
172
|
+
```javascript
|
|
173
|
+
// Core setup in spawnDave
|
|
174
|
+
const agent = new AgentManager({ name: 'spawn_dave', secret });
|
|
175
|
+
agent.setup({
|
|
176
|
+
prompt: 'You are AgentCreator... [detailed prompt for portability, validation]',
|
|
177
|
+
api: 'xai',
|
|
178
|
+
options: { model: 'grok-4-fast-reasoning', tools: [{ type: 'web_search' }], reasoning: { effort: 'high' } },
|
|
179
|
+
toolsetMode: 'auto',
|
|
180
|
+
contextWindow: 500000
|
|
181
|
+
});
|
|
182
|
+
agent.addGenericToolcall('execute_bash_script'); // For project inspection
|
|
183
|
+
agent.addGenericToolcall('read_file');
|
|
184
|
+
agent.addGenericToolcall('write_file'); // For generating bin/ scripts
|
|
185
|
+
|
|
186
|
+
await agent.start(); // Guides user to create e.g., bin/myagent.js
|
|
187
|
+
```
|
|
188
|
+
|
|
189
|
+
- Validates generated ESM code with `node --check` and tool rules (xAI natives pre-setup, generics post-setup).
|
|
190
|
+
- Ensures absolute imports for portability.
|
|
191
|
+
|
|
192
|
+
### Snippet: Using xAI Grok API Integration
|
|
193
|
+
|
|
194
|
+
The unified xAI Grok API access supports options like reasoning and tools:
|
|
195
|
+
|
|
196
|
+
```javascript
|
|
197
|
+
// In AgentManager setup
|
|
198
|
+
const options = {
|
|
199
|
+
model: 'grok-4-1-fast-reasoning',
|
|
200
|
+
temperature: 0.8,
|
|
201
|
+
tools: [{ type: 'web_search' }, { type: 'x_search', from_date: '2024-01-01' }], // Native xAI tools
|
|
202
|
+
reasoning: { effort: 'medium', summary: 'auto' } // Chain-of-thought support
|
|
203
|
+
};
|
|
204
|
+
```
|
|
205
|
+
|
|
206
|
+
Detailed examples for xAI integration (e.g., advanced tool calls, reasoning) are planned (see TODO).
|
|
207
|
+
|
|
208
|
+
### Running Examples
|
|
209
|
+
|
|
210
|
+
```bash
|
|
211
|
+
# Music agent (examples/daisy.js)
|
|
212
|
+
chmod +x examples/daisy.js
|
|
213
|
+
./examples/daisy.js "Generate lyrics for a pop song"
|
|
214
|
+
|
|
215
|
+
# TODO manager (examples/todoDave.js)
|
|
216
|
+
./examples/todoDave.js --connect ws://localhost:8080 --secret "secret"
|
|
217
|
+
|
|
218
|
+
# Server setup for networked examples
|
|
219
|
+
npx @j-o-r/hello-dave dave --ask --serve 8080 # Expose as WS server
|
|
220
|
+
```
|
|
221
|
+
|
|
222
|
+
## Development
|
|
223
|
+
|
|
224
|
+
- **Scripts**: `npm test` (runs scenarios/grok.js), `npm run types` (generate TypeScript defs), `npm run release` (pack for release).
|
|
225
|
+
- **Structure**: Core in `lib/` (AgentManager.js, wsCli.js, etc.), API integrations in `lib/API/`, examples in `examples/`, utils in `utils/`.
|
|
226
|
+
- **Testing**: Basic validation via `npm test`. Unit tests for xAI integration planned (see TODO).
|
|
227
|
+
- **Prep for v0.0.4**: Focus on spawnDave enhancements and release testing.
|
|
228
|
+
|
|
229
|
+
## Changelog
|
|
230
|
+
|
|
231
|
+
### v0.0.4 (Prep - March 2026)
|
|
232
|
+
- Reorganized examples to `examples/` folder (readmeDave, todoDave, etc.).
|
|
233
|
+
- Enhanced `bin/dave.js` for core utilities: spawning, WS with secrets, direct messaging.
|
|
234
|
+
- Improved xAI Grok API integration; added native tools/reasoning support.
|
|
235
|
+
- Removed heartbeat needs; direct CLI/cron support.
|
|
236
|
+
- Added piped one-shot support to dave --ask.
|
|
237
|
+
- TODO alignment: High-priority items noted (release prep, spawnDave enhancements).
|
|
238
|
+
|
|
239
|
+
### v0.0.3 (Previous)
|
|
240
|
+
- Initial WS secrets, generic tools, AgentManager refinements.
|
|
241
|
+
|
|
242
|
+
Full history in git tags.
|
|
243
|
+
|
|
244
|
+
## Contributing
|
|
245
|
+
|
|
246
|
+
Contributions are welcome! Fork the repo at [https://codeberg.org/duin/hello-dave](https://codeberg.org/duin/hello-dave), create a feature branch, and submit a pull request.
|
|
247
|
+
|
|
248
|
+
1. Install deps: `npm install`
|
|
249
|
+
2. Self dep `npm run link-self`
|
|
250
|
+
3. Run tests: `npm test`
|
|
251
|
+
4. Generate types: `npm run types`
|
|
252
|
+
5. Report issues: [https://codeberg.org/duin/hello-dave/issues](https://codeberg.org/duin/hello-dave/issues)
|
|
253
|
+
|
|
254
|
+
Follow the [Code of Conduct](CODE_OF_CONDUCT.md) and Apache-2.0 license.
|
|
255
|
+
|
|
256
|
+
## License
|
|
257
|
+
|
|
258
|
+
Apache License 2.0. See [LICENSE](LICENSE) for details.
|
|
259
|
+
|
|
260
|
+
## TODO Alignment
|
|
261
|
+
|
|
262
|
+
This README aligns with high-priority items from [TODO.md](TODO.md):
|
|
263
|
+
- **v0.0.4 Prep**: Changelog snippet added; release testing emphasized in Development.
|
|
264
|
+
- **spawnDave Enhancements**: Highlighted in Examples with portability notes.
|
|
265
|
+
- xAI integration tests/examples: Deferred to later (general enhancements).
|
|
266
|
+
- Documentation tasks (e.g., AgentManager internals) integrated into Usage/Examples.
|
|
267
|
+
- Deferred: Other xAI features to later; focus on core release and spawnDave.
|
|
268
|
+
|
|
269
|
+
For full TODO, see [TODO.md](TODO.md).
|