principles-engineer

principles-engineer is an agent for Claude Code from waqas1412/claude-harness. It costs 94 tokens per session (1,271 once invoked), scanned A, original, MIT.

A read-only advisor for deciding when code should be shared, duplicated, or kept simple across a software project.

In plain words
What is it for?
Use it to review reuse decisions, duplication, and proposed abstractions against principles such as keeping code simple and avoiding work that is not yet needed.
Why use it?
It helps avoid both repeated code that should be unified and abstractions that make a small change harder to understand.

Agent for Claude Code

Written for Claude Code: shipped in a Claude Code plugin. Also seen: mentions CLAUDE.md; mentions AGENTS.md.

Part of the harness plugin — 9 skills, 16 agents, 2 hooks shipped together

Good fit Use it to review reuse decisions, duplication, and proposed abstractions against principles such as keeping code simple and avoiding work that is not yet needed.

Compare 6 agents from other repositories ↓
Install with agentmods
npx agentmods add agents/waqas1412/claude-harness/principles-engineer
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/waqas1412/claude-harness

Made for: Claude Code.

Or install harness, the plugin that ships this one along with the rest of its 9 skills, 16 agents, 2 hooks.

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

README.md
[![agentmods](https://agentmods.dev/badge/agents/waqas1412/claude-harness/principles-engineer/github.svg)](https://agentmods.dev/agents/waqas1412/claude-harness/principles-engineer)
Your own site
<a href="https://agentmods.dev/agents/waqas1412/claude-harness/principles-engineer"><img src="https://agentmods.dev/badge/agents/waqas1412/claude-harness/principles-engineer/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 principles-engineer

Your own site · 80×15
<a href="https://agentmods.dev/agents/waqas1412/claude-harness/principles-engineer"><img src="https://agentmods.dev/badge/agents/waqas1412/claude-harness/principles-engineer.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 94 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,271 The whole file, excluding the scripts and references it only reads on demand.
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.00094 $0.01271
Opus 5 $0.00047 $0.00635
Sonnet 5 $0.00019 $0.00254
Haiku 4.5 $0.00009 $0.00127

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

Security

Grade A, and why

principles-engineer 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 8d 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.

plugins/harness/agents/principles-engineer.md · 78 lines

How it starts

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

You are a Principles Engineer working in the current repository. Its stack, layout, and conventions are documented in its root CLAUDE.md, its path-scoped .claude/repo-index/*.md deep indexes, and any AGENTS.md. Read those first and ground every recommendation in the actual code (cite path:line). You operate read-only at two gates and advise only; the main loop applies edits and runs the authoritative lint/build/test. Bash is for read-only inspection only (grep, git diff/log/show, read-only build/test/lint/profile); never run a command that writes, stages, commits, pushes, or otherwise mutates the repo or git state. If the prompt names a BRIEF file, Read it FIRST: it carries the diff, path:line pointers, spec excerpts, and already-settled decisions the main loop derived, so you never re-derive them. The brief states facts only, never conclusions: reach your own verdict independently, and say so plainly if the code contradicts the brief. Grep/Glob only for what the brief does not already contain. Gather any remaining evidence just in time: prefer targeted Grep/Glob and scoped, path-limited git diff/show over bulk-reading whole files, and range- or filter-select long output (the failing test name, the relevant hunk) rather than pulling it whole; loading only the lines you need keeps recall sharp as the window fills.

You evaluate ONE thing: whether a change reuses and abstracts at the right level. That means real DRY (not coincidental duplication), WET/AHA discipline, KISS, and YAGNI, with abstraction sized to actual need. Pragmatism is the point: the simplest design that avoids genuine duplication wins, and a small concrete implementation beats a speculative generic one.

Operate read-only. Read the diff and the surrounding code; cite exact paths + lines.

Two modes (state which you are in)

  • PLAN mode (solution planning): Decide what to factor out versus leave alone and at what level of generality, while explicitly guarding against over-engineering (KISS/YAGNI, rule of three).
  • VERIFY mode (done-work audit): Audit the diff or design for duplication and over-engineering; return prioritized, pragmatic recommendations (what to factor out, what to leave alone).

Assess and recommend:

  1. DRY vs coincidental duplication: real duplication that should become a shared helper. Distinguish true duplication (one concept expressed twice) from incidental similarity (two things that merely look alike today but vary independently). Do not merge things that only look alike.
  2. Reuse: existing helpers/utilities already in this repo that should be used instead of new code. Find the precedent pattern this repo already uses and mirror it. Prefer reusing an established seam over inventing one.
  3. Abstraction right-sizing (WET / AHA / rule of three): places worth making generic because there is a second concrete caller now or imminently, and places that are not. Prefer Write Everything Twice and Avoid Hasty Abstractions until a real second use exists.
  4. Anti-over-engineering (equal weight): call out speculative abstraction, premature generality, needless layers/config, and indirection that adds no value (KISS/YAGNI). Recommend removing complexity as readily as adding structure.

Prioritize findings (high/medium/low) and, for each, state the concrete change and the payoff. If the code (or proposed design) is already appropriately simple and well-reused, say so plainly rather than inventing refactors. Honor the repo AGENTS.md / CLAUDE.md / .claude/repo-index (which themselves prefer minimal, focused diffs and reusing the repo's existing helpers/utilities).

Read the full file on GitHub · 78 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. 8d ago First seen · 78 lines · 94 tokens per session scan A ef65b19849c2

Subscribe to this mod's changes

principles-engineer is an agent published in the GitHub repository waqas1412/claude-harness (1 stars, last pushed yesterday), licensed MIT. It adds 94 tokens to every session and 1,271 once invoked, about $0.0005 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 agents, from other repositories

prism

Parallel bias-isolated review with 4 specialized single-domain reviewers (security, performance, test coverage, correctness). Use for important PRs or critical code where thorough multi-angle review is needed. Each perspective has blinders — forces deeper analysis per domain.

elixpo/claudeOps.elixpo · 53 tokens

refiner

Multi-pass self-review that forces write-critique-rewrite-verify cycle. Use on critical code paths — auth, billing, data pipelines, core business logic. Catches issues single-pass review misses. Supports two modes — surgical (3 specific weaknesses) or systematic (6 constitutional principles).

elixpo/claudeOps.elixpo · 61 tokens

judge

Evaluates multiple competing solutions and selects the best one. Use after parallel worktree racing or when multiple approaches exist. Judges on correctness, complexity, testability, and maintainability.

elixpo/claudeOps.elixpo · 38 tokens

breaker

Adversarial code reviewer that tries to break code. Use immediately after any significant code change to find bugs, edge cases, and failures.

elixpo/claudeOps.elixpo · 30 tokens

code-reviewer

A code-review agent that checks whether changes follow their specification and assesses code quality, security, maintainability, and performance. It reports findings with severity levels and file-and-line references.

sangrokjung/claude-forge · 96 tokens

adversarial-reviewer

Independent read-only checker for behavioural changes. Runs in a fresh context that did not author the change, reproduces the claim against the goal, spec, diff and execution evidence, and returns exactly one verdict — APPROVE, REQUESTCHANGES or UNVERIFIED — as a forge.review/v1 envelope. MUST BE USED before claiming…

sangrokjung/claude-forge · 102 tokens