brain-ingest-gate
Pre-write quality gate for content entering the brain. No raw copies: a bare cp/mv into the brain repo is a bug. Before any new page lands, resolve named…
Schedule management with staggering, quiet hours, and wake-up override. Validates schedules, prevents collisions, and gates delivery during quiet hours.
$ npx -y skills add garrytan/gbrain --skill cron-scheduler --agent claude-codeHow it fires
How this skill gets triggered: by you, by Claude, or both.
/cron-schedulerContext preview
The summary Claude sees to decide when to auto-load this skill.
Schedule management with staggering, quiet hours, and wake-up override. Validates schedules, prevents collisions, and gates delivery during quiet hours.
name: cron-scheduler version: 1.0.0 description: | Schedule management with staggering, quiet hours, and wake-up override. Validates schedules, prevents collisions, and gates delivery during quiet hours. triggers: - "schedule a job" - "cron" - "quiet hours" - "what jobs are running" tools: - search - get_page - put_page mutating: true
> **Convention:** See `skills/conventions/test-before-bulk.md` — test every cron job on 3-5 items first.
This skill guarantees:
1. **Define job.** Name, schedule (cron expression), skill to run, timeout. 2. **Validate schedule.** Check no collision with existing jobs (5-minute offset rule).
3. **Check quiet hours.** Default: 11 PM - 8 AM local time.
4. **Register with host scheduler.** OpenClaw cron, Railway cron, crontab, or process manager. **Each registered entry should execute via Minions, not `agentTurn`.** See `skills/conventions/cron-via-minions.md` for the rewrite pattern (PGLite uses `--follow`, Postgres uses fire-and-forget + `--idempotency-key` on the cycle slot). GBrain's v0.11.0 migration auto-rewrites entries for built-in handlers; host-specific handlers need a code-level registration per `docs/guides/plugin-handlers.md`. 5. **Write thin prompt.** Job prompt is one line: "Read skills/{name}/SKILL.md and run it."
Every cron job MUST be idempotent:
Job configuration saved. Report: "Job '{name}' scheduled at {cron expression}. Next run: {time}."
When the brain has 2+ active sources (anything `gbrain sources list` shows with a non-null `local_path` that isn't archived), use one consolidated cron line instead of N per-source entries.
**Preferred (multi-source)**:
*/5 * * * * gbrain sync --all --parallel 4 --workers 4 --skip-failed
This replaces N per-source lines AND auto-picks-up future sources without a crontab edit. Concurrency budget: `parallel × workers × 2 ≈ 32` connections during the wave (each per-file worker opens its own 2-connection pool). Stay under your Postgres `max_connections` setting.
**Avoid (legacy)**: separate `gbrain sync --source default` and `gbrain sync --source zion-brain` entries staggered by 5 minutes. They require manual deconfliction every time a new source is added, and a slow source can race a fast source on the legacy global `gbrain-sync` lock (v0.40.3.0+ uses per-source `gbrain-sync:<sourceId>` locks but the per-source cron pattern doesn't benefit from the parallelism that `--all --parallel` actually delivers).
`gbrain doctor` surfaces the recommended line as a `sync_consolidation` check whenever it detects 2+ active sources. Paste-ready from there.
`gbrain sync --all --parallel N --workers N` would replace them with one line that auto-picks-up future sources.
Give the agent you already use a memory you control. GBrain stores explicit facts with their sources, supports corrections and withdrawal, and makes the same memory available across your agents.
Repo: garrytan/gbrain
Pre-write quality gate for content entering the brain. No raw copies: a bare cp/mv into the brain repo is a bug. Before any new page lands, resolve named…
When you report a brain page to the user — created, edited, committed, or relayed from a subagent — a working link is part of the deliverable, in the SAME…
Brain knowledge base operations. The core read/write cycle: brain-first lookup, read-enrich-write loop, source attribution, ambient enrichment, back-linking.…
Deduplicate and synthesize raw concept stubs into a tiered intellectual map (T1 Canon to T4 Riff), tracing idea evolution across sources over time. Transforms…
Token-hygiene audit of the always-loaded context stack — CLAUDE.md, AGENTS.md, auto-memory MEMORY.md, and the bootstrap-rendered identity files (SOUL.md,…
When the user corrects a factual error, root-cause it immediately. Don't just note the correction — trace the error to its source, fix the source, and prevent…