bobo-ai-cli 3.0.3 → 3.0.5

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 (238) hide show
  1. package/LICENSE +21 -21
  2. package/README.md +259 -259
  3. package/bundled-skills/CORE_SKILLS.txt +18 -18
  4. package/bundled-skills/backend-expert/SKILL.md +97 -97
  5. package/bundled-skills/code-review/SKILL.md +280 -280
  6. package/bundled-skills/code-review-expert/SKILL.md +85 -85
  7. package/bundled-skills/context-budget-analyzer/SKILL.md +76 -76
  8. package/bundled-skills/context-compressor/SKILL.md +75 -75
  9. package/bundled-skills/context-optimization-suite/SKILL.md +162 -162
  10. package/bundled-skills/frontend-expert/SKILL.md +93 -93
  11. package/bundled-skills/github/SKILL.md +12 -12
  12. package/bundled-skills/high-agency/SKILL.md +473 -473
  13. package/bundled-skills/high-agency/references/builder-patterns.md +126 -126
  14. package/bundled-skills/high-agency/references/recovery-playbook.md +298 -298
  15. package/bundled-skills/memory-manager/SKILL.md +214 -214
  16. package/bundled-skills/memory-manager/references/advanced-config.md +65 -65
  17. package/bundled-skills/orchestrator/SKILL.md +681 -681
  18. package/bundled-skills/planning-with-files/SKILL.md +193 -193
  19. package/bundled-skills/skill-creator/SKILL.md +220 -220
  20. package/bundled-skills/testing-expert/SKILL.md +99 -99
  21. package/bundled-skills/verify/SKILL.md +15 -15
  22. package/dist/agent.d.ts +5 -0
  23. package/dist/agent.js +11 -1
  24. package/dist/agent.js.map +1 -1
  25. package/dist/agents/catalog.d.ts +47 -0
  26. package/dist/agents/catalog.js +63 -5
  27. package/dist/agents/catalog.js.map +1 -1
  28. package/dist/agents/router.d.ts +12 -1
  29. package/dist/agents/router.js +43 -3
  30. package/dist/agents/router.js.map +1 -1
  31. package/dist/agents/spawn.js +36 -18
  32. package/dist/agents/spawn.js.map +1 -1
  33. package/dist/autonomous.js +5 -5
  34. package/dist/cli.js +23 -21
  35. package/dist/cli.js.map +1 -1
  36. package/dist/compactor.js +39 -39
  37. package/dist/dream.js +29 -29
  38. package/dist/image-input.d.ts +44 -0
  39. package/dist/image-input.js +161 -0
  40. package/dist/image-input.js.map +1 -0
  41. package/dist/memory.js +13 -13
  42. package/dist/project.js +15 -15
  43. package/dist/repl.js +88 -0
  44. package/dist/repl.js.map +1 -1
  45. package/dist/skills.js +54 -54
  46. package/dist/sub-agents.js +65 -65
  47. package/dist/tools/browser.js +21 -21
  48. package/dist/tools/claude-code.js +10 -10
  49. package/dist/web.js +7 -7
  50. package/dist/wiki-commands.d.ts +2 -0
  51. package/dist/wiki-commands.js +249 -0
  52. package/dist/wiki-commands.js.map +1 -0
  53. package/dist/wiki.d.ts +90 -0
  54. package/dist/wiki.js +614 -0
  55. package/dist/wiki.js.map +1 -0
  56. package/knowledge/advanced-patterns.md +70 -70
  57. package/knowledge/agent-directives.md +74 -74
  58. package/knowledge/api-integration-patterns.md +102 -0
  59. package/knowledge/code-review-protocol.md +69 -0
  60. package/knowledge/dream.md +36 -36
  61. package/knowledge/engineering.md +52 -46
  62. package/knowledge/error-catalog.md +38 -33
  63. package/knowledge/event-driven-architecture.md +43 -0
  64. package/knowledge/external-alignment.md +47 -0
  65. package/knowledge/high-agency.md +73 -0
  66. package/knowledge/image-generation.md +48 -0
  67. package/knowledge/index.json +194 -169
  68. package/knowledge/llm-wiki-pattern.md +71 -0
  69. package/knowledge/long-task-management.md +79 -0
  70. package/knowledge/memory/cache-optimization-and-skill-integration.md +102 -102
  71. package/knowledge/memory/engineering-patterns.md +134 -134
  72. package/knowledge/memory/feedback_root_structure.md +15 -15
  73. package/knowledge/memory/project-contexts.md +69 -69
  74. package/knowledge/memory/tools-and-services.md +85 -85
  75. package/knowledge/memory-management.md +72 -0
  76. package/knowledge/rules/advisor-strategy.md +204 -0
  77. package/knowledge/rules/agents.md +62 -62
  78. package/knowledge/rules/blocking-rules.md +323 -323
  79. package/knowledge/rules/cache-management.md +379 -379
  80. package/knowledge/rules/capability-evolution.md +132 -132
  81. package/knowledge/rules/coding.md +126 -126
  82. package/knowledge/rules/engineering-workflows.md +225 -225
  83. package/knowledge/rules/evomap-content-guidelines.md +354 -354
  84. package/knowledge/rules/evomap-guide.md +224 -224
  85. package/knowledge/rules/external-alignment.md +22 -0
  86. package/knowledge/rules/git.md +31 -31
  87. package/knowledge/rules/hooks.md +106 -106
  88. package/knowledge/rules/performance.md +101 -101
  89. package/knowledge/rules/remotion-auto-production.md +1120 -1120
  90. package/knowledge/rules/security.md +46 -46
  91. package/knowledge/rules/testing.md +32 -32
  92. package/knowledge/rules/work-mode.md +208 -208
  93. package/knowledge/rules.md +62 -62
  94. package/knowledge/self-evolution.md +78 -0
  95. package/knowledge/self-rationalization-guard.md +52 -0
  96. package/knowledge/skills/Skill_Seekers.md +1722 -1722
  97. package/knowledge/skills/ab-test-setup.md +557 -557
  98. package/knowledge/skills/agent-sdk-dev.md +238 -238
  99. package/knowledge/skills/agent-tools.md +136 -136
  100. package/knowledge/skills/analytics-tracking.md +597 -597
  101. package/knowledge/skills/artifacts-builder.md +89 -89
  102. package/knowledge/skills/asana.md +12 -12
  103. package/knowledge/skills/backend-expert.md +97 -97
  104. package/knowledge/skills/brand-voice.md +481 -481
  105. package/knowledge/skills/browser-use.md +419 -419
  106. package/knowledge/skills/cache-optimization-skill.md +179 -179
  107. package/knowledge/skills/canvas-design.md +147 -147
  108. package/knowledge/skills/citation-validator.md +203 -203
  109. package/knowledge/skills/clangd-lsp.md +52 -52
  110. package/knowledge/skills/code-review-expert.md +85 -85
  111. package/knowledge/skills/code-review.md +280 -280
  112. package/knowledge/skills/code-simplifier.md +12 -12
  113. package/knowledge/skills/commit-commands.md +258 -258
  114. package/knowledge/skills/competitor-alternatives.md +795 -795
  115. package/knowledge/skills/content-atomizer.md +910 -910
  116. package/knowledge/skills/content-research-writer.md +605 -605
  117. package/knowledge/skills/context-optimization-suite.md +162 -162
  118. package/knowledge/skills/context7.md +12 -12
  119. package/knowledge/skills/copy-editing.md +494 -494
  120. package/knowledge/skills/copywriting.md +510 -510
  121. package/knowledge/skills/csharp-lsp.md +40 -40
  122. package/knowledge/skills/decision-making-framework.md +154 -154
  123. package/knowledge/skills/developer-growth-analysis.md +335 -335
  124. package/knowledge/skills/direct-response-copy.md +2336 -2336
  125. package/knowledge/skills/docker-expert.md +229 -229
  126. package/knowledge/skills/document-skills.md +12 -12
  127. package/knowledge/skills/documentation-expert.md +126 -126
  128. package/knowledge/skills/email-sequence.md +1061 -1061
  129. package/knowledge/skills/email-sequences.md +910 -910
  130. package/knowledge/skills/example-plugin.md +72 -72
  131. package/knowledge/skills/explanatory-output-style.md +82 -82
  132. package/knowledge/skills/feature-dev.md +458 -458
  133. package/knowledge/skills/file-organizer.md +466 -466
  134. package/knowledge/skills/firebase.disabled.md +12 -12
  135. package/knowledge/skills/form-cro.md +488 -488
  136. package/knowledge/skills/free-tool-strategy.md +636 -636
  137. package/knowledge/skills/frontend-design-offical.md +55 -55
  138. package/knowledge/skills/frontend-design.md +41 -41
  139. package/knowledge/skills/frontend-expert.md +93 -93
  140. package/knowledge/skills/github.md +12 -12
  141. package/knowledge/skills/gitlab.md +12 -12
  142. package/knowledge/skills/gopls-lsp.md +32 -32
  143. package/knowledge/skills/got-controller.md +218 -218
  144. package/knowledge/skills/greptile.md +72 -72
  145. package/knowledge/skills/hookify.md +376 -376
  146. package/knowledge/skills/image-editor.md +189 -189
  147. package/knowledge/skills/image-enhancer.md +109 -109
  148. package/knowledge/skills/jdtls-lsp.md +49 -49
  149. package/knowledge/skills/json-canvas.md +654 -654
  150. package/knowledge/skills/keyword-research.md +559 -559
  151. package/knowledge/skills/kotlin-lsp.md +28 -28
  152. package/knowledge/skills/laravel-boost.md +12 -12
  153. package/knowledge/skills/launch-strategy.md +394 -394
  154. package/knowledge/skills/lead-magnet.md +393 -393
  155. package/knowledge/skills/learning-output-style.md +106 -106
  156. package/knowledge/skills/linear.md +12 -12
  157. package/knowledge/skills/lua-lsp.md +47 -47
  158. package/knowledge/skills/marketing-ideas.md +720 -720
  159. package/knowledge/skills/marketing-psychology.md +534 -534
  160. package/knowledge/skills/mcp-builder.md +369 -369
  161. package/knowledge/skills/meeting-insights-analyzer.md +347 -347
  162. package/knowledge/skills/memory-evolution-system.md +172 -172
  163. package/knowledge/skills/multi-lens-thinking.md +407 -407
  164. package/knowledge/skills/nano-banana-pro.md +116 -116
  165. package/knowledge/skills/newsletter.md +736 -736
  166. package/knowledge/skills/notebooklm.md +296 -296
  167. package/knowledge/skills/obsidian-bases.md +634 -634
  168. package/knowledge/skills/obsidian-markdown.md +651 -651
  169. package/knowledge/skills/onboarding-cro.md +494 -494
  170. package/knowledge/skills/orchestrator.md +681 -681
  171. package/knowledge/skills/page-cro.md +379 -379
  172. package/knowledge/skills/paid-ads.md +624 -624
  173. package/knowledge/skills/paywall-upgrade-cro.md +651 -651
  174. package/knowledge/skills/php-lsp.md +36 -36
  175. package/knowledge/skills/planning-with-files.md +193 -193
  176. package/knowledge/skills/playwright.md +12 -12
  177. package/knowledge/skills/plugin-dev.md +434 -434
  178. package/knowledge/skills/popup-cro.md +520 -520
  179. package/knowledge/skills/positioning-angles.md +330 -330
  180. package/knowledge/skills/pr-review-toolkit.md +359 -359
  181. package/knowledge/skills/pricing-strategy.md +777 -777
  182. package/knowledge/skills/programmatic-seo.md +714 -714
  183. package/knowledge/skills/pyright-lsp.md +43 -43
  184. package/knowledge/skills/quality-assurance-framework.md +168 -168
  185. package/knowledge/skills/question-refiner.md +160 -160
  186. package/knowledge/skills/ralph-loop.md +205 -205
  187. package/knowledge/skills/refactoring-expert.md +103 -103
  188. package/knowledge/skills/referral-program.md +668 -668
  189. package/knowledge/skills/research-executor.md +164 -164
  190. package/knowledge/skills/review-with-security.md +12 -12
  191. package/knowledge/skills/rust-analyzer-lsp.md +50 -50
  192. package/knowledge/skills/schema-markup.md +647 -647
  193. package/knowledge/skills/security-audit-expert.md +124 -124
  194. package/knowledge/skills/security-expert.md +140 -140
  195. package/knowledge/skills/security-guidance.md +12 -12
  196. package/knowledge/skills/seedance-prompt.md +139 -139
  197. package/knowledge/skills/self-evolution.md +1160 -1160
  198. package/knowledge/skills/seo-audit.md +432 -432
  199. package/knowledge/skills/seo-content.md +787 -787
  200. package/knowledge/skills/serena.md +12 -12
  201. package/knowledge/skills/signup-flow-cro.md +409 -409
  202. package/knowledge/skills/skill-creator.md +220 -220
  203. package/knowledge/skills/skill-manager.md +226 -226
  204. package/knowledge/skills/skill-share.md +98 -98
  205. package/knowledge/skills/slack.md +12 -12
  206. package/knowledge/skills/social-content.md +878 -878
  207. package/knowledge/skills/spec-flow-skill.md +124 -124
  208. package/knowledge/skills/stripe.md +12 -12
  209. package/knowledge/skills/supabase.md +12 -12
  210. package/knowledge/skills/swift-lsp.md +40 -40
  211. package/knowledge/skills/synthesizer.md +236 -236
  212. package/knowledge/skills/template-skill.md +16 -16
  213. package/knowledge/skills/testing-expert.md +99 -99
  214. package/knowledge/skills/theme-factory.md +72 -72
  215. package/knowledge/skills/tiktok-research.md +208 -208
  216. package/knowledge/skills/typescript-lsp.md +36 -36
  217. package/knowledge/skills/ui-ux-pro-max.md +247 -247
  218. package/knowledge/skills/verify.md +15 -15
  219. package/knowledge/skills/visual-prompt-engineer.md +102 -102
  220. package/knowledge/skills/webapp-testing.md +111 -111
  221. package/knowledge/skills/wide-research.md +191 -191
  222. package/knowledge/system.md +93 -93
  223. package/knowledge/task-router.md +46 -37
  224. package/knowledge/verification.md +38 -38
  225. package/knowledge/worker-prompt-craft.md +66 -0
  226. package/knowledge/workflows/3d-viz.md +47 -47
  227. package/knowledge/workflows/data-pipeline.md +47 -47
  228. package/knowledge/workflows/db-migration.md +51 -51
  229. package/knowledge/workflows/feature-dev.md +41 -41
  230. package/knowledge/workflows/tdd-flow.md +52 -52
  231. package/knowledge/workflows/ui-verify.md +51 -51
  232. package/package.json +74 -74
  233. package/dist/claude-bridge.d.ts +0 -18
  234. package/dist/claude-bridge.js +0 -91
  235. package/dist/claude-bridge.js.map +0 -1
  236. package/dist/tools/claude-bridge-tool.d.ts +0 -4
  237. package/dist/tools/claude-bridge-tool.js +0 -44
  238. package/dist/tools/claude-bridge-tool.js.map +0 -1
