open-agents-ai 0.62.0 → 0.63.0

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 (163) hide show
  1. package/README.md +45 -4
  2. package/dist/index.d.ts +6 -59
  3. package/dist/index.js +37932 -250
  4. package/package.json +1 -1
  5. package/dist/args.d.ts +0 -3
  6. package/dist/args.d.ts.map +0 -1
  7. package/dist/args.js +0 -51
  8. package/dist/args.js.map +0 -1
  9. package/dist/bin.d.ts +0 -3
  10. package/dist/bin.d.ts.map +0 -1
  11. package/dist/bin.js +0 -7
  12. package/dist/bin.js.map +0 -1
  13. package/dist/cli.d.ts +0 -5
  14. package/dist/cli.d.ts.map +0 -1
  15. package/dist/cli.js +0 -39
  16. package/dist/cli.js.map +0 -1
  17. package/dist/commands/config.d.ts +0 -32
  18. package/dist/commands/config.d.ts.map +0 -1
  19. package/dist/commands/config.js +0 -188
  20. package/dist/commands/config.js.map +0 -1
  21. package/dist/commands/eval.d.ts +0 -33
  22. package/dist/commands/eval.d.ts.map +0 -1
  23. package/dist/commands/eval.js +0 -211
  24. package/dist/commands/eval.js.map +0 -1
  25. package/dist/commands/index-repo.d.ts +0 -16
  26. package/dist/commands/index-repo.d.ts.map +0 -1
  27. package/dist/commands/index-repo.js +0 -84
  28. package/dist/commands/index-repo.js.map +0 -1
  29. package/dist/commands/run.d.ts +0 -25
  30. package/dist/commands/run.d.ts.map +0 -1
  31. package/dist/commands/run.js +0 -36
  32. package/dist/commands/run.js.map +0 -1
  33. package/dist/commands/serve.d.ts +0 -34
  34. package/dist/commands/serve.d.ts.map +0 -1
  35. package/dist/commands/serve.js +0 -195
  36. package/dist/commands/serve.js.map +0 -1
  37. package/dist/commands/status.d.ts +0 -14
  38. package/dist/commands/status.d.ts.map +0 -1
  39. package/dist/commands/status.js +0 -186
  40. package/dist/commands/status.js.map +0 -1
  41. package/dist/config.d.ts +0 -49
  42. package/dist/config.d.ts.map +0 -1
  43. package/dist/config.js +0 -150
  44. package/dist/config.js.map +0 -1
  45. package/dist/index.d.ts.map +0 -1
  46. package/dist/index.js.map +0 -1
  47. package/dist/open-agents-bin +0 -11
  48. package/dist/tui/bless-engine.d.ts +0 -53
  49. package/dist/tui/bless-engine.d.ts.map +0 -1
  50. package/dist/tui/bless-engine.js +0 -158
  51. package/dist/tui/bless-engine.js.map +0 -1
  52. package/dist/tui/braille-spinner.d.ts +0 -83
  53. package/dist/tui/braille-spinner.d.ts.map +0 -1
  54. package/dist/tui/braille-spinner.js +0 -288
  55. package/dist/tui/braille-spinner.js.map +0 -1
  56. package/dist/tui/call-agent.d.ts +0 -78
  57. package/dist/tui/call-agent.d.ts.map +0 -1
  58. package/dist/tui/call-agent.js +0 -299
  59. package/dist/tui/call-agent.js.map +0 -1
  60. package/dist/tui/carousel-descriptors.d.ts +0 -46
  61. package/dist/tui/carousel-descriptors.d.ts.map +0 -1
  62. package/dist/tui/carousel-descriptors.js +0 -367
  63. package/dist/tui/carousel-descriptors.js.map +0 -1
  64. package/dist/tui/carousel.d.ts +0 -53
  65. package/dist/tui/carousel.d.ts.map +0 -1
  66. package/dist/tui/carousel.js +0 -315
  67. package/dist/tui/carousel.js.map +0 -1
  68. package/dist/tui/commands.d.ts +0 -147
  69. package/dist/tui/commands.d.ts.map +0 -1
  70. package/dist/tui/commands.js +0 -1140
  71. package/dist/tui/commands.js.map +0 -1
  72. package/dist/tui/dmn-engine.d.ts +0 -199
  73. package/dist/tui/dmn-engine.d.ts.map +0 -1
  74. package/dist/tui/dmn-engine.js +0 -982
  75. package/dist/tui/dmn-engine.js.map +0 -1
  76. package/dist/tui/dream-engine.d.ts +0 -133
  77. package/dist/tui/dream-engine.d.ts.map +0 -1
  78. package/dist/tui/dream-engine.js +0 -1358
  79. package/dist/tui/dream-engine.js.map +0 -1
  80. package/dist/tui/edit-history.d.ts +0 -38
  81. package/dist/tui/edit-history.d.ts.map +0 -1
  82. package/dist/tui/edit-history.js +0 -140
  83. package/dist/tui/edit-history.js.map +0 -1
  84. package/dist/tui/emotion-engine.d.ts +0 -100
  85. package/dist/tui/emotion-engine.d.ts.map +0 -1
  86. package/dist/tui/emotion-engine.js +0 -334
  87. package/dist/tui/emotion-engine.js.map +0 -1
  88. package/dist/tui/index.d.ts +0 -7
  89. package/dist/tui/index.d.ts.map +0 -1
  90. package/dist/tui/index.js +0 -5
  91. package/dist/tui/index.js.map +0 -1
  92. package/dist/tui/interactive.d.ts +0 -12
  93. package/dist/tui/interactive.d.ts.map +0 -1
  94. package/dist/tui/interactive.js +0 -2723
  95. package/dist/tui/interactive.js.map +0 -1
  96. package/dist/tui/listen.d.ts +0 -128
  97. package/dist/tui/listen.d.ts.map +0 -1
  98. package/dist/tui/listen.js +0 -752
  99. package/dist/tui/listen.js.map +0 -1
  100. package/dist/tui/model-picker.d.ts +0 -55
  101. package/dist/tui/model-picker.d.ts.map +0 -1
  102. package/dist/tui/model-picker.js +0 -283
  103. package/dist/tui/model-picker.js.map +0 -1
  104. package/dist/tui/oa-directory.d.ts +0 -181
  105. package/dist/tui/oa-directory.d.ts.map +0 -1
  106. package/dist/tui/oa-directory.js +0 -500
  107. package/dist/tui/oa-directory.js.map +0 -1
  108. package/dist/tui/project-context.d.ts +0 -99
  109. package/dist/tui/project-context.d.ts.map +0 -1
  110. package/dist/tui/project-context.js +0 -377
  111. package/dist/tui/project-context.js.map +0 -1
  112. package/dist/tui/render.d.ts +0 -102
  113. package/dist/tui/render.d.ts.map +0 -1
  114. package/dist/tui/render.js +0 -883
  115. package/dist/tui/render.js.map +0 -1
  116. package/dist/tui/setup.d.ts +0 -99
  117. package/dist/tui/setup.d.ts.map +0 -1
  118. package/dist/tui/setup.js +0 -1349
  119. package/dist/tui/setup.js.map +0 -1
  120. package/dist/tui/snr-engine.d.ts +0 -115
  121. package/dist/tui/snr-engine.d.ts.map +0 -1
  122. package/dist/tui/snr-engine.js +0 -440
  123. package/dist/tui/snr-engine.js.map +0 -1
  124. package/dist/tui/status-bar.d.ts +0 -312
  125. package/dist/tui/status-bar.d.ts.map +0 -1
  126. package/dist/tui/status-bar.js +0 -1042
  127. package/dist/tui/status-bar.js.map +0 -1
  128. package/dist/tui/stream-renderer.d.ts +0 -106
  129. package/dist/tui/stream-renderer.d.ts.map +0 -1
  130. package/dist/tui/stream-renderer.js +0 -562
  131. package/dist/tui/stream-renderer.js.map +0 -1
  132. package/dist/tui/telegram-bridge.d.ts +0 -220
  133. package/dist/tui/telegram-bridge.d.ts.map +0 -1
  134. package/dist/tui/telegram-bridge.js +0 -1274
  135. package/dist/tui/telegram-bridge.js.map +0 -1
  136. package/dist/tui/tool-policy.d.ts +0 -57
  137. package/dist/tui/tool-policy.d.ts.map +0 -1
  138. package/dist/tui/tool-policy.js +0 -189
  139. package/dist/tui/tool-policy.js.map +0 -1
  140. package/dist/tui/voice-session.d.ts +0 -118
  141. package/dist/tui/voice-session.d.ts.map +0 -1
  142. package/dist/tui/voice-session.js +0 -846
  143. package/dist/tui/voice-session.js.map +0 -1
  144. package/dist/tui/voice.d.ts +0 -126
  145. package/dist/tui/voice.d.ts.map +0 -1
  146. package/dist/tui/voice.js +0 -1435
  147. package/dist/tui/voice.js.map +0 -1
  148. package/dist/types.d.ts +0 -10
  149. package/dist/types.d.ts.map +0 -1
  150. package/dist/types.js +0 -9
  151. package/dist/types.js.map +0 -1
  152. package/dist/ui/output.d.ts +0 -36
  153. package/dist/ui/output.d.ts.map +0 -1
  154. package/dist/ui/output.js +0 -117
  155. package/dist/ui/output.js.map +0 -1
  156. package/dist/ui/spinner.d.ts +0 -30
  157. package/dist/ui/spinner.d.ts.map +0 -1
  158. package/dist/ui/spinner.js +0 -106
  159. package/dist/ui/spinner.js.map +0 -1
  160. package/dist/updater.d.ts +0 -42
  161. package/dist/updater.d.ts.map +0 -1
  162. package/dist/updater.js +0 -165
  163. package/dist/updater.js.map +0 -1
