본문으로 건너뛰기
cccskills
무료GitHub에 공개

dreaming

Use when: Good night Team, EOD, Wrapping up, or end-of-day consolidation. Archives session context, promotes durable patterns, and compacts live agent memory files for the next session.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

설치 방법 보기

포함된 파일(1)

  • SKILL.md22.9 KB

SKILL.md(원문)

설치하기 전에 에이전트에게 전달되는 지시 내용을 확인할 수 있습니다.

Dreaming

End-of-day archive-and-compact routine. Reviews the current session plus relevant memory touched during the day, promotes durable patterns, writes a dated archive snapshot, then compacts the live repo memory file down to current state for the next session. Runs on demand — triggered by the team lead saying "Good night Team" (or variants).

Trigger

Phrases that activate dreaming: "Good night Team", "Good night", "Goodnight Team", "Wrapping up", "EOD".

Read your agent identity and follow the per-agent delta below after running the shared consolidation steps.

Consolidation Rules

  • Preserve scope. Do not flatten all memories into one file. Session, repo, and user memory remain in their native stores.
  • Treat the agent's live memory record (accessed via the active storage plugin using read-memory(agent)) as the current-state file for the next session, not as the full historical archive.
  • Write a dated archive snapshot via the active storage plugin using archive-memory(agent, date) before compacting the live file.
  • If the storage plugin's write tool (e.g. obsidian-mcp-server) is unavailable, do not switch to the free-tier path (memory/<agent>.md) — write via a direct file edit to the same vault path instead (vault/Memory/<agent>.md). This is not a "free-tier fallback" — the vault path never changes, only the write mechanism does.
  • Before compacting, run npm run memory -- ensure <agent> to scaffold the agent's memory record (with HOT / WARM / COLD headings) and the archive directory if either does not already exist yet. This is a no-op — it never overwrites or truncates an existing file — so it is safe to run unconditionally at the start of every dreaming cycle.
  • Session memory may be deleted after it has been captured in the daily checkpoint or promoted elsewhere.
  • Repo and user memory compaction is opt-in only. Rewrite or delete entries there only when they are explicitly marked dreaming-managed or were created as transient capture for the same dreaming cycle.
  • Never clear the full user, session, or repo memory stores wholesale.
  • When compacting the live file, keep only current HOT items, explicit carry-forward items, and durable WARM/COLD knowledge. Move fully resolved day-specific detail into the archive snapshot.

Tiered Memory Lifecycle

Where the active storage plugin defines sweep-memory(), moving entries between tiers is a script, not this skill's job. Good night order: Architect runs sweep-memory(force), then dreaming, then sweep-memory(force) again; dispatched agents never sweep. The decay rules (step 3 and the Compaction Decision Table age rows) and compaction (steps 4 and 8) then do not apply, and the skill keeps only judgement: promoting durable items into COLD via write-memory-entry(agent, 'COLD', content), the contradiction review (step 5), and the one-line summary for the archive snapshot. Where the plugin defines no sweep, every rule in this skill applies as written.

Compaction Decision Table

An entry or item is eligible for retirement to archive (and not carried forward to the live file) when it meets one of these criteria:

CriterionApplies ToDecisionAction
Resolved signal presentAny section"done", "✓ CLOSED", "✓ MERGED", "closed", "merged" in entry textRetire to archive. Summarise outcome (1 line) if exceeding 500 chars.
No open ticket/PR referenceLAST_EVENTEntry is older than 7 days AND contains no active GitHub issue, PR, or blocker referenceMove to archive.
LAST_EVENT age capLAST_EVENTMore than 10 entries in LAST_EVENT sectionKeep only the 10 most recent; move older to archive.
HOT entry not referenced in 48hHOTEntry not touched/updated in last 48 hoursMove to WARM during EOD consolidation.
WARM entry not referenced in 7dWARMEntry not touched/updated in last 7 daysMove to COLD during EOD consolidation.
Explicit carry-forward markerAny sectionEntry contains carry-forward: true or EOD-keepKeep in live file (overrides age/size rules).
Transient resolved detailAny sectionEntry explicitly marked dreaming-managed AND has been captured in archiveDelete from live file.

Size cap rule: Individual LAST_EVENT entries in the live file are soft-capped at 500 chars. Entries exceeding this during compaction are summarised to a one-liner (date + outcome + ticket reference) in the live file; full detail is archived.

Shared Consolidation Steps

