clean-code

A general set of principles for readable, maintainable code across programming languages. It focuses on names, function size, error handling, comments, and repeated code.

In plain words
What is it for?
Use it when writing, reviewing, or refactoring code, while following the project's existing conventions when they differ.
Why use it?
It helps make code easier to understand and reduces confusion caused by misleading names, unnecessary complexity, and duplicated logic.

Skill for Claude CodeCodex

Install

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.

agentmods
npx agentmods add skills/uwuclxdy/agenticat/clean-code
Any agent
npx skills add uwuclxdy/agenticat --skill clean-code
Clone the repo
git clone --depth 1 https://github.com/uwuclxdy/agenticat

Made for: Claude Code, Codex.

Per session 22 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 4,604 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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 $0.00022 $0.04604
Opus 5 $0.00011 $0.02302
Sonnet 5 $0.00004 $0.00921
Haiku 4.5 $0.00002 $0.00460

Measured 2d ago against content hash 5104f839cf22, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

clean-code 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 2d 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.

skills/clean-code/SKILL.md · 361 lines

How it starts

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

Clean Code Principles

Use these when you write, review, or refactor code.

Treat these as directional principles. Where a repo's established precedent or a language's own idioms conflict with a rule here, follow the local convention and match the surrounding code.


1. Naming & Readability

1.1 Avoid Disinformation

Never use variable names that create false expectations, contain misleading technical terms, or use visually confusing characters.

Do:

  • Use names that honestly reflect the data structure (accountsMap, accountsGroup).
  • Use distinct names for classes/variables so autocomplete doesn't trick you.

Don't:

  • Name a map accountList just because it holds several items; to a programmer "list" means an indexed structure.
  • Create names that vary in tiny ways (e.g., ABCManagerForEfficientProcessingOfUsers vs ...PersistingOfUsers).
  • Use characters that look identical (lowercase l vs 1, uppercase O vs 0).
    • Bad: int a = l; if (O == l) a = O1; else l = O1;

1.2 Make Meaningful Distinctions

If two things have different names, they must do different things. Avoid meaningless noise words and number series.

Do:

  • Reveal the actual role of variables (e.g., array, condition, transformation).
  • Use specific, role-based names for classes (e.g., OrderValidator, OrderRepository, OrderCalculator).

Don't:

  • Add meaningless noise suffixes when you can't think of a better name (e.g., OrderManager, OrderHandler, OrderController, OrderProcessor all existing side by side).

1.3 Use Searchable, Pronounceable Names

Names should read as natural words and match the size of their scope, so they can be spoken aloud and found by search. Avoid cryptic abbreviations, single letters outside tiny scopes, and raw magic numbers.

Do:

  • Use real words that describe intent.
    • Good: let generationTimestamp = new Date();
  • Use single letters (i, j) only in tiny scopes, like a short for loop.

Don't:

  • Mash abbreviations into cryptic strings.
  • Use single letters in larger scopes (searching for e returns thousands of useless hits).
  • Use an abbreviation that reads fine but decodes several ways: in const tx = t[i], is tx time, tax, text, or transaction? A pronounceable, searchable name can still force the reader to keep a lookup table in their head.

Read the full file on GitHub · 361 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. 2d ago First seen · 361 lines · 22 tokens per session scan A 5104f839cf22

Subscribe to this mod's changes

clean-code is a skill published in the GitHub repository uwuclxdy/agenticat (5 stars, last pushed 2d ago), licensed MIT. It adds 22 tokens to every session and 4,604 once invoked, about $0.0001 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.

Related

Other skills, from other repositories

meta-harness

Run a Meta-Harness-style optimization loop NATIVELY — automatically search over the scaffolding around a FIXED base model (memory, retrieval, context construction, prompt templates, summarization, tool-selection logic) by proposing candidate variants, scoring each on a cheap deterministic eval, and keeping a Pareto…

001TMF/harness-forge · 217 tokens

meta-harness-proteus

Run one iteration of proteus memory-summary evolution. Called by metaharness.py.

001TMF/harness-forge · 24 tokens

gbg

Convert any plan, PRD, feature idea, or brief into a sequenced goal-by-goal execution document with reviewer-gated commits — for everyday feature development, MVPs, migrations, refactors, and hardening alike. Generates a project brief, per-goal scope/tasks/acceptance criteria, an LLM-reviewer prompt (Codex/etc.), a…

cielebak/goal-by-goal · 150 tokens

project-graveyard

Scans the developer's machine for dead side projects, autopsies each one from its git history (died at the payments wall, killed by a newer project, finished but never shipped), surfaces their personal death patterns, and picks the corpse most worth resurrecting — then helps ship it. Use when the user mentions…

Shubhamsaboo/awesome-llm-apps · 127 tokens

haiku

When writing a haiku for this bot, follow these conventions.

agno-agi/agno · 0 tokens

deploy-docker-compose

Run the Omnigent server as a Docker compose stack (server + Postgres) on any Docker host — your laptop, a VPS, EC2 by hand, or as the base layer of any container-platform deploy. Invoke when the user wants to build the image, bring up the compose stack, debug the stack on a host they already have, or extend the stack…

omnigent-ai/omnigent · 84 tokens