Index of every page on this site: llms.txt
All skills
igorwarzocha avatar

/pi-stuff-tool-contracts

@c4f4852
Run it yourself

Read after general agent-tool design when reviewing or changing a model-facing Pi extension tool in this repository.

  • 4 files
  • 11.6 KB
  • Updated 2 months ago
  • GitHub
Use this Skill: https://skilld.dev/gh/igorwarzocha/howaboua-pi-stuff/pi-stuff-tool-contracts

Nothing lands on disk. Nothing to clean up.

Fork this Skill

Edit a local copy. It keeps the author and licence.

SKILL.md

≈35 tokens for metadata: the name and description. ≈586 when used: this file. ≈24 more on demand in 1 file.

Description uses 1.8% of example budget

Before choosing a Skill, your Agent reads its name and description. All available Skills share that space.

  • A shorter description leaves more room for other Skills. This entry exceeds our 1% size suggestion.

In our Claude Code example, all Skill names and descriptions share 8,000 characters. This Skill uses ≈142 characters, or 1.8%.

The 1% threshold is a size suggestion. Longer descriptions can still fit.

Your model, settings, and other Skills decide how much text your Agent can read.

Example settings and source

The example uses a 200k-token context and default Claude Code settings. The count includes the name, description, separators, and when_to_use when present. Codex also counts local file paths.

Skit's source and limits: Codex 0.160.1, Claude Code 2.1.292.

Discover and load applicable general agent tool design guidance before tool work. Load prompt caching guidance too when the active tool vector or system-prompt metadata changes.

Inspect retained Notebook bindings before writing measurement tooling. Reuse piStuffTokenCount when available with existing package prompt and schema builders.

Use scripts/tool-token-lines.mjs as this repo's preliminary migration and copy-cost probe. If its dependency is absent, install it once:

(cd .pi/skills/pi-stuff-tool-contracts/scripts && bun install --frozen-lockfile --ignore-scripts)
node .pi/skills/pi-stuff-tool-contracts/scripts/tool-token-lines.mjs <extension-file-or-directory>

Add --json for machine-readable output. The helper rejects known obsolete TypeBox, Pi package-scope, and removed custom-tool API markers before reporting an o200k token proxy over detected source lines.

The proxy is not the emitted schema or prompt payload. It can miss dynamic strings, imported schemas, conditional modes, and provider serialization. Use it only to locate likely duplication.

Validate the changed boundary

For wording-only edits, compare before-and-after prompt text and serialized schemas for affected modes using existing builders and token tooling. Review the diff for preserved instructions and constraints, and run focused checks. A small Notebook cell is enough; do not build an SDK harness, launch comparison sessions, or add tests merely because the text is model-facing.

For changes to schema shape, registration, prompt assembly, routing, or provider serialization:

  • Capture before-and-after emitted schemas and prompt additions for the affected modes and conditional tool sets, including final provider rewrites. Reuse existing capture tooling first.
  • Inspect assembled output across extension boundaries. Source proxies and passing functional tests do not prove the emitted contract.
  • New probes need a concrete risk that existing checks cannot resolve. Missing captures limit the claims you can make; they do not automatically justify a new harness.
  • Check affected model-visible results and run the owning package's relevant checks.

Measure schema and prompt text separately. Label source proxies as proxies, not emitted-payload or task-cost savings. Delete temporary captures and probes after validation.

Source: SKILL.md on GitHub

skilld matched fixed text patterns in SKILL.md and file names. Patterns miss obfuscated code.

skilld run checks every file with the same patterns. It asks for approval before it loads a Skill with a behavior marked Needs approval.

No third-party reports yet.

Signed by skilld at c4f4852. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub yesterday.

Activeupdated 2 months ago

README badge

README badge for igorwarzocha/howaboua-pi-stuff/pi-stuff-tool-contracts