engineering-principles

engineering-principles is a cursor rule for Cursor from adonai-labs/agent-runway. It costs 903 tokens per session, scanned A, original, MIT.

A set of language- and framework-independent guidelines for writing and reviewing software. It covers simplicity, code structure, naming, error handling, testing, and design.

In plain words
What is it for?
Use it while writing, reviewing, or reasoning about code in any programming language or project layer.
Why use it?
It helps avoid unnecessary complexity and code that is hard to understand, change, or test.

Cursor rule for Cursor

Written for Cursor: a Cursor rule (.mdc).

Good fit Use it while writing, reviewing, or reasoning about code in any programming language or project layer.

Compare 6 cursor rules from other repositories ↓
Install with agentmods
npx agentmods add rules/adonai-labs/agent-runway/engineering-principles
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.

Clone the repo
git clone --depth 1 https://github.com/adonai-labs/agent-runway

Made for: Cursor.

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 engineering-principles

README.md
[![agentmods](https://agentmods.dev/badge/rules/adonai-labs/agent-runway/engineering-principles/github.svg)](https://agentmods.dev/rules/adonai-labs/agent-runway/engineering-principles)
Your own site
<a href="https://agentmods.dev/rules/adonai-labs/agent-runway/engineering-principles"><img src="https://agentmods.dev/badge/rules/adonai-labs/agent-runway/engineering-principles/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for engineering-principles

Your own site · 80×15
<a href="https://agentmods.dev/rules/adonai-labs/agent-runway/engineering-principles"><img src="https://agentmods.dev/badge/rules/adonai-labs/agent-runway/engineering-principles.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 903 This file is loaded in full into every session.
When invoked 903 The same file — it is already loaded in full.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
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.1 $0.00903 $0.00903
Opus 5.5 $0.00361 $0.00361
Sonnet 5.5 $0.00181 $0.00181
Haiku 4.5 $0.00090 $0.00090

Measured 25d ago against content hash ea0f7335e157, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

engineering-principles 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 25d 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.

src/core/rules/engineering-principles.mdc · 88 lines

How it starts

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

Engineering Principles

Apply to all code, regardless of language, framework, or layer. Security principles live in the engineering-security rule; structural and system-design guidance in the engineering-architecture rule.

Simplicity first

  • Write the simplest solution that correctly solves the current problem; do not design for hypothetical futures
  • Earn complexity: every abstraction must isolate real variation or instability
  • If you cannot explain why a layer or pattern exists here, remove it
  • Prefer explicit code over framework magic in business-critical paths; make dependencies, side effects, and failure modes visible

Naming communicates intent

  • Name things for what they represent, not how they are implemented
  • Avoid abbreviations, single-letter names (except loop counters), and unqualified generic names (Manager, Helper, Utils, Service)
  • process() says nothing; placeOrder() or validatePayment() does
  • If a name needs a comment to explain it, rename it

Size limits

Unit Target Warning Needs justification
File / class < 600 lines 600–800 lines > 800 lines
Function < 60 lines > 60 lines (refactor prompt) > 100 lines
  • Split by responsibility, not by arbitrary line count
  • Exempt: generated code, migrations, snapshots, lockfiles, vendored code, declarative test data, framework-required boilerplate
  • Functions do one thing at a single level of abstraction; extract well-named helpers instead of nesting conditionals
  • Side effects should be obvious from the name and placement

SOLID, briefly

  • Single responsibility — one reason to change per module; HTTP, business rules, and persistence in one place is too many
  • Open/closed — add behaviour through composition or new implementations; if one change forces edits in many places, the design is closed to extension
  • Liskov substitution — subtypes honour the base contract; callers must never need to check the concrete type
  • Interface segregation — small, role-specific interfaces; clients depend only on what they use
  • Dependency inversion — business logic depends on abstractions; inject concrete implementations at the edges

Read the full file on GitHub · 88 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. 25d ago Changed · -115 lines · -622 tokens per session ea0f7335e157
  2. 1mo ago Changed · +3 lines · +77 tokens per session 9df89652a087
  3. 3mo ago First seen · 200 lines · 1,448 tokens per session scan A 9b19d1d2227b

Subscribe to this mod's changes

engineering-principles is a cursor rule published in the GitHub repository adonai-labs/agent-runway (2 stars, last pushed 4d ago), licensed MIT. It adds 903 tokens to every session, about $0.0036 per session on Opus 5.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

engineering-principles compared with cursor rules from other repositories

engineering-principles next to 6 cursor rules from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
engineering-principlesadonai-labs/agent-runwayCursor rule24d agoMITA903Cursor
optimize-dry-solid-principles-cursorrules-prompt-fPatrickJS/awesome-cursorrulesCursor rule41k6mo agoCC0-1.0A150Cursor
code-optimizationleshchenko1979/fast-mcp-telegramCursor rule509d agoMITA0Cursor
agent-masterSurya8991/AgentMasterCursor rule212d agoMITB211Cursor
ai-dev-os-reviewyunbow/ai-dev-os-plugin-cursorCursor rule28mo agoMITA56Cursor
Accessibility-ReviewTheSethRose/DevRulesCursor rule261y agoMITA0Cursor
checkysfAskri/archguardianCursor rule49mo agoMITA0Cursor