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 pantheon-org/tekhne --skill type-systemgit clone --depth 1 https://github.com/pantheon-org/tekhneWrote 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/pantheon-org/tekhne/type-system)<a href="https://agentmods.dev/skills/pantheon-org/tekhne/type-system"><img src="https://agentmods.dev/badge/skills/pantheon-org/tekhne/type-system/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/pantheon-org/tekhne/type-system"><img src="https://agentmods.dev/badge/skills/pantheon-org/tekhne/type-system.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.00100 | $0.01495 |
| Opus 5.5 | $0.00040 | $0.00598 |
| Sonnet 5.5 | $0.00020 | $0.00299 |
| Haiku 4.5 | $0.00010 | $0.00150 |
Grade A, and why
typescript-advanced-type-system 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 24d 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 — 140 lines — stays where its author put it; the contents beside it link to each section on GitHub.
TypeScript Type System
The type-level mechanics that everything else in this skill family builds on: unions, conditionals, mapped types, template literals, generics, and type-level extraction with infer.
Mindset
Model the problem in types before reaching for a runtime check — a type that makes an invalid combination unrepresentable is a compile-time guarantee, while a runtime check for the same thing only protects the paths that get exercised. Prefer deriving a type from another type (ReturnType<typeof fn>, a mapped type, a conditional extraction with infer) over hand-writing a parallel type that can drift out of sync with the thing it describes. When a conditional type distributes over a union unexpectedly, that is usually the type system doing exactly what it's told — wrap the checked type in a tuple ([T] extends [U]) to opt out of distribution rather than restructuring the type to dodge it. A type assertion (as) is a claim, not a check; only reach for one when you have already established the fact some other way (e.g. immediately after a runtime guard), never as a way to silence an error you haven't investigated.
When to Apply
Use this skill when:
- Modeling a union or intersection type, including discriminated unions at the type-definition level
- Writing a conditional type, especially one using
inferto extract a nested type - Building a mapped type or remapping its keys with an
asclause - Constructing a template literal type (e.g. typed route parameters)
- Designing a generic function or type with meaningful constraints
- Extracting a type from a function, array, promise, or constructor
- Deciding whether a value needs an index signature or a fixed shape
- Choosing between a type assertion and a real narrowing check
Use When
- "How do I extract the return type / element type / awaited type from this?"
- "How should I model this union or generic type?"
- "How do I build a type that changes shape based on another type?"
- "What's the difference between
asand a type guard here?"
What ships with it
22 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
- .audits/2026-09-23/Analysis.md 497 B
- .audits/2026-09-23/audit.json 559 B
- .audits/2026-09-23/Remediation.md 1.4 KB
- evals/instructions.json 1.9 KB
- evals/scenario-0/capability.txt 136 B
- evals/scenario-0/criteria.json 1.0 KB
- evals/scenario-0/task.md 1.3 KB
- evals/scenario-1/capability.txt 146 B
- evals/scenario-1/criteria.json 1.1 KB
- evals/scenario-1/task.md 1.4 KB
- evals/scenario-2/capability.txt 146 B
- evals/scenario-2/criteria.json 1.1 KB
- evals/scenario-2/task.md 1.4 KB
- evals/summary.json 503 B
- references/conditional-types.md 4.8 KB
- references/generics.md 4.2 KB
- references/index-signatures.md 3.8 KB
- references/infer-extraction.md 3.3 KB
- references/mapped-types.md 5.3 KB
- references/template-literal-types.md 5.3 KB
- references/type-assertions.md 3.5 KB
- references/unions-intersections.md 3.2 KB
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.
- 24d ago First seen · 140 lines · 100 tokens per session scan A da843b57b2ea
typescript-advanced-type-system is a skill published in the GitHub repository pantheon-org/tekhne (10 stars, last pushed yesterday), licensed MIT. It adds 100 tokens to every session and 1,495 once invoked, about $0.0004 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-24.
Other skills, from other repositories
developing-genkit-js
Develop AI-powered applications using Genkit in Node.js/TypeScript. Use when the user asks about Genkit, AI agents, flows, or tools in JavaScript/TypeScript, or when encountering Genkit errors, validation issues, type errors, or API problems.
antfu
Anthony Fu's opinionated tooling and conventions for JavaScript/TypeScript projects. Use when setting up new projects, configuring ESLint/Prettier alternatives, monorepos, library publishing, or when the user mentions Anthony Fu's preferences.
setup-ts-deep-modules
A setup for TypeScript packages that hides their implementation behind files at the package root. Dependency-cruiser checks that outside code uses these entry points, prevents dependency cycles, and keeps internal folders private.
aws-lambda-typescript-integration
Provides AWS Lambda integration patterns for TypeScript with cold start optimization. Use when creating or deploying TypeScript Lambda functions, choosing between NestJS framework and raw TypeScript approaches, optimizing cold starts, configuring API Gateway or ALB integration, or implementing serverless TypeScript…
loom-typescript
TypeScript language expertise for type-safe, production-quality code.
senior-frontend
Frontend development for React 19, Next.js 15, TypeScript, and Tailwind CSS v4 / Pengembangan frontend dengan React 19, Next.js 15, TypeScript, dan Tailwind CSS v4.