tsz: Skill for Claude Code

.claude/skills/tsz-emit/SKILL.md

tsz-emit is a skill for Claude Code from tsz-org/tsz. It costs 53 tokens per session (572 once invoked), scanned A, original, Apache-2.0.

A project guide for changing TSZ's TypeScript compiler output, including JavaScript, declaration files, source maps, and related tests.

In plain words
What is it for?
It is for work on emit transforms, module and target output, helper and temporary-variable planning, declaration output, source maps, and emit tests.
Why use it?
It helps contributors choose the right compiler structures and avoid unsafe text-based fixes when output is wrong.

Skill for Claude Code

Written for Claude Code: installed under .claude/. Also seen: mentions AGENTS.md.

This is tsz-org/tsz's own configuration. It tells Claude Code how to work on tsz itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything tsz configures →

Reuse

Borrowing it

Nothing to install: this file belongs to tsz-org/tsz. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/tsz-org/tsz/main/.claude/skills/tsz-emit/SKILL.md
Clone the repo
git clone --depth 1 https://github.com/tsz-org/tsz

Made for: Claude Code.

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 tsz-emit

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

Your own site · 80×15
<a href="https://agentmods.dev/skills/tsz-org/tsz/tsz-emit"><img src="https://agentmods.dev/badge/skills/tsz-org/tsz/tsz-emit.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 53 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 572 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.00053 $0.00572
Opus 5.5 $0.00021 $0.00229
Sonnet 5.5 $0.00011 $0.00114
Haiku 4.5 $0.00005 $0.00057

Measured 23d ago against content hash 20360675847b, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

tsz-emit 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 23d 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.

.claude/skills/tsz-emit/SKILL.md · 58 lines

How it starts

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

TSZ Emit

Use for JS/DTS emit, transforms, helpers, temp/hoist planning, target/module output, source maps, and emit parity tests.

Start

  1. Read AGENTS.md and docs/plan/ROADMAP.md for durable emit/DTS work.
  2. Inspect overlapping emit PRs/issues.
  3. Name the failure family: target gate, module/export schedule, helper, temp/ hoist, region transform, printer layout, DTS nameability/portability, source maps, or parser recovery.
  4. State: When <syntax/output context>, tsc emits X; tsz emits X through <owner>.

Architecture

  • Emit is OUTPUT: no checker/solver semantic validation in emitter code.
  • Prefer planned facts before writing text: target/module facts, helper needs, temp reservations, hoists, prologues, exports, resource/disposable regions.
  • Keep direct-to-target emit; do not introduce an ESNext -> ... -> ES5 pipeline.
  • No semantic output surgery with replace, replacen, or replace_range. Data cleanup is fine for escaping, source-map paths, numeric separators, and path normalization.
  • DTS should use declaration summaries/structured emission, not late string rewrites.

Hot Checks

  • Use writer/list/token/source-map helpers; add delimiter helpers when they prevent real mistakes.
  • Target/module policy belongs in target/module facts or emit-plan-like owners, not random printer branches.
  • Every function-like body needs temp scope and hoist strategy. Bypasses of emit_block must still handle function-body flags and insertion points.
  • Check adjacent shapes: arrows, declarations, expressions, methods, accessors, constructors, async/generator wrappers, static blocks, namespaces/modules, parameter prologues, ES2015+ and relevant legacy targets.

Verification

No full emit/conformance/fourslash locally.

scripts/emit/run.sh --filter=<family> --js-only --verbose --json-out=/tmp/<name>.json
scripts/emit/run.sh --filter=<family> --dts-only --verbose --json-out=/tmp/<name>.json
cargo nextest run -p tsz-emitter <test-or-family>

Read the full file on GitHub · 58 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. 23d ago First seen · 58 lines · 53 tokens per session scan A 20360675847b

Subscribe to this mod's changes

tsz-emit is a skill published in the GitHub repository tsz-org/tsz (577 stars, last pushed today), licensed Apache-2.0. It adds 53 tokens to every session and 572 once invoked, about $0.0002 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-28.