phoenix-patterns-analyst

phoenix-patterns-analyst is an agent for Claude Code from oliver-kriska/claude-elixir-phoenix. It costs 39 tokens per session (1,619 once invoked), scanned A, original, MIT.

A Phoenix codebase analyst that studies existing project structure and conventions. Phoenix is the Elixir web framework, and its contexts are modules that group related business operations.

In plain words
What is it for?
Use it before planning Phoenix features to inspect modules, contexts, routes, plugs, scopes, and framework choices, including whether the project uses Ash.
Why use it?
It helps planned features fit the project instead of introducing unfamiliar module, routing, or security patterns.

Agent for Claude Code

Written for Claude Code: effort in frontmatter. Also seen: model in frontmatter; names the NotebookEdit tool.

Part of the phx plugin — 50 skills, 26 agents, 8 hooks shipped together

Good fit Use it before planning Phoenix features to inspect modules, contexts, routes, plugs, scopes, and framework choices, including whether the project uses Ash.

Compare 6 agents from other repositories ↓
Install with agentmods
npx agentmods add agents/oliver-kriska/claude-elixir-phoenix/phoenix-patterns-analyst
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/oliver-kriska/claude-elixir-phoenix

Made for: Claude Code.

Or install phx, the plugin that ships this one along with the rest of its 50 skills, 26 agents, 8 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 phoenix-patterns-analyst

README.md
[![agentmods](https://agentmods.dev/badge/agents/oliver-kriska/claude-elixir-phoenix/phoenix-patterns-analyst/github.svg)](https://agentmods.dev/agents/oliver-kriska/claude-elixir-phoenix/phoenix-patterns-analyst)
Your own site
<a href="https://agentmods.dev/agents/oliver-kriska/claude-elixir-phoenix/phoenix-patterns-analyst"><img src="https://agentmods.dev/badge/agents/oliver-kriska/claude-elixir-phoenix/phoenix-patterns-analyst/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 phoenix-patterns-analyst

Your own site · 80×15
<a href="https://agentmods.dev/agents/oliver-kriska/claude-elixir-phoenix/phoenix-patterns-analyst"><img src="https://agentmods.dev/badge/agents/oliver-kriska/claude-elixir-phoenix/phoenix-patterns-analyst.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 39 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,619 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.00039 $0.01619
Opus 5.5 $0.00016 $0.00648
Sonnet 5.5 $0.00008 $0.00324
Haiku 4.5 $0.00004 $0.00162

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

Security

Grade A, and why

phoenix-patterns-analyst 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 2mo 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/elixir-phoenix/agents/phoenix-patterns-analyst.md · 236 lines

How it starts

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

Phoenix Patterns Analyst

You analyze Phoenix codebases to understand existing patterns, conventions, and structure. Your findings inform feature planning to ensure consistency.

Ash Framework Detection

Before analyzing Phoenix patterns, check for Ash Framework:

grep -E "ash|ash_phoenix|ash_postgres" mix.exs
grep -r "use Ash.Domain" lib/

If Ash detected:

  1. Warn user: "This project uses Ash Framework. Phoenix Context patterns don't apply to Ash Domain modules."
  2. Don't recommend contexts - Ash uses Ash.Domain instead of Phoenix Contexts
  3. Note pattern differences:
    • Ash Domains ≠ Phoenix Contexts
    • Ash Actions ≠ Context functions
    • Ash Policies ≠ Phoenix authorization plugs
  4. Redirect to Ash docs: "Consult ash-hq.org/docs for domain organization."

Still analyze: security headers, deployment patterns, general Elixir idioms, OTP patterns.

Analysis Process

1. Map Module Structure

find lib -name "*.ex" -type f | head -50
tree lib -L 3 -I "_build|deps|node_modules"

2. Identify Contexts (Bounded Contexts)

ls -la lib/*/
grep -r "defmodule.*Context" lib/ --include="*.ex"

3. Check Phoenix Version and Modern Patterns

grep "phoenix" mix.exs
grep -r "~p\"" lib/ --include="*.ex" | wc -l  # Verified routes?
grep -r "defmodule.*Scope" lib/ --include="*.ex"  # Phoenix 1.8 Scopes?
grep -r "action_fallback" lib/ --include="*.ex"  # FallbackController?

4. Analyze Existing Patterns

  • How are schemas organized?
  • What's the context API style?
  • Are there service modules? (anti-pattern check)
  • How is authorization handled?
  • Phoenix 1.8 scopes in use? (scope as first param)
  • Verified routes (~p sigil) or old path helpers?
  • FallbackController for error handling?
  • PubSub broadcast patterns in contexts?
  • Plugs for auth/authz (how structured)?
  • Ecto.Multi for side effects?

5. Check LiveView Structure

find lib -name "*_live*" -type f
find lib -name "*_component*" -type f

Read the full file on GitHub · 236 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. 2mo ago Changed · -1 lines c3486cf1cdb1
  2. 3mo ago First seen · 237 lines · 39 tokens per session scan A 4a34b5d3bc5f

Subscribe to this mod's changes

phoenix-patterns-analyst is an agent published in the GitHub repository oliver-kriska/claude-elixir-phoenix (579 stars, last pushed 2d ago), licensed MIT. It adds 39 tokens to every session and 1,619 once invoked, about $0.0002 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.

Related

phoenix-patterns-analyst compared with agents from other repositories

phoenix-patterns-analyst next to 6 agents from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
phoenix-patterns-analystoliver-kriska/claude-elixir-phoenixAgent5792d agoMITA39Claude Code
craft-site-buildermichtio/craftcms-claude-skillsAgent91yesterdayMITA61Claude Code
genpage-customapi-buildermicrosoft/power-platform-skillsAgent1.2ktodayMITA173Claude Code
enterprise-saas-revieweravelikiy/great_ctoAgent11715d agoMITA40Claude Code
integrations-engineeravelikiy/great_ctoAgent11715d agoMITA106Claude Code
craft-code-reviewer-deepmichtio/craftcms-claude-skillsAgent91yesterdayMITA76Claude Code
litestar-reviewerlitestar-org/litestar-skillsAgent199d agoMITA48Claude Code