flow-prune-agent-setup
Skill1 starsChanged 47 days agoMITView on GitHub
Audit and tidy a coding agent's configuration: instructions, memory, settings, hooks, MCP servers and plugins. Use when that setup has grown noisy, conflicting or stale. Feeds `flow-handoff`.
In this repository38 other files it gives its agents.
- AGENTS.mdAGENTS.md
- llms.txtllms.txt
- flow-a11ySkill
- flow-adversarial-reviewSkill
- flow-animateSkill
- flow-apiSkill
- flow-benchmarkSkill
- flow-brainstormSkill
- flow-commitSkill
- flow-data-migrateSkill
- flow-depsSkill
- flow-designSkill
- flow-diagnoseSkill
- flow-docsSkill
- flow-git-fixSkill
- flow-handoffSkill
- flow-migrateSkill
- flow-observeSkill
- flow-onboardSkill
- flow-orchestrateSkill
- flow-planSkill
- flow-pr-fixSkill
- flow-prototypeSkill
- flow-redesignSkill
- flow-refactorSkill
- flow-releaseSkill
- flow-repo-briefSkill
- flow-reviewSkill
- flow-shipSkill
- flow-simplifySkill
- flow-specializeSkill
- flow-stylesSkill
- flow-testSkill
- flow-triageSkill
- flow-uiSkill
- flow-verifySkill
- flow-workSkill
- flow-write-skillSkill
The file
We split this skill into the rules it gives an agent
4 rules. About 0 are common, 3 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈3
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 16
Instructions: every instruction file the host loads (for example AGENTS.md or a host-specific equivalent, rules directories) at user, …
- Distinctive: line 28
Run parallel read-only audits only when authorized and independent.
- Distinctive: line 35
Use the owning installer or plugin manager.
- Very specific: line 54
Use flow-handoff only if unresolved decisions or a later session need a continuation record.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 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.
Files
Prune an agent setup
Find stale or conflicting instructions and configuration, then apply only the cleanup the user authorizes. Judge by ownership, active scope, and effective behavior, not age.
Phase 1: Discover effective sources
Identify host and version, active project or profile, CLI overrides, and managed layers before attributing behavior to a file. Check the host's current official docs for locations and precedence; schemas differ between hosts and versions, and not every settings file is user-owned. Never print credentials.
- Instructions: every instruction file the host loads (for example AGENTS.md or a host-specific equivalent, rules directories) at user, project and local scope.
- Configuration: each settings layer (user, project, local, managed), including permissions, hooks, enabled plugins or extensions, and MCP server entries. Treat managed, system and CLI overrides as read-only context.
- Capabilities: skills, agents and plugins in user and project directories, plus any memory store.
- Locate skill ownership through its supported manager (plugin manager,
npx skills, or the owning installer).
Phase 2: Four audits
- Instructions: stale paths, redundant or contradictory rules, procedures that belong in a focused skill, rules tooling already enforces. Verify references first.
- Memory: outdated facts and duplicates, with source, age, and intended consumer. Unknown relevance is not evidence for deletion. Reconcile any memory index.
- Settings and integrations: effective values, obsolete hooks or MCP servers, conflicting scopes. Distinguish allow, ask, and deny entries; removing a protective rule changes behavior even when the tool looks unused.
- Skills, agents, and plugins: overlap, routing quality, inactive workflows, ownership, actual discovery. Inspect the host's enabled-plugins setting (for example
enabledPluginsin settings.json) where it has one; do not assume that schema elsewhere. Separate installed links from source directories and host-owned bundles.
Run parallel read-only audits only when authorized and independent. Merge into one punch list: item, source and owner, reason, evidence, consequence, confidence, proposed action. Label uncertain candidates and false positives.
Phase 3: Apply the requested scope
- Audit-only request: report the punch list and stop.
- Explicit cleanup: perform the authorized reversible edits without re-asking per item. Ask only about consequential uncertainty or unauthorized destructive actions. Never auto-delete unknown assets.
- Back up changed settings, preserve unrelated keys, and validate the resulting format and effective behavior.
- Use the owning installer or plugin manager. Unlinking an install is not deleting its source. Complete an explicitly requested user-owned skill removal through the supported mechanism instead of handing the user an unsafe shell command. Never edit managed or plugin-owned sources directly.
Phase 4: Confirm behavior
Reinspect active values and discovery. Explain removed and retained items and remaining conflicts. Distinguish disk state from cached session or UI state; do not keep rewriting correct files because the current session has not refreshed.
Anti-patterns
- Treating old or unused entries as proven obsolete.
- Auditing one settings file and claiming full effective coverage.
- Removing deny rules, plugin-owned assets, caches, or history under a vague cleanup request.
- Repeated approval questions after the user named the exact cleanup.
Done when
- Findings rest on effective scope, provenance, and a concrete behavioral consequence.
- Authorized changes validate and preserve unrelated setup; uncertain items stay explicit.
- Actual discovery and effective state are checked, or the limits are reported.
Use flow-handoff only if unresolved decisions or a later session need a continuation record.
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
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.

