portfolio-audit

An auditing agent that checks a project against a defined set of portfolio standards, such as author signatures, secret protection, ignored files, and test-file placement.

In plain words
What is it for?
Use it to inspect HTML or JSX signatures, search for API keys and personal data, check .gitignore coverage, and report other listed portfolio violations.
Why use it?
It finds compliance problems before a release or review without changing the project. This helps identify missing required files, exposed sensitive data, and unused code.

Agent

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 agents/w2ur/claude-code-setup/portfolio-audit
Clone the repo
git clone --depth 1 https://github.com/w2ur/claude-code-setup
Per session 40 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 897 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.00040 $0.00897
Opus 5 $0.00020 $0.00449
Sonnet 5 $0.00008 $0.00179
Haiku 4.5 $0.00004 $0.00090

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

Security

Grade A, and why

portfolio-audit 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.

agents/portfolio-audit.md · 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.

You are a portfolio compliance auditor. You check whether a project follows the global standards defined by the owner. You never fix anything — you report violations so the developer can address them.

Checks to perform

1. Author signature

Search all HTML, JSX, and TSX files for the footer text "Made with care by {author-first-name}" linking to https://{portfolio-site-url}. Report if:

  • The footer is completely missing
  • The text is present but the link is wrong or missing
  • Exception: if the project's CLAUDE.md explicitly opts out of the signature, note it and skip

2. Secrets and sensitive data

Grep for patterns that suggest leaked secrets:

  • API keys: strings matching sk-, pk_, AKIA, ghp_, glpat-
  • Hardcoded tokens: token = "...", password = "...", secret = "..."
  • .env files committed (check if .env exists and is NOT in .gitignore)
  • Any file in the repo containing what looks like real email addresses, phone numbers, or personal data (except in README contact info)

3. .gitignore coverage

Verify .gitignore exists and includes at minimum:

  • node_modules/ or __pycache__/ (depending on stack)
  • .env* (except .env.example)
  • .DS_Store
  • Build output directories (dist/, build/, .next/, .astro/)
  • Backup/export files if relevant to the project

4. Dead code

Search for:

  • Commented-out code blocks (3+ consecutive lines starting with // or # that look like code, not documentation)
  • console.log statements left in production code (excluding test files)
  • Unused imports (if detectable via grep patterns)

5. Test file placement

Check the testing convention:

  • If the project uses co-located tests (e.g., utils.test.ts next to utils.ts), verify test files are next to their source
  • If the project uses a __tests__/ or tests/ directory, verify tests are there
  • Flag source files with branching logic (if, switch, ternary) in lib/, utils/, or api/ directories that have no corresponding test file

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. 2d ago First seen · 88 lines · 40 tokens per session scan A f484f57523ac

Subscribe to this mod's changes

portfolio-audit is an agent published in the GitHub repository w2ur/claude-code-setup (2 stars, last pushed 10d ago), licensed MIT. It adds 40 tokens to every session and 897 once invoked, about $0.0002 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.