agentleFS
Foxfire1stFoxfire1st/agents-remember/skills/c-00-initialize-memory-repo/SKILL.md

c-00-initialize-memory-repo

Skill27 starsChanged 6 months agoMITView on GitHub

Initialize or repair the Agents Remember memory root for a target repository. Defaults to repo-local internal memory; creates an external memory repo only when the developer explicitly asks for external memory.

  • Reads credentials

The file

Show its rules and text

We split this skill into the rules it gives an agent

17 rules. About 0 are common, 12 are distinctive, and 5 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈12

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 5

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Create the minimal memory root required before onboarding or task workflows can use Agents Remember for a target repository.

    line 8
  2. Very specific:

    Use c-08-ar-coordination-context-resolver to inspect an existing repository's active context.

    line 18
  3. Distinctive:

    Use the Agents Remember MCP setup tools as the normal installed runtime entry points:

    line 30
  4. Very specific:

    Use memory_init for creating or repairing the configured memory root for a repo.

    line 43
  5. Distinctive:

    Never overwrite an existing memory file without explicit user approval.

    line 53
  6. Distinctive:

    Create missing directories and files only.

    line 54
  7. Distinctive:

    Keep starter files generic.

    line 55
  8. Distinctive:

    If the resolved memory root or coordination root points outside the intended workspace, state the resolved absolute path before writing.

    line 56
  9. Distinctive:

    Default internal scaffolding must not create or select an external memory repo.

    line 57
  10. Very specific:

    Do not create onboarding content.

    line 59
  11. Distinctive:

    Do not resolve or create an external memory repo.

    line 69
  12. Distinctive:

    Verify the coordinator runtime exists by checking for:

    line 75
  13. Very specific:

    If the runtime is missing, stop and ask the developer to request (preview first with runtime_install(dry_run=true)):

    line 84
  14. Distinctive:

    Check for these paths under the resolved memory root:

    line 96
  15. Distinctive:

    Create only missing directories:

    line 117
  16. Very specific:

    When creating an external memory Git repository, add docs/.gitkeep if docs/ would otherwise be empty so the scaffold can be committed.

    line 128
  17. Distinctive:

    Create only files that do not already exist.

    line 132

≈ “Common” is an estimate: at least 1 in 5 of the 213,895 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

c-00-initialize-memory-repo Initialize Memory Repo

Create the minimal memory root required before onboarding or task workflows can use Agents Remember for a target repository.

This skill initializes durable repo memory through MCP memory_init. It does not install the coordinator runtime, expose harness skills, create task worktrees, or generate onboarding content. Request MCP runtime_install only when the coordinator runtime scaffold is missing or stale. Harness skill exposure for first-run setup comes from the copied starter package, not from this skill. Use c-03-repo-bootstrap after the memory scaffold exists when the developer wants onboarding content generated.

Use c-08-ar-coordination-context-resolver to inspect an existing repository's active context. This skill creates or repairs missing memory scaffolding; it does not replace the c-08-ar-coordination-context-resolver skill as the normal resolver.

Inputs

  • repo_id: configured MCP repository ID whose memory is being initialized. This is the normal installed runtime input.
  • code_repository_root: root directory of the code repository whose memory is being initialized. Use this only for conceptual review or source-debugging; normal installed runtime calls identify the configured repository by repo_id.
  • topology: internal by default. Use external only when the developer explicitly asks for an external memory repo.
  • coordination_root: supplied by MCP settings for normal installed runtime calls.
  • mode: create-missing by default. Use repair only when the developer explicitly asks to fix existing memory scaffold files.

MCP Tools

Use the Agents Remember MCP setup tools as the normal installed runtime entry points:

Preview first. These setup tools now apply by default (dry_run defaults to false). For any effectful run, call once with dry_run=true to inspect the plan, confirm it, then run the real apply (omit dry_run).

memory_init(repo_id="<repo-id>", dry_run=true, initialize_git=true)   # preview
memory_init(repo_id="<repo-id>", initialize_git=true)                 # apply
runtime_install(include_benchmarks=false, install_provider_deps=false)

Use memory_init for creating or repairing the configured memory root for a repo. Use runtime_install only when the coordinator runtime scaffold itself is missing or stale. Do not use skills_install as part of package-based first-run setup; copied starter packages already carry the harness skills. skills_install remains available only for manual maintenance or non-package installs. The skill tree is instruction-only; installed and development workflows use the MCP/package route.

Safety Rules

  1. Never overwrite an existing memory file without explicit user approval.
  2. Create missing directories and files only.
  3. Keep starter files generic; do not invent project-specific tools, docs, sources, or onboarding.
  4. If the resolved memory root or coordination root points outside the intended workspace, state the resolved absolute path before writing.
  5. Default internal scaffolding must not create or select an external memory repo.
  6. External-memory setup must not install coordinator runtime files; if the coordinator runtime is missing, tell the developer to request MCP runtime_install first.
  7. Do not create onboarding content. An empty onboarding/ directory is enough for the c-08-ar-coordination-context-resolver skill to resolve the memory root; the c-03-repo-bootstrap skill owns onboarding generation.

Procedure

1. Resolve The Memory Root

Default internal memory:

  1. Resolve code_repository_root.
  2. Set memory_root to <code_repository_root>/ar-memory.
  3. Do not resolve or create an external memory repo.

Explicit external memory:

  1. Resolve code_repository_root.
  2. Resolve coordination_root from the developer-provided path or the installed runtime root.
  3. Verify the coordinator runtime exists by checking for:
<coordination-root>/AGENTS.md
<coordination-root>/skills/
<coordination-root>/tasks/
<coordination-root>/memory-repos/
  1. If the runtime is missing, stop and ask the developer to request (preview first with runtime_install(dry_run=true)):
