@moxxy/cli 0.0.0 → 0.1.3
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 +228 -0
- package/dist/bin.js +55943 -50844
- package/dist/bin.js.map +1 -1
- package/dist/read-handler.js +1 -0
- package/dist/read-handler.js.map +1 -1
- package/dist/sidecar.js +276 -0
- package/dist/sidecar.js.map +1 -0
- package/dist/skills/create-workflow.md +71 -0
- package/package.json +57 -24
package/README.md
ADDED
|
@@ -0,0 +1,228 @@
|
|
|
1
|
+
<p align="center">
|
|
2
|
+
<a href="https://moxxy.ai">
|
|
3
|
+
<img src="https://moxxy.ai/moxxy-head-256.png" alt="moxxy" width="128" />
|
|
4
|
+
</a>
|
|
5
|
+
</p>
|
|
6
|
+
|
|
7
|
+
<h1 align="center">@moxxy/cli</h1>
|
|
8
|
+
|
|
9
|
+
<p align="center">
|
|
10
|
+
The <code>moxxy</code> binary.<br/>
|
|
11
|
+
An interactive TUI, one-shot prompts, channels, scheduler, MCP, and OS services in a single bundled command.
|
|
12
|
+
</p>
|
|
13
|
+
|
|
14
|
+
<p align="center">
|
|
15
|
+
<a href="https://www.npmjs.com/package/@moxxy/cli">
|
|
16
|
+
<img src="https://img.shields.io/npm/v/@moxxy/cli?logo=npm&logoColor=white" alt="npm" />
|
|
17
|
+
</a>
|
|
18
|
+
<a href="https://nodejs.org">
|
|
19
|
+
<img src="https://img.shields.io/badge/node-%3E%3D20.10-brightgreen?logo=node.js&logoColor=white" alt="Node ≥20.10" />
|
|
20
|
+
</a>
|
|
21
|
+
<a href="https://www.typescriptlang.org">
|
|
22
|
+
<img src="https://img.shields.io/badge/TypeScript-strict-3178C6?logo=typescript&logoColor=white" alt="TypeScript" />
|
|
23
|
+
</a>
|
|
24
|
+
<a href="https://github.com/moxxy-ai/new_moxxy/actions/workflows/ci.yml">
|
|
25
|
+
<img src="https://github.com/moxxy-ai/new_moxxy/actions/workflows/ci.yml/badge.svg" alt="CI" />
|
|
26
|
+
</a>
|
|
27
|
+
</p>
|
|
28
|
+
|
|
29
|
+
<p align="center">
|
|
30
|
+
<a href="#installation">Install</a>
|
|
31
|
+
·
|
|
32
|
+
<a href="#quickstart">Quickstart</a>
|
|
33
|
+
·
|
|
34
|
+
<a href="https://moxxy.ai">Docs</a>
|
|
35
|
+
·
|
|
36
|
+
<a href="#commands">Commands</a>
|
|
37
|
+
·
|
|
38
|
+
<a href="#channels">Channels</a>
|
|
39
|
+
·
|
|
40
|
+
<a href="#services">Services</a>
|
|
41
|
+
</p>
|
|
42
|
+
|
|
43
|
+
---
|
|
44
|
+
|
|
45
|
+
## What this package is
|
|
46
|
+
|
|
47
|
+
`@moxxy/cli` is the published `moxxy` binary. It bundles the framework runtime, every built-in mode, every built-in provider, every built-in plugin, the Ink TUI channel, MCP support, the scheduler, webhooks, and the OS service installer into a single executable.
|
|
48
|
+
|
|
49
|
+
Install this if you want to use moxxy. If you want to author plugins, depend on [`@moxxy/sdk`](https://www.npmjs.com/package/@moxxy/sdk) instead.
|
|
50
|
+
|
|
51
|
+
## What you get out of the box
|
|
52
|
+
|
|
53
|
+
- A complete agent stack with Anthropic, OpenAI, and ChatGPT (OAuth) providers.
|
|
54
|
+
- Five loop strategies: `tool-use` (default Claude-Code-style), `plan-execute`, `bmad`, `developer`, and `deep-research`.
|
|
55
|
+
- Built-in tools: Read, Edit, Write, Bash, Grep, Glob, WebFetch, computer-control (macOS), and browser-session (Playwright, optional).
|
|
56
|
+
- Multi-channel by design: TUI, Telegram, HTTP, web, cron, and webhooks. One session can drive several surfaces at once.
|
|
57
|
+
- Voice input on any audio-capable channel through `@moxxy/plugin-stt-whisper`.
|
|
58
|
+
- An encrypted vault (AES-256-GCM at rest) so secrets in config are referenced as `${vault:KEY}` and never written in plaintext.
|
|
59
|
+
- A long-term memory subsystem with a journal and vector recall. TF-IDF ships built-in. Swap to OpenAI embeddings via `@moxxy/plugin-embeddings-openai`.
|
|
60
|
+
- A permission resolver that gates every tool call and learns allow-always rules per tool.
|
|
61
|
+
- Opt-in capability isolation. Tools declare what they need and an isolator enforces it. `inproc` ships built-in. `worker`, `subprocess`, `wasm`, and Docker isolators drop in behind the same interface.
|
|
62
|
+
- A scheduler for cron expressions and one-shot ISO timestamps.
|
|
63
|
+
- A webhook listener with HMAC verification, header and JSON-path filters, and a `cloudflared` or `ngrok` tunnel helper.
|
|
64
|
+
- An OS service installer for launchd (macOS) and systemd (Linux), or a single `serve --background` process that runs every channel together.
|
|
65
|
+
|
|
66
|
+
## Installation
|
|
67
|
+
|
|
68
|
+
```sh
|
|
69
|
+
npm install -g @moxxy/cli
|
|
70
|
+
```
|
|
71
|
+
|
|
72
|
+
Or run it without installing:
|
|
73
|
+
|
|
74
|
+
```sh
|
|
75
|
+
npx @moxxy/cli init
|
|
76
|
+
```
|
|
77
|
+
|
|
78
|
+
Requirements: Node.js 20.10 or later. An API key for a supported provider (Anthropic, OpenAI), or sign into ChatGPT via `moxxy login openai-codex`.
|
|
79
|
+
|
|
80
|
+
## Quickstart
|
|
81
|
+
|
|
82
|
+
```sh
|
|
83
|
+
moxxy init # interactive: choose provider, paste API key (stored in the vault)
|
|
84
|
+
moxxy # launch the interactive TUI
|
|
85
|
+
```
|
|
86
|
+
|
|
87
|
+
One-shot from the command line:
|
|
88
|
+
|
|
89
|
+
```sh
|
|
90
|
+
moxxy -p "summarize the README in three bullets"
|
|
91
|
+
```
|
|
92
|
+
|
|
93
|
+
Resume a previous conversation:
|
|
94
|
+
|
|
95
|
+
```sh
|
|
96
|
+
moxxy resume
|
|
97
|
+
```
|
|
98
|
+
|
|
99
|
+
`moxxy --help` lists every command. `moxxy <command> --help` shows per-command details.
|
|
100
|
+
|
|
101
|
+
## Commands
|
|
102
|
+
|
|
103
|
+
The CLI groups commands the same way `moxxy --help` does.
|
|
104
|
+
|
|
105
|
+
### Setup
|
|
106
|
+
|
|
107
|
+
| Command | What it does |
|
|
108
|
+
|---|---|
|
|
109
|
+
| `moxxy init` | Interactive first-time setup. Picks a provider, captures the key, writes it into the vault. |
|
|
110
|
+
| `moxxy login <provider>` | OAuth sign-in for providers that do not use API keys (for example `openai-codex`). |
|
|
111
|
+
| `moxxy login status` | Show stored OAuth credentials. |
|
|
112
|
+
| `moxxy login logout <provider>` | Remove stored OAuth credentials. |
|
|
113
|
+
| `moxxy doctor` | Diagnose your install: provider readiness, vault unlock, missing optional dependencies. |
|
|
114
|
+
|
|
115
|
+
### Run
|
|
116
|
+
|
|
117
|
+
| Command | What it does |
|
|
118
|
+
|---|---|
|
|
119
|
+
| `moxxy` | Default. Starts the Ink TUI. |
|
|
120
|
+
| `moxxy tui` | Same as above, explicit. |
|
|
121
|
+
| `moxxy -p "…"` (or `--prompt`) | One-shot prompt to stdout. |
|
|
122
|
+
| `moxxy resume [-s <id>]` | Resume a persisted session. Interactive picker if no id. |
|
|
123
|
+
| `moxxy <channel>` | Start a registered channel by name. |
|
|
124
|
+
| `moxxy channels` | List registered channels and their subcommands. |
|
|
125
|
+
| `moxxy serve` | Start every channel together with the scheduler and webhooks in one process. |
|
|
126
|
+
|
|
127
|
+
### Manage
|
|
128
|
+
|
|
129
|
+
| Command | What it does |
|
|
130
|
+
|---|---|
|
|
131
|
+
| `moxxy sessions list` and `delete` | Inspect or remove persisted sessions. |
|
|
132
|
+
| `moxxy skills list`, `new`, `audit` | Manage skill files across user, project, builtin, and plugin scopes. |
|
|
133
|
+
| `moxxy plugins list`, `reload`, `new` | Manage the plugin host. `reload` picks up newly installed packages. |
|
|
134
|
+
| `moxxy mcp list`, `add`, `enable`, `disable`, `remove` | Manage MCP servers in `~/.moxxy/mcp.json`. |
|
|
135
|
+
| `moxxy perms list`, `add`, `remove` | Inspect or edit the persisted permission rules. |
|
|
136
|
+
| `moxxy memory journal` and `recall` | Read or query long-term memory. |
|
|
137
|
+
| `moxxy schedule add`, `list`, `remove` | Time-driven prompts (cron or one-shot ISO). |
|
|
138
|
+
| `moxxy security audit`, `status`, `isolators` | Inspect tool capability declarations and the active isolator. |
|
|
139
|
+
| `moxxy service install`, `logs`, `status`, `uninstall` | Background OS services (launchd or systemd). |
|
|
140
|
+
| `moxxy self-update` | Update bundled plugins, skills, and core safely. |
|
|
141
|
+
|
|
142
|
+
### Flags
|
|
143
|
+
|
|
144
|
+
| Flag | What it does |
|
|
145
|
+
|---|---|
|
|
146
|
+
| `--prompt`, `-p "…"` | One-shot input. |
|
|
147
|
+
| `--model <id>` | Override the default model for this invocation. |
|
|
148
|
+
| `--output-format <fmt>` | `text`, `json`, or `stream-json` (one-shot output mode). |
|
|
149
|
+
| `--cwd <path>` | Set the agent's working directory. |
|
|
150
|
+
| `--config <path>` | Load a specific `moxxy.config.ts`. |
|
|
151
|
+
| `--no-color` | Disable ANSI colors. |
|
|
152
|
+
| `-h`, `--help`, `-v`, `--version` | Standard. |
|
|
153
|
+
|
|
154
|
+
### Environment
|
|
155
|
+
|
|
156
|
+
| Variable | What it does |
|
|
157
|
+
|---|---|
|
|
158
|
+
| `ANTHROPIC_API_KEY` | Default Anthropic provider key. |
|
|
159
|
+
| `OPENAI_API_KEY` | OpenAI provider key (also used by the openai embeddings plugin). |
|
|
160
|
+
| `MOXXY_VAULT_PASSPHRASE` | Headless vault unlock when no OS keychain is available. |
|
|
161
|
+
| `MOXXY_FIXTURES` | `record` or `replay`. Provider fixture mode used by tests. |
|
|
162
|
+
|
|
163
|
+
## Channels
|
|
164
|
+
|
|
165
|
+
Run your agent through whichever surface fits the task.
|
|
166
|
+
|
|
167
|
+
| Channel | What it does | Command |
|
|
168
|
+
|---|---|---|
|
|
169
|
+
| TUI | Grok-style interactive terminal UI. | `moxxy` |
|
|
170
|
+
| Telegram | Message the agent from anywhere. Voice notes get transcribed and run as turns. Pairs with a 6-digit code. | `moxxy telegram` |
|
|
171
|
+
| HTTP | `POST /v1/turn` (JSON, SSE streaming) and `POST /v1/turn/audio` (raw bytes, iOS Shortcut friendly), bearer-token auth. | `moxxy channels http` |
|
|
172
|
+
| Cron | Time-driven prompts. Cron expressions or one-shot ISO timestamps. | `moxxy schedule add …` |
|
|
173
|
+
| Webhooks | External systems fire prompts on signed POST. HMAC plus bearer plus filter rules. | `moxxy serve` (auto-starts the listener) |
|
|
174
|
+
|
|
175
|
+
## Services
|
|
176
|
+
|
|
177
|
+
Two ways to keep moxxy online 24/7.
|
|
178
|
+
|
|
179
|
+
Per-channel units, one process each so failures stay independent:
|
|
180
|
+
|
|
181
|
+
```sh
|
|
182
|
+
moxxy service install telegram # launchd on macOS, systemd --user on Linux
|
|
183
|
+
moxxy service logs telegram # tail the log
|
|
184
|
+
```
|
|
185
|
+
|
|
186
|
+
Or one process for everything, with a shared event log:
|
|
187
|
+
|
|
188
|
+
```sh
|
|
189
|
+
moxxy serve --background # every channel plus the scheduler plus webhooks
|
|
190
|
+
moxxy serve --background --except http # skip what you do not want
|
|
191
|
+
moxxy serve --status # is it running?
|
|
192
|
+
```
|
|
193
|
+
|
|
194
|
+
Logs land in `~/.moxxy/services/<name>.log`. The units survive reboots.
|
|
195
|
+
|
|
196
|
+
## Configuration
|
|
197
|
+
|
|
198
|
+
`moxxy.config.ts` at your project root:
|
|
199
|
+
|
|
200
|
+
```ts
|
|
201
|
+
import { defineConfig } from '@moxxy/config';
|
|
202
|
+
|
|
203
|
+
export default defineConfig({
|
|
204
|
+
provider: {
|
|
205
|
+
name: 'anthropic',
|
|
206
|
+
model: 'claude-sonnet-4-6',
|
|
207
|
+
config: { apiKey: '${vault:ANTHROPIC_API_KEY}' }, // resolved from the vault
|
|
208
|
+
},
|
|
209
|
+
mode: 'tool-use',
|
|
210
|
+
plugins: {
|
|
211
|
+
'@moxxy/mode-plan-execute': { enabled: false }, // disable per-plugin
|
|
212
|
+
},
|
|
213
|
+
});
|
|
214
|
+
```
|
|
215
|
+
|
|
216
|
+
`${vault:NAME}` placeholders resolve on session start. The vault unlocks via OS keychain (`keytar`) with a passphrase fallback (`MOXXY_VAULT_PASSPHRASE` for headless boxes).
|
|
217
|
+
|
|
218
|
+
## Docs
|
|
219
|
+
|
|
220
|
+
Full documentation lives at [docs.moxxy.ai](https://docs.moxxy.ai): concepts, recipes, plugin authoring, channel guides. The marketing site is at [moxxy.ai](https://moxxy.ai).
|
|
221
|
+
|
|
222
|
+
## Contributing
|
|
223
|
+
|
|
224
|
+
PRs welcome. The issue tracker and author guides live in the [moxxy monorepo](https://github.com/moxxy-ai/new_moxxy).
|
|
225
|
+
|
|
226
|
+
## License
|
|
227
|
+
|
|
228
|
+
MIT. See the repository root for the full text.
|