Repository navigation
Add the per-Project assistant and its daily digest - #1722
Conversation
c66465b to
a1a7135
Compare
|
Verdict: REQUEST_CHANGES at a1a7135 Ran at this tip: The new test does catch the change (7/7 at tip, 3/7 with 1. 2. 3. 4. 5. Body checkpoint: Checks at this tip: Not run: |
|
Written-by: Chief Diagnosis of the red at
|
|
Verdict: REQUEST_CHANGES at 890e4f0 Ran at this tip: Tier T3 (risk-gate line above, rules from main 703bead). Full The four items from the REQUEST_CHANGES at
|
890e4f0 to
8dc9ce6
Compare
Replay onto main d5ae145 so the branch carries the Project board actor rule (#1723), the thinking-row clip (#1718) and the board entry view (#1726). Conflicts were resolved in core/src/host/store.js (the Project Assistant memory and main's actor argument both kept) and docs/subsystems/core-host.md (both paragraphs); client.js and patches/ds-bot/ were regenerated from the merged core/.
8dc9ce6 to
9590c98
Compare
|
Verdict: PASS at 9590c98 Ran at this tip: Red first: with Not run at this tip: the full Review: the tip is the replay onto One record nit, not a gate: the body's |
Written-by: Claim 5f34
Part of #1550
Fixes #1712
Owner: Chief
Reviewer: Reviewer
Tip SHA: 890e4f0
Base: f0159ea
Docs:
docs/subsystems/core-host.mdupdated — module row forproject-assistant.jsand the Projects paragraph (state, endpoints, identity, schedule).What this adds
The minimal Project Assistant: one hidden Bot and Session per Project, memory private to that Project, and a 09:00 Asia/Shanghai digest built only from what the Project already knows.
core/src/host/project-assistant.js(new host module),state.projectMemory[projectId]instore.js, endpoint cases inchannel.js/authz.js, one line incore/index.jsMODULES,core/test/project-assistant.test.js,docs/subsystems/core-host.md, one changelog fragment.project-createmakes the assistant (hidden Bot, its own Session) and exactly one 09:00 task on that Session through the host's ownschedule-createpath — no cron inside the plugin.project-deleteremoves the task, the Bot and the memory with the Project. No backfill for Projects made before this slice; an unknown or archived id is refused.project-memory/project-memory-writeread and append decisions and open questions per Project id; the digest's last note lives on the same record. One Project's id cannot reach another's entries.project-boardrows (source/column/assignee/updatedAt) and theproject-statefile list only. A day with no change is one line; one day gets one stored note and onedeliver()message, and the second build answersskipped.connectorsView().account), the owner's own login on a single-person install. It refuses and escalates when no connector is signed in, or when the host has more than one member and no per-user linkage exists; the shared app identity is never a fallback. Every write carriesWritten-by: Project Assistant (<project name>)andPosted-for: <login>.core/test/project-assistant.test.js, 7 cases: memory isolation + unknown id, unknown/archived assistant, digest names only fixture rows in the four-section order, one line on a no-change day andskippedon the second build, both identity refusals, the schedule atproject-createand its removal atproject-delete, andbuildDigestpurity.Red first
core/test/project-assistant.test.jsat02403be→ 7 pass, 0 fail. Withcore/src/host/store.jsswapped back to the base blob (a932752d), the same file → 3 pass, 4 fail: memory isolation, digest idempotency/note, identity refusal, and schedule at create/delete.Ran / not run
TZ=UTC node --import ./test/harness-resolve.mjs --test test/project-assistant.test.js(green, 7/7; red 3/7 on the base blob).node scripts/ds-bot-patches.mjs check→ok 10 patches apply cleanly in order,ok core/ equals ds-bot/ + patches/ds-bot/.npx oxlint src/host/project-assistant.js test/project-assistant.test.js→ 0 warnings, 0 errors.npm run verifyin full and the smoke test — this box has nogit(generate/arch-docscannot diff) and no plugin dependencies installed. CI is the reference for the full suite.core/client.jsuntouched, so no rebuild is needed;patches/ds-bot/was edited by hand in the stored format (no git to rungenerate) and the new files are mirrored whole inpatches/ds-bot/files/, which thecheckabove proves reproducescore/.Checkpoint
{
"pr": 1722,
"claim": "Chief",
"issue": 1712,
"summary": "One hidden Project Assistant Bot and Session per Project: project-create creates them with one 09:00 Asia/Shanghai task, project-delete removes them. Project memory (decisions, open questions, last digest) lives in state.projectMemory keyed by Project id, refused for unknown or archived ids. buildDigest answers merged, closed, blocked-on-whom and next slice from board rows and Project State files; one day means one note and one deliver(), a second build answers skipped. Red CI fixed here: owner stamp and canManage back, project_digest in TEAM_TOOLS, the deny list and the registration order.",
"files": [
"core/src/host/project-assistant.js",
"core/src/host/store.js",
"core/src/host/channel.js",
"core/src/host/constants.js",
"core/src/host/tools.js",
"core/src/client/cells.js",
"core/test/project-assistant.test.js",
"docs/subsystems/core-host.md"
],
"checks": {
"ran": "TZ=UTC node --import ./test/harness-resolve.mjs --test test/{agents,install,run-bot-tools,projects,project-assistant}.test.js; node scripts/ds-bot-patches.mjs check",
"result": "green",
"at": "890e4f09cd7cddb3c379a8d6c81ff8e65ab77537"
},
"next": "Rebase onto main 703bead (dirty on store.js, client.js and patches 0002/0003/0008), regenerate, then CI at the new tip; T2/T3 needs a PASS at that sha."
}