@oyasmi/pipiclaw 0.9.5 → 0.9.6-beta.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.
Files changed (182) hide show
  1. package/README.en.md +220 -126
  2. package/README.md +217 -123
  3. package/dist/agent/channel-runner.d.ts +1 -1
  4. package/dist/agent/channel-runner.js +1 -1
  5. package/dist/agent/prompt/sections.js +1 -1
  6. package/dist/agent/prompt/types.d.ts +2 -1
  7. package/dist/agent/session/compaction.d.ts +2 -0
  8. package/dist/agent/session/compaction.js +22 -14
  9. package/dist/agent/session/session-host.d.ts +1 -1
  10. package/dist/agent/session/session-host.js +3 -1
  11. package/dist/agent/stop-watchdog.js +5 -1
  12. package/dist/agent/turn/turn-state.d.ts +2 -0
  13. package/dist/agent/turn/turn-state.js +2 -1
  14. package/dist/agent/types.d.ts +3 -1
  15. package/dist/channel/attachments.d.ts +4 -0
  16. package/dist/channel/attachments.js +4 -0
  17. package/dist/channel/store.d.ts +1 -1
  18. package/dist/commands/catalog.js +25 -9
  19. package/dist/commands/router.js +5 -1
  20. package/dist/desk/commands.d.ts +14 -2
  21. package/dist/desk/commands.js +68 -20
  22. package/dist/desk/registry.d.ts +6 -2
  23. package/dist/desk/registry.js +70 -4
  24. package/dist/desk/types.d.ts +17 -0
  25. package/dist/dingtalk/bot.d.ts +1 -1
  26. package/dist/dingtalk/bot.js +4 -3
  27. package/dist/dingtalk/delivery.js +13 -8
  28. package/dist/dingtalk/inbound-media.d.ts +36 -14
  29. package/dist/dingtalk/inbound-media.js +71 -12
  30. package/dist/dingtalk/inbound.d.ts +9 -2
  31. package/dist/dingtalk/inbound.js +18 -2
  32. package/dist/dingtalk/media.d.ts +4 -10
  33. package/dist/dingtalk/media.js +58 -32
  34. package/dist/events/commands.d.ts +2 -0
  35. package/dist/events/commands.js +13 -8
  36. package/dist/events/history.d.ts +9 -0
  37. package/dist/events/history.js +66 -0
  38. package/dist/events/parse.js +7 -3
  39. package/dist/events/types.d.ts +3 -0
  40. package/dist/events/watcher.d.ts +3 -7
  41. package/dist/events/watcher.js +51 -56
  42. package/dist/jobs/kill.d.ts +23 -0
  43. package/dist/jobs/kill.js +65 -0
  44. package/dist/jobs/manager.d.ts +19 -18
  45. package/dist/jobs/manager.js +36 -103
  46. package/dist/memory/reflect.js +23 -3
  47. package/dist/memory/session-corpus.d.ts +1 -1
  48. package/dist/memory/session-corpus.js +70 -1
  49. package/dist/memory/session-search.js +13 -11
  50. package/dist/memory/store.d.ts +2 -0
  51. package/dist/memory/store.js +19 -9
  52. package/dist/playbooks/agent-delegation.md +5 -4
  53. package/dist/playbooks/memory-and-learning.md +1 -1
  54. package/dist/playbooks/task-lead.md +4 -4
  55. package/dist/runtime/bootstrap.d.ts +6 -0
  56. package/dist/runtime/bootstrap.js +11 -7
  57. package/dist/runtime/desk-runtime.d.ts +8 -2
  58. package/dist/runtime/desk-runtime.js +35 -4
  59. package/dist/runtime/durable-dispatch.d.ts +14 -2
  60. package/dist/runtime/durable-dispatch.js +207 -65
  61. package/dist/runtime/ingress-busy.js +17 -8
  62. package/dist/runtime/ingress-deps.d.ts +4 -1
  63. package/dist/runtime/ingress.js +6 -1
  64. package/dist/runtime/request-execution.js +7 -6
  65. package/dist/runtime/shutdown.d.ts +1 -0
  66. package/dist/runtime/shutdown.js +87 -35
  67. package/dist/runtime/task-control.d.ts +1 -0
  68. package/dist/runtime/task-control.js +25 -2
  69. package/dist/runtime/task-lane.d.ts +1 -0
  70. package/dist/runtime/task-lane.js +21 -6
  71. package/dist/runtime/task-step.js +11 -2
  72. package/dist/runtime/turn-run.js +103 -66
  73. package/dist/security/command-guard.d.ts +1 -1
  74. package/dist/security/command-guard.js +237 -314
  75. package/dist/security/path-guard.js +48 -7
  76. package/dist/security/shell-parse.d.ts +10 -0
  77. package/dist/security/shell-parse.js +224 -0
  78. package/dist/security/types.d.ts +2 -0
  79. package/dist/subagents/commands.d.ts +1 -1
  80. package/dist/subagents/detached-discovery.d.ts +1 -1
  81. package/dist/subagents/discovery.d.ts +18 -199
  82. package/dist/subagents/discovery.js +35 -289
  83. package/dist/subagents/dispatch.d.ts +1 -2
  84. package/dist/subagents/dispatch.js +39 -20
  85. package/dist/subagents/external/antigravity-cli.d.ts +2 -0
  86. package/dist/subagents/external/antigravity-cli.js +517 -0
  87. package/dist/subagents/external/claude-code.js +8 -17
  88. package/dist/subagents/external/codex-cli.js +8 -18
  89. package/dist/subagents/external/cursor-cli.js +34 -31
  90. package/dist/subagents/external/dispatch.d.ts +21 -7
  91. package/dist/subagents/external/dispatch.js +139 -11
  92. package/dist/subagents/external/exec.js +3 -0
  93. package/dist/subagents/external/harness.d.ts +57 -33
  94. package/dist/subagents/external/harness.js +69 -40
  95. package/dist/subagents/external/reconciliation.js +1 -0
  96. package/dist/subagents/external/registry.js +4 -1
  97. package/dist/subagents/external/role-warnings.d.ts +4 -13
  98. package/dist/subagents/external/role-warnings.js +4 -28
  99. package/dist/subagents/external/run.d.ts +1 -2
  100. package/dist/subagents/external/run.js +11 -11
  101. package/dist/subagents/external/settlement.d.ts +2 -0
  102. package/dist/subagents/external/settlement.js +8 -2
  103. package/dist/subagents/format.d.ts +1 -1
  104. package/dist/subagents/format.js +1 -1
  105. package/dist/subagents/internal/outcome.d.ts +1 -2
  106. package/dist/subagents/internal/provider-retry.d.ts +1 -2
  107. package/dist/subagents/internal/provider-retry.js +1 -1
  108. package/dist/subagents/internal/run.d.ts +1 -2
  109. package/dist/subagents/internal/state.d.ts +1 -2
  110. package/dist/subagents/internal/worker.d.ts +1 -2
  111. package/dist/subagents/internal/worker.js +3 -1
  112. package/dist/subagents/resolve.d.ts +56 -0
  113. package/dist/subagents/resolve.js +202 -0
  114. package/dist/subagents/result.d.ts +1 -2
  115. package/dist/subagents/result.js +7 -3
  116. package/dist/subagents/run-record.d.ts +33 -2
  117. package/dist/subagents/run-record.js +2 -0
  118. package/dist/subagents/runs.d.ts +2 -24
  119. package/dist/subagents/runs.js +6 -0
  120. package/dist/subagents/task-envelope.d.ts +1 -2
  121. package/dist/subagents/task-envelope.js +8 -4
  122. package/dist/subagents/types.d.ts +93 -4
  123. package/dist/subagents/types.js +16 -1
  124. package/dist/subagents/workspace-lease.d.ts +11 -21
  125. package/dist/subagents/workspace-lease.js +48 -21
  126. package/dist/subagents/worktree.d.ts +10 -0
  127. package/dist/subagents/worktree.js +77 -0
  128. package/dist/tasks/archive.js +4 -0
  129. package/dist/tasks/commands.d.ts +3 -0
  130. package/dist/tasks/commands.js +16 -2
  131. package/dist/tasks/control.d.ts +2 -0
  132. package/dist/tasks/delivery.d.ts +2 -0
  133. package/dist/tasks/delivery.js +141 -21
  134. package/dist/tasks/loop-log.d.ts +2 -0
  135. package/dist/tasks/loop-log.js +9 -0
  136. package/dist/tools/bash.js +2 -0
  137. package/dist/tools/contract/presentation.js +3 -4
  138. package/dist/tools/event-manage.d.ts +2 -0
  139. package/dist/tools/event-manage.js +20 -2
  140. package/dist/tools/index.d.ts +2 -1
  141. package/dist/tools/index.js +2 -0
  142. package/dist/tools/registry.js +3 -1
  143. package/dist/tools/send-media.js +9 -5
  144. package/dist/tools/session-search.js +1 -1
  145. package/dist/tools/subagent-manage.d.ts +1 -1
  146. package/dist/tools/subagent-manage.js +15 -149
  147. package/dist/tools/subagent.d.ts +2 -0
  148. package/dist/tools/subagent.js +6 -1
  149. package/dist/tools/task-manage/factory.js +2 -2
  150. package/dist/tools/task-manage/lifecycle.d.ts +3 -3
  151. package/dist/tools/task-manage/lifecycle.js +49 -9
  152. package/dist/tools/task-manage/schema.d.ts +4 -1
  153. package/dist/tools/task-manage/schema.js +4 -1
  154. package/dist/tools/task-manage/types.d.ts +4 -1
  155. package/dist/tui/cli.d.ts +1 -6
  156. package/dist/tui/cli.js +29 -3
  157. package/dist/tui/client.d.ts +2 -0
  158. package/dist/tui/client.js +13 -4
  159. package/dist/usage/ledger.d.ts +1 -1
  160. package/dist/usage/render.js +1 -1
  161. package/examples/sub-agents/README.md +39 -73
  162. package/examples/sub-agents/agents/agy-main.md +23 -0
  163. package/examples/sub-agents/agents/claude-high.md +9 -9
  164. package/examples/sub-agents/agents/claude-main.md +9 -9
  165. package/examples/sub-agents/agents/codex-flash.md +9 -9
  166. package/examples/sub-agents/agents/codex-high.md +9 -9
  167. package/examples/sub-agents/agents/codex-main.md +9 -9
  168. package/examples/sub-agents/agents/codex-review.md +9 -9
  169. package/examples/sub-agents/agents/cursor-high.md +9 -9
  170. package/examples/sub-agents/agents/cursor-main.md +9 -9
  171. package/examples/sub-agents/agents/glm-flash.md +9 -9
  172. package/examples/sub-agents/agents/glm-high.md +9 -9
  173. package/package.json +8 -8
  174. package/examples/sub-agents/agents/scout.md +0 -30
  175. package/examples/sub-agents/roles/builder-hard.md +0 -34
  176. package/examples/sub-agents/roles/builder.md +0 -34
  177. package/examples/sub-agents/roles/explorer.md +0 -39
  178. package/examples/sub-agents/roles/git-committer.md +0 -43
  179. package/examples/sub-agents/roles/planner.md +0 -33
  180. package/examples/sub-agents/roles/reviewer.md +0 -33
  181. package/examples/sub-agents/roles/verifier.md +0 -35
  182. package/examples/sub-agents/roles/worker.md +0 -34