package/README.md CHANGED
@@ -40,6 +40,7 @@ An autonomous multi-turn tool-calling agent that reads your code, makes changes,
40
40
  - **Autoresearch Swarm** — 5-agent GPU experiment loop during REM sleep: Researcher, Monitor, Evaluator, Critic, Flow Maintainer autonomously run ML training experiments, keep improvements, discard regressions
41
41
  - **Live Listen** — bidirectional voice communication with real-time Whisper transcription
42
42
  - **Live Voice Session** — `/listen` with `/voice` enabled spawns a cloudflared tunnel with a real-time WebSocket audio endpoint. A floating presence UI shows live transcription, connected users, and audio visualization. Echo cancellation prevents TTS feedback loops
43
+ - **Call Sub-Agent** — each WebSocket caller gets a dedicated AgenticRunner for low-latency voice-to-voice loops, with admin/public access tiers and bidirectional activity sharing with the main agent
43
44
  - **Telegram Voice** — `/voice` enabled via Telegram forwards TTS audio as voice messages alongside text responses. Incoming voice messages are auto-transcribed and handled as text
44
45
  - **Neural TTS** — hear what the agent is doing via GLaDOS or Overwatch ONNX voices, with personality-driven expressiveness
45
46
  - **Personality Core** — SAC framework-based style control (concise/balanced/verbose/pedagogical) that shapes agent response depth, voice expressiveness, and system prompt behavior
