/selamy-skills:agents-as-iac-modulesfrom selamy-skills
Use when onboarding, scaling, decommissioning, or auditing autonomous agents (or any "software employee") in a fleet. Model each agent as a reusable infrastructure-as-code module whose inputs are its facets, so its whole configuration is declarative, reviewable, and reproducible.
Ships in selamy-skills. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Treat each autonomous agent — each "software employee" — as a reusable infrastructure-as-code MODULE, not a hand-assembled one-off. The agent's configuration becomes a single module instantiation: every meaningful property is an explicit input, the whole thing lives in version control, and the fleet is the set of instantiations.
When an agent is a module, the operations that are otherwise manual and error-prone become declarative:
This is the higher-level pattern. For the file layout of an individual module see [[terraform-module-layout]]; for the rule that infrastructure must be reproducible from source rather than clicked together live see [[iac-not-ad-hoc]].
Every agent decomposes into the same facets. Make each one an explicit input so two agents differ only by their inputs, never by bespoke wiring.
module "agent" {
identity = ... # the account/bot it acts as + its grants
runtime = ... # image, resources, replicas, lifecycle
capabilities = ... # tools / skills / connectors allowed
knowledge = ... # memory / wiki mounts and references
secrets = ... # declared secret-manager mappings (never values)
schedule = ... # always-on / cron / event-triggered
}
│
▼
one instantiated, running agent
The fleet is then just a set of these instantiations side by side in version control. A reviewer can diff one agent against another and see only the facets that differ. A new agent is a copy with new inputs, not a fresh investigation of how agents are built.
Not every step is fully declarative, and pretending otherwise is the failure mode. Some inputs require a one-time MANUAL step that the module cannot perform:
Handle these honestly: declare the reference (the secret mapping, the installed app id) in the module, and DOCUMENT the manual step that produces it as a named prerequisite with a verification check. The goal is "everything that can be declarative is declarative, and the few steps that can't are written down" — not a false claim of full automation.
Read the committed source — not a live instance — and confirm each facet is an explicit input:
What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub selamy-labs/agent-skills --plugin selamy-skills111 skills in this plugin
/adaptive-estimationUse when tracking a slowly-varying latent quantity from noisy measurements with quantifiable uncertainty — a drifting metric, capacity, latency trend, or confidence. Prefer a Kalman-style adaptive estimator over fixed moving averages or static thresholds./adaptive-loop-budgetingUse when an autonomous loop needs explicit limits on attempts, time, cost, tool calls, verification depth, or risk, and a clear stop, continue, yield, or escalate decision./adopt-and-deleteUse when adopting a shared module, library, chart, or service, or doing any consolidation, migration, or refactor that supersedes existing code. The change that adds the replacement must REMOVE what it replaced, in the same atomic change.Other plugins' skills for the same job