package/README.en.md CHANGED
@@ -1,113 +1,204 @@
1
1
  # Pipiclaw
2
2
 
3
- [简体中文](./README.md) | **English**
3
+ <p align="left">
4
+ <a href="./README.md">简体中文</a> | <strong>English</strong>
5
+ </p>
4
6
 
5
- **Turn DingTalk into an AI engineering entry point that keeps working.**
7
+ <p align="left">
8
+ <a href="https://www.npmjs.com/package/@oyasmi/pipiclaw"><img src="https://img.shields.io/npm/v/@oyasmi/pipiclaw?color=blue&label=npm" alt="npm version"></a>
9
+ <img src="https://img.shields.io/badge/node-%3E%3D22.19.0-brightgreen" alt="Node.js >= 22.19.0">
10
+ <img src="https://img.shields.io/badge/platform-Linux%20%7C%20macOS%20%7C%20WSL2-lightgrey" alt="Platform">
11
+ <a href="./LICENSE"><img src="https://img.shields.io/badge/license-AGPL--3.0-orange" alt="License: AGPL v3"></a>
12
+ </p>
6
13
 
7
- Pipiclaw is a DingTalk-first AI coding assistant runtime for individual developers. Assign a goal from DingTalk or the terminal, keep its working context, and let it progress in the background using your existing models, Claude Code, Codex CLI, or custom executors. Follow progress, add instructions, pause or cancel work, and retrieve the result with its verification evidence.
14
+ > **Turn DingTalk and your terminal into an always-on AI engineering workbench — assign a goal, close your laptop, and let it progress in the background across your models and coding agents, returning verified deliverables.**
8
15
 
