Skip to content
Back to skills

Brain

ASecurity

Turns a finished task's audit log into reusable rules and prunes scratch files. Use at the end of a long task to record lessons and to detect drift in the project's world model.

  • 24 stars
  • 0 votes
  • 0 copies
  • 5 views
  • Added October 14, 2026
ai-agentsgosql

Security analysis

A100/100

Pro scans all 21 files and shows the line behind each finding

Scanned November 22, 2026

npx -y skills add andreibesleaga/GABBE --skill brain --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Brain?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Brain
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/andreibesleaga-brain-a32fae22/badge)](https://www.skillsdirectory.com/skills/andreibesleaga-brain-a32fae22)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: episodic-consolidation
description: Turns a finished task's audit log into reusable rules and prunes scratch files. Use at the end of a long task to record lessons and to detect drift in the project's world model.
triggers: [episodic consolidation, consolidate lessons, end of long task, prune scratch files, world model drift]
tags: [brain]
context_cost: high
tools: [write_to_file, grep_search]
---
# Episodic Consolidation Skill

## Goal
This skill mimics the brain's "Sleep" process (Hippocampus to Neocortex transfer). Use it at the end of a long task (Task Boundary).

## Steps
## 1. The Consolidation Process
1.  **Replay:** Review the `AUDIT_LOG.md` or Session History.
2.  **Extract:** Identify "Generalized Rules" from specific events.
    *   *Event:* "I fixed a bug in `auth.go` caused by nil pointer."
    *   *Rule:* "Always check for nil in `auth.go` User structs."
3.  **Store:** Write this Rule to `agents/memory/semantic/rules.md` (create the file if it does not exist).

## 2. Identifying Episodic Drifts
Check if the "Story" of the project has changed.
*   **Drift:** "We used to use SQL, now we use NoSQL."
*   **Action:** Update `PROJECT_CONTEXT.md` (the world model; create it from `templates/brain/PROJECT_CONTEXT_TEMPLATE.md` if missing) to reflect this new reality.

## 3. Pruning (Forgetting)
Active forgetting is crucial.
*   **Action:** List temporary scratchpads and `tmp/` files that are no longer needed, then delete them only after the human confirms the list. Never list audit logs, snapshots or deployment records.

## Constraints
- A rule needs at least 3 observations and a source (log row, test or file).
- Rules are additive; a rule must not contradict the Constitution or an architecture rule.

## Output Format
The new or changed rules (with their sources), any change to `PROJECT_CONTEXT.md`, and the list of scratch files proposed for deletion.

## Limits and safety
- Write a rule only after the pattern appeared at least 3 times and a source backs it; check it against `architecture-governance.skill` and the Constitution.
- Strip names, credentials and personal data from every rule; keep the rule general.
- Never prune `AUDIT_LOG.md`, snapshots or deployment records. Delete scratch files only after the human confirms your list.
- A temporary waiver or hack is an incident, not a change to the world model; do not record it as drift.
- Ask the human to review `rules.md` at the next checkpoint.

Files in this skill

  • README.md3.8 KB
  • active-inference.skill.md4.4 KB
  • brain-mode.skill.md8.5 KB
  • cognitive-architectures.skill.md3.3 KB
  • cognitive-testing.skill.md5.2 KB
  • consciousness-loop.skill.md3.8 KB
  • cost-benefit-router.skill.md6.2 KB
  • episodic-consolidation.skill.md3.6 KB
  • epistemology-knowledge.skill.md4 KB
  • global-workspace.skill.md3.8 KB
  • learning-adaptation.skill.md5.2 KB
  • loki-mode.skill.md15.9 KB
  • neuroscience-foundations.skill.md3.8 KB
  • scripts/active_inference_loop.py2.6 KB
  • scripts/cognition_test.py2.2 KB
  • scripts/global_workspace.py2.8 KB
  • self-improvement.skill.md5.7 KB
  • sensory-motor.skill.md4 KB
  • sequential-thinking.skill.md3.9 KB
  • working-memory.skill.md4.2 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in ai-agents →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.