package/LICENSE CHANGED
@@ -1,21 +1,21 @@
1
- MIT License
2
-
3
- Copyright (c) 2026 Bobo Zhou
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.
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Bobo Zhou
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 CHANGED
@@ -1,259 +1,259 @@
1
- <div align="center">
2
-
3
- # 🐕 Bobo CLI
4
-
5
- **Portable AI Engineering Assistant**
6
-
7
- [![npm version](https://img.shields.io/npm/v/bobo-cli.svg)](https://www.npmjs.com/package/bobo-cli)
8
- [![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](LICENSE)
9
-
10
- An AI-powered CLI assistant with embedded engineering knowledge, a pluggable skill system, persistent memory, and project-aware context — designed to be your pair-programming partner in the terminal.
11
-
12
- ![Bobo CLI 介绍](assets/bobo-cli-intro.png)
13
-
14
- </div>
15
-
16
- ---
17
-
18
- ## Quick Start
19
-
20
- ```bash
21
- # Install
22
- npm install -g bobo-ai-cli
23
-
24
- # Initialize
25
- bobo init
26
- bobo config set apiKey sk-your-anthropic-key
27
-
28
- # Start interactive REPL
29
- bobo
30
-
31
- # Or run a one-shot prompt
32
- bobo "explain this codebase"
33
- ```
34
-
35
- ## Features
36
-
37
- ### ⚡ Claude Code Architecture (v2.1.0)
38
- Bobo CLI v2.1.0 implements advanced AI agent patterns inspired by Claude Code:
39
-
40
- - **🔍 Verification Agent** — 'Try to break it' philosophy with adversarial testing (build/test/lint + boundary probing)
41
- - **🎭 Role-Based Sub-Agents** — Explore (read-only), Plan (strategy), Worker (execution), Verify (validation)
42
- - **🗜️ Three-Tier Compression** — Microcompact (tool result clearing) → Auto-compact (87% threshold + circuit breaker) → Full compact (LLM summary)
43
- - **🛡️ Tool Governance Pipeline** — Input validation → Risk classification → Permission checks → Execution hooks → Telemetry
44
- - **💾 Cache Boundary Optimization** — STATIC/DYNAMIC prompt separation for provider caching (Anthropic prompt caching compatible)
45
- - **🌙 KAIROS Dream Mode** — Automated memory consolidation (reads logs → LLM distillation → structured insights)
46
-
47
- ### 🧠 Knowledge System
48
- 9 built-in knowledge files that shape the assistant's behavior and engineering methodology:
49
-
50
- | File | Type | Description |
51
- |------|------|-------------|
52
- | `system.md` | always | Core identity, work mode, and personality |
53
- | `rules.md` | always | Coding standards, honest reporting, git workflow |
54
- | `agent-directives.md` | always | 10 mechanical override rules (edit safety, context decay, phased execution) |
55
- | `engineering.md` | on-demand | Task routing, search strategies, three-file pattern |
56
- | `error-catalog.md` | on-demand | Top 10 high-frequency error patterns with quick fixes |
57
- | `verification.md` | on-demand | Adversarial verification protocol |
58
- | `task-router.md` | on-demand | Task classification and strategy selection |
59
- | `dream.md` | on-demand | Memory consolidation protocol |
60
- | `advanced-patterns.md` | on-demand | Memory taxonomy, compact protocol, sub-agent architecture |
61
-
62
- On-demand files are loaded automatically when the user's message matches trigger keywords.
63
-
64
- ### 🧩 Skill System
65
- 47 skills (2 built-in + 45 importable) covering coding, research, verification, context management, self-improvement, and domain-specific tools:
66
-
67
- ```bash
68
- bobo skill list # List all skills
69
- bobo skill enable semrush # Enable a skill
70
- bobo skill disable coding # Disable a skill
71
- bobo skill import ~/skills/ # Batch import from directory
72
- ```
73
-
74
- **Core skills (enabled by default):**
75
- - `coding` — Code standards, zero-comment principle, review checklist
76
- - `research` — Search strategies, information synthesis
77
- - `adversarial-verification` — Break-it-don't-confirm-it validation
78
- - `context-compressor` — Nine-section context compression
79
- - `context-budget-analyzer` — Token usage analysis
80
- - `proactive-self-improving` — Automatic experience capture and evolution
81
- - `high-agency` — Sustained motivation and ownership mindset
82
- - `memory-manager` — Structured long-term memory management
83
- - `deep-research` — Multi-model deep research with citations
84
-
85
- ### 🔧 Tool System
86
- 18 tools available to the AI assistant:
87
-
88
- | Category | Tools |
89
- |----------|-------|
90
- | **File** | `read_file`, `write_file`, `edit_file`, `search_files`, `list_directory` |
91
- | **Shell** | `shell` |
92
- | **Memory** | `save_memory`, `search_memory` |
93
- | **Git** | `git_status`, `git_diff`, `git_log`, `git_commit`, `git_push` |
94
- | **Planner** | `create_plan`, `update_plan`, `show_plan` |
95
- | **Web** | `web_search`, `web_fetch` |
96
-
97
- ### 💾 Memory System
98
- Persistent memory across sessions with structured categories:
99
-
100
- - **user** — Preferences and habits
101
- - **feedback** — Corrections and confirmations
102
- - **project** — Active tasks and goals
103
- - **reference** — External knowledge not in code
104
- - **experience** — Lessons learned
105
-
106
- Memory is stored in `~/.bobo/memory.md` with a 5KB auto-slim cap and daily logs in `~/.bobo/memory/`.
107
-
108
- ### 📁 Project Awareness
109
- Drop a `.bobo/` directory in any project to provide project-specific context:
110
-
111
- ```bash
112
- cd my-project
113
- bobo project init # Creates .bobo/project.json
114
- ```
115
-
116
- Bobo automatically detects and loads `AGENTS.md`, `CLAUDE.md`, and `CONVENTIONS.md` from the project root.
117
-
118
- ## Architecture
119
-
120
- ```
121
- bobo CLI v2.1.0 — Claude Code-inspired Agent Architecture
122
-
123
- ├── System Prompt Assembly (STATIC/DYNAMIC separation)
124
- │ STATIC (cacheable):
125
- │ ① Knowledge (3 always-load + 6 on-demand)
126
- │ ② Skills (active skill prompts)
127
- │ ③ BOBO.md project instructions
128
- │ ━━━━━━━━ DYNAMIC BOUNDARY ━━━━━━━━
129
- │ DYNAMIC (session-specific):
130
- │ ④ Memory (persistent user/project/feedback data)
131
- │ ⑤ Project context (.bobo/ + auto-detected files)
132
- │ ⑥ Environment (CWD + turn count + decay warnings)
133
-
134
- ├── Agent Loop (with governance)
135
- │ ├── Streaming responses with tool calls
136
- │ ├── Tool Governance Pipeline:
137
- │ │ Input validation → Risk classification → PreToolUse Hook →
138
- │ │ Permission check → Execution → PostToolUse Hook → Telemetry
139
- │ ├── Three-tier compression:
140
- │ │ 60%: Microcompact (clear old tool results)
141
- │ │ 87%: Auto-compact (with circuit breaker)
142
- │ │ 95%: Full compact (LLM summary)
143
- │ └── Max 20 iterations per turn
144
-
145
- ├── Sub-Agent System (role-based)
146
- │ ├── explore — Read-only exploration
147
- │ ├── plan — Strategy without execution
148
- │ ├── worker — Full tools + anti-recursion
149
- │ └── verify — Adversarial validation
150
-
151
- ├── Verification Agent
152
- │ ├── Build/Test/Lint enforcement
153
- │ ├── Adversarial probing (boundary tests, API calls)
154
- │ └── Verdict: PASS / FAIL / PARTIAL
155
-
156
- ├── KAIROS Dream Mode
157
- │ ├── Auto-trigger: 50+ entries or 24h since last dream
158
- │ ├── LLM distillation: Logs → Insights (confidence-scored)
159
- │ └── Memory consolidation: Dedupe + category organization
160
-
161
- ├── Structured Knowledge (advanced)
162
- │ ├── knowledge/rules/ — 15+ domain rule files
163
- │ ├── knowledge/skills/ — 140+ structured skill files
164
- │ ├── knowledge/workflows/ — 6 workflow templates
165
- │ └── knowledge/memory/ — Extracted patterns
166
-
167
- └── CLI Commands
168
- ├── bobo [prompt] — One-shot or REPL mode
169
- ├── bobo config — Configuration management
170
- ├── bobo init — Initialize ~/.bobo/
171
- ├── bobo knowledge — View knowledge base
172
- ├── bobo skill — Skill management
173
- ├── bobo spawn <task> — Background sub-agent (with role)
174
- ├── bobo agents — Manage sub-agents
175
- ├── bobo kb — Structured knowledge search
176
- ├── bobo rules — Browse engineering rules
177
- ├── bobo skills — Structured skill browser
178
- ├── bobo template — Project scaffolding
179
- └── bobo project — Project configuration
180
- ```
181
-
182
- ## REPL Commands
183
-
184
- | Command | Description |
185
- |---------|-------------|
186
- | `/help` | Show available commands |
187
- | `/status` | Session status (model, turns, CWD) |
188
- | `/knowledge` | List loaded knowledge files |
189
- | `/skills` | List active skills |
190
- | `/plan` | Show current task plan |
191
- | `/compact` | Compress context (nine-section summary) |
192
- | `/dream` | 🌙 KAIROS memory consolidation (LLM-powered insight extraction) |
193
- | `/verify [task]` | 🔍 Run verification agent with adversarial testing |
194
- | `/spawn <task>` | Spawn background sub-agent (with role support) |
195
- | `/agents` | List all sub-agents and their status |
196
- | `/clear` | Clear conversation history |
197
- | `/history` | Show turn count |
198
- | `/quit` | Exit |
199
-
200
- ## Configuration
201
-
202
- ```bash
203
- bobo config set apiKey sk-your-key # API key (required)
204
- bobo config set model gpt-4o # Model name
205
- bobo config set baseUrl https://... # API base URL
206
- bobo config set maxTokens 8192 # Max response tokens
207
- bobo config list # Show all config
208
- ```
209
-
210
- Configuration is stored in `~/.bobo/config.json`. The API key is masked in `config list` output.
211
-
212
- ### Supported Providers
213
-
214
- Bobo CLI uses the OpenAI-compatible API format. It works with:
215
- - **Anthropic** (default) — `baseUrl: https://api.anthropic.com/v1`
216
- - **OpenAI** — `baseUrl: https://api.openai.com/v1`
217
- - **Azure OpenAI** — Set your Azure endpoint as `baseUrl`
218
- - **Any OpenAI-compatible API** — Ollama, Together, Groq, etc.
219
-
220
- ## Knowledge Customization
221
-
222
- ### Adding custom knowledge
223
- Place `.md` files in `~/.bobo/knowledge/` — they'll be loaded as custom context:
224
-
225
- ```bash
226
- echo "# My Team Standards\n\nAlways use TypeScript strict mode." > ~/.bobo/knowledge/team.md
227
- ```
228
-
229
- ### Importing skills from OpenClaw
230
- If you use [OpenClaw](https://github.com/openclaw/openclaw), you can import its skills directly:
231
-
232
- ```bash
233
- bobo skill import ~/.openclaw/workspace/skills/
234
- ```
235
-
236
- ## Contributing
237
-
238
- Contributions are welcome! Please:
239
-
240
- 1. Fork the repo
241
- 2. Create a feature branch (`git checkout -b feat/my-feature`)
242
- 3. Run tests (`npm test`)
243
- 4. Ensure the build passes (`npm run build`)
244
- 5. Submit a PR
245
-
246
- ### Development
247
-
248
- ```bash
249
- git clone https://github.com/Arxchibobo/bobo-cli.git
250
- cd bobo-cli
251
- npm install
252
- npm run dev # Run with tsx (hot reload)
253
- npm run build # Compile TypeScript
254
- npm test # Run tests
255
- ```
256
-
257
- ## License
258
-
259
- MIT — see [LICENSE](LICENSE) for details.
1
+ <div align="center">
2
+
3
+ # 🐕 Bobo CLI
4
+
5
+ **Portable AI Engineering Assistant**
6
+
7
+ [![npm version](https://img.shields.io/npm/v/bobo-cli.svg)](https://www.npmjs.com/package/bobo-cli)
8
+ [![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](LICENSE)
9
+
10
+ An AI-powered CLI assistant with embedded engineering knowledge, a pluggable skill system, persistent memory, and project-aware context — designed to be your pair-programming partner in the terminal.
11
+
12
+ ![Bobo CLI 介绍](assets/bobo-cli-intro.png)
13
+
14
+ </div>
15
+
16
+ ---
17
+
18
+ ## Quick Start
19
+
20
+ ```bash
21
+ # Install
22
+ npm install -g bobo-ai-cli
23
+
24
+ # Initialize
25
+ bobo init
26
+ bobo config set apiKey sk-your-anthropic-key
27
+
28
+ # Start interactive REPL
29
+ bobo
30
+
31
+ # Or run a one-shot prompt
32
+ bobo "explain this codebase"
33
+ ```
34
+
35
+ ## Features
36
+
37
+ ### ⚡ Claude Code Architecture (v2.1.0)
38
+ Bobo CLI v2.1.0 implements advanced AI agent patterns inspired by Claude Code:
39
+
40
+ - **🔍 Verification Agent** — 'Try to break it' philosophy with adversarial testing (build/test/lint + boundary probing)
41
+ - **🎭 Role-Based Sub-Agents** — Explore (read-only), Plan (strategy), Worker (execution), Verify (validation)
42
+ - **🗜️ Three-Tier Compression** — Microcompact (tool result clearing) → Auto-compact (87% threshold + circuit breaker) → Full compact (LLM summary)
43
+ - **🛡️ Tool Governance Pipeline** — Input validation → Risk classification → Permission checks → Execution hooks → Telemetry
44
+ - **💾 Cache Boundary Optimization** — STATIC/DYNAMIC prompt separation for provider caching (Anthropic prompt caching compatible)
45
+ - **🌙 KAIROS Dream Mode** — Automated memory consolidation (reads logs → LLM distillation → structured insights)
46
+
47
+ ### 🧠 Knowledge System
48
+ 9 built-in knowledge files that shape the assistant's behavior and engineering methodology:
49
+
50
+ | File | Type | Description |
51
+ |------|------|-------------|
52
+ | `system.md` | always | Core identity, work mode, and personality |
53
+ | `rules.md` | always | Coding standards, honest reporting, git workflow |
54
+ | `agent-directives.md` | always | 10 mechanical override rules (edit safety, context decay, phased execution) |
55
+ | `engineering.md` | on-demand | Task routing, search strategies, three-file pattern |
56
+ | `error-catalog.md` | on-demand | Top 10 high-frequency error patterns with quick fixes |
57
+ | `verification.md` | on-demand | Adversarial verification protocol |
58
+ | `task-router.md` | on-demand | Task classification and strategy selection |
59
+ | `dream.md` | on-demand | Memory consolidation protocol |
60
+ | `advanced-patterns.md` | on-demand | Memory taxonomy, compact protocol, sub-agent architecture |
61
+
62
+ On-demand files are loaded automatically when the user's message matches trigger keywords.
63
+
64
+ ### 🧩 Skill System
65
+ 47 skills (2 built-in + 45 importable) covering coding, research, verification, context management, self-improvement, and domain-specific tools:
66
+
67
+ ```bash
68
+ bobo skill list # List all skills
69
+ bobo skill enable semrush # Enable a skill
70
+ bobo skill disable coding # Disable a skill
71
+ bobo skill import ~/skills/ # Batch import from directory
72
+ ```
73
+
74
+ **Core skills (enabled by default):**
75
+ - `coding` — Code standards, zero-comment principle, review checklist
76
+ - `research` — Search strategies, information synthesis
77
+ - `adversarial-verification` — Break-it-don't-confirm-it validation
78
+ - `context-compressor` — Nine-section context compression
79
+ - `context-budget-analyzer` — Token usage analysis
80
+ - `proactive-self-improving` — Automatic experience capture and evolution
81
+ - `high-agency` — Sustained motivation and ownership mindset
82
+ - `memory-manager` — Structured long-term memory management
83
+ - `deep-research` — Multi-model deep research with citations
84
+
85
+ ### 🔧 Tool System
86
+ 18 tools available to the AI assistant:
87
+
88
+ | Category | Tools |
89
+ |----------|-------|
90
+ | **File** | `read_file`, `write_file`, `edit_file`, `search_files`, `list_directory` |
91
+ | **Shell** | `shell` |
92
+ | **Memory** | `save_memory`, `search_memory` |
93
+ | **Git** | `git_status`, `git_diff`, `git_log`, `git_commit`, `git_push` |
94
+ | **Planner** | `create_plan`, `update_plan`, `show_plan` |
95
+ | **Web** | `web_search`, `web_fetch` |
96
+
97
+ ### 💾 Memory System
98
+ Persistent memory across sessions with structured categories:
99
+
100
+ - **user** — Preferences and habits
101
+ - **feedback** — Corrections and confirmations
102
+ - **project** — Active tasks and goals
103
+ - **reference** — External knowledge not in code
104
+ - **experience** — Lessons learned
105
+
106
+ Memory is stored in `~/.bobo/memory.md` with a 5KB auto-slim cap and daily logs in `~/.bobo/memory/`.
107
+
108
+ ### 📁 Project Awareness
109
+ Drop a `.bobo/` directory in any project to provide project-specific context:
110
+
111
+ ```bash
112
+ cd my-project
113
+ bobo project init # Creates .bobo/project.json
114
+ ```
115
+
116
+ Bobo automatically detects and loads `AGENTS.md`, `CLAUDE.md`, and `CONVENTIONS.md` from the project root.
117
+
118
+ ## Architecture
119
+
120
+ ```
121
+ bobo CLI v2.1.0 — Claude Code-inspired Agent Architecture
122
+
123
+ ├── System Prompt Assembly (STATIC/DYNAMIC separation)
124
+ │ STATIC (cacheable):
125
+ │ ① Knowledge (3 always-load + 6 on-demand)
126
+ │ ② Skills (active skill prompts)
127
+ │ ③ BOBO.md project instructions
128
+ │ ━━━━━━━━ DYNAMIC BOUNDARY ━━━━━━━━
129
+ │ DYNAMIC (session-specific):
130
+ │ ④ Memory (persistent user/project/feedback data)
131
+ │ ⑤ Project context (.bobo/ + auto-detected files)
132
+ │ ⑥ Environment (CWD + turn count + decay warnings)
133
+
134
+ ├── Agent Loop (with governance)
135
+ │ ├── Streaming responses with tool calls
136
+ │ ├── Tool Governance Pipeline:
137
+ │ │ Input validation → Risk classification → PreToolUse Hook →
138
+ │ │ Permission check → Execution → PostToolUse Hook → Telemetry
139
+ │ ├── Three-tier compression:
140
+ │ │ 60%: Microcompact (clear old tool results)
141
+ │ │ 87%: Auto-compact (with circuit breaker)
142
+ │ │ 95%: Full compact (LLM summary)
143
+ │ └── Max 20 iterations per turn
144
+
145
+ ├── Sub-Agent System (role-based)
146
+ │ ├── explore — Read-only exploration
147
+ │ ├── plan — Strategy without execution
148
+ │ ├── worker — Full tools + anti-recursion
149
+ │ └── verify — Adversarial validation
150
+
151
+ ├── Verification Agent
152
+ │ ├── Build/Test/Lint enforcement
153
+ │ ├── Adversarial probing (boundary tests, API calls)
154
+ │ └── Verdict: PASS / FAIL / PARTIAL
155
+
156
+ ├── KAIROS Dream Mode
157
+ │ ├── Auto-trigger: 50+ entries or 24h since last dream
158
+ │ ├── LLM distillation: Logs → Insights (confidence-scored)
159
+ │ └── Memory consolidation: Dedupe + category organization
160
+
161
+ ├── Structured Knowledge (advanced)
162
+ │ ├── knowledge/rules/ — 15+ domain rule files
163
+ │ ├── knowledge/skills/ — 140+ structured skill files
164
+ │ ├── knowledge/workflows/ — 6 workflow templates
165
+ │ └── knowledge/memory/ — Extracted patterns
166
+
167
+ └── CLI Commands
168
+ ├── bobo [prompt] — One-shot or REPL mode
169
+ ├── bobo config — Configuration management
170
+ ├── bobo init — Initialize ~/.bobo/
171
+ ├── bobo knowledge — View knowledge base
172
+ ├── bobo skill — Skill management
173
+ ├── bobo spawn <task> — Background sub-agent (with role)
174
+ ├── bobo agents — Manage sub-agents
175
+ ├── bobo kb — Structured knowledge search
176
+ ├── bobo rules — Browse engineering rules
177
+ ├── bobo skills — Structured skill browser
178
+ ├── bobo template — Project scaffolding
179
+ └── bobo project — Project configuration
180
+ ```
181
+
182
+ ## REPL Commands
183
+
184
+ | Command | Description |
185
+ |---------|-------------|
186
+ | `/help` | Show available commands |
187
+ | `/status` | Session status (model, turns, CWD) |
188
+ | `/knowledge` | List loaded knowledge files |
189
+ | `/skills` | List active skills |
190
+ | `/plan` | Show current task plan |
191
+ | `/compact` | Compress context (nine-section summary) |
192
+ | `/dream` | 🌙 KAIROS memory consolidation (LLM-powered insight extraction) |
193
+ | `/verify [task]` | 🔍 Run verification agent with adversarial testing |
194
+ | `/spawn <task>` | Spawn background sub-agent (with role support) |
195
+ | `/agents` | List all sub-agents and their status |
196
+ | `/clear` | Clear conversation history |
197
+ | `/history` | Show turn count |
198
+ | `/quit` | Exit |
199
+
200
+ ## Configuration
201
+
202
+ ```bash
203
+ bobo config set apiKey sk-your-key # API key (required)
204
+ bobo config set model gpt-4o # Model name
205
+ bobo config set baseUrl https://... # API base URL
206
+ bobo config set maxTokens 8192 # Max response tokens
207
+ bobo config list # Show all config
208
+ ```
209
+
210
+ Configuration is stored in `~/.bobo/config.json`. The API key is masked in `config list` output.
211
+
212
+ ### Supported Providers
213
+
214
+ Bobo CLI uses the OpenAI-compatible API format. It works with:
215
+ - **Anthropic** (default) — `baseUrl: https://api.anthropic.com/v1`
216
+ - **OpenAI** — `baseUrl: https://api.openai.com/v1`
217
+ - **Azure OpenAI** — Set your Azure endpoint as `baseUrl`
218
+ - **Any OpenAI-compatible API** — Ollama, Together, Groq, etc.
219
+
220
+ ## Knowledge Customization
221
+
222
+ ### Adding custom knowledge
223
+ Place `.md` files in `~/.bobo/knowledge/` — they'll be loaded as custom context:
224
+
225
+ ```bash
226
+ echo "# My Team Standards\n\nAlways use TypeScript strict mode." > ~/.bobo/knowledge/team.md
227
+ ```
228
+
229
+ ### Importing skills from OpenClaw
230
+ If you use [OpenClaw](https://github.com/openclaw/openclaw), you can import its skills directly:
231
+
232
+ ```bash
233
+ bobo skill import ~/.openclaw/workspace/skills/
234
+ ```
235
+
236
+ ## Contributing
237
+
238
+ Contributions are welcome! Please:
239
+
240
+ 1. Fork the repo
241
+ 2. Create a feature branch (`git checkout -b feat/my-feature`)
242
+ 3. Run tests (`npm test`)
243
+ 4. Ensure the build passes (`npm run build`)
244
+ 5. Submit a PR
245
+
246
+ ### Development
247
+
248
+ ```bash
249
+ git clone https://github.com/Arxchibobo/bobo-cli.git
250
+ cd bobo-cli
251
+ npm install
252
+ npm run dev # Run with tsx (hot reload)
253
+ npm run build # Compile TypeScript
254
+ npm test # Run tests
255
+ ```
256
+
257
+ ## License
258
+
259
+ MIT — see [LICENSE](LICENSE) for details.
@@ -1,18 +1,18 @@
1
- # Core skills shipped with bobo-cli
2
- # Only these are included in the npm package to reduce bloat
3
-
4
- high-agency
5
- memory-manager
6
- context-budget-analyzer
7
- context-compressor
8
- context-optimization-suite
9
- code-review
10
- code-review-expert
11
- planning-with-files
12
- verify
13
- skill-creator
14
- github
15
- backend-expert
16
- frontend-expert
17
- testing-expert
18
- orchestrator
1
+ # Core skills shipped with bobo-cli
2
+ # Only these are included in the npm package to reduce bloat
3
+
4
+ high-agency
5
+ memory-manager
6
+ context-budget-analyzer
7
+ context-compressor
8
+ context-optimization-suite
9
+ code-review
10
+ code-review-expert
11
+ planning-with-files
12
+ verify
13
+ skill-creator
14
+ github
15
+ backend-expert
16
+ frontend-expert
17
+ testing-expert
18
+ orchestrator