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 amadeus-dlc/amadeus --skill functional-domain-modeling-tsgit clone --depth 1 https://github.com/amadeus-dlc/amadeusWrote 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/amadeus-dlc/amadeus/functional-domain-modeling-ts)<a href="https://agentmods.dev/skills/amadeus-dlc/amadeus/functional-domain-modeling-ts"><img src="https://agentmods.dev/badge/skills/amadeus-dlc/amadeus/functional-domain-modeling-ts/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/amadeus-dlc/amadeus/functional-domain-modeling-ts"><img src="https://agentmods.dev/badge/skills/amadeus-dlc/amadeus/functional-domain-modeling-ts.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.00094 | $0.01526 |
| Opus 5 | $0.00047 | $0.00763 |
| Sonnet 5 | $0.00019 | $0.00305 |
| Haiku 4.5 | $0.00009 | $0.00153 |
Grade A, and why
functional-domain-modeling-ts 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 10d 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 — 114 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Functional Domain Modeling (TypeScript)
class / interface を使わず、データ = 型、振る舞い = 関数で構成する TypeScript スタイル。Scott Wlaschin『Domain Modeling Made Functional』の流儀を TypeScript のイディオムに落としたもの。正準実装例は j5ik2o/event-store-adapter-js packages/library。
適用条件: 方式依存。プロジェクトがこのスタイルを採用する場合のみ適用し、採用プロジェクトは memory/project.md にこのガイドへのポインタルールを追加する(索引 ../README.md の運用に従う)。
構成イディオム(5つ)
1. type エイリアスによる構造的契約 — interface の代替
契約はメソッドシグネチャを持つ type で定義する。実装側に implements 宣言は不要で、構造的互換で満たされる。
export type EventStore<AID extends AggregateId, /* ... */> = {
persistEvent(event: E, expectedVersion: number): Promise<Result<void, EventStoreError>>;
getLatestSnapshotById(id: AID): Promise<A | undefined>;
};
2. ファクトリ関数 + クロージャ — class の代替
コンストラクタの代わりに create* ファクトリ関数。private フィールドの代わりにクロージャ変数。返すオブジェクトリテラルは Object.freeze する。実装関数は internal/ に置き、公開はコンパニオンオブジェクト経由に限定する。
function createMemoryEventStore<...>(input = {}): EventStore<...> {
const events = new Map(/* クロージャに閉じた可変状態 */);
function appendEvent(id: string, event: E): void { /* 内部ヘルパー */ }
return Object.freeze({
async persistEvent(event, expectedVersion) { /* ... */ },
});
}
3. コンパニオンオブジェクトパターン — static メンバの代替
同名の type と namespace を宣言マージし、コンストラクタ関数・ファクトリを namespace 側に置く(名前は Scala 由来)。namespace 自体も Object.freeze する。
export type Result<T, E> = { type: "ok"; value: T } | { type: "err"; error: E };
export namespace Result {
export function ok<T>(value: T): Result<T, never> {
return Object.freeze({ type: "ok", value });
}
export function err<E>(error: E): Result<never, E> {
return Object.freeze({ type: "err", error });
}
}
Object.freeze(Result);
利用側は Result.ok(x)、EventStore.createMemory(input) のように型名を経由して呼ぶ。
4. ブランド型 + スマートコンストラクタ — 公称型の擬似再現
プリミティブに unique symbol のブランドを交差させ、検証を通ったコンパニオンの create だけがその型を作れるようにする(parse-dont-validate の型システム版)。
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.
- 10d ago First seen · 114 lines · 94 tokens per session scan A 3d13b24a3324
functional-domain-modeling-ts is a skill published in the GitHub repository amadeus-dlc/amadeus (8 stars, last pushed 19d ago), licensed Apache-2.0. It adds 94 tokens to every session and 1,526 once invoked, about $0.0005 per session on Opus 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.
Other skills, from other repositories
no-bare-casts
Writing as in TypeScript or TSX production code, modifying a file that contains a bare as cast, silencing a type error with a cast, encountering as unknown as, or reviewing a cast site.
aws-sst-development
SST v4 (Ion) expert for managing AWS resources as code with the Pulumi-backed framework.
dd-code-generation
Use pup CLI for immediate Datadog operations or generate code for integration into applications.
fast-typescript-check
Keep www-sacred's TypeScript fast to type-check and fast to run. Use when touching the ASCII/canvas animation components (the only real per-frame code here), tightening type-check wall-clock, or auditing a change for runtime or compiler regressions. Scoped to this repo — a React 19 / Next.js 16 component library plus…
typescript-magician
Designs complex generic types, refactors any types to strict alternatives, creates type guards and utility types, and resolves TypeScript compiler errors. Use when the user asks about TypeScript (TS) types, generics, type inference, type guards, removing any types, strict typing, type errors, infer, extends…
drizzle-migrations
Drizzle ORM schema management and SQLite migrations — adding tables, modifying columns, creating indexes, generating and running migrations, Drizzle query patterns. NOT for Prisma, TypeORM, Sequelize, or raw SQL migration tools.