This repository has been archived on 2026-07-09. You can view files and clone it, but cannot push or open issues or pull requests.
agent-knowledge-base-archived/skills/chat-driven-knowledge-sync.md

3.1 KiB

Chat-Driven Knowledge Sync

Purpose

Use this workflow when the user gives an agent the knowledge-base repository link in any Codex or agent chat.

The repository link is the coordination trigger. Realtime heartbeats, background polling, and automatic after-reboot knowledge uploads are not the default workflow.

Startup

  1. Clone or open krustophski/agent-knowledge-base.
  2. Pull or fetch the latest GitHub state when possible.
  3. Read AGENTS.md, projects/index.md, locations/index.md, and mcp-servers/index.md.
  4. Identify the active project and current machine from the user request, hostname, and project files.
  5. Read the active project's status.md, technical-spec.md, repositories.md, decisions.md, notes.md, and agent-log.md when they exist.
  6. Search global knowledge before solving: skills/, problems/, locations/, mcp-servers/, and dialog-summaries/.

During Work

After each meaningful operation, extract durable knowledge:

  • user requirements or corrections;
  • project status and blockers;
  • commands that worked;
  • commands or approaches that failed and are likely to be retried;
  • machine facts, paths, ports, and access notes;
  • repository state, branches, remotes, and merge decisions;
  • reusable setup or troubleshooting procedures.

Put reusable knowledge in global files. Put project-specific state in the project folder.

Dialogue Summaries

If the repository link was introduced into an existing chat, create a compact summary in:

dialog-summaries/YYYY-MM-DD-short-topic.md

Summarize only durable context. Do not paste full transcripts unless the user explicitly asks.

Push Rule

GitHub is the required durable memory target.

  1. Update Markdown files.
  2. Run a quick diff/status check.
  3. Commit the knowledge update.
  4. Pull or rebase against origin/main.
  5. Push to GitHub.

If local Git server notes or local repository notes are written, duplicate the durable knowledge to the GitHub knowledge base in the same session.

Project Repository Push Rule

When the agent changes an actual project repository:

  • verified working solution: commit and push it as a restore point in the project repository, create/push a stable tag for important states, and record the commit/tag in the GitHub knowledge base;
  • useful failed or incomplete attempt: commit and push it only to a separate branch such as attempt/<topic>, debug/<topic>, or failed/<topic>, then record why it failed in the GitHub knowledge base;
  • useless or unsafe attempt: do not push it to the project repository, but record the lesson in problems/ or the project log.

Do not merge unverified or failed attempts into main or another stable branch.

Disabled By Default

Do not start persistent realtime sync for knowledge updates:

  • no scheduled garage-agent-runner by default;
  • no heartbeat polling by default;
  • no daemon that auto-commits after reboot by default.

If a live runner is needed for a specific diagnostic task, the user must ask for it explicitly. After the task, return the machine to chat-driven sync unless the user explicitly says to keep monitoring.