@@ -518,7 +519,7 @@ The agent stack includes a real-time emotion system that modulates behavior base
518
519
  - **Valence** (-1 to +1): displeasure ↔ pleasure
519
520
  - **Arousal** (0 to 1): calm ↔ energized
520
521
 
521
- Every agent event (tool success/failure, task completion, errors, context pressure) is appraised and shifts the emotional state, which decays back toward a baseline over ~60 seconds. The emotional state modulates agent behavior:
522
+ Every agent event (tool success/failure, task completion, errors, context pressure) is appraised and shifts the emotional state, which decays back toward a baseline over ~5 minutes. The emotional state modulates agent behavior across all layers: system prompt behavioral hints, voice narration tone, and decision-making style:
522
523
 
523
524
  | Quadrant | Valence | Arousal | Behavioral Effect |
524
525
  |----------|---------|---------|-------------------|
@@ -853,19 +854,31 @@ The TUI features an animated multilingual phrase carousel, live metrics bar with
853
854
 
854
855
  All settings commands accept `--local` to save to project `.oa/settings.json` instead of global config.
855
856
 
856
- ### Mid-Task Steering
857
+ ### Mid-Task Steering (Sub-Agent Architecture)
857
858
 
858
- While the agent is working (shown by the `+` prompt), type to add context:
859
+ While the agent is working (shown by the `+` prompt), type to add context. A **dedicated steering sub-agent** spins up in the background to process your input:
860
+
861
+ 1. **Immediate acknowledgment** — the steering agent speaks a brief response via TTS (e.g., "Got it, I'll adjust the approach")
862
+ 2. **Context expansion** — your terse input is expanded into a structured steering instruction grounded in the current task goal and recent agent activity
863
+ 3. **Non-blocking injection** — the expanded instruction is injected into the main agent's context at the next turn boundary, without interrupting the current tool call
859
864
 
