@wheatley-ai/cli 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.
package/README.md ADDED
@@ -0,0 +1,192 @@
1
+ # @wheatley-ai/cli
2
+
3
+ Wheatley is a personal AI assistant that you host yourself. It runs as a daemon on your machine or server and keeps working when you close the terminal. It remembers what you tell it and runs jobs on a schedule. Before it writes a file or runs a shell command, it asks you.
4
+
5
+ You can talk to it from the terminal, from the web dashboard, or from Telegram, Slack, and Discord.
6
+
7
+ This package installs the `wheatley` command. The daemon, the CLI, and the dashboard all ship in it.
8
+
9
+ ## Install
10
+
11
+ You need Node.js 26.13.1 or newer.
12
+
13
+ ```sh
14
+ npm install -g @wheatley-ai/cli
15
+ ```
16
+
17
+ pnpm works too: `pnpm add -g @wheatley-ai/cli`.
18
+
19
+ ## Quick start
20
+
21
+ Create the config files. By default they go in `~/.wheatley`. Set `WHEATLEY_HOME` or pass `--home` to put them somewhere else.
22
+
23
+ ```sh
24
+ wheatley init
25
+ ```
26
+
27
+ Put your API key in `~/.wheatley/secrets.yaml`:
28
+
29
+ ```yaml
30
+ ANTHROPIC_API_KEY: sk-ant-...
31
+ ```
32
+
33
+ Start the daemon:
34
+
35
+ ```sh
36
+ wheatley daemon
37
+ ```
38
+
39
+ Then, in another terminal:
40
+
41
+ ```sh
42
+ wheatley ask "Summarize the README in the current folder"
43
+ wheatley chat
44
+ ```
45
+
46
+ The dashboard is at <http://127.0.0.1:7420>.
47
+
48
+ `wheatley init` sets up Anthropic with `claude-sonnet-5-5`. For another provider, pass `--provider` and `--model`. For example, `wheatley init --provider openai --model gpt-5.4-mini` expects `OPENAI_API_KEY`.
49
+
50
+ ## Run it in the background
51
+
52
+ `wheatley service` installs a user service: systemd on Linux, launchd on macOS.
53
+
54
+ ```sh
55
+ wheatley service install
56
+ wheatley service start
57
+ wheatley service status
58
+ ```
59
+
60
+ ## Commands
61
+
62
+ | Command | What it does |
63
+ | --- | --- |
64
+ | `wheatley init` | Create `config.yaml` and `secrets.yaml` |
65
+ | `wheatley daemon` | Run the daemon in the foreground |
66
+ | `wheatley chat` | Open an interactive chat with an agent |
67
+ | `wheatley ask "<prompt>"` | Send one prompt and print the reply |
68
+ | `wheatley status` | Show the health of the daemon and each agent |
69
+ | `wheatley service <action>` | `install`, `start`, `stop`, `restart`, or `status` |
70
+ | `wheatley update` | Update to the newest release in your major version |
71
+ | `wheatley restore <agent> [id]` | List or restore an agent's database backups |
72
+
73
+ Run `wheatley --help` for all the options.
74
+
75
+ With no arguments, `ask` reads the prompt from stdin:
76
+
77
+ ```sh
78
+ { echo "Review this diff:"; git diff; } | wheatley ask
79
+ ```
80
+
81
+ If stdin is not a terminal, `ask` cannot ask for approval. It denies every tool call that needs one.
82
+
83
+ ## Configuration
84
+
85
+ Wheatley reads its settings from `~/.wheatley/config.yaml`. Secrets go in `secrets.yaml`, and the config refers to them by name. If an environment variable has the same name as a secret, the variable wins.
86
+
87
+ ```yaml
88
+ version: 1
89
+
90
+ providers:
91
+ anthropic:
92
+ apiKey:
93
+ secret: ANTHROPIC_API_KEY
94
+
95
+ agents:
96
+ default:
97
+ model:
98
+ provider: anthropic
99
+ id: claude-sonnet-5-5
100
+
101
+ # First match wins. Tools without a rule use their own default.
102
+ permissionPolicy:
103
+ - tool: read_file
104
+ action: allow
105
+ - tool: shell
106
+ action: ask
107
+
108
+ # Chat with the agent from Telegram.
109
+ frontends:
110
+ - id: phone
111
+ type: telegram
112
+ config:
113
+ botToken:
114
+ secret: TELEGRAM_BOT_TOKEN
115
+ allowedChatIds: [123456789]
116
+
117
+ # Give the agent the tools of an MCP server.
118
+ mcpServers:
119
+ github:
120
+ transport: http
121
+ url: https://api.githubcopilot.com/mcp/
122
+ headers:
123
+ Authorization:
124
+ secret: GITHUB_MCP_AUTH
125
+ ```
126
+
127
+ You can define more than one agent. Each agent gets its own model, memory, schedule, and folder under `~/.wheatley/agents/<name>/`. After you edit the config, restart the agent from the dashboard or with `/restart` in a chat.
128
+
129
+ ## Approvals
130
+
131
+ The file and shell tools work inside `agents/<name>/workspace`. Writing files, running shell commands, and calling MCP tools need your approval by default. When the agent wants to do one of these, the chat shows the tool and its input. You answer with one of these:
132
+
133
+ - `o`: allow it once.
134
+ - `c`: allow it for the rest of the conversation.
135
+ - `a`: allow it always. Wheatley adds an `allow` rule to your config.
136
+ - `d <reason>`: deny it, and tell the agent why.
137
+
138
+ An approval waits 15 minutes and then expires. Change this with `approvalTimeout` on the agent.
139
+
140
+ ## Chat commands
141
+
142
+ | Command | What it does |
143
+ | ------------------- | ---------------------------------------------- |
144
+ | `/new` | Start a new conversation |
145
+ | `/model <id>` | Use another model for this conversation |
146
+ | `/compact` | Compact the conversation to save context |
147
+ | `/stop` | Stop the current run |
148
+ | `/goal <objective>` | Start a long-running task |
149
+ | `/status` | Show the conversation, model, and agent health |
150
+ | `/restart` | Restart the agent |
151
+
152
+ ## What else it does
153
+
154
+ - **Memory.** Each agent keeps notes in `agents/<name>/memory/MEMORY.md` and reads them at the start of each conversation. Every day at 03:00, the agent reviews its notes. It merges duplicates and removes facts that are out of date.
155
+ - **Schedules.** Ask "remind me every weekday at 9 to check my email" and the agent creates a cron trigger. It can set one-off reminders too. A webhook trigger starts a run when it receives an HTTP request. You create webhook triggers in the dashboard.
156
+ - **Skills.** Put a folder with a `SKILL.md` in `~/.wheatley/skills/` to share it with all agents, or in `agents/<name>/skills/` for one agent.
157
+ - **Plugins.** Add your own tools and chat integrations in TypeScript. See [`@wheatley-ai/sdk`](https://www.npmjs.com/package/@wheatley-ai/sdk).
158
+
159
+ ## Docker
160
+
161
+ If you would rather not install Node.js, use the image on the GitHub Container Registry:
162
+
163
+ ```sh
164
+ docker volume create wheatley-data
165
+ docker run --rm -v wheatley-data:/data ghcr.io/sphericalkat/wheatley:latest wheatley init
166
+ docker run --rm -v wheatley-data:/data ghcr.io/sphericalkat/wheatley:latest \
167
+ sh -c 'printf "daemon:\n host: 0.0.0.0\n port: 7420\n" >> /data/config.yaml'
168
+ docker run --rm -v wheatley-data:/data ghcr.io/sphericalkat/wheatley:latest \
169
+ sh -c 'echo "ANTHROPIC_API_KEY: sk-ant-..." >> /data/secrets.yaml'
170
+
171
+ docker run -d --name wheatley --init --restart unless-stopped --stop-timeout 45 \
172
+ -p 127.0.0.1:7420:7420 -v wheatley-data:/data ghcr.io/sphericalkat/wheatley:latest
173
+ ```
174
+
175
+ Each release gets four image tags. For release `0.1.0`, these are `0.1.0`, `0.1`, `0`, and `latest`.
176
+
177
+ ## Updating
178
+
179
+ ```sh
180
+ wheatley update --check
181
+ wheatley update
182
+ ```
183
+
184
+ `wheatley update` stays inside your current major version. To move to a new major version, run `npm install -g @wheatley-ai/cli@latest`. Then restart the daemon, for example with `wheatley service restart`.
185
+
186
+ ## Security
187
+
188
+ The daemon has no login. Anyone who can reach port 7420 can use your agents, so keep it on `127.0.0.1`, which is the default. It also rejects browser requests from other origins. If you need remote access, use an SSH tunnel or a private network such as Tailscale.
189
+
190
+ ## License
191
+
192
+ ISC
@@ -7,5 +7,5 @@
7
7
  },
8
8
  "name": "@wheatley-ai/sdk",
9
9
  "type": "module",
10
- "version": "0.1.0"
10
+ "version": "0.1.1"
11
11
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wheatley-ai/cli",
3
- "version": "0.1.0",
3
+ "version": "0.1.1",
4
4
  "description": "Wheatley daemon and CLI",
5
5
  "license": "ISC",
6
6
  "repository": {
@@ -41,7 +41,7 @@
41
41
  "@types/ws": "8.18.2",
42
42
  "@wheatley-ai/dashboard": "0.0.0",
43
43
  "@wheatley-ai/protocol": "0.0.0",
44
- "@wheatley-ai/sdk": "0.1.0"
44
+ "@wheatley-ai/sdk": "0.1.1"
45
45
  },
46
46
  "engines": {
47
47
  "node": ">=26.13.1"