You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
archer-slack-review polls a watermark every 15 min (~100K input/run × ~96 runs/day ≈ 9.6M/day) and usually finds nothing. Replace the polling with an event-driven collector (Drew approved 2026-10-29):
A small service using Slack Socket Mode (outbound WebSocket — no public endpoint needed; Cloudflare Worker + Events API is the off-box alternative) appends messages, replies, and reactions from the watched channels to a local store.
The review job wakes ONLY when the store has new items (hook/signal), reads just the delta, and acts.
Placement per the flake rule (developing-today/code flake if on the laptop; sandbox systemd if on the sandbox). The service is deterministic — no LLM in the collection path.
PoC scope: the #alignment channel end-to-end (collect → store → wake → review). Success: quiet-day agent cost ~0; no missed Aster replies over a 3-day parallel run against the existing poller. Afterwards, generalize the pattern to other watermark polls.
TOP PRIORITY (Drew, 2026-10-29 01:23 CDT): Batch 3 fleet consolidation — pick this up in the next runs, ahead of routine work. Being enqueued to repo-health-code-pilot at top priority now.
archer-slack-review is enabled and running on a 15-minute interval (checked live: last run 2026-10-29 01:39 CDT, succeeded; next 01:53) — ~96 agent runs/day.
The mechanism it uses is a watermark pull (puller.py + state DB) — collection and the LLM review are currently the same run, which is exactly the coupling this issue removes.
Design / decisions
Placement: the sandbox, as a systemd user service. Both the puller store (~/workspace/archer-slack/puller/state/archer-slack.db) and the review job live on the sandbox; the collector is an outbound WebSocket (no public endpoint, no laptop flake involvement). Per this issue's placement rule: sandbox systemd.
No Slack app changes expected for the PoC. The Archer app manifest already has socket_mode_enabled: true and the needed bot events (message.channels/groups/im/mpim, app_mention), and the app-level token already exists in Bitwarden Secrets Manager as slack.archer-app-token (name verified; value not read). If connections:write turns out to be missing, the implementer stops and names the exact app change for Drew rather than widening scopes silently.
Collector shape: a small deterministic Python service beside the puller. It appends messages, thread replies and reactions for the watched channel to the local store, deduplicated by (channel, ts) — so overlap with the watermark puller is safe and the puller remains the backfill safety net for any collector downtime. No LLM in the collection path.
PoC = parallel run, no cadence change. For 3 days the collector runs alongside the untouched 15-min poller; fidelity is compared against the puller's history (zero missed messages; Aster replies checked explicitly — that is the channel's reason to exist). Quiet-day agent cost only reaches ~0 at cutover (signal-triggered review replacing the poll), and cutover is a separate decision gated on the parallel-run report — cadence changes stay Drew-approved, so the PoC itself changes no schedule.
Wake mechanism at cutover (for the report to confirm): the review job fires from the store's new-item signal rather than the clock; the design in ~/workspace/archer-slack/slack-agent-design.md already sketches Socket Mode as the Phase-2 escape hatch from polling, and this implements it.
Implementation routed: queue task 3176 (priority 10, per Drew's top-priority direction for Batch 3) carries the build + 3-day parallel run + report-back on this issue. Epic #2055 updated with this outcome.
Found via: atomic queue re-claim at the recorded parallel-run end
Task: Revalidate the #alignment collector fidelity window and report only from fresh data.
Environment check: This lane is on the laptop; ~/workspace/archer-slack is absent locally and archer-slack-collector.service is inactive here. The required collector and SQLite store are specified as sandbox-resident, so no fidelity result is available locally.
Next: block pending sandbox-side aggregate comparison (including Aster replies and service uptime); do not modify or stop the collector.
Blocker: The required sandbox workspace/database and collector service are absent/inactive on this laptop, and this lane is restricted to laptop-local work. I did not inspect or modify the service or its data.
Required to resume: Run an aggregate collected_events vs puller-history comparison for #alignment over the 3-day window (explicitly check Aster replies) and report service uptime/restarts from the sandbox; then attach/post the evidence here. No fidelity or cutover conclusion until then.
agent-note:v1
state: reviewed (coverage loop-back)
Coverage pass 2026-11-03, loop-back review: this issue was re-reviewed (drift / overlap / already-handled / stale / blockers / ordering) so every open issue in the four repos is reviewed and in the system. Verdict: still live; in the system as task 3176 (small_fix, blocked, priority 10) in repo-health-code-pilot. Labels audited and synced. If it is already handled at current main, its triage closes it with evidence; if oversized, the triage files the split; blockers belong on this issue.
Found via: coverage loop-back 2026-11-03
Activity
developing-today commentedon Oct 29, 2026
CODE-1035
dezren39 commentedon Oct 29, 2026
TOP PRIORITY (Drew, 2026-10-29 01:23 CDT): Batch 3 fleet consolidation — pick this up in the next runs, ahead of routine work. Being enqueued to repo-health-code-pilot at top priority now.
dezren39 commentedon Oct 29, 2026
🤖 Agent note · picked up
dezren39 commentedon Oct 29, 2026
🤖 Agent note · done
Premise — verified against live state
archer-slack-reviewis enabled and running on a 15-minute interval (checked live: last run 2026-10-29 01:39 CDT, succeeded; next 01:53) — ~96 agent runs/day.3a02ea3to370cd4d#5 (2026-10-28 23:56 CDT) measured its per-run floor at ~100K input/run, so ≈ 9.6M input/day, and the channel is quiet most of the day — the "usually finds nothing" claim holds.puller.py+ state DB) — collection and the LLM review are currently the same run, which is exactly the coupling this issue removes.Design / decisions
~/workspace/archer-slack/puller/state/archer-slack.db) and the review job live on the sandbox; the collector is an outbound WebSocket (no public endpoint, no laptop flake involvement). Per this issue's placement rule: sandbox systemd.socket_mode_enabled: trueand the needed bot events (message.channels/groups/im/mpim,app_mention), and the app-level token already exists in Bitwarden Secrets Manager asslack.archer-app-token(name verified; value not read). Ifconnections:writeturns out to be missing, the implementer stops and names the exact app change for Drew rather than widening scopes silently.(channel, ts)— so overlap with the watermark puller is safe and the puller remains the backfill safety net for any collector downtime. No LLM in the collection path.~/workspace/archer-slack/slack-agent-design.mdalready sketches Socket Mode as the Phase-2 escape hatch from polling, and this implements it.Implementation routed: queue task 3176 (priority 10, per Drew's top-priority direction for Batch 3) carries the build + 3-day parallel run + report-back on this issue. Epic #2055 updated with this outcome.
Labels updated to mirror the queued follow-up.
10 remaining items
dezren39 commentedon Nov 1, 2026
🤖 Agent note · picked up (resume after 3-day window)
~/workspace/archer-slackis absent locally andarcher-slack-collector.serviceis inactive here. The required collector and SQLite store are specified as sandbox-resident, so no fidelity result is available locally.dezren39 commentedon Nov 1, 2026
🤖 Agent note · blocked (execution-host access)
collected_eventsvs puller-history comparison for #alignment over the 3-day window (explicitly check Aster replies) and report service uptime/restarts from the sandbox; then attach/post the evidence here. No fidelity or cutover conclusion until then.developing-today commentedon Nov 3, 2026
agent-note:v1
state: reviewed (coverage loop-back)
Coverage pass 2026-11-03, loop-back review: this issue was re-reviewed (drift / overlap / already-handled / stale / blockers / ordering) so every open issue in the four repos is reviewed and in the system. Verdict: still live; in the system as task 3176 (small_fix, blocked, priority 10) in repo-health-code-pilot. Labels audited and synced. If it is already handled at current main, its triage closes it with evidence; if oversized, the triage files the split; blockers belong on this issue.
Found via: coverage loop-back 2026-11-03