860
865
  ```
861
866
  > fix the auth bug
862
867
  ⎿ Read: src/auth.ts
863
868
  + also check the session handling ← typed while agent works
864
- Context added: also check the session handling
869
+ 🔊 "Got it, adjusting to include session handling"
870
+ ↪ USER STEERING: Check session handling in addition to auth...
865
871
  ⎿ Search: session
866
872
  ⎿ Edit: src/auth.ts
867
873
  ```
868
874
 
875
+ The steering sub-agent uses the same model and backend as the main agent with `maxTurns: 3` and `maxTokens: 512` for fast response. If the steering agent fails, the raw input is injected as a fallback.
876
+
877
+ **Research foundations:**
878
+ - **ReAct** (Yao et al., 2023) — interleaved reasoning + acting benefits from external course corrections grounded in current state
879
+ - **LATS** (Zhou et al., 2024) — mid-execution replanning with user-provided value signals improves task completion on complex multi-step problems
880
+ - **AutoGen** (Wu et al., 2023) — human-in-the-loop patterns work best when user messages are expanded into structured instructions, reducing ambiguity for the primary agent
881
+
869
882
  ## Tools (47)
870
883
 
871
884
  | Tool | Description |
@@ -1051,6 +1064,34 @@ When `/voice` is enabled and the Telegram bridge is active:
1051
1064
 
1052
1065
  Cloudflared is automatically installed at startup alongside other dependencies (moondream, tesseract, transcribe-cli). The install is non-blocking and runs in the background.
1053
1066
 
1067
+ ### Call Sub-Agent Architecture
1068
+
1069
+ Each WebSocket caller in a live voice session gets a **dedicated AgenticRunner** — a fully independent agent instance that handles the voice-to-text-to-LLM-to-TTS-to-reply pipeline with minimal latency.
1070
+
1071
+ **Access tiers** — callers connect at one of two privilege levels:
1072
+
1073
+ | Tier | URL | Tool Access | Max Turns |
1074
+ |------|-----|-------------|-----------|
1075
+ | **Admin** | `wss://…?key=<session-key>` | Full tool set (12 tools: file read/write/edit, shell, grep, glob, list directory, web search/fetch, memory read/write/search) | 15 |
1076
+ | **Public** | `wss://…` (no key) | Read-only tools (6 tools: file read, grep, glob, list directory, memory read/search) | 5 |
1077
+
1078
+ The **session key** is a `crypto.randomBytes(16)` hex string generated per TUI session and displayed in the terminal when the voice session starts. Passing it as the `?key=` URL parameter on the WebSocket connection upgrades the caller to admin access.
1079
+
1080
+ **ActivityFeed** — the main TUI agent and all call sub-agents share a bidirectional ring buffer (max 100 entries). Tool calls and results from call sub-agents surface in the main terminal waterfall, and the main agent's activity is visible to connected callers. Each entry carries timestamp, source (main/call), sourceId, tool name, success status, and a summary. Admin callers see verbose timestamped activity; public callers see surface-level summaries.
1081
+
1082
+ **Per-client lifecycle** — on WebSocket connect, a `CallSubAgent` is instantiated with its own `AgenticRunner`, `OllamaAgenticBackend`, and conversation history. Transcripts are queued FIFO if the agent is mid-response, ensuring nothing is dropped. On disconnect, the sub-agent is disposed and removed from the active client map.
1083
+
1084
+ ### Content-Aware Voice Narration
1085
+
1086
+ The stochastic narration engine generates spoken descriptions of what the agent is doing for TTS output. Instead of preset phrases, it uses:
1087
+
1088
+ - **Variant pools** — 6-10 phrasings per tool per personality tier (terse/conversational/chatty), selected randomly with no back-to-back repeats
1089
+ - **Context modifiers** — tracks session state (consecutive errors, file revisits, progress beats) to add natural transitions like "Third time's the charm" or "Coming back to"
1090
+ - **Content digests** — extracts key details from actual tool result content (ETH balances, test results, error messages, wallet addresses, status tags, version numbers) and weaves them into the spoken narration. Instead of "Got it", the agent says "Got it — 2.5 ETH, address 0x9fe7F838..." or "That worked, 42 tests passed"
1091
+ - **Cross-tool context** — the digest from a tool result optionally carries forward into the next tool call description, so the agent can say "Checking that file, following up on 2.5 ETH" instead of repeating a generic opener
1092
+ - **Personality scaling** — terse mode (level 1-2) uses short functional descriptions; conversational (3) adds natural phrasing; chatty (4-5) adds theatrical commentary and content references
1093
+ - **Natural silence** — on bland successes without notable content, ~40% of the time the narration is skipped entirely for a more natural rhythm
1094
+
1054
1095
  ## Personality Core — SAC Framework Style Control
