phoenix
Skill15 starsChanged 43 days agoMITView on GitHub
Expert Phoenix assistance covering Elixir web development, LiveView real-time reactive UIs, Ecto queries, and Channels. Use when building high-concurrency real-time web applications with minimal JavaScript.
3 other projects use a version of this.
Adopted by
Most recently taken up by
- Mindrally/skillstheir own version, first seen Oct 8, 2026
- conjure-3301/skillstheir own version, first seen Aug 17, 2026
- BadBeta/elixir-phase-skillstheir own version, first seen May 12, 2026
Other versions3 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 3
- Mindrally/skills★ 275same name
- BadBeta/elixir-phase-skills★ 4same name
- conjure-3301/skills★ 0same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository350 other files it gives its agents.
- airflowSkill
- catboostSkill
- claudeSkill
- comfyuiSkill
- cursor-aiSkill
- dalleSkill
- daskSkill
- dbtSkill
- deepseekSkill
- fastaiSkill
- geminiSkill
- github-copilotSkill
- huggingfaceSkill
- jaxSkill
- jupyterSkill
- kerasSkill
- langchainSkill
- lightgbmSkill
- llamaindexSkill
- llamaSkill
- matplotlibSkill
- midjourneySkill
- mistralSkill
- mlflowSkill
- nltkSkill
- numpySkill
- ollamaSkill
- openai-gptSkill
- opencvSkill
- pandasSkill
- perplexitySkill
- plotlySkill
- polarsSkill
- pytorchSkill
- raySkill
- scikit-learnSkill
- seabornSkill
- spacySkill
- sparkSkill
- stable-diffusionSkill
- tensorflowSkill
- vaexSkill
- weights-biasesSkill
- whisperSkill
- xgboostSkill
- api-gatewaySkill
- clean-architectureSkill
- cqrsSkill
- domain-driven-designSkill
- event-drivenSkill
- event-sourcingSkill
- graphqlSkill
- grpcSkill
- hexagonalSkill
- microservicesSkill
- modular-monolithSkill
- monolithSkill
- rest-apiSkill
- sagaSkill
- serverlessSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
3 rules. 0 are common, 1 is distinctive, and 2 are very specific to this project.
0
Common
Most of the 3 edited versions we read keep these.
1
Distinctive
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 115
Use Phoenix LiveView with PubSub broadcasting:
- Very specific: line 144
Use LiveView streams (stream/3) for large collections to minimize memory usage on both client and server.
- Very specific: line 145
Use Ecto Multi (Ecto.Multi) for atomic multi-table transactional workflows.
“Common” is measured: kept by at least 6 in 10 of the 3 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Phoenix
Phoenix (Elixir) provides real-time scalability (millions of connections). v1.7 + LiveView allows building rich SPAs without writing JavaScript.
When to Use
- Real-Time Interactive Web Applications: Real-time dashboards, multiplayer games, and collaboration tools with LiveView.
- High-Concurrency Distributed Backends: Leveraging Erlang/Elixir BEAM VM for fault-tolerant microservices.
- Scalable WebSocket & Channel Architectures: Millions of persistent connections with minimal memory per process.
- Maintainable Functional Web Development: Clean separation with Ecto schemas, contexts, and Plugs.
Quick Start
defmodule MyAppWeb.PageController do
use MyAppWeb, :controller
def home(conn, _params) do
render(conn, :home, layout: false)
end
end
# In router.ex:
# scope "/", MyAppWeb do
# pipe_through :browser
# get "/", PageController, :home
# endCore Concepts
Phoenix LiveView: Server-Driven Interactivity
Real-time UI state management over WebSockets without JavaScript client state:
defmodule MyAppWeb.CounterLive do
use MyAppWeb, :live_view
def mount(_params, _session, socket) do
{:ok, assign(socket, count: 0)}
end
def handle_event("increment", _params, socket) do
{:noreply, update(socket, :count, &(&1 + 1))}
end
def render(assigns) do
~H[
<div class="counter-box">
<h2 class="text-xl">Count: <%= @count %></h2>
<button phx-click="increment" class="bg-blue-500 text-white px-4 py-2 rounded">
Increment
</button>
</div>
]
end
endEcto Contexts & Composability
Decoupled business logic and transactional database access:
defmodule MyApp.Accounts do
import Ecto.Query, warn: false
alias MyApp.Repo
alias MyApp.Accounts.User
def list_active_users do
from(u in User, where: u.is_active == true, order_by: [desc: u.inserted_at])
|> Repo.all()
end
def create_user(attrs \\ %{}) do
%User{}
|> User.changeset(attrs)
|> Repo.insert()
end
endPhoenix Channels: Low-Latency Pub/Sub
Real-time broadcasting across connected clients:
defmodule MyAppWeb.RoomChannel do
use MyAppWeb, :channel
def join("room:lobby", _payload, socket) do
{:ok, socket}
end
def handle_in("new_msg", %{"body" => body}, socket) do
broadcast!(socket, "new_msg", %{body: body, user: socket.assigns.user_id})
{:reply, :ok, socket}
end
endCommon Patterns
Real-Time LiveView Counter with PubSub Broadcasts
Problem: Synchronizing live state changes across multiple concurrent browser tabs.
Solution: Use Phoenix LiveView with PubSub broadcasting:
defmodule MyAppWeb.CounterLive do
use MyAppWeb, :live_view
def mount(_params, _session, socket) do
if connected?(socket), do: Phoenix.PubSub.subscribe(MyApp.PubSub, "counter")
{:ok, assign(socket, count: 0)}
end
def handle_event("inc", _params, socket) do
new_count = socket.assigns.count + 1
Phoenix.PubSub.broadcast(MyApp.PubSub, "counter", {:count_updated, new_count})
{:noreply, assign(socket, count: new_count)}
end
def handle_info({:count_updated, count}, socket) do
{:noreply, assign(socket, count: count)}
end
endBest Practices
Do:
- Target Phoenix 1.7+ with verified routes (
~p"/users") and HEEx functional components. - Structure domain boundaries using Phoenix Contexts rather than exposing Ecto queries in controllers.
- Use LiveView streams (
stream/3) for large collections to minimize memory usage on both client and server. - Use Ecto Multi (
Ecto.Multi) for atomic multi-table transactional workflows.
Don't:
- Store large binary data or huge collections in LiveView socket assigns; use temporary assigns or streams.
- Make blocking third-party HTTP calls directly in LiveView processes without wrapping in
Task. - Bypass Ecto changesets for user input validation.
Troubleshooting
| Error | Cause | Solution |
(Ecto.NoResultsError) expected at least one result | Repo.get! or Repo.one! returned nil for query. | Use non-bang variant Repo.get and handle nil safely. |
phx-socket closed / reconnecting in LiveView | LiveView process crashed due to unhandled handle_info or handle_event. | Inspect Elixir crash stack trace in iex -S mix phx.server. |
CompileError: undefined function MyAppWeb... | Module name typo or Phoenix view helper not included. | Run mix compile and check module namespace in my_app_web.ex. |
References
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

