Skip to content
Agentmart
Submit a tool

coding-standards

Applies language-neutral engineering standards when writing or reviewing code, especially around boundaries, failures, domain models, dependencies, tests, and…

Skill by iurysza

IndexedMIT★ 5
Write a review

Install

Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.

npx agentmarket install skill/iurysza-coding-standards

Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.

Get the weekly diff

The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.

We use your email only for this newsletter. Privacy

About

Applies language-neutral engineering standards when writing or reviewing code, especially around boundaries, failures, domain models, dependencies, tests, and type safety.

Use cases: writing

No reviews yet. Installed it? Reviews come from verified installers only. How reviews work

Permissions

What this skill can do and what it asks for, from its SKILL.md and code. Checked Oct 25, 2026.

Tools
No tools found
Secrets
None asked for
Install scripts
None found

Network hosts it talks to 1

  • codeload.github.com · found in install command

Files it touches

  • ~/.claude/skills/coding-standards

What's inside

Skill name
coding-standards
Description
Applies language-neutral engineering standards when writing or reviewing code, especially around boundaries, failures, domain models, dependencies, tests, and type safety.
License
MIT
Metadata
category: development
Instructions
171 lines in SKILL.md · view on GitHub

Files (1)

  • SKILL.md

SKILL.md (first lines)

# Coding Standards

Inspect the repository before introducing patterns, libraries, or abstractions. Follow compatible local conventions; contain incompatible legacy patterns at the nearest boundary instead of spreading them into new code.

The examples use TypeScript syntax, but the principles apply across languages. Adapt them to the language and ecosystem already in use.

## Priorities

1. Correctness, safety, and debuggability.
2. Explicit domain meaning and dependencies.
3. Compatibility with sound project conventions.
4. The narrowest change that fully solves the requested behavior.
5. Documentation for surprising, durable trade-offs.

## Parse at boundaries

Turn unknown or loosely shaped input into application and domain types as early as possible.

```text
unknown -> protocol input -> parser -> domain/application input
```

A parser returns the refined value or an explicit parsing failure. Do not validate input and then continue carrying the original primitive or transport shape.

Use constrained domain types where they prevent realistic mistakes: identifiers, URLs, email addresses, money, units, constrained numbers, and non-empty values. Construct them through parsers or smart constructors.

## Expected failures are values

Known failures belong in explicit return types or equivalent language constructs. This includes parsing, authorization, configuration, persistence, I/O, integration, and workflow failures.

```ts
type Result<T, E extends Error> =
  | { readonly _tag: "ok"; readonly value: T }
  | { readonly _tag: "err"; readonly error: E };
```

Translate dependency-specific exceptions inside the adapter that owns that dependency. Reserve throws, panics, or equivalent mechanisms for defects and impossible internal states. At entrypoints, turn expected failures into valid protocol outcomes: responses, exit codes, retry decisions, dead letters, or startup messages.

Errors should have a stable category, useful safe context, and preserve the original cause where the language supports it. Never put secrets or raw credentials in errors, traces, snapshots, or logs.

## Model meaningful states

Make illegal states hard to construct. Prefer explicit variants over boolean combinations and nullable bags.

```ts
type Invoice =
  | { readonly _tag: "draft"; readonly id: InvoiceId }
  | { readonly _tag: "sent"; readonly id: InvoiceId; readonly sentAt: Instant }
  | { readonly _tag: "paid"; readonly id: InvoiceId; readonly paidAt: Instant };
```

Avoid boolean parameters that control behavior. Use named options, enums, variants, or domain values.

## Functional core, imperative shell

Separate business decisions from side effects when they are tangled together.

- **Functional core:** pure logic that operates only on its inputs and returns data. It does not read clocks, databases, environment variables, random generators, networks, or mutable global state.
- **Imperative shell:** acquires inputs, invokes the core, and performs effects such as persistence, network calls, logging, and message delivery.

Do not mix policy and I/O in the same loop:

```ts
// Logic, time, storage, and email delivery are coupled.
function sendUserExpiryEmail(): void {
  for (const user of db.getUsers()) {
    if (user.subscriptionEndDate > Date.now()) continue;
    if (user.isFreeTrial) continue;
    email.send(user.email, `Your account has expired ${user.name}.`);
  }
}
```

Move decisions and output construction into the functional core:

```ts
type ExpiryEmail = { readonly to: string; readonly body: string };

function getExpiredUsers(
  users: readonly User[],
  cutoff: number,
): readonly User[] {
  return users.filter(
    (user) => user.subscriptionEndDate <= cutoff && !user.isFreeTrial,
  );
}

function generateExpiryEmails(users: readonly User[]): readonly ExpiryEmail[] {
  return users.map((user) => ({
    to: user.email,
    body: `Your account has expired ${user.name}.`,
  }));
}
```

Keep the imperative shell thin and explicit:

```ts
const users = db.getUsers();
const cutoff = Date.now();
const expiredUsers = getExpiredUsers(users, cutoff);
const messages = generateExpiryEmails(expiredUsers);
email.bulkSend(messages);
```

Pass changing context such as time into the core as data. Prefer returning decisions, commands, or messages for the shell to execute. This keeps policy reusable and lets most behavior be tested without mocks. Do not force trivial orchestration into artificial abstractions; separate effects where doing so clarifies meaningful logic.

Further reading: [Simplify Your Code: Functional Core, Imperative Shell](https://testing.googleblog.com/2025/10/simplify-your-code-functional-core.html) by Arham Jain.

## Module responsibilities

Use these roles when the behavior needs them; do not create layers to satisfy a diagram.

- **Domain module:** pure meanings, invariants, calculations, and legal transitions.
- **Application service:** authorization, policy, and sequencing across explicit ports.
- **Adapter:** framework, protocol, storage, runtime, or vendor translation.
- **Composition root:** configuration, resource acquisition, concrete wiring, and lifecycle.

Dependencies point inward. Domain code knows no framework or adapter. Application services depend on narrow application-owned ports, not SDK or database types. Adapters translate external types and failures at the edge.

From iurysza/agent-skills, MIT.

More from iurysza/agent-skills

Signals

Stars
5
Forks
0
Open issues
0
Last commit (this folder)
Oct 10, 2026 (19 days ago)

From GitHub (fetched Oct 24, 2026).

Details

License
MIT
First seen
Oct 24, 2026
Last checked
Oct 24, 2026

More from iurysza

Cite this page

coding-standards skill. Agent Mart. https://agentmart.dev/skills/iurysza-coding-standards (last updated 2026-10-24)