1055
1096
 
1056
1097
  The personality system controls how the agent communicates — from silent operator to teacher mode. It's based on the **SAC framework** (arXiv:2506.20993) which models personality along five behavioral intensity dimensions rather than binary trait toggles.
package/dist/index.d.ts CHANGED
@@ -1,59 +1,6 @@
1
- #!/usr/bin/env node
2
- /**
3
- * index.ts Main CLI entry point for @open-agents/cli
4
- *
5
- * Routes CLI arguments to the appropriate command handler.
6
- *
7
- * Commands:
8
- * open-agents "task" implicit run
9
- * open-agents run "task" explicit run
10
- * open-agents index /path/to/repo index a repository
11
- * open-agents status show system status
12
- * open-agents config show config
13
- * open-agents config set KEY VALUE set config key
14
- * open-agents serve start vLLM server
15
- * open-agents eval run eval suite
16
- * open-agents --help help
17
- * open-agents --version version
18
- */
19
- import type { BackendType } from "./config.js";
20
- export type CommandName = "run" | "index" | "status" | "config" | "serve" | "eval" | "unknown";
21
- export interface ParsedCliArgs {
22
- command: CommandName;
23
- /** Task text for the run command */
24
- task?: string;
25
- /** Repository path (for run and index commands) */
26
- repoPath?: string;
27
- /** Config sub-command (e.g. "set", "keys") */
28
- configSubCommand?: string;
29
- /** Config key (for config set) */
30
- configKey?: string;
31
- /** Config value (for config set) */
32
- configValue?: string;
33
- /** Eval suite name */
34
- evalSuite?: string;
35
- /** vLLM server port for serve command */
36
- servePort?: number;
37
- model?: string;
38
- backendUrl?: string;
39
- backendType?: BackendType;
40
- dryRun?: boolean;
41
- verbose?: boolean;
42
- maxRetries?: number;
43
- timeoutMs?: number;
44
- offline?: boolean;
45
- /** When true, config set writes to .oa/settings.json (project-local) */
46
- local?: boolean;
47
- help?: boolean;
48
- version?: boolean;
49
- }
50
- export declare function routeCommand(command: string): CommandName;
51
- export declare function parseCliArgs(argv: string[]): ParsedCliArgs;
52
- export { createCli } from "./cli.js";
53
- export { parseArgs } from "./args.js";
54
- export type { CliOptions } from "./types.js";
55
- export { loadConfig, mergeConfig, setConfigValue, DEFAULT_CONFIG } from "./config.js";
56
- export type { AgentConfig, BackendType } from "./config.js";
57
- export { Spinner } from "./ui/spinner.js";
58
- export { printHeader, printSuccess, printError, printWarning, printInfo, printSection, printKeyValue, printBlank, printReport, formatDuration, } from "./ui/output.js";
59
- //# sourceMappingURL=index.d.ts.map
1
+ export { parseCliArgs, routeCommand } from "./types.js";
2
+ export type { ParsedCliArgs, CommandName } from "./types.js";
3
+ export { loadConfig, mergeConfig, setConfigValue, DEFAULT_CONFIG } from "./types.js";
4
+ export type { AgentConfig, BackendType } from "./types.js";
5
+ export { Spinner } from "./types.js";
6
+ export { printHeader, printSuccess, printError, printWarning, printInfo, printSection, printKeyValue, printBlank, printReport, formatDuration } from "./types.js";