Skip to content
Back to skills

Strata Scriptsmith

ASecurity

The Strata script creation protocol — when a script is required, run vs extend vs new, scaffolding with strata new script, manifest fields and side-effect classes, runtime choice, shared lib reuse, tests and the --format json contract, gates, catalog and linking. Use when an operation is repeatable and deterministic, before improvising a command you have run before, or when writing or changing anything under scripts/.

  • 2 stars
  • 0 votes
  • 0 copies
  • 1 view
  • Added November 29, 2026
developmenttypescriptpythonrustgoshellbashsecurity

Works with

  • cli

Security analysis

A100/100

Scanned December 3, 2026

npx -y skills add zbmowrey/strata --skill strata-scriptsmith --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Strata Scriptsmith?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Strata Scriptsmith
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/zbmowrey-strata-scriptsmith/badge)](https://www.skillsdirectory.com/skills/zbmowrey-strata-scriptsmith)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: strata-scriptsmith
description: The Strata script creation protocol — when a script is required, run vs extend vs new, scaffolding with strata new script, manifest fields and side-effect classes, runtime choice, shared lib reuse, tests and the --format json contract, gates, catalog and linking. Use when an operation is repeatable and deterministic, before improvising a command you have run before, or when writing or changing anything under scripts/.
tags: [strata, scripts]
---

# Writing Strata scripts

## Find first

`strata search '<need> kind:script'` · `strata scripts list` · then `strata run <id> -- <args>`.

| Situation                                                                         | Action                                                                               |
| --------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------ |
| A script fits                                                                     | Run it.                                                                              |
| Nearly fits; change additive, backward-compatible, current behavior tested        | Extend: new flag, existing output byte-identical, new tests.                         |
| Change alters semantics, interface, output, side-effect class, or callers unknown | New script; move shared code into `scripts/lib/<runtime>/` first — never copy-paste. |
| Nothing fits and it will recur                                                    | `strata new script <domain>/<name> [--runtime go\|python]`                           |
| Genuinely one-off                                                                 | Run ad hoc (repeats are detected and become garden tasks).                           |

## Manifest (`script.yaml`) — scaffold placeholders fail lint until filled

`id, summary, description, status, runtime, entry, usage, examples, inputs, outputs,
exit_codes, side_effect, writes, network, idempotent, deterministic, requires, env, timeout,
tags, applies_to, shards, tests, owner`.

Side-effect class = the **maximum** of any code path:
`read-only` (stdout only) · `writes-local` (repo files matching declared `writes` globs,
checked after each run) · `network` (declared hosts; prompts) · `destructive` (needs `--yes`).

Runtime: choose by purpose (D-041), passing `--runtime` to `strata new script`:
**Rust** when latency or resource use is the priority · **Python** when data science,
analysis or ML is central · **Go** for fast development, concurrency and orchestration ·
TypeScript only for JS-only ecosystems · Bash only for ≤ 40 lines of glue. A runtime other
than the instance default needs `runtime_justification` (≥ 40 chars) naming the purpose it
serves. Split a job whose parts need different runtimes into separate scripts joined by
`--format json` (e.g. a Go operator running a Rust indexer and a Python analysis via
`strata run`).

Quality bar for every runtime: strict static typing (no `Any`, no unchecked casts or
`unwrap`); formatters, linters, complexity limits and tests are the judges; simple beats
complex; a few lines of custom code beat a framework or dependency for a small need.

## Conventions

`--help` from `usage`; `--format text|json` with a stable JSON shape; errors on stderr;
exit codes per manifest; no prompts unless destructive; no undeclared network; no secrets
read from repo files; no shell interpolation (use the lib exec helpers). Go:
`scripts/lib/go` (`cli`, `out`, `repo`, `exec`, `fsx`); Python: `strata_lib` (`cli`, `out`,
`repo`, `proc`, `fsx`); Rust: `scripts/lib/rust` crate `strata_lib`, std only (`cli`,
`out`, `repo`, `exec`, `fsx`), one crate per script, built and cached by `strata run`.

## Done means

1. Manifest complete, `strata lint` clean, `side_effect` honest.
2. Tests: happy path, ≥ 1 error path, the `--format json` contract (golden file);
   `deterministic: true` → a test proving identical output across two runs.
3. `strata check <script dir>` green (format, lint, types, complexity, security, tests).
4. Linked both ways: script `shards:` ↔ shard `scripts:`.
5. `strata scripts catalog`; `strata search '<summary terms>'` finds it.

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in development →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.