ohbaby-cli 0.1.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.
- package/LICENSE +21 -0
- package/README.md +69 -0
- package/dist/bin.d.ts +19 -0
- package/dist/bin.d.ts.map +1 -0
- package/dist/bin.js +5705 -0
- package/dist/bin.js.map +1 -0
- package/dist/cli/commands/run.d.ts +8 -0
- package/dist/cli/commands/run.d.ts.map +1 -0
- package/dist/cli/commands/serve.d.ts +13 -0
- package/dist/cli/commands/serve.d.ts.map +1 -0
- package/dist/cli/commands/terminal.d.ts +13 -0
- package/dist/cli/commands/terminal.d.ts.map +1 -0
- package/dist/cli/commands/types.d.ts +64 -0
- package/dist/cli/commands/types.d.ts.map +1 -0
- package/dist/cli/exit-codes.d.ts +7 -0
- package/dist/cli/exit-codes.d.ts.map +1 -0
- package/dist/cli/stdin.d.ts +3 -0
- package/dist/cli/stdin.d.ts.map +1 -0
- package/dist/cli/stdout-renderer.d.ts +10 -0
- package/dist/cli/stdout-renderer.d.ts.map +1 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +5215 -0
- package/dist/index.js.map +1 -0
- package/dist/package-version.d.ts +2 -0
- package/dist/package-version.d.ts.map +1 -0
- package/dist/tui/app.d.ts +10 -0
- package/dist/tui/app.d.ts.map +1 -0
- package/dist/tui/components/dialog/command-panel-manager.d.ts +14 -0
- package/dist/tui/components/dialog/command-panel-manager.d.ts.map +1 -0
- package/dist/tui/components/dialog/command-panel-state.d.ts +25 -0
- package/dist/tui/components/dialog/command-panel-state.d.ts.map +1 -0
- package/dist/tui/components/dialog/connect-panel.d.ts +9 -0
- package/dist/tui/components/dialog/connect-panel.d.ts.map +1 -0
- package/dist/tui/components/dialog/overlay-card.d.ts +7 -0
- package/dist/tui/components/dialog/overlay-card.d.ts.map +1 -0
- package/dist/tui/components/header.d.ts +6 -0
- package/dist/tui/components/header.d.ts.map +1 -0
- package/dist/tui/components/logo.d.ts +3 -0
- package/dist/tui/components/logo.d.ts.map +1 -0
- package/dist/tui/components/message/message-list.d.ts +10 -0
- package/dist/tui/components/message/message-list.d.ts.map +1 -0
- package/dist/tui/components/message/message-row.d.ts +50 -0
- package/dist/tui/components/message/message-row.d.ts.map +1 -0
- package/dist/tui/components/message/notice-banner.d.ts +9 -0
- package/dist/tui/components/message/notice-banner.d.ts.map +1 -0
- package/dist/tui/components/message/parts/tool-part.d.ts +10 -0
- package/dist/tui/components/message/parts/tool-part.d.ts.map +1 -0
- package/dist/tui/components/prompt/completion.d.ts +9 -0
- package/dist/tui/components/prompt/completion.d.ts.map +1 -0
- package/dist/tui/components/prompt/editor-reducer.d.ts +46 -0
- package/dist/tui/components/prompt/editor-reducer.d.ts.map +1 -0
- package/dist/tui/components/prompt/index.d.ts +21 -0
- package/dist/tui/components/prompt/index.d.ts.map +1 -0
- package/dist/tui/components/shimmer-text.d.ts +28 -0
- package/dist/tui/components/shimmer-text.d.ts.map +1 -0
- package/dist/tui/components/spinner.d.ts +8 -0
- package/dist/tui/components/spinner.d.ts.map +1 -0
- package/dist/tui/components/transcript/command-notice-lane.d.ts +6 -0
- package/dist/tui/components/transcript/command-notice-lane.d.ts.map +1 -0
- package/dist/tui/components/transcript/committed-transcript.d.ts +13 -0
- package/dist/tui/components/transcript/committed-transcript.d.ts.map +1 -0
- package/dist/tui/components/transcript/live-tail-window.d.ts +14 -0
- package/dist/tui/components/transcript/live-tail-window.d.ts.map +1 -0
- package/dist/tui/components/transcript/live-tail.d.ts +6 -0
- package/dist/tui/components/transcript/live-tail.d.ts.map +1 -0
- package/dist/tui/components/transcript/notice-lane.d.ts +6 -0
- package/dist/tui/components/transcript/notice-lane.d.ts.map +1 -0
- package/dist/tui/components/transcript/transcript-viewport.d.ts +13 -0
- package/dist/tui/components/transcript/transcript-viewport.d.ts.map +1 -0
- package/dist/tui/components/working-phrases.d.ts +13 -0
- package/dist/tui/components/working-phrases.d.ts.map +1 -0
- package/dist/tui/components/working-spinner.d.ts +12 -0
- package/dist/tui/components/working-spinner.d.ts.map +1 -0
- package/dist/tui/dialogs/confirm.d.ts +9 -0
- package/dist/tui/dialogs/confirm.d.ts.map +1 -0
- package/dist/tui/dialogs/manager.d.ts +10 -0
- package/dist/tui/dialogs/manager.d.ts.map +1 -0
- package/dist/tui/dialogs/model-dialog.d.ts +9 -0
- package/dist/tui/dialogs/model-dialog.d.ts.map +1 -0
- package/dist/tui/dialogs/permission-dialog.d.ts +8 -0
- package/dist/tui/dialogs/permission-dialog.d.ts.map +1 -0
- package/dist/tui/dialogs/select-one.d.ts +10 -0
- package/dist/tui/dialogs/select-one.d.ts.map +1 -0
- package/dist/tui/dialogs/session-dialog.d.ts +10 -0
- package/dist/tui/dialogs/session-dialog.d.ts.map +1 -0
- package/dist/tui/index.d.ts +6 -0
- package/dist/tui/index.d.ts.map +1 -0
- package/dist/tui/layout/app-shell.d.ts +6 -0
- package/dist/tui/layout/app-shell.d.ts.map +1 -0
- package/dist/tui/layout/context.d.ts +9 -0
- package/dist/tui/layout/context.d.ts.map +1 -0
- package/dist/tui/layout/metrics.d.ts +13 -0
- package/dist/tui/layout/metrics.d.ts.map +1 -0
- package/dist/tui/render/highlight.d.ts +2 -0
- package/dist/tui/render/highlight.d.ts.map +1 -0
- package/dist/tui/render/logo.d.ts +5 -0
- package/dist/tui/render/logo.d.ts.map +1 -0
- package/dist/tui/render/markdown.d.ts +5 -0
- package/dist/tui/render/markdown.d.ts.map +1 -0
- package/dist/tui/render/status-panel.d.ts +2 -0
- package/dist/tui/render/status-panel.d.ts.map +1 -0
- package/dist/tui/render/usage.d.ts +3 -0
- package/dist/tui/render/usage.d.ts.map +1 -0
- package/dist/tui/render/wrap.d.ts +4 -0
- package/dist/tui/render/wrap.d.ts.map +1 -0
- package/dist/tui/slash-commands/completions.d.ts +7 -0
- package/dist/tui/slash-commands/completions.d.ts.map +1 -0
- package/dist/tui/slash-commands/hints.d.ts +5 -0
- package/dist/tui/slash-commands/hints.d.ts.map +1 -0
- package/dist/tui/slash-commands/runtime.d.ts +23 -0
- package/dist/tui/slash-commands/runtime.d.ts.map +1 -0
- package/dist/tui/store/events.d.ts +7 -0
- package/dist/tui/store/events.d.ts.map +1 -0
- package/dist/tui/store/selectors/transcript.d.ts +19 -0
- package/dist/tui/store/selectors/transcript.d.ts.map +1 -0
- package/dist/tui/store/selectors.d.ts +9 -0
- package/dist/tui/store/selectors.d.ts.map +1 -0
- package/dist/tui/store/snapshot.d.ts +82 -0
- package/dist/tui/store/snapshot.d.ts.map +1 -0
- package/dist/tui/store/stream-coalescer.d.ts +10 -0
- package/dist/tui/store/stream-coalescer.d.ts.map +1 -0
- package/dist/tui/store/transcript.d.ts +43 -0
- package/dist/tui/store/transcript.d.ts.map +1 -0
- package/dist/tui/theme/colors.d.ts +55 -0
- package/dist/tui/theme/colors.d.ts.map +1 -0
- package/dist/tui/theme/detect.d.ts +12 -0
- package/dist/tui/theme/detect.d.ts.map +1 -0
- package/dist/tui/theme/index.d.ts +14 -0
- package/dist/tui/theme/index.d.ts.map +1 -0
- package/dist/tui/theme/tokens.d.ts +61 -0
- package/dist/tui/theme/tokens.d.ts.map +1 -0
- package/package.json +55 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 ohbaby-agent contributors
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
ADDED
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
<p align="center">
|
|
2
|
+
<img src="https://raw.githubusercontent.com/diverHansun/ohbaby-agent/main/assets/images/logo.png" alt="ohbaby-agent" width="150">
|
|
3
|
+
</p>
|
|
4
|
+
|
|
5
|
+
<p align="center">The MVP CLI/TUI package for ohbaby-agent.</p>
|
|
6
|
+
|
|
7
|
+
<p align="center">
|
|
8
|
+
<a href="https://github.com/diverHansun/ohbaby-agent/actions/workflows/ci.yml"><img alt="CI" src="https://img.shields.io/github/actions/workflow/status/diverHansun/ohbaby-agent/ci.yml?style=flat-square&label=CI&logo=github"></a>
|
|
9
|
+
<a href="https://www.npmjs.com/package/ohbaby-cli"><img alt="npm" src="https://img.shields.io/npm/v/ohbaby-cli?style=flat-square&color=cb3837&logo=npm"></a>
|
|
10
|
+
<a href="https://github.com/diverHansun/ohbaby-agent/blob/main/LICENSE"><img alt="license" src="https://img.shields.io/badge/license-MIT-blue?style=flat-square"></a>
|
|
11
|
+
<img alt="node" src="https://img.shields.io/node/v/ohbaby-cli?style=flat-square&color=339933&logo=node.js">
|
|
12
|
+
</p>
|
|
13
|
+
|
|
14
|
+
<p align="center">
|
|
15
|
+
<img src="https://raw.githubusercontent.com/diverHansun/ohbaby-agent/main/assets/images/dashboard.png" alt="ohbaby-agent CLI/TUI" width="760">
|
|
16
|
+
</p>
|
|
17
|
+
|
|
18
|
+
---
|
|
19
|
+
|
|
20
|
+
**ohbaby-agent** is a provider-agnostic AI coding agent. This package provides its
|
|
21
|
+
current MVP interface: a fast [Ink](https://github.com/vadimdemedes/ink)-based CLI/TUI
|
|
22
|
+
installed from npm as `ohbaby-cli` and launched with the `ohbaby` command. The same
|
|
23
|
+
runtime can support future web or app interfaces.
|
|
24
|
+
|
|
25
|
+
## Installation
|
|
26
|
+
|
|
27
|
+
Requires **Node.js >= 24**.
|
|
28
|
+
|
|
29
|
+
```bash
|
|
30
|
+
npm install -g ohbaby-cli
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
This installs the `ohbaby` command globally.
|
|
34
|
+
|
|
35
|
+
## Quick Start
|
|
36
|
+
|
|
37
|
+
1. Launch the ohbaby-agent CLI/TUI:
|
|
38
|
+
|
|
39
|
+
```bash
|
|
40
|
+
ohbaby
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
2. Type `/connect` in the CLI/TUI to configure your model provider (provider, base URL,
|
|
44
|
+
API key, model name), then save.
|
|
45
|
+
|
|
46
|
+
<p align="center">
|
|
47
|
+
<img src="https://raw.githubusercontent.com/diverHansun/ohbaby-agent/main/assets/images/connect-providers.png" alt="ohbaby-agent /connect provider setup" width="760">
|
|
48
|
+
</p>
|
|
49
|
+
|
|
50
|
+
3. Start coding.
|
|
51
|
+
|
|
52
|
+
Supports OpenAI, Anthropic/Claude, and any OpenAI-compatible endpoint (Zhipu/GLM,
|
|
53
|
+
DeepSeek, Qwen/DashScope, …).
|
|
54
|
+
|
|
55
|
+
**Web search (optional):** get a free [Tavily](https://tavily.com) API key and add
|
|
56
|
+
`TAVILY_API_KEY=tvly-...` to `~/.ohbaby-agent/.env` or your project's `.env`.
|
|
57
|
+
|
|
58
|
+
**MCP & Skills:** configure MCP servers globally or per project under `.ohbaby-agent/mcp/`.
|
|
59
|
+
Skills are discovered from ohbaby-agent-compatible skill directories and exposed as slash commands.
|
|
60
|
+
|
|
61
|
+
## Documentation
|
|
62
|
+
|
|
63
|
+
Full docs, configuration, and source: **https://github.com/diverHansun/ohbaby-agent**
|
|
64
|
+
([English](https://github.com/diverHansun/ohbaby-agent/blob/main/README.md) ·
|
|
65
|
+
[简体中文](https://github.com/diverHansun/ohbaby-agent/blob/main/README.zh.md))
|
|
66
|
+
|
|
67
|
+
## License
|
|
68
|
+
|
|
69
|
+
[MIT](https://github.com/diverHansun/ohbaby-agent/blob/main/LICENSE)
|
package/dist/bin.d.ts
ADDED
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import type { Readable } from "node:stream";
|
|
3
|
+
import type { CliCommandRuntime, CliCoreHostResult, CliGlobalOptions, CliWritable } from "./cli/commands/types.js";
|
|
4
|
+
export interface RunOhbabyCliIo {
|
|
5
|
+
readonly stderr?: CliWritable;
|
|
6
|
+
readonly stdin?: Readable & {
|
|
7
|
+
readonly isTTY?: boolean;
|
|
8
|
+
};
|
|
9
|
+
readonly stdout?: CliWritable;
|
|
10
|
+
}
|
|
11
|
+
export interface RunOhbabyCliDependencies {
|
|
12
|
+
readonly createCoreHost?: (options: CliGlobalOptions) => CliCoreHostResult;
|
|
13
|
+
readonly loadRuntimeEnvIntoProcessEnv?: () => Promise<void> | void;
|
|
14
|
+
readonly readDaemonStatus?: CliCommandRuntime["readDaemonStatus"];
|
|
15
|
+
readonly startDaemonServer?: CliCommandRuntime["startDaemonServer"];
|
|
16
|
+
readonly stopDaemonFromState?: CliCommandRuntime["stopDaemonFromState"];
|
|
17
|
+
}
|
|
18
|
+
export declare function runOhbabyCli(argv?: readonly string[], io?: RunOhbabyCliIo, dependencies?: RunOhbabyCliDependencies): Promise<number>;
|
|
19
|
+
//# sourceMappingURL=bin.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"bin.d.ts","sourceRoot":"","sources":["../src/bin.ts"],"names":[],"mappings":";AACA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAS5C,OAAO,KAAK,EACV,iBAAiB,EAEjB,iBAAiB,EACjB,gBAAgB,EAChB,WAAW,EACZ,MAAM,yBAAyB,CAAC;AAiBjC,MAAM,WAAW,cAAc;IAC7B,QAAQ,CAAC,MAAM,CAAC,EAAE,WAAW,CAAC;IAC9B,QAAQ,CAAC,KAAK,CAAC,EAAE,QAAQ,GAAG;QAAE,QAAQ,CAAC,KAAK,CAAC,EAAE,OAAO,CAAA;KAAE,CAAC;IACzD,QAAQ,CAAC,MAAM,CAAC,EAAE,WAAW,CAAC;CAC/B;AAED,MAAM,WAAW,wBAAwB;IACvC,QAAQ,CAAC,cAAc,CAAC,EAAE,CAAC,OAAO,EAAE,gBAAgB,KAAK,iBAAiB,CAAC;IAC3E,QAAQ,CAAC,4BAA4B,CAAC,EAAE,MAAM,OAAO,CAAC,IAAI,CAAC,GAAG,IAAI,CAAC;IACnE,QAAQ,CAAC,gBAAgB,CAAC,EAAE,iBAAiB,CAAC,kBAAkB,CAAC,CAAC;IAClE,QAAQ,CAAC,iBAAiB,CAAC,EAAE,iBAAiB,CAAC,mBAAmB,CAAC,CAAC;IACpE,QAAQ,CAAC,mBAAmB,CAAC,EAAE,iBAAiB,CAAC,qBAAqB,CAAC,CAAC;CACzE;AA8FD,wBAAsB,YAAY,CAChC,IAAI,GAAE,SAAS,MAAM,EAAiB,EACtC,EAAE,GAAE,cAAmB,EACvB,YAAY,GAAE,wBAA6B,GAC1C,OAAO,CAAC,MAAM,CAAC,CA2GjB"}
|