sandcastle

sandcastle is a skill for Claude Code, Codex from killernay/sandcastle-huahin. It costs 66 tokens per session (2,681 once invoked), scanned A, original, MIT.

A checker and setup guide for the Sandcastle AFK coding-agent harness, a system that lets coding work run with less supervision. It checks or installs the required files, dependencies, environment settings, and safeguards.

In plain words
What is it for?
Use it to configure Sandcastle in a repository or audit an existing setup. It reports each check as passing, needing attention, or failing, with a suggested fix.
Why use it?
It helps explain why an automated run produced no commits or failed without a clear result, and shows what needs fixing.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: reads .claude/ paths.

Needs its repository: it reads a path above its own folder, which exists only inside the repository. The line is mkdir -p .claude/skills && ln -s ../../.sandcastle/skill .claude/skills/sandcastle.

Good fit Use it to configure Sandcastle in a repository or audit an existing setup. It reports each check as passing, needing attention, or failing, with a suggested fix.

Compare 6 skills from other repositories ↓
Install

Getting it into your agent

It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.

Clone the repo
git clone --depth 1 https://github.com/killernay/sandcastle-huahin
agentmods
npx agentmods add skills/killernay/sandcastle-huahin/skill

Made for: Claude Code, Codex.

Wrote 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.

agentmods badge for sandcastle

README.md
[![agentmods](https://agentmods.dev/badge/skills/killernay/sandcastle-huahin/skill/github.svg)](https://agentmods.dev/skills/killernay/sandcastle-huahin/skill)
Your own site
<a href="https://agentmods.dev/skills/killernay/sandcastle-huahin/skill"><img src="https://agentmods.dev/badge/skills/killernay/sandcastle-huahin/skill/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.

agentmods 80×15 button for sandcastle

Your own site · 80×15
<a href="https://agentmods.dev/skills/killernay/sandcastle-huahin/skill"><img src="https://agentmods.dev/badge/skills/killernay/sandcastle-huahin/skill.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 66 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,681 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5.1 $0.00066 $0.02681
Opus 5.5 $0.00026 $0.01072
Sonnet 5.5 $0.00013 $0.00536
Haiku 4.5 $0.00007 $0.00268

Measured 3mo ago against content hash 4a416f73b1f8, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

sandcastle 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 3mo 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.

.sandcastle/skill/SKILL.md · 202 lines

How it starts

The opening of the file, as written. The whole thing — 202 lines — stays where its author put it; the contents beside it link to each section on GitHub.

/sandcastle

Two modes. Pick by what the repo already has.

  • .sandcastle/ missing → SETUP
  • .sandcastle/ present → CHECK (default; also use after a run misbehaves)

Never guess a value. Every item below is a command whose output decides the answer. Report a table of PASS / WARN / FAIL with the fix next to each failure, then offer to apply the fixes — don't apply silently.

CHECK

Run these from the repo root. Each line is one check.

# 1. harness files
ls .sandcastle/{main.mts,plan-prompt.md,implement-prompt.md,review-prompt.md,merge-prompt.md,Dockerfile}

# 2. deps + script  (FAIL → npm i -D @ai-hero/sandcastle tsx zod; npm pkg set scripts.sandcastle="tsx .sandcastle/main.mts")
ls -d node_modules/@ai-hero/sandcastle && npm pkg get scripts.sandcastle

# 3. real .env, not just the example  (FAIL → cp .sandcastle/.env.example .sandcastle/.env and fill it)
test -f .sandcastle/.env && grep -c "^GH_TOKEN=." .sandcastle/.env

# 4. WORKSPACE_DIR points at a real workspace (empty value = repo root is the workspace)
W=$(grep -m1 "^WORKSPACE_DIR=" .sandcastle/.env | cut -d= -f2); ls "${W:-.}/package.json"

# 5. the false-green guard — see "Three slots" below
test -f .sandcastle/workspace-hint.md

# 6. optional planner knowledge
test -f .sandcastle/planning-rules.md

# 7. DEP_ORDER_FILE, if set, must exist
D=$(grep -m1 "^DEP_ORDER_FILE=" .sandcastle/.env | cut -d= -f2); [ -z "$D" ] || ls "$D"

# 8. issues exist — github: the label has open issues; local: issue files present
S=$(grep -m1 "^ISSUE_SOURCE=" .sandcastle/.env | cut -d= -f2); S=${S:-github}
if [ "$S" = "local" ]; then ls .sandcastle/issues/*.md; else
  L=$(grep -m1 "^ISSUE_LABEL=" .sandcastle/.env | cut -d= -f2); L=${L:-ready-for-agent}
  gh label list --search "$L" | head -3; gh issue list --state open --label "$L" --limit 5
fi

# 9. models live + sandbox image built + prompt args wired + no built-in overridden
npx tsx .sandcastle/check-models.mts

# 9b. the harness's own rules and its docs agree with its code (~200ms, no Docker)
npx tsx --test .sandcastle/*.test.mts

# 10. how many runs are live — TWO lines per run, 0 before you start another
ps -eo pid,lstart,command | grep "[.]sandcastle/main[.]mts"

# 11. containers: 2 per issue in flight is normal; only non-zero with NO run live is a leak
docker ps -a --filter name=sandcastle -q | wc -l

# 12. worktrees left dirty by a killed run — startup auto-rescues these (WIP commit on the issue branch, then clears); listed here so you know a kill happened
for w in .sandcastle/worktrees/*/; do [ -d "$w" ] && git -C "$w" status --porcelain | head -3; done

Read the full file on GitHub · 202 lines

Changes

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.

  1. 3mo ago First seen · 202 lines · 66 tokens per session scan A 4a416f73b1f8

Subscribe to this mod's changes

sandcastle is a skill published in the GitHub repository killernay/sandcastle-huahin (5 stars, last pushed 4mo ago), licensed MIT. It adds 66 tokens to every session and 2,681 once invoked, about $0.0003 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-08-31.

Related

sandcastle compared with skills from other repositories

sandcastle next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
sandcastlekillernay/sandcastle-huahinSkill54mo agoMITA66Claude Code, Codex
local-ai-agentsmicrosoft/ai-agents-for-beginnersSkill82ktodayMITA200Claude Code, Codex
imagegenopenai/codexSkill137ktodayApache-2.0A113Codex
playwright-climicrosoft/playwrightSkill102ktodayApache-2.0A19Claude Code
browser-automationopenclaw/openclawSkill396ktodayMITA36Claude Code
free-llm-apismnfst/awesome-free-llm-apisSkill15ktodayCC0-1.0A113Claude Code, Codex
systematic-debuggingobra/superpowersSkill332k6d agoMITA21Claude Code