Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add RailtownAI/railtracks --skill agent-buildergit clone --depth 1 https://github.com/RailtownAI/railtracksWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/railtownai/railtracks/agent-builder)<a href="https://agentmods.dev/skills/railtownai/railtracks/agent-builder"><img src="https://agentmods.dev/badge/skills/railtownai/railtracks/agent-builder/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/railtownai/railtracks/agent-builder"><img src="https://agentmods.dev/badge/skills/railtownai/railtracks/agent-builder.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00037 | $0.02453 |
| Opus 5.5 | $0.00015 | $0.00981 |
| Sonnet 5.5 | $0.00007 | $0.00491 |
| Haiku 4.5 | $0.00004 | $0.00245 |
Grade A, and why
agent-builder scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 227 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Build a Railtracks Agent
The user wants to build an agent using the railtracks framework: $ARGUMENTS
How railtracks works
- Tools are plain Python functions decorated with
@rt.function_node. Type hints become the parameter schema; the docstring becomes the description. - Agents are created with
rt.agent_node(). Its behaviour depends on whether tools or a structured output schema are passed (see below). - Flows wrap an agent or async function as the entry point and handle execution, config, and context.
rt.call()is used inside async workflows to call agents or nodes directly.- Results:
flow.invoke(),await flow.ainvoke()andawait rt.call()on an agent return a response object. Read it with.content: astrfor a text agent, an instance of your schema for anoutput_schemaagent. The full conversation is on.message_history. When the agent was given anoutput_schema,.structuredalso returns that instance; otherwise.textalso returns thestr.
What agent_node builds
rt.agent_node() builds one node behind the scenes — there is no separate named type to pick. What you pass changes what the agent does at runtime:
| Passed | Behaviour |
|---|---|
Neither tool_nodes nor output_schema |
Plain chat, text output |
output_schema only |
Structured output, no tools |
tool_nodes only |
Tool-calling loop, text output |
LLM Providers
# Example model IDs; use the provider and model the project already uses
rt.llm.AnthropicLLM("claude-sonnet-5-5")
rt.llm.OpenAILLM("gpt-6-luna")
rt.llm.GeminiLLM("gemini-3.8-flash")
rt.llm.OpenAICompatibleProvider(
"my-model", api_base="https://api.example.com/v1", api_key="..."
)
Steps
- Read the existing code — check what files already exist in the project. Understand the task before writing anything.
- Identify what tools the agent needs — each capability the agent should have becomes a
@rt.function_node. Ask the user to clarify if it's not obvious from$ARGUMENTS. - Define the tools — write each tool as a Python function with:
- Full type hints on all parameters and return value
- A docstring with a one-line summary and
Args:/Returns:sections - Real implementation (or a clear stub with a TODO if the user needs to fill it in)
- Define the agent — call
rt.agent_node()with (note: it returns a class/type, so use PascalCase for the variable name):- A descriptive name
tool_nodeslisting the tools (if any), oroutput_schemaas a PydanticBaseModelfor structured output — one or the other, never both (passing both raisesNodeCreationError)llm— follow the provider the project already uses, or one whose API key is configured (providers and their key variables: https://docs.railtracks.org/documentation/getting_started/llm_setup/); otherwise ask the user which LLM to usesystem_message— a clear, specific system prompt
- Wrap in a Flow — create
rt.Flow(name="...", entry_point=MyAgent)for simple cases. For multi-step or multi-agent workflows, define anasync deffunction as the entry point and useawait rt.call(MyAgent, ...)inside it. - Add invocation code — include a
if __name__ == "__main__":block that callsflow.invoke(...)with a representative example and printsresult.content, so the user can run it immediately. Useawait flow.ainvoke(...)instead if the code is already async. - Check imports — make sure
import railtracks as rtis at the top and any Pydantic models importfrom pydantic import BaseModel.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 2d ago Changed 055acd57e2a5
- 3d ago Changed · +16 lines 82ea200ffdb2
- 11d ago Changed · -6 lines d68c31f1128e
- 14d ago Changed · +51 lines d83fc6079d60
- 22d ago Changed d1a847ac5d6f
- 24d ago First seen · 166 lines · 37 tokens per session scan A e13d20f9e96b
agent-builder is a skill published in the GitHub repository RailtownAI/railtracks (233 stars, last pushed today), licensed MIT. It adds 37 tokens to every session and 2,453 once invoked, about $0.0001 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-23.
Other skills, from other repositories
first-reader
Beta readers for any draft, run by simulating how a real reader experiences it, moment by moment. A skim gate, a no-lookahead timed read producing an attention transcript with quit points, a recall test of what a reader remembers the next day, and a trust ledger of the implied author. Use when the user asks for a beta…
mcp-apps-builder
MANDATORY for ALL MCP server work - mcp-use framework best practices and patterns. READ THIS FIRST before any MCP server work, including: Creating new MCP servers Modifying existing MCP servers (adding/updating tools, resources, prompts, widgets) Debugging MCP server issues or errors Reviewing MCP server code for…
project-graveyard
Scans the developer's machine for dead side projects, autopsies each one from its git history (died at the payments wall, killed by a newer project, finished but never shipped), surfaces their personal death patterns, and picks the corpse most worth resurrecting — then helps ship it. Use when the user mentions…
commit-archaeologist
Reconstructs why code exists from local git history, including the introducing commit, later changes, current authors, repeated companion files, and likely intent. Use when the user asks "why does this code exist", "who wrote this function and why", or to "explain the history of this function" before a rewrite…
dependency-doctor
Checks requirements.txt, pyproject.toml, and package.json dependency manifests for surface-level direct-dependency footguns: standard-library shadowing pins, abandoned backports, unpinned dependencies, and obvious intra-manifest conflicts, plus opt-in PyPI yanked releases. Use when the user asks to check a manifest…
scope-creep-detector
Analyzes git diffs against a stated intent to detect scope creep, unrelated files, broad pull requests, changes that grew beyond a fix, dependency additions, public API renames, config or CI edits, oversized hunks, and formatting-only files. Use when the user asks whether a change grew beyond the fix, a PR is too…