agentleFS
OrionicsLtdOrionicsLtd/claude-skills/coding-standards/SKILL.md

coding-standards

Skill1 starsChanged 5 months agoMITView on GitHub

Production-level coding standards for backend work. Use this WHENEVER writing or editing code, adding a dependency, creating a new module, organising packages, or running quality checks — trigger on any file edit, package install, or review of code structure. Keep modules small and focused, reuse before adding, name things professionally, type-hint and document every function, comment the WHY not the what, use the repo's existing tooling (uv/poetry, ruff etc for Python), and lint after every change. Aim for the smallest change that reads like the surrounding code.

  • Installs packages

67 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use springboot-security, configure-ecc and 10 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • FaisalAlqarniSkill

    springboot-security

    Spring Security best practices for authn/authz, validation, CSRF, secrets, headers, rate limiting, and dependency security in Java Spring Boot services.

    Also in 9 projects that use this

  • saxon-ySkill

    configure-ecc

    Interactive installer for Everything Claude Code — guides users through selecting and installing skills and rules to user-level or project-level directories, verifies paths, and optionally optimizes installed files.

    Also in 5 projects that use this

  • joneqianSkill

    continuous-learning-v2

    Instinct-based learning system that observes sessions via hooks, creates atomic instincts with confidence scoring, and evolves them into skills/commands/agents.

    Also in 11 projects that use this

  • FaisalAlqarniSkill

    springboot-tdd

    Test-driven development for Spring Boot using JUnit 5, Mockito, MockMvc, Testcontainers, and JaCoCo. Use when adding features, fixing bugs, or refactoring.

    Also in 7 projects that use this

  • Microsoft AzureSkill

    iterative-retrieval

    Max-3-cycle protocol for agent sub-tasks with WHY context and coordinator validation. Use when spawning sub-agents to complete scoped work.

    Also in 13 projects that use this

  • InfopibeSkill

    deployment-patterns

    Deployment workflows, CI/CD pipeline patterns, Docker containerization, health checks, rollback strategies, and production readiness checklists for web applications.

    Also in 10 projects that use this

  • +3 more from FaisalAlqarni

The file

Show its rules and text

We split this skill into the rules it gives an agent

13 rules. 0 are common, 11 are distinctive, and 2 are very specific to this project.

  • 0

    Common

    Most of the 56 edited versions we read keep these.

  • 11

    Distinctive

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Write code to production standards: small, focused, well-named, and consistent with what's already there.

    line 15
  2. Distinctive:

    Don't introduce new tools — find what the repo already uses and use it:

    line 28
  3. Distinctive:

    Group by feature, not by layer-within-layer: Keep the things that change together close together.

    line 47
  4. Distinctive:

    Don't hardcode parameters within random scripts.

    line 52
  5. Distinctive:

    Env variables: only use environment variables for secrets such as API keys, seed phrases, RPC nodes etc.

    line 56
  6. Distinctive:

    Always ensure these are gitignored.

    line 57
  7. Very specific:

    Before writing a new function/class/module, ask "does this already exist?" Duplicated logic (three functions doing the same thing) is a …

    line 63
  8. Distinctive:

    If it exists, use or extend it.

    line 66
  9. Distinctive:

    If the honest answer is "a new top-level package," the feature is probably big enough to deserve one — but flag that before creating it, …

    line 68
  10. Very specific:

    Functions: short, ~3 words max: If you need more, the function is usually doing too much — split it.

    line 75
  11. Distinctive:

    Keep comments objective and professional — as if they were always part of the codebase.

    line 96
  12. Distinctive:

    Don't leave debug prints, stray scaffolding, or half-finished alternatives behind.

    line 108
  13. Distinctive:

    Run the repo's lint/format, type checks, and tests after the change.

    line 112

“Common” is measured: kept by at least 6 in 10 of the 56 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Coding standards

Write code to production standards: small, focused, well-named, and consistent with what's already there. The bar is code a senior engineer would approve in review without comments. Before writing, read enough of the surrounding code to match its idiom — naming, structure, comment density, error handling. New code should look like it was always there, not like it was pasted from elsewhere.

