@stratusagent/cli 0.1.0 → 0.2.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 CHANGED
@@ -1,82 +1,78 @@
1
1
  # @stratusagent/cli
2
2
 
3
- Thin local entrypoint for exercising the Stratus Agent kernel without pulling product UI concerns into the runtime.
3
+ Stratus Agent CLI — create always-on agents that get smarter over time. Quickly set up Stratus Agent on your machine, create new agents, connect AI providers, and configure channels.
4
4
 
5
- ## Local usage
6
-
7
- From the repo root:
5
+ ## Install
8
6
 
9
7
  ```bash
10
- pnpm install
11
- pnpm cli run "say hello"
12
- pnpm cli run --prompt "please use the echo tool"
13
- echo "please inspect this with the echo tool" | pnpm cli run --stdin
14
- pnpm cli run --prompt "please use the echo tool" --format json
15
- pnpm cli dashboard
16
- pnpm cli dashboard --port 4123 --no-open
8
+ npm install -g @stratusagent/cli
9
+ stratus setup
17
10
  ```
18
11
 
19
- ## Real provider usage
20
-
21
- You can run the CLI against an OpenAI-compatible API instead of only the demo provider.
22
-
23
- ### Environment-only setup
12
+ `stratus setup` is the whole onboarding, as a small navigable menu:
24
13
 
25
- ```bash
26
- export STRATUS_PROVIDER=openai
27
- export OPENAI_API_KEY=your-key
28
- export STRATUS_MODEL=gpt-4.1-mini
29
- pnpm cli run "Say hello"
30
14
  ```
31
-
32
- Optional:
33
-
34
- ```bash
35
- export STRATUS_BASE_URL=https://openrouter.ai/api/v1
15
+ 1) Providers anthropic — signed in with your Claude subscription
16
+ 2) Models default claude-opus-5 · fallback gpt-4.1-mini
17
+ 3) Agent ~/.stratus/agents/ava.md
18
+ 4) Test run say hello with the current settings
19
+ 5) Save & finish
36
20
  ```
37
21
 