Every agent runs these steps. Per-agent sections below specify only the variables (which file, what to promote, who to dispatch).

  1. Review session memory — read the session working buffer if it exists (session context captured during the session by the Working Buffer Protocol in proactive-agent; the concrete path is defined in the active storage plugin file).
  2. Review relevant durable memory touched this session — inspect the live repo memory file plus any user-memory or repo-memory topics updated during the session; skip unrelated memory topics.
  3. Identify promotable patterns, carry-forward items, and compaction candidates — using the agent's promotion focus and the Compaction Decision Table (above). Apply decay rules explicitly:
    • HOT → WARM decay: Items last referenced more than 48 hours ago move to WARM.
    • WARM → COLD decay: Items last referenced more than 7 days ago move to COLD.
    • LAST_EVENT retirement: Entries older than 7 days with no open ticket/PR/blocker reference go to archive. Cap LAST_EVENT at 10 most recent entries total.
  4. Size audit LAST_EVENT entries — entries exceeding 500 chars are summarised to a one-liner (date + outcome + ticket ref) in the live file; full detail moves to archive.
  5. Contradiction review pass (best-effort, human-review only) — before or alongside promoting durable items (next step), review this agent's own recent memory for statements that appear to contradict an existing entry on the same tracked topic (same entity/fact — e.g. a tier's stack description, a port number, a repo path, a capability claim — asserted with a different value in two places).
    • Scope: own memory only. Never read another agent's memory record (do not call read-memory(other-agent)) or their archive snapshots for this step — the Cascade rule below ("no agent reads or writes another agent's memory during dreaming") applies here too. The review covers this agent's own current HOT section plus its own archive snapshots from roughly the last 7 days (the same window the WARM → COLD decay rule already uses), not its full historical archive — a full-history semantic scan is out of scope and would blow out a nightly pass's cost.
    • Gather the scan corpus mechanically, judge it yourself. Run node pipelines/deploy/lib/dreaming-contradiction-scan.js scan <agent-id> --hub-root <hub root> to assemble the corpus (own live memory + own recent archive snapshots, scoped to the window above) — this is pure file-gathering, not detection. Its JSON output includes indexAvailable: when true, a memory-index CLI has shipped into this hub and node pipelines/deploy/lib/memory-index.js find <keyword> can additionally be used for cheaper cross-entry lookup within this agent's own entries only (filter any results to agent === <this agent's own id> — never act on another agent's indexed entries this way, same isolation rule as above); when false (memory-index hasn't shipped in this hub, or hasn't been built yet), the scan-corpus script's own file reads are already the full fallback — no separate action needed.
    • Deciding whether two statements actually conflict is judgment, not mechanics — per established best-practice and architectural decision-making protocols. Only flag entries that plausibly assert a different value for the same tracked fact; do not flag a routine update, a correction already reconciled by a later entry, or two entries that merely share a keyword without actually disagreeing.
    • Write findings, never resolve them. Record each finding in a new ## Flagged Contradictions section in this cycle's archive snapshot (see structure below): both conflicting statements (verbatim or a faithful excerpt), their source (tier/section and date), and nothing else. Never edit, delete, or pick a winner between the two entries as part of this step — a human (the team lead) decides which is current. Omit the section entirely from the snapshot when no contradiction is found this cycle.
    • This is a best-effort net, not a guarantee. The pass will miss real contradictions — it only catches what a routine read of the scoped window surfaces, depends on the judgment quality of whichever model runs dreaming, and does not attempt full-corpus or semantic coverage. Never present this step to a customer as complete or guaranteed contradiction detection.
  6. Promote durable items — append to the targets listed in the agent's per-agent delta, preserving source labels when helpful.
  7. Write daily archive snapshot — create or overwrite the archive file at the per-agent path using the structure below. Record before/after line counts in the "Compacted" section.
  8. Compact live memory — rewrite the live file so it remains a short current-state file:
    • keep active HOT items only (apply 48h decay rule)
    • preserve explicit carry-forward items that still matter tomorrow
    • move durable longer-lived facts into WARM / COLD as appropriate (apply 7d decay rule for WARM → COLD)
    • retire resolved or expired LAST_EVENT entries (apply 7d retirement rule and 10-entry cap)
    • remove resolved day-only detail that is now preserved in the archive snapshot
  9. Compact safe memory only — delete session memory files whose content has been captured above; optionally trim or rewrite only dreaming-managed entries; never clear untouched repo or user memory.
  10. Refresh vault index (vault-backed hubs only — dev:sub, ops) — run npm run vault:index from the hub root. This is the nightly maintenance pass that keeps the hierarchical index notes current after any task, memory, or document activity during the day. The script is idempotent and deterministic: it adds only links that are not yet present in existing index notes and produces zero writes when nothing has changed. Skip silently on free-tier (dev, dev:graph) hubs where no vault/ directory exists. Interactive/manual trigger only. This step is a prose instruction to whichever agent is running the trigger by hand and has no execution guarantee on its own — a real incident found it silently skipped or run against a stale on-disk state across several consecutive automated nights (see nightly-dreaming.js's own header comment). For the automated Scheduled Task path specifically, pipelines/deploy/lib/nightly-dreaming.js's runNightlyDreamingWithLogging() already invokes the equivalent scan directly in code, unconditionally, after the whole session's claude -p subprocess has exited — so that path does not depend on this prose step at all. Still follow this step for every interactive/manual "Good night Team" run, since there is no wrapping process to guarantee it there.
  11. Sweep the Learnings store for threshold-crossing entries and promote — repo-wide, not agent-scoped (.learnings/LEARNINGS.md/.learnings/ERRORS.md, or their vault-tier Research/Learnings/ equivalents, live once at the project root, not per agent — see agent-foundations/SKILL.md's Storage Plugin Contract Learnings store). Read self-improving-agent/SKILL.md's own "Promotion threshold" definition and Promotion table directly rather than restating either here — both may evolve independently of this step, and a copy here would drift.
    • Read pending entries via list-pending-learnings('LEARNINGS') and list-pending-learnings('ERRORS') — the active storage plugin's operation, not a raw file read. On free tier this resolves to a direct read of .learnings/LEARNINGS.md/.learnings/ERRORS.md; on vault-backed tiers it resolves to Research/Learnings/LEARNINGS.md/Research/Learnings/ERRORS.md (see storage/obsidian.md) — so this step is correct on every tier without a tier-specific branch here.
    • Sweep the returned entries for ones that meet the promotion threshold defined in self-improving-agent's own "Promotion threshold" section.
    • Promote every entry that crosses the threshold in this same pass — not just flag it for a human to promote later — using self-improving-agent's own Promotion table to pick the correct target (including that table's storage-plugin note for vault-backed tiers).
    • Mark the entry **Status**: promoted and add **Promoted**: <target file>, per self-improving-agent's own Resolving Entries format — write the update via write-learning-entry on vault-backed tiers rather than a raw file edit.
    • Record what was promoted in this cycle's archive snapshot (## Promoted Memory → Learnings: line below) so it is never a silent side effect.
    • This step is idempotent: an entry already marked promoted is not re-swept or re-promoted on a later run, so it is safe for every agent's consolidation pass to run it independently — the same tolerance step 10's vault-index refresh already relies on above.

Daily Archive Snapshot Structure

# <Agent> Archive — YYYY-MM-DD

## Completed Today

- [...]

## Promoted Memory

- Repo: [...]
- User: [...]    <!-- omit if the agent does not promote to user memory -->
- Learnings: [...]    <!-- `.learnings/`/Learnings-store entries promoted this cycle via step 11, with their target file; omit if none crossed the threshold -->

## Flagged Contradictions

<!-- Omit this section entirely when no contradiction was found this cycle. Never auto-resolved — see the Contradiction review pass step above. -->
- Statement A: [...] (source: [tier/section], [date]) vs. Statement B: [...] (source: [tier/section], [date]) — unresolved, needs human review.

## Carry-Forward

- [...]

## Blockers For Team Lead

- [...]

## Compacted

- Before: XXX lines | After: YYY lines (NNN chars removed from LAST_EVENT; M entries archived)
- Entries moved: [date range], ticket refs: [#XX, #YY, ...]
- [...]

The "Compacted" section must always report:

  • Line count delta: "Before: XXX lines | After: YYY lines" (count the full live file before and after compaction).
  • LAST_EVENT delta: Number of chars removed and number of entries archived.
  • Date range and ticket refs: Which entries were retired (by date) and which tickets they reference.

Per-Agent Deltas

Architect

Live file: accessed via the active storage plugin using read-memory('architect') Archive file: written via the active storage plugin using archive-memory('architect', date)

Promotion focus: recurring design patterns, confirmed conventions, architectural decisions, corrections from the team lead, unresolved next-day items, transient notes safe to collapse.

Promotion targets:

  • Session corrections from the team lead → agent memory WARM/COLD tiers via write-memory-entry('architect', tier, content) every run
  • Cross-project architectural patterns → auto-memory (user-level memory files) when the pattern recurs across 2+ projects
  • Dreaming-managed transient captures → compacted in their original memory file after checkpoint (only when explicitly marked)

Compaction enforcement (Architect): the shared rules above, unchanged: the Compaction Decision Table, decay, archive snapshot counts, and the own-memory-only contradiction review.

Cross-agent tracking (Architect): after reviewing Architect's HOT entries, check whether any HOT entry references a ticket, topic, or capability also tracked as open or handed-off in another agent's memory (using the status contributions collected in the status-report phase). Surface any matches under a 'Cross-agent tracking' note in the EOD report. Informational only: a visibility signal, not a blocker.

Dispatch behaviour:

  • If Architect receives the trigger directly:

    1. Status report phase — invoke Builder, Tester, and Router as subagents simultaneously with the status-contribution prompt: "EOD status check. Read your memory file (resolve your real memory file per the Memory Path Resolution protocol in skills/agent-foundations/SKILL.md — check for an active storage plugin at skills/agent-foundations/storage/*.md; do not assume the free-tier memory/<agent>.md path) and return your status contribution: active tickets, dispatched-but-unreturned work, and any blockers. Bullets only." Collect all responses.
    2. Compile and deliver EOD report — using the status contributions plus Architect's own HOT section, compile a single project-grouped report (per the multi-project output format in agent-foundations: group by project, mention the relevant agent owner inside each section). Deliver to the team lead before any consolidation output.
    3. Consolidation phase — run shared steps (including decay rules + LAST_EVENT retirement), then invoke Builder, Tester, and Router as subagents simultaneously with the dreaming consolidation prompt: "End of day consolidation. Run the dreaming skill for [role] workspace. Resolve your real memory file per the Memory Path Resolution protocol in skills/agent-foundations/SKILL.md — check for an active storage plugin at skills/agent-foundations/storage/*.md; do not assume the free-tier memory/<agent>.md path." Wait for all invoked agents to acknowledge.
    4. Confirm to the team lead: "Good night. All agents consolidated."
  • If the trigger arrives via subagent dispatch: run shared steps (including decay rules + LAST_EVENT retirement) only, then acknowledge: "Architect consolidated. Good night."

Builder

Live file: accessed via the active storage plugin using read-memory('builder') Archive file: written via the active storage plugin using archive-memory('builder', date)

Promotion focus: project conventions, coding patterns, resolved edge cases, corrections from the team lead or Architect, unresolved next-day items, transient notes safe to collapse.

Promotion targets:

  • Project conventions and verified practices → agent memory WARM/COLD tiers via write-memory-entry('builder', tier, content) every run
  • Cross-project coding patterns → auto-memory (user-level memory files) when the pattern recurs across 2+ projects
  • Dreaming-managed transient captures → compacted in their original memory file after checkpoint (only when explicitly marked)

Compaction enforcement (Builder): the shared rules above, unchanged: the Compaction Decision Table, decay, archive snapshot counts, and the own-memory-only contradiction review.

Dispatch behaviour:

  • Builder runs end-of-day consolidation when dispatched by Architect as a subagent. Builder does NOT cascade the trigger.
  • If dispatched with the status-contribution prompt: read the HOT section from the agent's memory record via the active storage plugin using read-memory('builder'). Return bullets only — active tickets (branch/ticket reference), dispatched-but-unreturned items, blockers. Do not run consolidation steps; Architect will dispatch again for that separately.
  • If dispatched with the consolidation prompt: run shared steps (including decay rules + LAST_EVENT retirement). Acknowledge: "Builder consolidated. Good night."

Tester

Live file: accessed via the active storage plugin using read-memory('tester') Archive file: written via the active storage plugin using archive-memory('tester', date)

Promotion focus: recurring QA failure patterns, environment gotchas, acceptance criteria that consistently catch regressions, reliable distinguishing tests, blockers, unresolved next-day items, transient notes safe to collapse.

Promotion targets:

  • Recurring QA failure patterns → agent memory WARM/COLD tiers via write-memory-entry('tester', tier, content) every run
  • Environment-specific gotchas → agent memory WARM/COLD tiers via write-memory-entry('tester', tier, content) every run
  • Dreaming-managed transient captures → compacted in their original memory file after checkpoint (only when explicitly marked)

(Tester does not promote to user memory — QA intelligence is project-scoped.)

Compaction enforcement (Tester): the shared rules above, unchanged: the Compaction Decision Table, decay, archive snapshot counts, and the own-memory-only contradiction review.

Dispatch behaviour:

  • Tester runs end-of-day consolidation when dispatched by Architect as a subagent. Tester does NOT cascade the trigger.
  • If dispatched with the status-contribution prompt: read the HOT section from the agent's memory record via the active storage plugin using read-memory('tester'). Return bullets only — QA queue (tickets in state:ready-for-qa or in-progress), blockers, any outstanding verdicts. Do not run consolidation steps; Architect will dispatch again for that separately.
  • If dispatched with the consolidation prompt: run shared steps (including decay rules + LAST_EVENT retirement). Acknowledge: "Tester consolidated. Good night."

Router

Live file: accessed via the active storage plugin using read-memory('router') Archive file: written via the active storage plugin using archive-memory('router', date)

Promotion focus: stable classification patterns, resolved ambiguous-message types, known escalation triggers and outcomes, unresolved next-day items, transient notes safe to collapse.

Promotion targets:

  • Stable routing classification patterns → agent memory WARM/COLD tiers via write-memory-entry('router', tier, content) every run
  • Resolved ambiguous message types → same as above
  • Dreaming-managed transient captures → compacted in their original memory file after checkpoint (only when explicitly marked)

(Router does not promote to user memory.)

Compaction enforcement (Router): the shared rules above, unchanged: the Compaction Decision Table, decay, archive snapshot counts, and the own-memory-only contradiction review.

Dispatch behaviour:

  • Router runs end-of-day consolidation when dispatched by Architect as a subagent. Router does NOT cascade the trigger.
  • If dispatched with the status-contribution prompt: read the HOT section from the agent's memory record via the active storage plugin using read-memory('router'). Return bullets only — any unresolved routing classifications, pending escalations, or relay activity since last session. Do not run consolidation steps; Architect will dispatch again for that separately.
  • If dispatched with the consolidation prompt: run shared steps (including decay rules + LAST_EVENT retirement). Acknowledge: "Router consolidated. Good night."

This is internal-only. Do not post to GitHub issues, PRs, or any external channel.

리뷰

아직 리뷰가 없습니다. 사용해 본 소감을 남겨 주세요.

댓글

로그인 없이 쓸 수 있습니다. 사용 후기, 질문, 작동하지 않은 환경 등을 편하게 남겨 주세요.

아직 댓글이 없습니다. 첫 댓글을 남겨 보세요.

보내면 바로 공개됩니다. 이메일 주소나 전화번호 같은 개인 정보는 쓰지 마세요. URL은 2개까지입니다.

0 / 1,000자

이 양식은 reCAPTCHA로 보호되며 Google 개인정보처리방침 및 서비스 약관이 적용됩니다.

같은 저장소의 스킬

Universal guardrails loaded by every agent. Defines Verify Before Reporting (VBR), Write-Ahead Log (WAL), and the security baseline. Always-on, role-independent.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

Agistra/agistra.dev52026년 10월 14일 업데이트

Use when: architecture mode, architect this, ADR, C4, PlantUML, system boundary, design decision, PRD gap, high ambiguity, multiple technical approaches, security architecture, data architecture, integration risk, implementability gap, story ticket, or epic ticket.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

Agistra/agistra.dev52026년 10월 14일 업데이트

Use when: assumptions audit, audit assumptions, check for hidden assumptions, plan/ticket has ambiguous scope edges, pre-flight before finalizing a ticket, unstated assumptions, or 'what am I assuming'. Surfaces unstated assumptions, ambiguous scope edges, and untested preconditions in a finished plan/ticket/ADR before it is handed to Builder. Optional pass — Architect judges when to apply it; not a mandatory gate on every ticket.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

Agistra/agistra.dev52026년 10월 14일 업데이트

Use when: Tester needs UI state evidence for VBR, or Builder needs to verify an integration wire is observable end-to-end. Powered by agent-browser MCP — token-efficient browser automation (200–400 tokens/page).

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

Agistra/agistra.dev52026년 10월 14일 업데이트

Use when drafting a bug or defect ticket, reviewing one someone else wrote, or deciding whether a reported problem is ready to file. Keeps what the reporter actually saw separate from what the agent later found out, so a reader can tell which lines are testimony and which are collected proof. Trigger phrases: 'file a bug', 'write up this defect', 'triage this report', 'is this ticket ready to file', 'what did the reporter actually see'.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

Agistra/agistra.dev52026년 10월 14일 업데이트

Conducts multi-axis code review. Use before merging any change. Use when reviewing code written by yourself, another agent, or a human. Use when you need to assess code quality across multiple dimensions before it enters the main branch.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

Agistra/agistra.dev52026년 10월 14일 업데이트

Agistra의 스킬 모두 보기

이 스킬의 문제 신고