Setup
28.9kConfigura GBrain con auto-aprovisionamiento de Supabase o PGLite, inyección en AGENTS.md y primera importación.
- Costo de contexto al activarse
- 7.4k tok
- Tamaño del paquete
- 1 archivo
- Última actualización
- hace 4 días
Archivista universal para archivos personales (Dropbox/B2/Gmail-takeout/disco local). Filtra contenido de alto valor y lo muestra de forma interactiva; exige un allow-list scan_paths explícito en gbrain.yml.
en todo el repo
0–100, la ruta de este skill
último commit aquí
últimos 90 días
75 tok en reposo
11 KB
Funciona con cualquier agente que lea SKILL.md
npx -y skills add garrytan/gbrain --skill archive-crawler --agent claude-codeSe instala solo en este repositorio.
Este skill makes network requests.
Di cualquiera de estas frases y el agente debería cargar este skill.
Convention: see conventions/quality.md for citation rules, exact-phrasing requirements when capturing the user's reactions, and back-link enforcement.
Convention: see _brain-filing-rules.md — this skill is schema-generic: it reads the user's filing rules from the rules JSON instead of hardcoding any specific era / archive layout.
archive-crawler refuses to run unless archive-crawler.scan_paths: is
explicitly set in gbrain.yml. This is a deliberate safety fence against
the agent over-scoping a scan and ingesting sensitive content (tax PDFs,
medical records, credentials).
# gbrain.yml — the allow-list is mandatory
archive-crawler:
scan_paths:
- ~/Documents/writing/
- ~/Dropbox/Archive/
- /mnt/backup/old-letters/
# Optional deny-list inside the allow-list:
# deny_paths:
# - ~/Documents/finances/
# - ~/Documents/medical/
If scan_paths is empty or missing, the skill exits with:
archive-crawler: refusing to run. No `archive-crawler.scan_paths:` allow-list
in gbrain.yml. Add explicit paths the agent is permitted to scan, then re-run.
This is a safety fence — the agent will not infer what's safe to read.
This contract is enforced by src/core/storage-config.ts (mirrors the
db_tracked / db_only allow-list pattern from v0.22.11 storage tiering).
Generic engine for exploring any tree of personal content within an
explicit allow-list. Works on local mounts, Dropbox API targets,
Backblaze B2, Gmail takeouts (.mbox), and similar archives. Filters
for "gold" (the user's own writing, ideas, relationships) and surfaces
it interactively for review. Skips noise (system files, configs, binary
blobs).
A source is any tree of files to explore. Sources have:
local | dropbox | backblaze | gmail-takeout | mbox | pstprojects/<archive-slug>/STATUS.mdEvery archive exploration gets a manifest brain page that tracks:
⬜ unseen / 👀 reviewed /
✅ ingested / ⏭️ skip / 🔥 high-signalBefore showing anything to the user, apply the gold filter:
| Keep (show) | Skip (note existence, don't show) |
|---|---|
| Personal writing (journals, letters, reflections, essays) | System files, configs, package.json, node_modules |
| Conversations (IM logs, email threads with substance) | Binary blobs (images / video) |
| Ideas, theses, frameworks | Receipts, invoices, tax docs |
| Relationship material (letters to / from people who matter) | Spam, newsletters, mailing-list bulk |
| Creative work (poetry, stories, code with soul) | Corrupted / null files |
| Origin stories (first versions of things that became important) | |
| Emotional content (anger, love, grief, discovery) |
When pointed at a new source:
projects/<archive-slug>/STATUS.md with
the full inventory.Work through folders in priority order:
When an item is worth keeping, file it by primary subject per
_brain-filing-rules.md:
originals/<slug>.mdpersonal/<slug>.mdideas/<slug>.mdpeople/<person>/timeline
back-link plus the letter at personal/<slug>.md or originals/<slug>.mdThe skill is schema-generic. It does NOT bake in any specific
era-folder structure (e.g., originals/archive/ for pre-2003,
originals/yc-era/ for post-2019, etc.). The user's filing rules from
_brain-filing-rules.json are read at runtime; the agent decides per-page
where content lands within those sanctioned directories.
Brain page format:
---
title: "[Title or first line]"
type: original
source_type: "[local|dropbox|backblaze|gmail-takeout|mbox|pst]"
source_path: "[path within the allow-listed scan_paths]"
date: "YYYY-MM-DD" # date from the file metadata or content
people: ["person-1", "person-2"]
tags: ["tag-1", "tag-2"]
---
# [Title]
[Summary: what it is, when it's from, why it matters]
**User's reaction:** [exact quote, no paraphrasing]
## Context
[Cross-links to people, concepts, projects.]
---
[Raw source material below the line — full text]
Read directly. Strip HTML tags for display.
.mbox (email archives)import mailbox
mbox = mailbox.mbox('/path/to/file.mbox')
for msg in mbox:
body = ''
if msg.is_multipart():
for part in msg.walk():
if part.get_content_type() == 'text/plain':
body = part.get_payload(decode=True).decode('utf-8', errors='replace')
break
else:
body = msg.get_payload(decode=True).decode('utf-8', errors='replace')
# Apply gold filter
.doc / .docx# .docx (modern)
python3 -c "
import zipfile, xml.etree.ElementTree as ET
with zipfile.ZipFile('/path/to/file.docx') as z:
tree = ET.parse(z.open('word/document.xml'))
print(''.join(t.text or '' for t in tree.iter('{http://schemas.openxmlformats.org/wordprocessingml/2006/main}t')))
"
# .doc (legacy, requires antiword or catdoc)
antiword /path/to/file.doc 2>/dev/null || catdoc /path/to/file.doc 2>/dev/null
.pst (Outlook archives)# Validate first; many PSTs are null bytes
python3 -c "
with open('/path/to/file.pst', 'rb') as f:
print('Valid PST' if f.read(4) == b'!BDN' else 'CORRUPT/NULL')
"
# If valid:
readpst -o /tmp/pst-output /path/to/file.pst
.zip / .tar / .tar.gzExtract to a temp dir, then recurse through the extracted tree.
Note existence + metadata (filename, size, date). Don't show unless the user asks. Flag scans / portraits as potentially personal.
---
title: "[Archive Name] — Ingestion Status"
type: project
created: YYYY-MM-DD
updated: YYYY-MM-DD
source_type: "[local|dropbox|...]"
scan_paths: ["paths from gbrain.yml"]
---
# [Archive Name] — Ingestion Status
## Source
- **Type:** [local|dropbox|...]
- **Allow-listed paths:** [from gbrain.yml]
- **Total files:** [N]
- **Total size:** [X GB]
- **Date range:** [earliest] — [latest]
## Inventory
### [Folder 1]
| Item | Type | Size | Status | Reaction |
|------|------|------|--------|----------|
| file1.txt | text | 2KB | ✅ ingested | 🔥 "exact quote" |
| file2.doc | doc | 15KB | ⏭️ skip | — |
| file3.html | html | 4KB | ⬜ unseen | — |
### [Folder 2]
...
## Priority Queue
1. [Highest priority — why]
2. [Next — why]
...
## Session Log
### YYYY-MM-DD — [Session topic]
- Reviewed: [list]
- Reactions: [exact quotes]
- Ingested: [brain pages created]
- Next: [what's queued]
archive-crawler.scan_paths: set. Hard refusal.
This is the safety contract — never bypass.originals/archive/,
originals/yc-era/). Read filing rules at runtime instead.skills/voice-note-ingest/SKILL.md — same exact-phrasing pattern for
audio captureskills/idea-ingest/SKILL.md — single-link-or-article ingest with
the same primary-subject filing ruleskills/conventions/quality.md — citations, back-links, voiceThis skill guarantees:
writes_to: (when applicable).quality.md, brain-first.md, _brain-filing-rules.md) are followed.The full behavior contract is documented in the body sections above; this section exists for the conformance test.
The skill's output shape is documented inline in the body sections above (see "Output", "Brain page format", or equivalent). The literal section header here exists for the conformance test (test/skills-conformance.test.ts).
Reproducido de garrytan/gbrain bajo licencia MIT. Leer esta página en markdown.
2 archivos en el paquete. Solo se lee SKILL.md al activarse — las referencias se cargan si el skill decide que las necesita.
Requiere definir explícitamente archive-crawler.scan_paths en gbrain.yml antes de ejecutar; sin eso el skill se rehúsa a correr.
Necesita en el PATH:python3
Este repo incluye 75 skills. Si instalas uno, normalmente ya tienes los demás.
Configura GBrain con auto-aprovisionamiento de Supabase o PGLite, inyección en AGENTS.md y primera importación.
Chequeos de salud del brain: aplicación de back-links, auditoría de citas, validación de filing, detección de info obsoleta, páginas huérfanas y benchmarks.
Migra un brain de gbrain-base a la taxonomía de 14 tipos canónicos de gbrain-base-v2 usando gbrain onboard --check y el handler Minion unify-types.
Cuándo y qué recuperar: abre la página del brain de una entidad relevante antes de responder desde memoria.
Operaciones del brain: búsqueda primero, ciclo leer-enriquecer-escribir, atribución de fuentes, enriquecimiento ambiental y back-linking. Leer antes de cualquier interacción con el brain.
Importa exports de ChatGPT, Claude y Perplexity y transcripciones de sesiones como páginas fechadas en conversations/, valida y extrae hechos, y mantiene el archivo sin huecos con detección y backfill.
Transforma volcados de texto crudo de artículos en el brain en páginas estructuradas con resumen ejecutivo, citas textuales, insights clave, por qué importa y referencias cruzadas.
Filtro de calidad previo a la escritura para todo lo que entra al brain: nada de cp/mv en crudo. Resuelve entidades con nombre por registro y aplica el árbol de decisión de dedup leyendo el primer resultado.
Operaciones del brain: búsqueda primero, ciclo leer-enriquecer-escribir, atribución de fuentes, enriquecimiento ambiental y back-linking. Leer antes de cualquier interacción con el brain.