Vocabulary note: examples below use Python terms: module = source file, subpackage = directory of modules. Substitute your language's equivalent: file/directory in TS/JS, file/package in Go and Java, file/module in Rust (with mod.rs), etc. The principles are the same.

Use the repo's existing tooling

Don't introduce new tools — find what the repo already uses and use it:

  • Dependencies & commands through the project's manager (uv/poetry in Python, npm/pnpm/yarn in JS/TS, go mod in Go, cargo in Rust, etc.) — check the project's manifest and lockfile first. Never pip install into a uv project.
  • Format & lint after every change with the repo's configured tool (ruff format, ruff check, etc.) — run it before considering an edit done, and run the type checker / tests if the repo has them. Adding a dependency is itself a real decision — keep it minimal (see the dependency-safety skill).

Small, focused modules

  • Aim for under ~200 lines per file. When a file grows past that, it's usually doing too much — split it along its natural seams. When the pieces cluster around one theme, promote them into a subpackage (a directory with __init__.py). A long file is a smell that a concept is hiding inside another.
  • One concept per module, one theme per subpackage. Name each for what it holds — parsers.py, not utils_and_helpers.py; billing/, not misc/. utils/helpers/common/shared/misc at either level is where cohesion goes to die — give things a real home.
  • Group by feature, not by layer-within-layer. Keep the things that change together close together.

Use config files

Don't hardcode parameters within random scripts.

  • Config files: set up a config file for the repository (or a config subpackage if more appropriate), where you can introduce relevant constants and parameters.
  • Env variables: only use environment variables for secrets such as API keys, seed phrases, RPC nodes etc. Always ensure these are gitignored.
  • CLI parameters: for scripts that use CLI arguments, do not overcrowd -- allow tunable configs via CLI only for a small set of very important parameters.

Reuse before adding

Before writing a new function/class/module, ask "does this already exist?" Duplicated logic (three functions doing the same thing) is a maintenance trap.

  • If it exists, use or extend it. If it doesn't, decide which existing place it belongs in rather than defaulting to a new file.
  • If the honest answer is "a new top-level package," the feature is probably big enough to deserve one — but flag that before creating it, don't do it silently.

Naming

Names are the cheapest documentation — spend care on them.

  • Functions: short, ~3 words max. If you need more, the function is usually doing too much — split it. (parse_row, not parse_row_and_validate_and_store.)
  • Variables: descriptive but concise — pending_rows, not pr and not the_list_of_pending_rows.
  • Classes: noun phrases — BankParser, MerchantMapping, ParsedTransaction.
  • Modules: snake_case, single concept (see above).

Type hints and docstrings

  • Type-hint every function signature — parameters and return. Types are checkable documentation and catch whole classes of bugs.
  • Give each function a one-line description of what it does; docstrings on public functions and classes (a single line is fine when a single line says it). Skip docstrings on trivial private helpers whose name already says everything.

Comments

The code already shows what it does; comments explain why — the reason this approach was chosen, a non-obvious constraint, or why a simpler-looking option would be wrong. A comment restating the code is noise.

  • Keep comments objective and professional — as if they were always part of the codebase. Never conversational meta ("as requested", "as you asked", "fixed the bug you mentioned") and never review/planning artifacts (priority tags like P1/B2, "TODO from review") left in source.
  • Note genuine quirks and gotchas (e.g. a preserved upstream typo, a workaround for a known bug) so the next reader doesn't "fix" them.

Keep the diff minimal and clean

  • Change only what the task needs. Don't reformat or refactor unrelated code — it buries the real change and burdens review.
  • Remove dead code; don't comment it out. Version control is the history.
  • Don't leave debug prints, stray scaffolding, or half-finished alternatives behind.

Verify before done

Run the repo's lint/format, type checks, and tests after the change. "It should work" isn't done — a clean lint + type pass (and green tests, where they exist) is the minimum before calling an edit complete.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.