agentleFS
kenhuanguskenhuangus/defense-factory-skills/skills/build-inventory/SKILL.md

build-inventory

Skill2 starsChanged 47 days agoMITView on GitHub

Enumerates services, repos, APIs, and related assets into schema-valid inventory files for the Defense Factory Inventory phase. Use when starting discovery or when asset ownership is unknown.

We split this skill into the rules it gives an agent

5 rules. About 0 are common, 4 are distinctive, and 1 is very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈4

    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
  1. Distinctive:

    After prepare skills (policy + optional threat model)

    line 13
  2. Very specific:

    When ownership routing needs accurate asset_ids

    line 15
  3. Distinctive:

    Read access to repos, cloud inventories, manifests, or deployment configs in scope.

    line 21
  4. Distinctive:

    Do not scan or inventory out-of-scope third-party production systems without authorization.

    line 50
  5. Distinctive:

    Do not store secrets (API keys, passwords) inside inventory notes.

    line 51

≈ “Common” is an estimate: at least 1 in 5 of the 308,232 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

build-inventory

Phase: Inventory
Style: Blue (defensive)

When to use

  • After prepare skills (policy + optional threat model)
  • Before security-scan / security-diff-scan
  • When ownership routing needs accurate asset_ids

Preconditions

  1. Authorization / ownership confirmed per SECURITY.md.
  2. .defense-factory/ exists (python scripts/init_workspace.py).
  3. Read access to repos, cloud inventories, manifests, or deployment configs in scope.

Procedure

  1. Collect sources: git remotes, package manifests, Docker/K8s/IaC, API gateways, service catalogs, README deploy docs.
  2. For each asset, create an entry matching schemas/inventory-entry.schema.json:
    • id (stable, e.g. inv-<type>-<name>)
    • name, asset_type, owner, environment, discovered_at, source
    • Optional urls, repos, tags, exposure, notes
  3. Write:
    • .defense-factory/inventory/inventory.json — { "entries": [ ... ] }
    • Optionally one file per asset under .defense-factory/inventory/entries/
  4. Validate:
python <skills-repo>\scripts\validate_artifacts.py .defense-factory\inventory\inventory.json --schema inventory-entry
  1. Flag assets with owner unknown; list them for route-ownership later.
  2. Cross-check threat-model priorities; tag high-priority assets.

Required outputs

PathSchema
.defense-factory/inventory/inventory.jsoninventory-entry (entries array)

Stop / refuse

  • Do not scan or inventory out-of-scope third-party production systems without authorization.
  • Do not store secrets (API keys, passwords) inside inventory notes.

Next phase

security-scan (full) or security-diff-scan (change-scoped).

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.