samzong/agent-brains / skills/agent-loader
agent-loader
VerifiedLoad or list repo-scoped and user-scoped agent brains. Use when the user asks to load an agent by name, list available agents, inspect agent descriptions or workflows, or start a session or task with a personal agent brain.
| File | Kind | Size |
|---|---|---|
| SKILL.md | skill md | 3.8 KB |
| scripts/list_agents.py | script | 6.0 KB |
SKILL.md
View on GitHub---
name: agent-loader
description: Load or list repo-scoped and user-scoped agent brains. Use when the user asks to load an agent by name, list available agents, inspect agent descriptions or workflows, or start a session or task with a personal agent brain.
---
# Agent Loader
Use this skill to list and load agent brains from two scopes:
```text
REPO: $CWD/.agents/agents up to $REPO_ROOT/.agents/agents
USER: $HOME/.agents/agents
```
Repo scope is searched from the current working directory upward to the repository root. User scope is searched after repo scope. If the same agent name exists in multiple places, the first discovered agent wins.
For a global setup, clone this repository to `~/.agents/agent-brains`, then symlink `~/.agents/agents` to `~/.agents/agent-brains/agents`.
The discovery roots can be overridden with `AGENT_BRAINS_ROOT` or the script's `--root` option. Overrides use `custom` scope.
## Modes
### List Agents
Use when the user asks what agents exist, asks for agent names, or is unsure which agent to load.
Run the bundled script:
```bash
uv run python skills/agent-loader/scripts/list_agents.py
```
Report each agent's `name`, `description`, `scope`, and `path`. Discovery only reads `AGENTS.md` frontmatter; it does not read the body or any other core file. If an agent has no description, say so directly.
### List Workflows
Use when the user asks what workflows an agent has, or when loading an agent and a lightweight workflow summary is useful.
Run:
```bash
uv run python skills/agent-loader/scripts/list_agents.py --agent <name> --workflows
```
The script resolves `<name>` through the same repo/user discovery order, then reads only each workflow's `WORKFLOW.md` frontmatter. Report each workflow's `name`, `description`, and `path`. Do not read workflow bodies just to list workflows.
### Load An Agent
Use when the user names an agent or asks to start working as an agent.
First resolve the agent path:
```bash
uv run python skills/agent-loader/scripts/list_agents.py --agent <name>
```
The script prints:
```text
name<TAB>description<TAB>scope<TAB>path
```
For the resolved `path`, read in this order:
1. `path/AGENTS.md`
2. `path/SOUL.md`
3. `path/MEMORY.md`
Then acknowledge the active agent and summarize:
- identity
- main responsibilities
- key operating rules
- available skills
- available workflows
Do not read every file under `memories/` by default. Read a memory file only when `AGENTS.md`, `MEMORY.md`, or the user's task points to it.
Do not read every `skills/*/SKILL.md` by default. Read a skill only when the task matches that skill or the agent's `AGENTS.md` tells you to use it for the current task.
Do not read every `workflows/*/WORKFLOW.md` by default. Use the workflow frontmatter list first; read a workflow body only when the current task matches it or the user asks for it.
## Validation
If the agent cannot be resolved, list available agents instead of guessing.
If `AGENTS.md`, `SOUL.md`, or `MEMORY.md` is missing, report the missing file and load only the existing files.
If `AGENTS.md` lacks frontmatter with `name` and `description`, report that the agent brain needs metadata cleanup.
If `skills/` contains files directly under it instead of `skills/SKILL_NAME/SKILL.md`, report that the agent brain violates the current skill layout.
If `workflows/` contains files directly under it instead of `workflows/WORKFLOW_NAME/WORKFLOW.md`, report that the agent brain violates the current workflow layout.
If a `WORKFLOW.md` lacks frontmatter with `name` and `description`, report that the workflow needs metadata cleanup.
## Boundaries
This skill loads agent context. It does not create, update, or audit agent brains unless the user explicitly asks for that work.
For creating, updating, or auditing agent brains, load `agent-creator`.
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| reverse-engineer-anythingmorluto/reaReverse engineer native, managed, Electron/JavaScript, packaged, firmware, and browser targets with REA, and build agent environments (AgentEnv bundles) of web applications from a live instance or a capture, and of Linux desktop apps with a task from a request. Use shipped-artifact or requested runtime evidence to explain features, compare versions, decompile code, or guide a reconstruction. Skip REA for ordinary source-repository architecture analysis. | Stars: 472k | Updated | Claude CodeCodex | Verified | Install |
| diagnosing-superpowersobra/superpowersUse when a superpowers session went wrong and your human partner wants to know why — repeated work, ignored plans, stumbles, poor results, a skill that didn't fire, "it took too long", "why is it so expensive", "what is it doing" — or wants to build a bug report for the superpowers maintainers, for the current session or a past one identified by id or path, on any harness. | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| dispatching-parallel-agentsobra/superpowersUse when facing 2+ independent tasks that can be worked on without shared state or sequential dependencies | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| executing-plansobra/superpowersUse when executing an implementation plan in the current session as the implementer yourself — your human partner chose inline execution, or no subagent tool is available | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |