typing-and-design-standards

Repository rules for Python typing and software design, including type checking, SOLID principles, and DRY principles. SOLID is a set of design guidelines, while DRY means avoiding real duplication.

In plain words
What is it for?
Use them when writing or reviewing code in this repository, especially when validating types with the configured type checker or designing modules and interfaces.
Why use it?
They provide consistent standards for catching type errors and keeping code organized, maintainable, and understandable.

Cursor rule for Cursor

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 rules/bitflight-devops/skilllint/typing-and-design-standards
Clone the repo
git clone --depth 1 https://github.com/bitflight-devops/skilllint

Made for: Cursor.

Per session 476 This file is loaded in full into every session.
When invoked 476 The same file — it is already loaded in full.
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.00476 $0.00476
Opus 5 $0.00238 $0.00238
Sonnet 5 $0.00095 $0.00095
Haiku 4.5 $0.00048 $0.00048

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

Security

Grade A, and why

typing-and-design-standards 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.

.cursor/rules/typing-and-design-standards.mdc · 35 lines

What it actually says

Typing and design standards (no compromise)

Typing

  • Follow docs/TYPING_POLICY.md as the source of truth. The type gate is uv run ty check packages/ (see pyproject.toml [tool.ty.*]).
  • No using Any, unchecked cast(), or type: ignore / ty: ignore to silence the checker without a documented, localized reason (e.g. test-only @no_type_check with a short rationale).
  • cast() only after a real proof step (runtime check, Pydantic validation, or documented library guarantee). cast() is not validation.
  • Ingress: isolate unknown shape in boundary-style modules (*_ingest.py, boundary/, etc.); validate with Pydantic; pass concrete types inward.

SOLID and structure

  • Single responsibility: one module/function, one reason to change.
  • Open/closed: extend via new types or adapters, not sprawling conditionals.
  • Liskov: subtypes honor contracts; no surprise narrowing of behavior.
  • Interface segregation: small Protocols / facades; avoid fat “god” interfaces.
  • Dependency inversion: depend on abstractions at boundaries; wire concretions at the edge.

DRY and clarity

  • DRY real duplication only—do not abstract for two copies or speculative reuse.
  • Prefer explicit names and small helpers over clever one-offs.
  • Match existing project patterns (imports, error handling, test layout per CLAUDE.md).

Non-negotiables

  • No invented constraints (magic numbers, timeouts, length limits) without a spec, config, or comment citing the source (CLAUDE.md).
  • No drive-by refactors unrelated to the task; every changed line should serve the request.
  • Prefer one principled fix over a quick hack; if a shortcut is unavoidable, isolate it, document why, and keep it out of domain code.
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 · 35 lines · 476 tokens per session scan A fb7c685614fb

Subscribe to this mod's changes

typing-and-design-standards is a cursor rule published in the GitHub repository bitflight-devops/skilllint (6 stars, last pushed 2d ago), licensed MIT. It adds 476 tokens to every session, about $0.0024 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.