xiaoju
8754ff51cd
feat(upulse): add rollback command — time-machine revert for engine
...
CI / test (push) Has been cancelled
- upulse rollback <commit> [--dry-run] [--engine <path>] [--events <path>]
- Exports events after cutoff to .pulse/rollbacks/rollback-<date>-<commit>.db
- Deletes those events from events.db
- Clears projection cache
- git checkout target commit in engine
- Also adds migrate.ts stub (missing file)
Ref: pulse#3
2026-04-18 01:34:26 +00:00
xiaoju
37e3331ccb
feat(workflow): add in-memory checkpoint for incremental tick
...
CI / test (push) Has been cancelled
- WorkflowCheckpoint caches lastEventId, topic summaries, and per-topic events
- First tick: full read (getAfter(0)), subsequent ticks: incremental (getAfter(lastEventId))
- Newly written role events also update checkpoint in-place
- No interface changes, no new files
2026-04-18 01:30:01 +00:00
xiaomo
90f7ba5a62
feat: export new CursorCall interface and executeCursorTask function
CI / test (push) Has been cancelled
2026-04-17 15:28:29 +00:00
xiaomo
2c1ed1419e
refactor: thin cursor executor + CursorCall schema (refs xiaoju/pulse#2 )
CI / test (push) Has been cancelled
2026-04-17 15:27:59 +00:00
xiaoju
e165d1a91d
fix: update adapter tests for simplified workflow-rule-adapter
...
CI / test (push) Has been cancelled
- meta:null test: expect undefined instead of remainingRounds JSON
- maxRounds test: moderator self-counts via meta, no remainingRounds param
- maxTicksPerWindow test: replaced with multi-topic processing test
- Remove 4-arg createWorkflowRule calls (options removed in adaptive-tick refactor)
68 pass, 0 fail
2026-04-17 15:22:36 +00:00
xiaoju
041756117b
feat: daemon adaptive tick — 5s active, backoff ×2 up to 5min idle
...
CI / test (push) Has been cancelled
Replaces fixed 30s setInterval with setTimeout-based adaptive loop.
Resets to 5s when new events detected, backs off to 5min when idle.
2026-04-17 15:03:14 +00:00
xiaomo
b6a927cb58
feat: adaptive tick frequency with exponential backoff ( closes xiaoju/pulse#1 )
CI / test (push) Has been cancelled
2026-04-17 14:19:18 +00:00
xiaoju
ee1c0cc9c0
refactor: meta workflow targets ~/.upulse/engine/ instead of pulse repo
...
CI / test (push) Has been cancelled
- ENGINE_DIR = ~/.upulse/engine for meta coder/reviewer/tester/promoter
- REPO_DIR still used for coding workflow
- Tester accepts buildCmd/testCmd opts, no longer hardcoded to monorepo paths
- Init engine dir with package.json + tsconfig.json + git repo
2026-04-17 14:12:47 +00:00
xiaoju
f88d325db8
feat: cli.refactor workflow — auto-generated by meta-workflow
CI / test (push) Has been cancelled
2026-04-17 13:32:42 +00:00
xiaoju
3e30503c08
feat: upulse CLI refactor — 4 commands (init/inspect/workflow/status)
...
CI / test (push) Has been cancelled
Auto-generated by meta workflow (cli-cleanup topic).
Removed: daemon, deploy, dev, gc, list, tick, ui commands.
Added: status (systemd + db stats), updated inspect + workflow.
2026-04-17 13:30:17 +00:00
xiaoju
620c5a8323
fix: REPO_DIR resolve to pulse root, not repos root
...
CI / test (push) Has been cancelled
Tester was failing with ENOENT because cwd pointed to
/home/azureuser/repos/packages/pulse (nonexistent) instead of
/home/azureuser/repos/pulse/packages/pulse.
2026-04-17 13:29:54 +00:00
xingyue
6e8b2b7ba6
fix: use effect.kind as fallback for effect type display
CI / test (push) Has been cancelled
2026-04-17 21:26:48 +08:00
xiaoju
ba31086c30
fix: daemon cooldownMs=0, add tick logging, systemd service + launcher
...
CI / test (push) Has been cancelled
- cooldownMs: 0 for both coding and meta workflow rules
- logTick wrapper prints timestamp + elapsed ms per tick
- start-daemon.sh loads secrets before starting bun
- pulse-workflow.service systemd unit (enabled + started)
2026-04-17 13:09:38 +00:00
xiaoju
ce36c08e9c
feat: restore coding-tdd workflow + barrel exports (lost in rebase)
CI / test (push) Has been cancelled
2026-04-17 13:03:17 +00:00
xiaoju
02847d9001
feat: workflow daemon + submit-task CLI
CI / test (push) Has been cancelled
2026-04-17 13:01:33 +00:00
xiaoju
04ced5b5f0
feat: coding-tdd workflow — auto-generated by meta-workflow
2026-04-17 13:01:33 +00:00
luming
c703befcdc
chore: remove obsolete binding and broker tests
...
CI / test (push) Has been cancelled
These tests reference modules (binding.js/broker.js) that no longer exist.
Signed-off-by: Xiaonuo <xiaonuo@git.shazhou.work >
2026-04-17 20:47:06 +08:00
luming
3cdd9aeba6
feat(ui): workflow dashboard — list, timeline, and overview card
...
CI / test (push) Has been cancelled
- Backend: GET /api/workflows, GET /api/workflows/:topicId/timeline
- Frontend: WorkflowsPage with list view + timeline detail
- Dashboard: workflow overview card (active/completed counts)
- Nav: Workflows entry with Workflow icon
— 小糯/Xiaonuo
2026-04-17 20:41:35 +08:00
xiaoju
bf6de91c61
feat(coding): declare maxRounds + moderator remainingRounds awareness
CI / test (push) Has been cancelled
2026-04-17 12:25:17 +00:00
xiaoju
a54c36f758
refactor: remainingRounds countdown in event meta, replace maxTicksPerTopic with workflow-declared maxRounds
CI / test (push) Has been cancelled
2026-04-17 11:51:57 +00:00
xiaoju
e1a96fdc71
feat: cursor health check + workflow circuit breaker
...
CI / test (push) Has been cancelled
- 新增 Cursor Health Rule (cursor-health.ts):
- 监控 ~/.cursor/ai-tracking/ai-code-tracking.db
- 检查最近 15 分钟内调用次数,默认阈值 100
- 支持自定义时间窗口、阈值、数据库路径
- 完整测试覆盖,包括边界情况处理
- 增强 Workflow 保护机制 (workflow-rule-adapter.ts):
- maxTicksPerTopic (默认20):同一 topic 超限强制写 __end__ 事件
- maxTicksPerWindow (默认50):1小时内全局 tick 超限暂停所有执行
- cooldownMs (默认60s):同一 topic 两次 tick 最小间隔
- 完整事件日志记录,便于调试分析
防止 workflow 死循环空转事故,保护 Cursor Agent 额度不被恶意消耗。
小橘 🍊 (NEKO Team)
2026-04-17 11:37:46 +00:00
xiaoju
2e216c2f81
revert: restore --yolo flag for cursor agent
...
CI / test (push) Has been cancelled
--yolo = auto-approve permissions, needed for unattended runs.
2026-04-17 10:49:23 +00:00
xiaoju
3f1db4ed58
chore: cursor agent switch from --yolo to auto mode
...
CI / test (push) Has been cancelled
Save API quota — first day already used 31%.
2026-04-17 10:46:43 +00:00
xiaoju
c2a0e8c96b
feat: coding workflow — auto-generated by meta-workflow
CI / test (push) Has been cancelled
2026-04-17 10:44:41 +00:00
xiaoju
029417ce33
fix: meta-tester cwd path double-nesting bug
...
CI / test (push) Has been cancelled
tester was running 'cd packages/pulse && bun test packages/pulse/...'
which doubled the path. Fixed to cwd=packages/pulse + relative paths.
2026-04-17 10:39:40 +00:00
xiaoju
592a5566a5
feat: enhance coding workflow — structured architect design, reviewer retry with retryCount cap
...
- ArchitectMeta now includes targetFiles, changes (file→description), and verification criteria
- CoderMeta prepPrompt explicitly consumes architect.changes, architect.verification, and reviewer.rejectionReason on retry
- ReviewerMeta now outputs verdict, rejectionReason, and monotonic retryCount (starting from 0)
- Moderator enforces retryCount < 3 limit — forces closer when exceeded
- Updated mock implementations, role factories, and e2e to match new meta structures
- Added test for retry limit (retryCount >= 3 → closer)
2026-04-17 10:27:53 +00:00
xiaoju
4139f1d5d5
fix: tick() returns content+meta in executed roles
...
CI / test (push) Has been cancelled
- ExecutedRole: { topicId, role, content, meta }
- No more indirect event reading to get role results
- 28 tests pass
2026-04-17 10:14:44 +00:00
xiaoju
a1a6dba24b
feat: workflow scaffold + unified modify mode
...
CI / test (push) Has been cancelled
- scaffold.ts: generates {name}.ts + {name}.test.ts + roles/{name}-*.ts
- CLI: upulse workflow init <name> --roles planner,executor
- meta-architect prompt: 统一为'修改已有骨架'语义
- meta-coder prompt: 在已有文件上填充实现
- 28 tests pass
2026-04-17 09:56:51 +00:00
xiaoju
898809abd3
refactor: rename *-workflow.ts → *.ts — drop redundant suffix
...
CI / test (push) Has been cancelled
workflows/coding.ts, report.ts, meta.ts + matching tests
All 28 tests pass, build clean
2026-04-17 09:52:27 +00:00
xiaoju
2f461bffeb
feat: meta-workflow — workflow for developing workflows
...
CI / test (push) Has been cancelled
Roles: architect(LLM) → coder(Cursor) → reviewer(Cursor) → tester(code+LLM) → promoter(code)
- Retry loop: reviewer rejected or tester failed → back to coder
- Meta architect uses structured tool output (workflow spec JSON)
- Coder/reviewer use agent-executor factory with LLM₂ meta parsing
- Tester: build+test then LLM judges result
- Promoter: git commit + push
- docs/workflow-spec.md: reference context for coder role
- 3 unit tests (moderator routing, happy path, retry path)
- 28 total workflow tests pass
2026-04-17 09:20:45 +00:00
xiaoju
4abe7bf620
refactor: extract createLlmRole/createToolRole factory — shared sandwich pattern
...
CI / test (push) Has been cancelled
- llm-role-factory.ts: shared LLM call skeleton (build messages → chat → parse)
- createLlmRole: free-text response roles (architect)
- createToolRole: tool_choice structured output roles (analyst)
- analyst-llm.ts + architect-llm.ts rewritten on factory
- 25 tests pass, live report verified
2026-04-17 09:12:32 +00:00
xiaoju
a040819a09
feat: report i18n — 中文模板 + analyst 中文输出
CI / test (push) Has been cancelled
2026-04-17 08:58:15 +00:00
xiaoju
5ad4145dfc
feat: report workflow — analyst(LLM) + renderer(template)
...
CI / test (push) Has been cancelled
- analyst: structured JSON output via tool_choice (score, highlights, issues, roleAnalysis with eventId refs)
- renderer: pure code HTML template — dark theme, gantt bar, role cards, verdict badges
- report-live.ts: e2e test script, reads coding workflow DB → generates HTML report
- renderer-llm.ts: kept as reference (LLM version, not used — timeout issues)
- 2 unit tests pass, live test: 17.9s end-to-end
2026-04-17 08:46:40 +00:00
xiaoju
9efb535ead
feat: upulse workflow timeline <key> — view event timeline
...
CI / test (push) Has been cancelled
- Shows offset, duration, role, meta for each event
- --json for structured output (feeds report workflow)
- --content for content preview
2026-04-17 08:22:35 +00:00
xiaoju
3c6c8840ef
fix: live script uses agent-executor sandwich (no more includes hack)
...
CI / test (push) Has been cancelled
- council-v2-live.ts: coder/reviewer now use createCoderRole/createReviewerRole
- Removed inline runCursorAgent (moved to agent-executor.ts)
- reviewer verdict via LLM₂ tool_choice instead of includes('rejected')
- Live verified: architect→coder→reviewer(approved)→closer in 135s
2026-04-17 06:53:48 +00:00
xiaoju
a4aa990e9f
docs: add roles/ directory reference to COUNCIL-V2.md
...
Reference concrete role implementations (architect-llm, coder-cursor,
reviewer-cursor, agent-executor) in the Roles section.
Made-with: Cursor
2026-04-17 06:40:54 +00:00
xiaoju
f191d594b3
feat: LLM-Agent-LLM sandwich (agent-executor)
...
- createAgentExecutorRole: prepPrompt → agent.run → LLM₂ tool_choice → meta
- createCursorRunner: extracts Cursor CLI into AgentRunner interface
- Coder role: LLM₂ extracts filesChanged + testsPassed via tool_choice
- Reviewer role: LLM₂ extracts verdict via tool_choice (no more includes hack)
- defaultMeta fallback when LLM₂ fails or returns no tool_call
- 5 new agent-executor tests, 24 total pass
2026-04-17 06:27:19 +00:00
xiaoju
5a8fe051bf
docs: tighten COUNCIL-V2.md to 49 lines within 30-50 target
...
Made-with: Cursor
2026-04-17 06:16:20 +00:00
xiaoju
b458daecb8
docs: trim COUNCIL-V2.md to 50 lines and inline source references
...
Made-with: Cursor
2026-04-17 06:14:08 +00:00
xiaoju
ac6db24d6e
docs: rewrite COUNCIL-V2.md with concise model overview
...
Simplified structure with inline code block for WorkflowType,
streamlined section headings, and tighter prose while retaining
all key topics: START/END automaton, pure roles, Moore-machine
diff-driven ticks, and source file references.
Made-with: Cursor
2026-04-17 06:12:04 +00:00
xiaoju
8cec21d285
docs: add COUNCIL-V2.md overview of the WorkflowType model
...
Covers WorkflowType definition, START/END automaton, pure roles,
and Moore machine diff-driven ticks with source file references.
Made-with: Cursor
2026-04-17 06:09:43 +00:00
xiaoju
2290c478c5
refactor: START/END automaton + pure roles
...
- START = Symbol('workflow.START'), END = Symbol('workflow.END')
- Moderator: (START | RoleOutput) → Role | END — complete automaton
- Role returns { content: string, meta: Meta | null } — pure function
- Adapter handles all storage: CAS putObject + appendEvent
- 'user' pseudo-role removed, trigger event = coding.__start__
- Roles no longer import/call store.putObject or store.appendEvent
- content fixed to string (not unknown), meta allows null
- -653/+484 lines, 22 tests pass
2026-04-17 06:04:18 +00:00
xiaoju
c13290dd25
refactor: type-safe workflow — Role<Meta> + discriminated union moderator
...
- Role<Meta> = (chain, topicId, store) => Promise<Meta>
- MetaOf<R> extracts Meta from Role type
- RoleOutput<Roles> = discriminated union { role: K, meta: MetaOf<Roles[K]> }
- Moderator receives RoleOutput, switch on role narrows meta type
- WorkflowType simplified: no projection field, just name + roles + moderator
- Adapter builds per-topic summary internally
- coding-workflow: ArchitectMeta, CoderMeta, ReviewerMeta, CloserMeta
- -538/+326 lines — simpler AND more type-safe
2026-04-17 05:24:10 +00:00
xiaoju
ff689ce3ce
refactor: workflow message chain + CAS storage
2026-04-17 05:02:58 +00:00
xiaoju
59afcf6211
docs: add Workflow as Conversation design notes
2026-04-17 04:24:17 +00:00
xiaoju
c61a8d1666
refactor: rename Topic → Workflow, routine → workflows scope
2026-04-17 04:10:56 +00:00
xiaoju
f5eb899711
fix(upulse): topic command uses routine scope, not _system
2026-04-17 04:03:38 +00:00
xiaoju
62c1ddd23b
feat(upulse): add topic create/list CLI commands
...
Add 'upulse topic create' to write coding.created events with
auto-generated slugified topicId, and 'upulse topic list' to
display topics grouped by state with --all flag for closed topics.
Made-with: Cursor
2026-04-17 03:56:17 +00:00
xiaoju
d073e93d8e
chore: update daemon config for v2-only + rename COUNCIL-V2.md
2026-04-17 03:25:23 +00:00
xiaoju
b65e9d65cb
refactor: remove v1 Council code (Container/Binding/Task/Moderator)
2026-04-17 03:24:36 +00:00