9
- - npm: [`@oyasmi/pipiclaw`](https://www.npmjs.com/package/@oyasmi/pipiclaw)
10
- - Runtime: Node.js `>= 22.19.0`, Linux / macOS; on Windows use WSL2
11
- - License: [GNU AGPL v3](./LICENSE)
16
+ **Pipiclaw** is a DingTalk-first AI coding assistant runtime for individual developers. Assign a goal from DingTalk, the terminal, or your own scripts, keep its working context intact, and let it advance long-running work in the background while delegating to your existing models, **Claude Code**, **Codex CLI**, **Cursor CLI**, **Antigravity CLI**, or custom executors. Follow progress, steer mid-turn, pause or take over at any moment, and receive deliverables backed by verification evidence.
12
17
 
13
- ## Why Pipiclaw
18
+ **[Key Highlights](#key-highlights) · [How It Works](#how-it-works) · [Use Cases](#use-cases) · [Quick Start](#quick-start) · [Common Commands](#common-commands) · [Documentation](#documentation)**
14
19
 
15
- ### Use your existing executors as needed
20
+ ---
16
21
 
17
- Pipiclaw supports two kinds of delegation at once: built-in sub-agents do lightweight work in-process such as retrieval and log triage; external agents launch real Claude Code, Codex CLI, or any script to handle heavy tasks that need long runs, many files, and repeated self-testing.
22
+ ## Key Highlights
18
23
 
19
- In DingTalk daemon mode, external tasks keep running in the background after dispatch and automatically wake the channel that dispatched them on completion. You can use `/subagents` at any time to check run status, the actual command, and outputs, use `/subagents cancel` to terminate directly, and let the main agent keep asking follow-up questions on a finished Claude Code / Codex session. The repo ships recommended capability-and-cost entries plus earlier job-style role templates for reference.
24
+ ### 🚀 1. Work Keeps Moving When You Walk Away: Task Lane & Scheduled Events
20
25
 
21
- ### Work does not end when a conversation ends
26
+ Traditional CLI coding agents stop the moment you close the terminal or end a chat. Pipiclaw decouples long-horizon engineering work from ephemeral conversations:
22
27
 
23
- Pipiclaw is one personal assistant: by default the terminal, DingTalk DMs and group chats all share long-term memory, a daily journal, tasks, scheduled events and working files (kept in the default desk, `default`), while each keeps its own conversation — just start chatting. Sharing also means that something you tell the assistant in a DM may be recalled in a group; when you want to keep a project or purpose apart, use the advanced [desk mechanism](https://github.com/oyasmi/pipiclaw/blob/main/docs/scaling-and-concurrency.md#按需分开工位): each desk has its own memory, tasks and files. Each task is a one-off project with goals, done criteria, and work items in a Markdown contract, and steps, dispatches, and settlements in a JSONL task log; tasks run in a background task lane, independent of chat, and you can check progress, add instructions, pause or cancel them with `/tasks` at any time. Scheduled and recurring work uses event templates to create an independent task instance per occurrence. The runtime pauses a task with a notice when a budget, idle-loop, step-timeout or repeated-error boundary is reached.
28
+ - **Background Task Lane**: Multi-step, multi-hour projects advance in a dedicated background task lane **without blocking your chat**. Each task is backed by a human-readable Markdown **task spec** (goal, Definition of Done checklist, **work items**) and an append-only JSONL **task log** (steps, delegations, settlements). Task states are derived deterministically by the runtime from observed facts — never stuck in a hallucinated "waiting" state.
29
+ - **Scheduled Events & Zero-Token Sensors**: Trigger `one-shot` reminders or `periodic` (Cron) workflows. Run local `preAction` gate scripts as **zero-token conditional sensors**, or spawn fresh, isolated task instances from event templates (e.g., daily repo inspections or weekly release digests) with automatic overlap protection.
30
+ - **Deterministic Budgets & Circuit Breakers**: Built-in step and USD budgets, idle-loop detection, per-step timeouts, and consecutive-error guards pause runaway work automatically and notify you.
24
31
 
25
- ### Natively at home in DingTalk
32
+ ### 🤝 2. One Workflow Orchestrating All Your Top Coding Agents
26
33
 
27
- Pipiclaw uses DingTalk Stream Mode, so no self-hosted message relay or public IP is needed. AI Cards can continuously show thinking, tool execution, and status updates; while a task runs you can still use `/steer` to adjust direction, `/followup` to queue the next thing, and `/stop` to abort the current turn. Generated reports, screenshots, and exported files can be delivered as native DingTalk attachments.
34
+ Stop copy-pasting context across multiple terminal tabs. Pipiclaw lets your main assistant act as the lead, dispatching work to the right executor based on capability, cost, and execution boundaries:
28
35
 
29
- A single bot instance can serve many direct and group chats at once: every DM and every group is a channel, and model turns in different channels can progress in parallel; within one channel turns run serially so one conversation's context is not modified by multiple turns at once. Note that isolation between desks is not code-directory isolation; if several channels point at the same project directory, you should still avoid having the main agent edit the same set of files concurrently, or prepare separate Git worktrees for parallel implementation. See [Scaling and concurrency](https://github.com/oyasmi/pipiclaw/blob/main/docs/scaling-and-concurrency.md) for the full boundaries.
36
+ - **Built-in Sub-Agents (`internal`)**: Spin up isolated in-process agents in milliseconds under Pipiclaw's security guards for fast retrieval, log triage, and focused analysis.
37
+ - **Heavyweight External Harnesses (`external`)**: Launch real **Claude Code**, **Codex CLI**, **Cursor CLI**, **Antigravity CLI (`agy`)**, GLM wrapper scripts, or custom shell commands to tackle multi-file implementations, write and run tests, and iterate autonomously.
38
+ - **Async Wakeup, Session Continuation & Independent Verification**: External runs execute in the background (with records and managed artifacts retained for 30 days) and automatically wake the originating channel upon completion. You can ask follow-up questions on finished external sessions, or dispatch CLI-enforced read-only agents (such as `codex-review`) for independent verification (`purpose: verify`).
30
39
 
31
- ### Autonomous, and always interruptible
40
+ ### 💬 3. Native in DingTalk + Terminal TUI + OpenAI-Compatible Web API
32
41
 
33
- Scheduled events are good for reminders, periodic checks, and zero-token conditional sensors; the task ledger is good for long-running work that spans hours and sessions. Runtime status, model usage, tasks, memory, and delegation runs all have control commands that do not go through the LLM, so even when the model is unavailable or the current turn is stuck, you can still inspect and intervene.
42
+ - **Zero Public IP DingTalk Setup**: Built on **DingTalk Stream Mode** — connect directly from your laptop or private server without hosting webhook relays or exposing public ports.
43
+ - **Live AI Card Streaming**: Watch thinking steps, tool calls, and stage updates stream live in DingTalk AI Cards. Send a message mid-turn to adjust direction on the fly (`/steer`), queue the next request (`/followup`), or abort immediately (`/stop`). Deliver generated reports, screenshots, and exports as **native DingTalk attachments**.
44
+ - **One Assistant, Every Surface**: A single daemon serves multiple DMs and group chats concurrently (parallel across channels, serialized within each channel). The terminal UI (`pipiclaw tui`) and your own scripts connect to the exact same assistant over a local Unix socket or TCP **Web API** compatible with the official **OpenAI SDK (implemented Responses API subset)**.
34
45
 
35
- ### Your config, data, and way of working
46
+ ### 🧠 4. Remembers Conventions, Respects Boundaries: Layered Memory & Desks
36
47
 
37
- Models support built-in providers, OpenAI-compatible gateways, API keys, and subscription login. Memory, tasks, roles, events, and working rules are all stored in human-readable files on your machine. Pipiclaw provides command, path, and network guards plus an audit log; when you need stronger isolation, you can put the whole process in its own account or container.
48
+ - **Shared by Default, Isolated on Demand**: Your terminal, DingTalk DMs, and group chats bind to the `default` desk out of the box — sharing long-term memory, daily journals, tasks, and working files with zero setup. When you want to separate projects or contexts, create an isolated desk with `/desk new <name>`.
49
+ - **Three-Layer Transparent Memory (No Keyword Guessing)**:
50
+ - **Desk Memory (`memory/*.md`)**: One durable fact per file with an auto-generated `MEMORY.md` index injected in full at session start — the model sees all your conventions up front without fragile RAG keyword matching.
51
+ - **Daily Journal (`journal/YYYY-MM-DD.md`)**: Day-by-day working notes written by the background reflect pass, keeping temporary progress out of permanent rules.
52
+ - **Automatic Reflection & Probation**: Automatically consolidates memory before context compaction, on `/new`, on shutdown, or during idle windows. Newly inferred facts enter a 30-day **probation period** before promotion; `/memory forget` leaves a hash tombstone so background reflection never resurrects forgotten items. Idle checks pass through a local deterministic gate first — **burning zero tokens when idle**.
38
53
 
39
- ## What it's good for
54
+ ### 🛡️ 5. Autonomous Yet Instantly Interruptible: Deterministic Control Plane & Local Ownership
40
55
 
41
- - Providing an always-online dev assistant, internal tech support, or ops collaboration entry point in DingTalk
42
- - Delivering complete changes with code, tests, documentation, and appropriate checks, with independent review based on risk
43
- - Following up on coding, investigation, migration, reporting, and periodic work that spans hours or days
44
- - Keeping a separate conversation per group and direct chat, sharing one body of memory by default and splitting it with desks when needed
45
- - Reusing existing model gateways, Claude Code / Codex CLI accounts, and personal or project conventions
56
+ - **LLM-Free Control Plane**: `/help`, `/stop`, `/steer`, `/followup`, `/tasks`, `/subagents`, `/events`, `/desk`, `/status`, `/usage`, and `/context` are handled directly by the runtime. **Even if a model provider is down or a turn is stuck**, you can still inspect state, pause tasks, or kill external processes (`/subagents cancel`) immediately.
57
+ - **Your Config, Your Plain-Text Data**: Works with built-in providers, OpenAI-compatible gateways, API keys, and subscription logins (`pipiclaw auth login`). Every memory, task, role, event, and audit log lives as human-readable Markdown, JSON, or JSONL under `~/.pipiclaw/`, protected by command, path, and network guards.
46
58
 
47
- Pipiclaw targets individual developers and supports self-hosted, single-instance operation. It is not a hard multi-tenant SaaS, and it does not provide an OS-level sandbox; the real permissions an external agent holds are determined together by the target CLI's sandbox parameters, the run account, and the host environment.
59
+ ---
48
60
 
49
- ## Quick start
61
+ ## How It Works
50
62
 
51
- The steps below cover local verification, DingTalk setup, and external-agent configuration in order. If you already have a clear goal, jump straight to the relevant part.
63
+ ```mermaid
64
+ flowchart LR
65
+ subgraph Entries["Entry Surfaces (Channels)"]
66
+ DT["📱 DingTalk DM / Group<br/>(Stream Mode + AI Card)"]
67
+ TUI["💻 Terminal UI<br/>(pipiclaw tui)"]
68
+ API["🔌 Scripts & Clients<br/>(OpenAI SDK / Web API)"]
69
+ end
52
70
 
53
- ### 1. Install and confirm the CLI
71
+ subgraph Runtime["Pipiclaw Runtime (Daemon)"]
72
+ CP["⚡ Deterministic Control Plane<br/>(/stop /steer /tasks /subagents ...)"]
73
+ CR["🧭 Channel Runner & Session Host<br/>(Serial per channel · Parallel across channels)"]
74
+ TL["🛤️ Background Task Lane<br/>(Independent execution · Budget & timeout guards)"]
75
+ EV["⏰ Scheduled Events & Sensors<br/>(Cron / One-shot / preAction)"]
76
+ end
77
+
78
+ subgraph Desk["Desk Context (default / custom)"]
79
+ MEM["🧠 Layered Memory & Journal<br/>(memory/*.md · journal/)"]
80
+ TSK["📋 Task Specs & Logs<br/>(tasks/<id>.md · <id>.jsonl)"]
81
+ end
82
+
83
+ subgraph Executors["Executors & Guards"]
84
+ INT["🔍 Built-in Tools & Internal Sub-Agents<br/>(Command / Path / Network Guards)"]
85
+ EXT["🛠️ External Coding Agents<br/>Claude Code · Codex · Cursor · Antigravity"]
86
+ end
87
+
88
+ DT & TUI & API --> CP & CR
89
+ EV -->|Wake / Spawn task instance| CR & TL
90
+ CR <--> Desk
91
+ TL <--> Desk
92
+ CR & TL --> INT & EXT
93
+ ```
94
+
95
+ ### Core Concepts at a Glance
96
+
97
+ | Concept | What It Is | Problem It Solves |
98
+ |---|---|---|
99
+ | **Channel** | A DingTalk DM, DingTalk group, or Web API / TUI conversation | Keeps each conversation history separate while acting as your remote control to assign, inspect, and steer work |
100
+ | **Desk** | A named work context (`default` built-in, custom desks on demand) | Owns the long-term memory, daily journal, tasks, scheduled events, and working directory for a body of work |
101
+ | **Task** | A one-off project running in the background task lane (`.md` spec + `.jsonl` log) | Advances multi-step, multi-hour deliverables independently of chat and survives restarts |
102
+ | **Event** | A `one-shot` or `periodic` (Cron) trigger with optional `preAction` or task template | Answers *"when to wake up"* — driving reminders, zero-token checks, and recurring task instances |
103
+ | **Sub-Agent** | An in-process lightweight role (`internal`) or external CLI process (`external`) | Answers *"who executes this step"* — uniting your subscriptions and external coding CLIs under one workflow |
104
+
105
+ ---
106
+
107
+ ## Use Cases
108
+
109
+ - **📱 Mobile Engineering Workbench**: Assign *"migrate this module to the new interface and add unit tests"* from DingTalk on your commute; the background task breaks down work items, dispatches Claude Code / Codex to implement and run tests, runs an independent `codex-review` check on the diff, and delivers the summary with test evidence to your phone.
110
+ - **⏰ Low-Noise Scheduled Inspections & Reports**: Set up daily or weekly event templates that run a local `preAction` script first, spawning a background task to investigate and deliver a DingTalk report only when new commits or anomalies appear.
111
+ - **🔀 Multi-Model & Multi-Agent Compute Routing**: Use fast or cost-effective models for everyday chat, route tough architectural trade-offs and root-cause debugging to `claude-high` / `codex-high` / `cursor-high`, batch mechanical edits with `codex-flash` / `glm-flash`, and leverage `agy-main` for long-context collaboration.
112
+ - **🤝 Multi-Surface Personal & Small-Team Collaboration**: Keep separate conversations across DMs and group chats while sharing one body of project memory by default — or split contexts cleanly with desks when needed.
113
+ - **🔌 Scriptable Personal Assistant via Official OpenAI SDK**: Enable the Web API and connect CI hooks, local scripts, or custom frontends to your assistant in a few lines of Python or JS.
114
+
115
+ > [!NOTE]
116
+ > **Scope & Security Boundaries**: Pipiclaw is designed for individual developers (and small-scale shared use of a single assistant) in self-hosted, single-instance deployments. It is not a hard multi-tenant SaaS platform and does not provide an OS-level sandbox. **External agents bypass Pipiclaw's built-in command and path guards** — their real permissions are governed by the target CLI's sandbox flags, the host user account, and the operating environment.
117
+
118
+ ---
119
+
120
+ ## Quick Start
121
+
122
+ Follow the steps below to go from **installation → 30-second terminal verification → DingTalk connection → external coding agent delegation**. Jump straight to any section if you already know what you need.
123
+
124
+ <details>
125
+ <summary>💡 <b>Shortcut: Let your favorite local AI Agent (Claude Code / Codex / Cursor) install and configure Pipiclaw for you</b></summary>
126
+
127
+ Copy and paste the prompt below into your local AI coding agent:
128
+
129
+ ```text
130
+ Please install and initialize Pipiclaw for me:
131
+
132
+ 1. Check Node.js >= 22.19.0; stop and explain if it is not met.
133
+ 2. Run npm install -g @oyasmi/pipiclaw; on a permission failure do not sudo on your own.
134
+ 3. Run pipiclaw once to initialize ~/.pipiclaw/; it prompting you to complete channel.json and exiting because it is still a template is normal.
135
+ 4. Ask me whether I want to use an API key, a custom provider, or a subscription login supported by pipiclaw auth login; do not invent missing values.
136
+ 5. If I want to connect DingTalk, collect clientId, clientSecret, optional cardTemplateId, and allowFrom item by item, write them into the `dingtalk` section of channel.json, and remove all your-* placeholder values.
137
+ 6. When configuration is done, ask first whether to start. Terminal mode uses pipiclaw tui; DingTalk mode uses pipiclaw, and after it starts message the bot directly or @ it in a group — no desk needs to be created or bound.
138
+ 7. Honestly list the operations performed, files changed, verification results, and information still missing; do not pretend it succeeded.
139
+ ```
140
+
141
+ </details>
142
+
143
+ ### 1. Prerequisites & Installation
144
+
145
+ - **Node.js**: `>= 22.19.0`
146
+ - **OS**: Linux / macOS (on Windows, use WSL2)
54
147
 
55
148
  ```bash
56
149
  npm install -g @oyasmi/pipiclaw
57
150
  pipiclaw tui --help
58
151
  ```
59
152
 
60
- The first real start of `pipiclaw` or `pipiclaw tui` creates:
153
+ The first real launch of `pipiclaw` or `pipiclaw tui` scaffolds `~/.pipiclaw/` (set `PIPICLAW_HOME=/your/path` to relocate the entire directory):
61
154
 
62
155
  ```text
63
156
  ~/.pipiclaw/
64
- ├── channel.json # Channel switches: DingTalk app, Web API
65
- ├── auth.json # model credentials
66
- ├── models.json # custom model providers
67
- ├── settings.json # default model and runtime settings
68
- ├── tools.json # capability switches for web tools, tasks, etc.
69
- ├── security.json # command, path, and network guards
70
- └── workspace/ # shared config and extensions; the default desk's data is in desk-default/
157
+ ├── channel.json # Channel switches & config: DingTalk app (dingtalk), Web API (webapi)
158
+ ├── auth.json # Model credentials & login state
159
+ ├── models.json # Custom model providers & gateways
160
+ ├── settings.json # Default model & runtime settings
161
+ ├── tools.json # Capability switches for web search/fetch, tasks, etc.
162
+ ├── security.json # Command, path, and network guard policies
163
+ └── workspace/ # Shared rules (AGENTS.md / SOUL.md), skills/, sub-agents/, and desk-default/
71
164
  ```
72
165
 
73
- Set `PIPICLAW_HOME=/your/path` to relocate this directory as a whole.
166
+ ### 2. Fastest Taste: Run in the Terminal in 30 Seconds
74
167
 
75
- ### 2. Fastest taste: get it working in the terminal first
76
-
77
- Terminal mode needs no DingTalk credentials, only a working model. Pick either way:
168
+ Terminal mode requires no DingTalk credentials — just a working model. Configure credentials using either option:
78
169
 
79
170
  ```bash
80
- # Option A: use an API key
171
+ # Option A: Provide an API key via environment variable
81
172
  export ANTHROPIC_API_KEY=sk-ant-...
82
173
 
83
- # Option B: log in to a subscription provider supported by the SDK
174
+ # Option B: Log in to a subscription provider supported by the SDK
84
175
  pipiclaw auth login
85
176
  ```
86
177
 
87
- Then chat right in the terminal (the first run initializes the default desk):
178
+ Launch the interactive terminal UI (initializes the `default` desk automatically on first run):
88
179
 
89
180
  ```bash
90
181
  pipiclaw tui
91
182
  ```
92
183
 
93
- It can also be used for scripted one-shot requests:
184
+ Or run a one-shot non-interactive verification:
94
185
 
95
186
  ```bash
96
187
  pipiclaw tui --print "Reply with only: Pipiclaw model call succeeded"
97
188
  ```
98
189
 
99
- Only an actual model reply proves that the request path works; `pipiclaw tui --help` and `/model` only prove that the CLI or model catalog is visible. To connect an enterprise gateway, a local model, or set a default model, see [Configuration reference](https://github.com/oyasmi/pipiclaw/blob/main/docs/configuration.md).
190
+ > Receiving an actual model reply confirms the full request pipeline is working (`--help` and `/model` only verify CLI or catalog visibility). To configure an enterprise gateway, local model, or default model, see the [Configuration Reference](https://github.com/oyasmi/pipiclaw/blob/main/docs/configuration.md).
100
191
 
101
- ### 3. Connect DingTalk
192
+ ### 3. Connect DingTalk (No Public IP Required)
102
193
 
103
- Create an enterprise internal app on the [DingTalk Open Platform](https://open-dev.dingtalk.com/):
194
+ Create an enterprise internal application on the [DingTalk Open Platform](https://open-dev.dingtalk.com/):
104
195
 
105
- 1. Get the `Client ID` and `Client Secret`
106
- 2. Enable the bot capability
107
- 3. Enable Stream Mode
108
- 4. Recommended: create an AI Card template and get its `Card Template ID`
196
+ 1. Copy the **`Client ID`** and **`Client Secret`**
197
+ 2. Enable the **Bot** capability
198
+ 3. Select **Stream Mode** for message receiving
199
+ 4. *(Recommended)* Create an AI Card template and copy its **`Card Template ID`** for live streaming updates
109
200
 
110
- Edit `~/.pipiclaw/channel.json`:
201
+ Edit `~/.pipiclaw/channel.json` (make sure no `your-*` placeholder values remain):
111
202
 
112
203
  ```json
113
204
  {
@@ -124,131 +215,134 @@ Edit `~/.pipiclaw/channel.json`:
124
215
  }
125
216
  ```
126
217
 
127
- - The `dingtalk` and `webapi` sections each have an `enabled` switch; turn on at least one. `webapi` lets scripts and other clients connect to your assistant through the official OpenAI SDK using the implemented Responses subset (see [Web API](https://github.com/oyasmi/pipiclaw/blob/main/docs/webapi.md)).
128
- - The only hard-required DingTalk fields are `clientId` and `clientSecret`.
129
- - When `robotCode` is empty it falls back to `clientId`.
130
- - `cardTemplateId` can be left empty for now; configuring an AI Card is recommended for real use.
131
- - `allowFrom: []` means all senders are allowed; during a limited rollout, fill in tester staff IDs.
132
- - The file must not keep any `your-*` placeholder values.
218
+ - **Required fields**: Only `clientId` and `clientSecret` are strictly required. `robotCode` falls back to `clientId` when empty; `cardTemplateId` can be left blank initially (AI Card is strongly recommended for daily use).
219
+ - **Access control**: `allowFrom: []` allows all senders; populate tester staff IDs during a staged rollout.
220
+ - **Web API**: Set `webapi.enabled` to `true` if you also want scripts or other clients to connect via the official OpenAI SDK (see [Web API](https://github.com/oyasmi/pipiclaw/blob/main/docs/webapi.md)).
133
221
 
134
- Start the daemon:
222
+ Start the background daemon:
135
223
 
136
224
  ```bash
137
225
  pipiclaw
138
226
  ```
139
227
 
140
- In DingTalk, message the bot directly or @ it in a group — there is no desk to create or bind. New DMs and groups join the default desk on their first authorized message; `allowFrom` still controls who may use it. Send `/model` to inspect the model reference, and a normal message to verify a real call:
228
+ Open DingTalk and **DM the bot** or **@mention it in a group** — no manual desk creation or binding is needed. Send `/model` to check the active model, then send a message to verify a live turn:
141
229
 
142
230
  ```text
143
231
  Please introduce yourself and explain what you can do right now
144
232
  ```
145
233
 
146
- If the first message does not succeed, start from [Deployment and operations](https://github.com/oyasmi/pipiclaw/blob/main/docs/deployment-and-operations.md).
234
+ *(If your first message does not go through, check [Deployment and Operations](https://github.com/oyasmi/pipiclaw/blob/main/docs/deployment-and-operations.md).)*
235
+
236
+ ### 4. Enable External Agent Delegation (Claude / Codex / Cursor / Antigravity)
147
237
 
148
- ### 4. Enable external agent delegation
238
+ Install and log in to your target CLIs (`claude`, `codex`, Cursor's `agent`, or Antigravity's `agy`) under the same OS user account that runs Pipiclaw.
149
239
 
150
- First install and log in to the target CLI under the same account that runs Pipiclaw, then copy the capability entries you need. This enables the main Claude Code and Codex entries:
240
+ The package ships curated capability entries organized by executor, capability tier (`flash` / `main` / `high`), and read-only review (`codex-review`). Copy the entries you actually have accounts for into your workspace:
151
241
 
152
242
  ```bash
153
243
  mkdir -p ~/.pipiclaw/workspace/sub-agents
154
244
  PIPICLAW_PACKAGE_DIR="$(npm root -g)/@oyasmi/pipiclaw"
155
- cp "$PIPICLAW_PACKAGE_DIR"/examples/sub-agents/agents/{claude-main,codex-main}.md \
245
+
246
+ # Example: enable Claude Code and Codex main entries plus read-only independent review
247
+ cp "$PIPICLAW_PACKAGE_DIR"/examples/sub-agents/agents/{claude-main,codex-main,codex-review}.md \
156
248
  ~/.pipiclaw/workspace/sub-agents/
157
249
  ```
158
250
 
159
- Role file changes are rediscovered at runtime. Send:
251
+ *(Entries for `cursor-main`, `cursor-high`, `agy-main`, `glm-high`, `glm-flash`, etc. are also included; see [Sub-Agent Examples](./examples/sub-agents/README.md).)*
160
252
 
161
- ```text
162
- /subagents roles
163
- ```
164
-
165
- Once the entries show as available, describe the goal and acceptance criteria and let the main agent select an executor:
253
+ Role changes are discovered dynamically without restarting the daemon. Send:
166
254
 
167
255
  ```text
168
- Please hand this cross-module implementation to a suitable executor, then independently check the final changes.
256
+ /subagents roles
169
257
  ```
170
258
 
171
- Common control entry points:
259
+ Once the entries appear as available, describe your goal and acceptance criteria in plain language — the main agent will select the appropriate executor:
172
260
 
173
261
  ```text
174
- /subagents # running and recently completed delegations
175
- /subagents show <runId> # status, actual argv, artifact directory, stderr
176
- /subagents output <runId> # view text output
177
- /subagents cancel <runId|all> # terminate directly, not through the model
178
- /subagents roles [name] # view the role directory and a single role's config
262
+ Please hand this cross-module implementation to a suitable executor, then independently verify the final diff and send me the conclusion with evidence.
179
263
  ```
180
264
 
181
- External agents do not go through Pipiclaw's command and path guards. The recommended entries above use permissive CLI flags; before using them, read the authorization, security boundary, and sandbox notes in the [Agent delegation guide](https://github.com/oyasmi/pipiclaw/blob/main/docs/sub-agents.md).
265
+ > [!IMPORTANT]
266
+ > External agents do not pass through Pipiclaw's built-in command and path guards, and the recommended write entries use permissive CLI flags. Read the authorization and sandbox guidance in the [Agent Delegation Guide](https://github.com/oyasmi/pipiclaw/blob/main/docs/sub-agents.md) before enabling them, and run long external delegations under the persistent `pipiclaw` daemon.
182
267
 
183
- Long-running external delegations should run in the long-lived daemon; without one, the runtime embedded in `pipiclaw tui` handles external-run completions only while the terminal is open.
268
+ ### 5. Optional: Enable Web Search & Fetch Tools
184
269
 
185
- ### 5. Optional: enable web tools
270
+ `web_search` and `web_fetch` are disabled by default. Edit `~/.pipiclaw/tools.json` and set `tools.web.enable: true` (supports DuckDuckGo, Tavily, Jina, and SearXNG; DuckDuckGo works out of the box without an API key). See [Configuration Reference](https://github.com/oyasmi/pipiclaw/blob/main/docs/configuration.md) for all fields.
186
271
 
187
- `web_search` / `web_fetch` are off by default. Edit `~/.pipiclaw/tools.json`, set `tools.web.enable: true`, and configure a search provider. DuckDuckGo, Tavily, Jina, and SearXNG are supported; DuckDuckGo is the default. See [Configuration reference](https://github.com/oyasmi/pipiclaw/blob/main/docs/configuration.md) for the full fields.
272
+ ---
188
273
 
189
- <details>
190
- <summary>Let your favorite AI agent install it for you</summary>
274
+ ## Common Commands
191
275
 
192
- Hand the following request to Claude Code, Codex, or another local AI agent:
276
+ Slash commands are split into **runtime-handled commands (work mid-turn and bypass the LLM)** and **session commands**:
193
277
 
194
- ```text
195
- Please install and initialize Pipiclaw for me:
278
+ ### Available Anytime (Handled directly by the runtime — works even when busy or stuck)
196
279
 
197
- 1. Check Node.js >= 22.19.0; stop and explain if it is not met.
198
- 2. Run npm install -g @oyasmi/pipiclaw; on a permission failure do not sudo on your own.
199
- 3. Run pipiclaw once to initialize ~/.pipiclaw/; it prompting you to complete channel.json and exiting because it is still a template is normal.
200
- 4. Ask me whether I want to use an API key, a custom provider, or a subscription login supported by pipiclaw auth login; do not invent missing values.
201
- 5. If I want to connect DingTalk, collect clientId, clientSecret, optional cardTemplateId, and allowFrom item by item, write them into the `dingtalk` section of channel.json, and remove all your-* placeholder values.
202
- 6. When configuration is done, ask first whether to start. Terminal mode uses pipiclaw tui; DingTalk mode uses pipiclaw, and after it starts message the bot directly or @ it in a group — no desk needs to be created or bound.
203
- 7. Honestly list the operations performed, files changed, verification results, and information still missing; do not pretend it succeeded.
204
- ```
205
-
206
- </details>
207
-
208
- ## Common commands
280
+ | Command | Purpose |
281
+ |---|---|
282
+ | `/help [command]` | Show the top-level command list, or detailed subcommands and examples for a command (e.g. `/help tasks`) |
283
+ | `/status` | Inspect runtime status, active model, context usage, uptime, version, and desk task summary |
284
+ | `/stop` | Abort the current chat turn and clear queued messages (use `/tasks pause` for tasks, `/subagents cancel` for delegations) |
285
+ | `/steer <message>` | Steer the running turn after the current tool call finishes (default behavior for plain messages sent while busy) |
286
+ | `/followup <message>` | Queue a request to run after the current turn finishes |
287
+ | `/tasks [show\|log\|msg\|pause\|resume\|cancel\|archive\|doctor]` | Inspect, message (`msg`), pause, resume, or cancel background long-horizon tasks |
288
+ | `/subagents [list\|show\|output\|cancel\|roles]` | Inspect running/recent delegations, view outputs, browse roles, or terminate directly (`cancel`) |
289
+ | `/events <list\|show\|delete\|history>` | List, inspect, or delete scheduled events and view trigger history |
290
+ | `/desk [list\|new <name>\|bind <name>]` | View desk bindings, create a new desk, or bind the current channel to another desk |
291
+ | `/usage [7d\|month]` | View token usage and cost breakdown for the current desk and globally |
292
+ | `/context [detail]` | Inspect what is actually sent to the model: system prompt sections, tool definitions, and last-turn context |
293
+ | `/skills [list\|show <name>]` | List workspace and user-shared skills or view a specific skill |
294
+ | `/new` | Start a fresh conversation session |
295
+
296
+ ### Available When Idle (Requires the current turn to finish)
209
297
 
210
298
  | Command | Purpose |
211
299
  |---|---|
212
- | `/help` | Full command help for the current version |
213
- | `/stop` | Stop the current turn; a task-driven turn also pauses its task |
214
- | `/steer <message>` | Adjust the running turn |
215
- | `/followup <message>` | Queue the next request |
216
- | `/desk [list\|new <name>\|bind <name>]` | Advanced: create a desk, or switch the current channel to another desk |
217
- | `/status` | Execution status, model, context, uptime, and version |
218
- | `/usage [7d\|month]` | Model usage and cost for the current desk and globally |
219
- | `/tasks ...` | View, diagnose, and control long-running tasks |
220
- | `/subagents ...` | View and control delegation runs and the role directory |
221
- | `/memory ...` | View the current desk's long-term memory |
222
- | `/model [ref]` | View or switch the model |
223
-
224
- `/help`, `/stop`, `/steer`, `/followup`, `/desk`, `/events`, `/tasks`, `/status`, `/usage`, `/context`, and `/subagents` are handled directly by the runtime and work mid-turn. `/stop` does not cancel an already dispatched delegation run; use `/subagents cancel`.
225
-
226
- See [Interaction and commands](https://github.com/oyasmi/pipiclaw/blob/main/docs/interaction-and-commands.md) for full interaction details.
300
+ | `/memory [status\|list\|show\|forget\|journal]` | Inspect desk memories, probation items, daily journals, or delete and block a memory (`forget`) |
301
+ | `/model [provider/modelId\|modelId]` | View or switch the active model by exact ID or unique substring |
302
+ | `/thinking [off\|minimal\|low\|medium\|high\|xhigh\|max\|cycle]` | View or change the active model's reasoning effort level |
303
+ | `/compact [instructions]` | Manually compact the current session context with optional retention instructions |
304
+ | `/session` | Display message stats, token usage, and model info for the active session |
305
+ | `/reload` | Reload skills, tools, and resources while preserving conversation history |
306
+
307
+ See [Interaction and Commands](https://github.com/oyasmi/pipiclaw/blob/main/docs/interaction-and-commands.md) for full details.
308
+
309
+ ---
227
310
 
228
311
  ## Documentation
229
312
 
230
- The full index is at **[docs/README.md](https://github.com/oyasmi/pipiclaw/blob/main/docs/README.md)**. Good starting points:
313
+ The complete documentation index is at **[docs/README.md](https://github.com/oyasmi/pipiclaw/blob/main/docs/README.md)**. Jump straight to what you need:
231
314
 
232
- | I want to understand | Doc |
315
+ | I want to... | Guide |
233
316
  |---|---|
234
- | DingTalk, TUI, AI Card, and control commands | [Interaction and commands](https://github.com/oyasmi/pipiclaw/blob/main/docs/interaction-and-commands.md) |
235
- | Claude Code / Codex / built-in sub-agent delegation | [Agent delegation](https://github.com/oyasmi/pipiclaw/blob/main/docs/sub-agents.md) |
236
- | Configuring models, tools, and the workspace | [Configuration reference](https://github.com/oyasmi/pipiclaw/blob/main/docs/configuration.md) |
237
- | Memory, scheduled events, and long-running tasks | [Memory](https://github.com/oyasmi/pipiclaw/blob/main/docs/memory.md) · [Events and tasks](https://github.com/oyasmi/pipiclaw/blob/main/docs/events-and-tasks.md) |
238
- | Default security boundaries and external agent authorization | [Security guide](https://github.com/oyasmi/pipiclaw/blob/main/docs/security.md) |
239
- | Deployment, upgrades, backup, and troubleshooting | [Deployment and operations](https://github.com/oyasmi/pipiclaw/blob/main/docs/deployment-and-operations.md) |
240
- | The concurrency model and capacity limits for many groups and DMs | [Scaling and concurrency](https://github.com/oyasmi/pipiclaw/blob/main/docs/scaling-and-concurrency.md) |
317
+ | 💬 Understand DMs, groups, AI Cards, busy-time messages, and slash commands | [Interaction and Commands](https://github.com/oyasmi/pipiclaw/blob/main/docs/interaction-and-commands.md) |
318
+ | 🤝 Delegate to Claude Code / Codex / Cursor / Antigravity and author roles | [Agent Delegation](https://github.com/oyasmi/pipiclaw/blob/main/docs/sub-agents.md) · [Role Examples](./examples/sub-agents/README.md) |
319
+ | 📋 Use the background task lane, scheduled events, Cron templates, and budgets | [Events and Tasks](https://github.com/oyasmi/pipiclaw/blob/main/docs/events-and-tasks.md) |
320
+ | 🧠 Understand layered memory, daily journals, probation, and forgetting | [Memory](https://github.com/oyasmi/pipiclaw/blob/main/docs/memory.md) |
321
+ | ⚙️ Configure models, gateways, proxies, web tools, and workspace files | [Configuration Guide](https://github.com/oyasmi/pipiclaw/blob/main/docs/configuration.md) · [Field Reference](https://github.com/oyasmi/pipiclaw/blob/main/docs/configuration-reference.md) |
322
+ | 🔌 Connect scripts or custom clients via the official OpenAI SDK | [Web API](https://github.com/oyasmi/pipiclaw/blob/main/docs/webapi.md) |
323
+ | 🧩 Package reusable personal or project workflows as Skills | [Skills Guide](https://github.com/oyasmi/pipiclaw/blob/main/docs/skills.md) |
324
+ | 💡 Get higher leverage and end-to-end delivery from your setup | [Leverage Notes](https://github.com/oyasmi/pipiclaw/blob/main/docs/leverage/README.md) · [Design Philosophy](https://github.com/oyasmi/pipiclaw/blob/main/docs/design-philosophy.md) |
325
+ | 🛡️ Review default security guards, path/command rules, and external CLI boundaries | [Security Guide](https://github.com/oyasmi/pipiclaw/blob/main/docs/security.md) |
326
+ | 🚀 Deploy the daemon, upgrade, back up, and understand concurrency limits | [Deployment and Operations](https://github.com/oyasmi/pipiclaw/blob/main/docs/deployment-and-operations.md) · [Scaling and Concurrency](https://github.com/oyasmi/pipiclaw/blob/main/docs/scaling-and-concurrency.md) |
327
+ | 🏗️ Explore the module layering, runtime topology, and internals | [Architecture](https://github.com/oyasmi/pipiclaw/blob/main/docs/architecture.md) · [Runtime Mechanisms](https://github.com/oyasmi/pipiclaw/blob/main/docs/runtime-mechanisms.md) |
328
+
329
+ ---
241
330
 
242
331
  ## Development
243
332
 
244
333
  ```bash
245
334
  npm install
246
335
  npm run build
247
- npm run check # lint + typecheck + deadcode + test
336
+ npm run check # lint + typecheck + arch + deadcode + unit test
248
337
  ```
249
338
 
250
- Minimal verification: `npm run typecheck` and `npm run test`. `npm run test:e2e` is deterministic, offline, and credential-free; the small real-model smoke suite uses `npm run test:e2e:live`.
339
+ - **Minimum verification**: `npm run typecheck` and `npm run test`
340
+ - **Architecture & dependency boundaries**: `npm run arch`
341
+ - **Deterministic full-stack E2E (offline, zero API cost)**: `npm run test:e2e`
342
+ - **Live model smoke suite**: `npm run test:e2e:live`
343
+
344
+ ---
251
345
 
252
346
  ## License
253
347
 
254
- GNU Affero General Public License v3.0. See [LICENSE](./LICENSE).
348
+ Licensed under the [GNU Affero General Public License v3.0 (AGPL-3.0)](./LICENSE).