10a601c28b
Reflect recent changes across all docs: - README: add executor loop (fire-and-forget), task events lifecycle, pending-tasks projection, update architecture diagram, add pulse-hermes package, add RFC #58 reference - CONTRIBUTING: add task-events.ts, defs.ts, projection-engine.ts, pending-tasks-projection.ts to code structure, update architecture diagram to three-layer decoupled model, add design principles 6-7, add ui/ directory, add migrate.ts, add RFC #58 reference - DESIGN: update packages table with all current packages
1.3 KiB
1.3 KiB
Design Document
See RFC #44: Pulse — Agent 的自主神经系统
Summary
Core Formula
f(prevSnapshot, currSnapshot) → (Effect[], tickMs)
Key Properties
- Moore Machine — Effects determined by state, not events. Pulse polls projection values, not event streams.
- Path Dependent — Sampling is lossy. A→B + B→C ≠ A→C at the effect level. Poll frequency = resolution of reality.
- S Combinator — Single composition primitive.
pulse = S r3 . S r2 . S r1 $ dummy - Not Forced Pure — Rules can be async/impure. Framework doesn't distinguish certain/uncertain.
- Agent Managed — The rule repo is managed by the Agent. Types, rules, collectors, effectors — all TypeScript, all under
tscguard. - Staging via git worktree — Safe experimentation before promote to production.
Packages
| Package | Purpose |
|---|---|
@uncaged/pulse |
Core engine: runPulse() + Rule type + executorLoop + task projections. Generic, zero deps. |
@uncaged/pulse-openclaw |
OpenClaw adapter: Gateway/LLM watchers + OC-specific rules + executors. |
@uncaged/pulse-cursor |
Cursor Agent CLI executor adapter. |
@uncaged/pulse-hermes |
Hermes Agent adapter. |
@uncaged/upulse |
CLI: daemon lifecycle + test/staging/promote + embedded WebUI |