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.
npx skills add dev-toolings/superpowers-symfony --skill doctrine-fetch-modesgit clone --depth 1 https://github.com/dev-toolings/superpowers-symfonyWrote 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.
[](https://agentmods.dev/skills/dev-toolings/superpowers-symfony/doctrine-fetch-modes)<a href="https://agentmods.dev/skills/dev-toolings/superpowers-symfony/doctrine-fetch-modes"><img src="https://agentmods.dev/badge/skills/dev-toolings/superpowers-symfony/doctrine-fetch-modes/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.
<a href="https://agentmods.dev/skills/dev-toolings/superpowers-symfony/doctrine-fetch-modes"><img src="https://agentmods.dev/badge/skills/dev-toolings/superpowers-symfony/doctrine-fetch-modes.svg" alt="Reviewed on agentmods" width="80" height="20"></a>- NVIDIA SkillSpector pass
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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00031 | $0.00590 |
| Opus 5.5 | $0.00012 | $0.00236 |
| Sonnet 5.5 | $0.00006 | $0.00118 |
| Haiku 4.5 | $0.00003 | $0.00059 |
Grade A, and why
doctrine-fetch-modes 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 1mo 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.
What it actually says
Doctrine Fetch Modes (Symfony)
Use when
- A list or detail endpoint runs one query per row (N+1) on a relation.
- A read-only list needs a few columns, not full managed entities.
- Choosing
LAZY,EAGERorEXTRA_LAZYon a mapping, or porting ORM 2 code that relied onPARTIALobjects. - A report or projection query drops to raw SQL through DBAL 4.
Default workflow
- Confirm the N+1 or over-fetch in the Symfony profiler before changing any mapping.
- Keep relations on
fetch: 'LAZY'; setfetch: 'EXTRA_LAZY'on large collections socount(),contains()andslice()run targeted SQL. - Load the relations a use case needs with a fetch join in the repository (
addSelect()plusleftJoin()). - For read-only lists, project into a
readonlyDTO withSELECT NEW(constructor argument order must match theNEWlist). - Use
Query::HINT_READ_ONLYor an index-by alias (createQueryBuilder('p', 'p.id')) when the result is only displayed or looked up by id. - For raw SQL, use the DBAL 4 methods (
fetchAllAssociative(),fetchOne(),executeStatement()).
Guardrails
PARTIALin DQL fails on ORM 3.0 to 3.2 and only returns from 3.3: useSELECT NEWDTOs for read-only lists instead.- Avoid
fetch: 'EAGER'on a mapping; a fetch join in the query gives the same result per use case. SELECT NEWreturns DTOs, not managed entities: never modify or flush them.- DBAL 4 removed
query(),exec()andfetchAll().
Progressive disclosure
- Use this file for execution posture and risk controls.
- Open references when deep implementation details are needed.
Output contract
- Repository methods with the fetch strategy chosen per use case.
- DTO classes and the
SELECT NEWqueries that fill them. - Query count before and after, from the profiler or
doctrine:query:dql --show-sql.
References
reference.md
What ships with it
1 file beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
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.
- 1mo ago Changed · +4 lines · -4 tokens per session f5696fc8a464
- 2mo ago Changed · +2 lines · -3 tokens per session c1f0c8f02f02
- 3mo ago First seen · 43 lines · 38 tokens per session scan A cf4ed4818146
doctrine-fetch-modes is a skill published in the GitHub repository dev-toolings/superpowers-symfony (235 stars, last pushed 19d ago), licensed MIT. It adds 31 tokens to every session and 590 once invoked, about $0.0001 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-30.
doctrine-fetch-modes compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| doctrine-fetch-modesdev-toolings/superpowers-symfony | Skill | 235 | 19d ago | MIT | A | 31 | Claude Code |
| database-performanceAaronontheweb/dotnet-skills | Skill | 1.3k | 10d ago | MIT | A | 44 | Claude Code |
| flux-migratetonone-ai/tonone | Skill | 84 | 2d ago | MIT | A | 51 | Claude Code |
| forge-infratonone-ai/tonone | Skill | 84 | 2d ago | MIT | A | 53 | Claude Code |
| flux-schematonone-ai/tonone | Skill | 84 | 2d ago | MIT | A | 55 | Claude Code |
| flux-recontonone-ai/tonone | Skill | 84 | 2d ago | MIT | A | 48 | Claude Code |
| forge-audittonone-ai/tonone | Skill | 84 | 2d ago | MIT | A | 54 | Claude Code |