relay: Skill for Claude Code

.agents/skills/wrdn-effect-value-inferred-types/SKILL.md

wrdn-effect-value-inferred-types is a skill for Claude Code from adarshp14/relay. It costs 59 tokens per session (739 once invoked), scanned A, a copy of wrdn-effect-value-inferred-types, MIT.

A TypeScript design rule for deriving an object type from the function that creates the object. The inferred type automatically follows the returned value's properties and methods.

In plain words
What is it for?
Replacing manually repeated interfaces or type aliases for plugin extensions, clients, route maps, and handler tables with ReturnType-based types.
Why use it?
It removes duplicate type definitions that can drift away from the implementation. This keeps consumers' types aligned with the actual runtime object.

Skill for Claude Code

Written for Claude Code: allowed-tools in frontmatter. Also seen: installed under .agents/ (shared by several agents).

This is adarshp14/relay's own configuration. It tells Claude Code how to work on relay 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 relay configures →

Reuse

Borrowing it

Nothing to install: this file belongs to adarshp14/relay. 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/adarshp14/relay/main/.agents/skills/wrdn-effect-value-inferred-types/SKILL.md
Clone the repo
git clone --depth 1 https://github.com/adarshp14/relay

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 wrdn-effect-value-inferred-types

README.md
[![agentmods](https://agentmods.dev/badge/skills/adarshp14/relay/wrdn-effect-value-inferred-types.svg)](https://agentmods.dev/skills/adarshp14/relay/wrdn-effect-value-inferred-types)
Your own site
<a href="https://agentmods.dev/skills/adarshp14/relay/wrdn-effect-value-inferred-types"><img src="https://agentmods.dev/badge/skills/adarshp14/relay/wrdn-effect-value-inferred-types.svg" alt="Measured on agentmods" height="20"></a>
Per session 59 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 739 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 100% copy Near-identical to another mod 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.00059 $0.00739
Opus 5 $0.00030 $0.00369
Sonnet 5 $0.00012 $0.00148
Haiku 4.5 $0.00006 $0.00074

Measured 6d ago against content hash 6e843fa41ebd, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-06, from the pricing page.

Security

Grade A, and why

wrdn-effect-value-inferred-types 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 6d 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.

Origin

This is a copy

100% identical to wrdn-effect-value-inferred-types — 0 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

.agents/skills/wrdn-effect-value-inferred-types/SKILL.md · 96 lines

How it starts

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

You fix one pattern: a TypeScript object type manually mirrors a runtime object that already owns the shape.

Prefer value-first APIs. Build the object in a named factory, then export type X = ReturnType<typeof makeX>. Consumers keep importing the stable type name, but the type cannot drift from the implementation.

Trace before changing

  1. Find the source value. Look for an object returned from a named factory, extension: (...) => ({ ... }), a client object, route map, or handler table.
  2. Find the duplicate type. A nearby interface X or type X = { ... } repeats the object methods/properties.
  3. Check whether the value is the source of truth. If the interface is a contract with multiple implementations, keep the interface.
  4. Preserve the exported type name. Replace its definition with ReturnType<typeof makeX> and update callers only if needed.
  5. Use satisfies only at boundaries. Do not make the implementation satisfy a duplicate shape that could drift.

Fix shape

const makePluginExtension = (ctx: PluginCtx<Store>) => {
  const addSource = ...
  const removeSource = ...

  return {
    addSource,
    removeSource,
  };
};

export type PluginExtension = ReturnType<typeof makePluginExtension>;

For factories that need options:

const makePluginExtension =
  (options: PluginOptions) =>
  (ctx: PluginCtx<Store>) => ({
    addSource: ...,
  });

export type PluginExtension = ReturnType<ReturnType<typeof makePluginExtension>>;

Bad

export interface McpPluginExtension {
  readonly addSource: (config: McpSourceConfig) => Effect.Effect<AddResult, Failure>;
  readonly removeSource: (namespace: string, scope: string) => Effect.Effect<void, Failure>;
}

extension: (ctx) => {
  return {
    addSource,
    removeSource,
  } satisfies McpPluginExtension;
};

Good

const makeMcpPluginExtension = (ctx: PluginCtx<McpStore>) => {
  return {
    addSource,
    removeSource,
  };
};

export type McpPluginExtension = ReturnType<typeof makeMcpPluginExtension>;

extension: makeMcpPluginExtension;

Read the full file on GitHub · 96 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. 6d ago First seen · 96 lines · 59 tokens per session scan A 6e843fa41ebd

Subscribe to this mod's changes

wrdn-effect-value-inferred-types is a skill published in the GitHub repository adarshp14/relay (0 stars, last pushed 2mo ago), licensed MIT. It adds 59 tokens to every session and 739 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. It is 100% identical to wrdn-effect-value-inferred-types, differing in 0 lines, and is treated as a copy.

Related

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.

prisma/orm · 52 tokens

coding-standards

Universal coding standards, best practices, and patterns for TypeScript, JavaScript, React, and Node.js development.

hashgraph-online/awesome-codex-plugins · 28 tokens

code-quality

Agents should invoke this skill for code reviews, linting/formatting setup, maintainability checks, complexity concerns, warning cleanup, coding standards, or quality gates in Rust, TypeScript, Python, shell, and mixed repos.

waybarrios/opencode-power-pack · 49 tokens

transformers-js

Run Hugging Face models in JavaScript or TypeScript with Transformers.js, WebGPU, or WASM across browser, Node.js, Bun, and Deno. Use for client-side or JS-runtime inference, not Python training.

waybarrios/opencode-power-pack · 50 tokens

splitting-oversized-modules

Split an oversized Python module (a thousand-plus-line logic.py, models.py, api.py, or its test file) into a package of one module per concern, mechanically and provably without changing behavior. Use on a request to split / break up / decompose a god module or move functions out of one, once a human has agreed to…

PostHog/posthog · 197 tokens

plankton-code-quality

Write-time code quality enforcement using Plankton — auto-formatting, linting, and Claude-powered fixes on every file edit via hooks.

loulanyue/awesome-claude-notes · 34 tokens