runtime_install()
  1. Set memory_root to <coordination-root>/memory-repos/ar-<code-repository-name>.
  2. Initialize the external memory root as a Git repository when it is newly created or when it exists without .git.

2. Inspect Existing State

Check for these paths under the resolved memory root:

system/settings.md
system/settings.json
system/sources.md
system/tools.md
onboarding/
docs/

For external memory, also check:

.git/

Report which are present and which are missing. If everything exists, stop with a clean summary.

3. Create Missing Directories

Create only missing directories:

<memory-root>/
  system/
  onboarding/
  docs/

For external memory, ensure <coordination-root>/memory-repos/ exists before creating the per-repo memory root. Do not create or modify coordinator runtime directories such as skills/, tasks/, worktrees/, notes/, or temp/.

When creating an external memory Git repository, add docs/.gitkeep if docs/ would otherwise be empty so the scaffold can be committed.

4. Create Missing Starter Files

Create only files that do not already exist.

system/settings.md

# Settings

This memory root stores durable context for Agents Remember.

Use this Markdown file for human and agent instructions, scaffold notes, and operational context. Machine-readable storage, path-rule, and cross-repo settings live in `system/settings.json`.

Do not duplicate active `pathRules` here as the authoritative machine source when `system/settings.json` exists.

## Scaffold

| Layer         | Location               | Purpose                                                     |
| ------------- | ---------------------- | ----------------------------------------------------------- |
| instructions  | `system/settings.md`   | Human and agent guidance, path contract, and scaffold notes |
| path settings | `system/settings.json` | Machine-readable storage, pathRules, and cross-repo data    |
| sources       | `system/sources.md`    | External and domain documentation registry                  |
| tools         | `system/tools.md`      | Repo-specific commands, checks, and local tool notes        |
| onboarding    | `onboarding/`          | Durable repo and file-level code commentary                 |
| docs          | `docs/`                | Local domain docs, mirrors, and reference material          |

system/settings.json

For internal memory:

{
  "version": 1,
  "onboarding": {
    "storage": {
      "mode": "repo-sidecar"
    },
    "pathRules": {
      "include": {
        "paths": ["README.md", "docs/**", "src/**"],
        "fileTypes": [".md", ".py", ".ts", ".tsx"]
      },
      "exclude": {
        "paths": [
          "node_modules/**",
          "vendor/**",
          "dist/**",
          "build/**",
          "coverage/**",
          ".cache/**",
          ".pytest_cache/**",
          ".venv/**",
          ".idea/**",
          ".vscode/**",
          ".env",
          ".env.*",
          "**/generated/**",
          "**/*.generated.*",
          "**/*.Zone.Identifier",
          "**/*:Zone.Identifier"
        ],
        "fileTypes": [".png", ".jpg", ".zip"]
      }
    }
  },
  "crossRepo": {
    "allow": []
  }
}

For external memory:

{
  "version": 2,
  "onboarding": {
    "storage": {
      "mode": "memory-repo"
    },
    "pathRules": {
      "include": {
        "paths": ["README.md", "docs/**", "src/**"],
        "fileTypes": [".md", ".py", ".ts", ".tsx"]
      },
      "exclude": {
        "paths": [
          "node_modules/**",
          "vendor/**",
          "dist/**",
          "build/**",
          "coverage/**",
          ".cache/**",
          ".pytest_cache/**",
          ".venv/**",
          ".idea/**",
          ".vscode/**",
          ".env",
          ".env.*",
          "**/generated/**",
          "**/*.generated.*",
          "**/*.Zone.Identifier",
          "**/*:Zone.Identifier"
        ],
        "fileTypes": [".png", ".jpg", ".zip"]
      }
    }
  },
  "crossRepo": {
    "allow": []
  }
}

onboarding.storage decides where eligible onboarding artifacts live. onboarding.pathRules decides which source paths and file types are eligible for onboarding. Cross-repo policy belongs in the memory layer, not in untracked coordinator runtime files.

system/sources.md

# Sources

## Domain Documentation

No domain documentation configured yet.

Add project-specific docs, local mirrors, API references, and canonical source links here before creating durable onboarding that depends on external behavior.

## External References

No external references configured yet.

## Notes

- Prefer local mirrors for reading when available.
- Link onboarding `Docs References` rows to canonical source URLs when a canonical online reference exists.
- If no relevant domain documentation exists for a task, record what was checked instead of implying the search space was complete.

system/tools.md

# Tools

## Checks

No repo-specific checks configured yet.

Add test, lint, typecheck, build, and smoke-check commands for each onboarded repo.

## Commands

No repo-specific commands configured yet.

## Runtime Notes

Record environment setup, local service assumptions, MCP notes, and command caveats here.

5. Report Result

Summarize:

  • resolved topology
  • resolved memory root
  • resolved coordination root when external memory is used
  • whether an external Git repository was initialized
  • directories created
  • files created
  • files left untouched
  • next suggested skill, usually c-03-repo-bootstrap when the developer wants onboarding content under the resolved onboarding root

Common Outcomes

Fresh Internal Memory

Expected result: create <code-repository-root>/ar-memory/ with system/, onboarding/, and docs/, then tell the developer the repo is ready for optional repo bootstrap.

Fresh External Memory

Expected result: create <coordination-root>/memory-repos/ar-<repo-name>/, initialize Git if needed, add system/, onboarding/, and docs/, then tell the developer the repo is ready for optional repo bootstrap.

Partial Memory Scaffold

Expected result: create only missing files or directories. Preserve existing docs/, system/, and onboarding content.

Existing Complete Memory Scaffold

Expected result: make no changes and report that the memory root is already initialized.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.