38
- ### Config file setup
39
-
40
- Create `stratus.config.json` in the repo root, or pass `--config`:
22
+ - **Providers** — sign in to one or more. For Claude, use an **Anthropic API key**, pasted straight into the prompt (input is hidden) and checked against the live API when the endpoint supports it — a rejected key is refused; an unreachable endpoint saves the key and verifies it on your first run. A **Claude Pro/Max subscription** sign-in (via `claude setup-token`) can be stored today, but subscription-billed runs arrive with the Claude Code integration ([#25](https://github.com/stratuslabs/agent/issues/25)) — until then, runs need an API key. OpenAI-compatible services work like API keys, including local models and proxies via a custom base URL.
23
+ - **Models** — pick a **default** and a **fallback**, listed live from the provider APIs where possible (subscription sign-ins and offline setups fall back to the known Claude lineup). If the default model errors mid-run, the run automatically retries on the fallback — even across providers.
24
+ - **Menus are keyboard-driven** — arrow keys (or `j`/`k`) to move, Enter to pick, digits to jump, Esc to go back.
25
+ - **Agent** — name your agent (or accept a generated identity), describe their personality, and their soul file lands in `~/.stratus/agents/`, ready to edit.
26
+ - **Test run** — say hello with the current settings before saving anything.
41
27
 
42
- ```json
43
- {
44
- "provider": "openai",
45
- "model": "gpt-4.1-mini",
46
- "baseUrl": "https://api.openai.com/v1",
47
- "apiKeyEnv": "OPENAI_API_KEY"
48
- }
49
- ```
28
+ Credentials are stored in `~/.stratus/credentials.json` (owner-read-only) and settings in `~/.stratus/config.json`, so `stratus run` works from any directory afterwards. No env vars to export, no config files to hand-edit.
50
29
 
51
- Then run:
30
+ ## Usage
52
31
 
53
32
  ```bash
54
- export OPENAI_API_KEY=your-key
55
- pnpm cli run "Say hello"
33
+ stratus run "say hello"
34
+ stratus run --soul ./ava.md "introduce yourself"
35
+ stratus run --provider anthropic --model claude-opus-5 "hello"
36
+ stratus run --prompt "use the echo tool" --format json
37
+ stratus agent new # generate an agent identity
38
+ stratus agent new --format soul > ava.md
39
+ stratus dashboard # local browser dashboard
56
40
  ```
57
41
 
58
- Legacy `STRATUSCLAW_*` env vars and `stratusclaw.config.json` are still accepted.
42
+ ## Agents are people
59
43
 
60
- ## Dashboard
44
+ An agent's identity lives in a **soul file** — markdown with frontmatter for the structured parts (name, provider, model, tool allowlists) and prose for the personality:
61
45
 
62
- `stratus dashboard` starts a small local server, prints the URL, opens your browser, and serves:
46
+ ```markdown
47
+ ---
48
+ name: Ava
49
+ provider: anthropic
50
+ model: claude-opus-5
51
+ tools:
52
+ - demo.echo
53
+ - memory.remember
54
+ ---
55
+
56
+ You are a sharp, warm generalist. Answer first, explain second...
57
+ ```
63
58
 
64
- - `GET /`, a simple Stratus Agent dashboard page
65
- - `GET /api/status`, a basic status payload
66
- - `POST /api/echo`, a tiny local test endpoint used by the page
59
+ Agents remember: facts saved with the built-in `memory.remember` tool persist to `~/.stratus/memory.jsonl`, keyed to the agent — so the Ava you talk to tomorrow remembers today, from any directory.
67
60
 
68
- This is intentionally dependency-light and built on Node standard library primitives.
61
+ ## Options
69
62
 
70
- ## What it does today
63
+ | Flag | Purpose |
64
+ | --- | --- |
65
+ | `--soul <file>` | Run as the agent defined by a soul file (also `STRATUS_SOUL` / config `soul` key) |
66
+ | `--provider` | `anthropic`, `openai`, or `demo` (offline, no account) |
67
+ | `--model` | Model for real providers (anthropic default: `claude-opus-5`) |
68
+ | `--base-url` | Override the provider API base URL |
69
+ | `--config <file>` | Load settings from a specific config file |
70
+ | `--approvals` | Tool approval mode: `always`, `ask`, or `never` |
71
+ | `--max-turns` | Max provider turns per run (default 8) |
72
+ | `--format` | `text` or `json` |
71
73
 
72
- - runs a single local session against either the demo provider or an OpenAI-compatible provider
73
- - shows event progress in text mode
74
- - executes the built-in `demo.echo` tool through `@stratusagent/executor-local`
75
- - can emit the full session as JSON for scripts and fixtures
76
- - serves a minimal dashboard for browser-based local smoke tests
74
+ Precedence: flags → `STRATUS_*` env vars → soul file hints → config file. Project-local `stratus.config.json` outranks the global `~/.stratus/config.json`; stored sign-ins are endpoint-bound and never sent to endpoints a project config selects.
77
75
 
78
- ## Notes
76
+ Today the CLI covers setup, one-shot runs, agent creation, and the local dashboard; channels and the always-on agent service are the next milestones.
79
77
 
80
- - `pnpm cli ...` runs the TypeScript source directly, so local testing does not require a pre-build step
81
- - `pnpm demo` is still the quickest smoke test for the demo path
82
- - real provider mode is text-only for now, it does not expose tool calling yet
78
+ Part of [Stratus Agent](https://github.com/stratuslabs/agent) — a tiny TypeScript agent runtime.
package/dist/index.d.ts CHANGED
@@ -1,4 +1,5 @@
1
- import { type JsonValue, type Session, type StratusEvent } from '@stratusagent/core';
1
+ import { type AgentMemoryStore, type JsonValue, type Session, type StratusEvent } from '@stratusagent/core';
2
+ import { type ParsedSoul } from '@stratusagent/agents';
2
3
  export interface CliStreams {
3
4
  stdout: Pick<typeof process.stdout, 'write'>;
4
5
  stderr: Pick<typeof process.stderr, 'write'>;
@@ -10,6 +11,8 @@ export interface CliEnvironment {
10
11
  setupInput?: NodeJS.ReadableStream;
11
12
  processEnv?: NodeJS.ProcessEnv;
12
13
  cwd?: string;
14
+ /** Home directory override (tests). Defaults to os.homedir(). */
15
+ homeDir?: string;
13
16
  fetch?: typeof fetch;
14
17
  openExternal?: (url: string) => Promise<void> | void;
15
18
  dashboardAutoShutdownMs?: number;
@@ -19,7 +22,7 @@ export interface CliRunOptions {
19
22
  streams?: CliStreams;
20
23
  env?: CliEnvironment;
21
24
  }
22
- export type CliProviderName = 'demo' | 'openai';
25
+ export type CliProviderName = 'demo' | 'openai' | 'anthropic';
23
26
  export type CliApprovalMode = 'always' | 'ask' | 'never';
24
27
  export interface ParsedRunCommand {
25
28
  command: 'run';
@@ -28,6 +31,8 @@ export interface ParsedRunCommand {
28
31
  model?: string;
29
32
  baseUrl?: string;
30
33
  configPath?: string;
34
+ /** Path to a soul file defining the agent to run as. */
35
+ soul?: string;
31
36
  format: 'text' | 'json';
32
37
  events: boolean;
33
38
  approvals: CliApprovalMode;
@@ -47,14 +52,23 @@ export interface ParsedAgentNewCommand {
47
52
  command: 'agent-new';
48
53
  name?: string;
49
54
  instructions?: string;
50
- format: 'text' | 'json';
55
+ format: 'text' | 'json' | 'soul';
51
56
  }
52
57
  export interface ParsedHelpCommand {
53
58
  command: 'help';
54
59
  }
55
60
  export type ParsedCommand = ParsedRunCommand | ParsedDashboardCommand | ParsedSetupCommand | ParsedAgentNewCommand | ParsedHelpCommand;
61
+ /** A resolved, ready-to-run fallback model (always a real provider). */
62
+ interface FallbackRuntime {
63
+ provider: 'anthropic' | 'openai';
64
+ model: string;
65
+ baseUrl?: string;
66
+ apiKey?: string;
67
+ authToken?: string;
68
+ }
56
69
  type RuntimeConfig = {
57
70
  provider: 'demo';
71
+ soul?: ParsedSoul;
58
72
  } | {
59
73
  provider: 'openai';
60
74
  model: string;
@@ -62,13 +76,38 @@ type RuntimeConfig = {
62
76
  apiKey: string;
63
77
  systemPrompt?: string;
64
78
  fetch?: typeof fetch;
79
+ soul?: ParsedSoul;
80
+ fallback?: FallbackRuntime;
81
+ } | {
82
+ provider: 'anthropic';
83
+ model: string;
84
+ baseUrl?: string;
85
+ apiKey?: string;
86
+ /** Claude subscription auth (Claude Code setup token). */
87
+ authToken?: string;
88
+ systemPrompt?: string;
89
+ fetch?: typeof fetch;
90
+ soul?: ParsedSoul;
91
+ fallback?: FallbackRuntime;
65
92
  };
93
+ /** A stored sign-in for a provider, kept in ~/.stratus/credentials.json. */
94
+ export interface StoredCredential {
95
+ type: 'api_key' | 'oauth_token';
96
+ value: string;
97
+ /**
98
+ * The endpoint this credential belongs to (openai-compatible services).
99
+ * Kept with the credential so a key for a local model or proxy is never
100
+ * sent to a different service, whatever the current default provider is.
101
+ */
102
+ baseUrl?: string;
103
+ }
66
104
  export interface DashboardServerHandle {
67
105
  url: string;
68
106
  close: () => Promise<void>;
69
107
  }
70
- declare const HELP_TEXT = "Stratus Agent CLI\n\nUsage:\n stratus setup\n stratus run --prompt \"Use the demo tool\"\n stratus run \"Say hello\"\n echo \"Use the echo tool\" | stratus run --stdin\n STRATUS_PROVIDER=openai OPENAI_API_KEY=... stratus run \"Say hello\"\n stratus run --config ./stratus.config.json --provider openai \"Say hello\"\n stratus dashboard\n stratus dashboard --port 4123 --host 0.0.0.0 --no-open\n\nCommands:\n setup Interactive walkthrough that writes stratus.config.json\n run Execute one local Stratus Agent session\n agent new Create an agent identity (generates a human-ish name + avatar theme)\n dashboard Start the local Stratus Agent dashboard and open it in your browser\n help Show this help message\n\nAgent options:\n --name Agent name (omit to have one generated)\n --instructions The agent's persona/instructions\n --format Output format for agent new: text or json\n\nOptions:\n --prompt, -p Prompt to send to the local agent loop\n --stdin Read the prompt from stdin\n --provider Provider to use: demo or openai\n --model Model name for real providers (default: gpt-4.1-mini)\n --base-url Override the OpenAI-compatible API base URL\n --config Config file path (run: load settings from it, setup: write it)\n --format Output format: text or json (default: text)\n --no-events Hide event-by-event progress lines in text mode\n --approvals Tool approval mode: always, ask, or never (default: always)\n --max-turns Maximum provider turns per run (default: 8)\n --port Dashboard port, defaults to an open local port\n --host Dashboard host (default: 127.0.0.1)\n --no-open Do not open the browser automatically\n --help, -h Show this help message\n\nConfig file:\n The CLI looks for ./stratus.config.json by default, or a path from --config / STRATUS_CONFIG.\n Legacy STRATUSCLAW_* env vars and stratusclaw.config.json are still supported for compatibility.\n";
108
+ declare const HELP_TEXT = "Stratus Agent CLI\n\nUsage:\n stratus setup\n stratus run --prompt \"Use the demo tool\"\n stratus run \"Say hello\"\n ANTHROPIC_API_KEY=... stratus run --provider anthropic \"Say hello\"\n stratus run --soul ./examples/souls/ava.md \"Say hello\"\n echo \"Use the echo tool\" | stratus run --stdin\n STRATUS_PROVIDER=openai OPENAI_API_KEY=... stratus run \"Say hello\"\n stratus run --config ./stratus.config.json --provider openai \"Say hello\"\n stratus dashboard\n stratus dashboard --port 4123 --host 0.0.0.0 --no-open\n\nCommands:\n setup Menu-driven onboarding: pick a provider, sign in (Claude\n subscription or API key), create your agent, and test it \u2014\n settings go to ~/.stratus/config.json, sign-ins to\n ~/.stratus/credentials.json (0600)\n run Execute one local Stratus Agent session\n agent new Create an agent identity (generates a human-ish name + avatar theme)\n dashboard Start the local Stratus Agent dashboard and open it in your browser\n help Show this help message\n\nAgent options:\n --name Agent name (omit to have one generated)\n --instructions The agent's persona/instructions\n --format Output format for agent new: text, json, or soul (a ready-to-edit soul file)\n\nOptions:\n --prompt, -p Prompt to send to the local agent loop\n --stdin Read the prompt from stdin\n --provider Provider to use: anthropic, openai, or demo\n --model Model name for real providers (anthropic default: claude-opus-5, openai default: gpt-4.1-mini)\n --base-url Override the provider API base URL\n --soul Run as the agent defined by a soul file (markdown + frontmatter, see examples/souls)\n --config Config file path (run: load settings from it, setup: write it)\n --format Output format: text or json (default: text)\n --no-events Hide event-by-event progress lines in text mode\n --approvals Tool approval mode: always, ask, or never (default: always)\n --max-turns Maximum provider turns per run (default: 8)\n --port Dashboard port, defaults to an open local port\n --host Dashboard host (default: 127.0.0.1)\n --no-open Do not open the browser automatically\n --help, -h Show this help message\n\nConfig file:\n The CLI looks for ./stratus.config.json first, then a path from --config / STRATUS_CONFIG,\n then the global ~/.stratus/config.json written by `stratus setup`.\n A \"soul\" key (or STRATUS_SOUL) points at a soul file so every run uses that agent.\n Legacy STRATUSCLAW_* env vars and stratusclaw.config.json are still supported for compatibility.\n\nSoul files:\n A soul file is markdown with frontmatter (name, provider, model, tools, credentials)\n followed by the agent's persona in prose. See examples/souls/ava.md.\n";
71
109
  declare const stringifyValue: (value: JsonValue) => string;
110
+ export declare const createFileMemoryStore: (filePath: string) => AgentMemoryStore;
72
111
  export declare const parseCommand: (argv: string[], env?: CliEnvironment) => ParsedCommand;
73
112
  export declare const formatEvent: (event: StratusEvent) => string | null;
74
113
  export declare const resolveRuntimeConfig: (command: ParsedRunCommand, env?: CliEnvironment) => Promise<RuntimeConfig>;
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAOA,OAAO,EAML,KAAK,SAAS,EAEd,KAAK,OAAO,EACZ,KAAK,YAAY,EAClB,MAAM,oBAAoB,CAAC;AAY5B,MAAM,WAAW,UAAU;IACzB,MAAM,EAAE,IAAI,CAAC,OAAO,OAAO,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAC7C,MAAM,EAAE,IAAI,CAAC,OAAO,OAAO,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;CAC9C;AAED,MAAM,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