lv-assigns

lv-assigns is a skill for Claude Code, Codex from oliver-kriska/claude-elixir-phoenix. It costs 47 tokens per session (729 once invoked), scanned A, a copy of assigns-audit, MIT.

A read-only checker for Phoenix LiveView data stored in socket assigns, the values a page keeps while it is running. It looks for large lists, full database records, large binaries, missing temporary assigns, and assigns that are not initialized.

In plain words
What is it for?
Use it to review LiveView memory usage, check whether lists should use streams, and find data that should be temporary or reduced to only needed fields.
Why use it?
It helps find patterns that can make a LiveView use more memory than necessary or grow without limit. It reports problems without changing the code.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to review LiveView memory usage, check whether lists should use streams, and find data that should be temporary or reduced to only needed fields.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/oliver-kriska/claude-elixir-phoenix/lv-assigns
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.

Any agent
npx skills add oliver-kriska/claude-elixir-phoenix --skill lv-assigns
Clone the repo
git clone --depth 1 https://github.com/oliver-kriska/claude-elixir-phoenix

Made for: Claude Code, Codex.

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 lv-assigns

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

Your own site · 80×15
<a href="https://agentmods.dev/skills/oliver-kriska/claude-elixir-phoenix/lv-assigns"><img src="https://agentmods.dev/badge/skills/oliver-kriska/claude-elixir-phoenix/lv-assigns.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 47 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 729 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 92% copy Near-identical to another mod 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.00047 $0.00729
Opus 5 $0.00023 $0.00365
Sonnet 5 $0.00009 $0.00146
Haiku 4.5 $0.00005 $0.00073

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

Security

Grade A, and why

lv-assigns 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 7d 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.

Origin

This is a copy

92% identical to assigns-audit — 11 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

targets/amp/skills/lv-assigns/SKILL.md · 92 lines

How it starts

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

LiveView Assigns Audit

Analyze LiveView socket assigns for memory efficiency, clarity, and best practices.

Iron Laws - Never Violate These

  1. Use streams for lists > 100 items - Never store large lists directly in assigns
  2. Use temporary_assigns for transient data - Flash messages, temp errors, notifications
  3. Preload only needed fields - Don't store full Ecto schemas when only needing subset
  4. Initialize all assigns in mount - Never access assigns that might not exist
  5. NEVER modify assigns or code during audit — this is a read-only diagnostic; report findings only

Quick Audit Commands

Extract All Assigns

Use Grep to find all assign( and assign_new( calls in the target LiveView file.

Find Large Data Patterns

Use Grep to find large data patterns: lists stored in assigns (assign.*\[\], assign.*Repo\.all) and full schema storage (assign.*Repo\.get) in the target file.

Audit Checklist

1. Memory Issues

Pattern Problem Solution
assign(:items, Repo.all(...)) Unbounded list Use stream/3
assign(:user, Repo.get!(...)) Full schema Select only needed fields
assign(:file_data, binary) Large binary Store reference, not data
Nested preloads Excessive data Preload only what's rendered

2. Missing temporary_assigns

Should use temporary_assigns:

  • Flash messages
  • Form errors after submission
  • One-time notifications
  • Upload progress
def mount(_params, _session, socket) do
  {:ok, socket, temporary_assigns: [flash_message: nil]}
end

3. Unused Assigns

Search for assigns defined but never used in templates:

Use Grep to extract all assign names (assign\(:(\w+)) from the LiveView file, then use Grep to find all @\w+ references in the corresponding .heex template. Compare to find unused assigns.

4. Missing Initialization

# BAD: @items might not exist
def render(assigns) do
  ~H"<%= for item <- @items do %>"
end

# GOOD: Initialize in mount
def mount(_params, _session, socket) do
  {:ok, assign(socket, items: [])}
end

Read the full file on GitHub · 92 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. 7d ago First seen · 92 lines · 47 tokens per session scan A 7a757cb6513c

Subscribe to this mod's changes

lv-assigns is a skill published in the GitHub repository oliver-kriska/claude-elixir-phoenix (542 stars, last pushed today), licensed MIT. It adds 47 tokens to every session and 729 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. It is 92% identical to assigns-audit, differing in 11 lines, and is treated as a copy.

Related

Other skills, from other repositories

bug-fix

Use when a bug, regression, or unexpected behaviour is reported and the user wants it fixed end to end — "why is X broken", "this stopped working after Y", "fix this crash". Also use when a symptom is known but its cause is not. Not for building new behaviour, and not for a change whose cause is already proven.

kardebadas/claude-plugin · 74 tokens

bug-investigate

Use when someone wants to know WHY something is broken and has not asked for it to be fixed — "why is this happening", "what's causing this error", "find out what's wrong", "diagnose this before we decide". Also use before committing to a fix, when the cause is unknown and the decision depends on it. Not for fixing …

kardebadas/claude-plugin · 83 tokens

gurobi-advanced-features

When the user wants to use Gurobi beyond plain model building — callbacks for lazy constraints, user cuts, heuristic solution injection, and early termination; IIS computation for diagnosing an infeasible model; the solution pool; the multi-objective API; the matrix API (addMVar/addMConstr); MIP starts; and parameter…

hajibabaie/combinatorial-optimization-skills · 154 tokens

cige-product-defect-escalation

Invoked by cige-failure-classification when a run is classified as a Product Defect: execution reached the system under test, the environment is healthy, execution steps are current — but the outcome does not match Intent.

vivekkrishna/agentic-validation-skills · 0 tokens

cige-stale-execution-repair

Invoked by cige-failure-classification in two situations: Outdated Test Logic (Mode A — repair Execution[]) and a confirmed False Positive (Mode B — strengthen Guardrails). These are different repairs with different targets; do not conflate them.

vivekkrishna/agentic-validation-skills · 0 tokens

diagnose

Disciplined diagnosis loop for hard bugs and performance regressions. Reproduce → minimise → hypothesise → instrument → fix → regression-test. Use when user says "diagnose this" / "debug this", reports a bug, says something is broken/throwing/failing, or describes a performance regression.

saitarrun/Sdlc-ai-workflow · 66 tokens