mcpbeat Sign in

Phx Mix Compression Skill for Claude

Reduce mix output noise (5-15% token savings) by installing rtk; Use when long mix output floods context.

6k tokens
context cost
the whole folder, loaded on every use
3
files
instructions only
0
copies elsewhere
how many repositories repackaged it
514
stars on the repo
on the repository, not the skill itself

Install

one command, takes just this skill from the repository
npx skills add https://github.com/oliver-kriska/claude-elixir-phoenix --skill phx-mix-compression

What comes with it

19 382 bytes besides the instruction
references/install.md
references/rtk-filters.toml

The instruction itself

11 sections, as written by the author

Mix Output Compression

Mix commands (mix test, mix credo, mix dialyzer, mix compile) emit

verbose, repetitive output that consumes context fast. This skill installs

rtk — a CLI proxy that filters tool output

before it lands in the transcript.

The filters short-circuit happy paths to a single line (mix test: all pass)

while preserving full failure blocks, compile errors, and stack traces. Net win:

5-15% per-session token reduction on mix-heavy workflows.

When to use

  • Long sessions$elixir-phoenix:phx-work or $elixir-phoenix:phx-full hitting context limits from mix output
  • Debugging loops$elixir-phoenix:phx-investigate retrying mix compile/mix test repeatedly
  • Dialyzer-heavy projectsmix dialyzer output dominates the transcript

Iron Laws

  • NEVER strip critical signals — compile errors (** (CompileError),

== Compilation error in), test failures (FAILURES, 0 failures — preserved

even on short-circuit), dialyzer warnings, and stack traces with file:line MUST

pass through unchanged

  • Verify after install — run rtk verify (or rtk verify --filter mix-test) to

confirm the bundled test fixtures pass before declaring success

  • Never overwrite existing .rtk/filters.toml — diff and merge instead

Workflow

Step 1: Detect rtk

which rtk && rtk --version

Read references/install.md if rtk is missing — covers

homebrew install + shell hook setup.

Step 2: Seed .rtk/filters.toml

Reference filters live at references/rtk-filters.toml. Six

production-tested filters covering:

  • mix-test — short-circuits all-pass, preserves failure blocks + compile errors
  • mix-credo — collapses clean runs, preserves violation blocks
  • mix-dialyzer — drops PLT progress, keeps warnings + summary
  • mix-deps-get — collapses unchanged package lists
  • mix-ecto-migrate — strips compile prefix, short-circuits "already up"
  • mix-compile — handles parallel worker prefixes (N>) and MIX_ENV

Run this if the project has no .rtk/filters.toml yet:

mkdir -p .rtk
cp "references/rtk-filters.toml" .rtk/filters.toml

Read both files if one already exists. Present a diff to the user. Merge only

the filters they don't already have.

Step 3: Verify filters work

rtk verify                       # runs all embedded [[tests.*]] fixtures
rtk verify --filter mix-test     # one filter only

Check that all report "passed". Flag and stop if any fail — usually means the

user has a custom rtk version with regex differences.

Step 4: Confirm shell hook

Run rtk init zsh (or rtk init bash) to install the transparent rewrite hook

that turns mix X into rtk mix X. Re-running is safe (idempotent). Skip this

step and mix calls run unfiltered.

Customization

Add custom regex patterns to strip_lines_matching for project-specific noise

sources (e.g., third-party hex deps spamming stack traces). See the inline

example in references/rtk-filters.toml lines 57-59.

What this is NOT

  • Not a hook — Claude Code's PostToolUse hooks fire after the tool result

is in the transcript and cannot shrink it. rtk works at the subprocess layer

(the only layer where transcript-shortening is possible).

  • Not project-analysis — the bundled filter set is universal across Phoenix

projects. No mix.exs inspection needed.

  • Not telemetry — rtk has telemetry off by default (enabled = false in

config.toml). Filters run locally, no data leaves the machine.

References

  • references/rtk-filters.toml — bundled filter set
  • references/install.md — rtk install + shell hook setup
  • rtk on GitHub

Other skills for the same job

different authors, same section of the catalogue
Protocolsio Integration
by christophacham
×4

Integration with protocols.io API for managing scientific protocols. This skill should be used when working with protocols.io to search, create, update, or publish protocols; manage protocol steps and materials; handle discussions and comments; organize workspaces; upload and manage files; or integrate protocols.io functionality into workflows. Applicable for protocol discovery, collaborative protocol development, experiment tracking, lab protocol management, and scientific documentation.

16k tokens
Tailored Resume Generator
by frostant
×4

Analyzes job descriptions and generates tailored resumes that highlight relevant experience, skills, and achievements to maximize interview chances

3k tokens
Excalidraw Diagram Generator
by github
vendor ×3

Generate Excalidraw diagrams from natural language descriptions. Use when asked to "create a diagram", "make a flowchart", "visualize a process", "draw a system architecture", "create a mind map", or "generate an Excalidraw file". Supports flowcharts, relationship diagrams, mind maps, and system architecture diagrams. Outputs .excalidraw JSON files that can be opened directly in Excalidraw.

36k tokens scripts
Expo Dev Client
by openai
vendor ×3

Build and distribute Expo development clients locally or via TestFlight

961 tokens
Executing Plans
by ZhanlinCui
×3

Use when you have a written implementation plan to execute in a separate session with review checkpoints

542 tokens
Anndata
by christophacham
×3

Data structure for annotated matrices in single-cell analysis. Use when working with .h5ad files or integrating with the scverse ecosystem. This is the data format skill—for analysis workflows use scanpy; for probabilistic models use scvi-tools; for population-scale queries use cellxgene-census.

16k tokens
Benchling Integration
by christophacham
×3

Benchling R&D platform integration. Access registry (DNA, proteins), inventory, ELN entries, workflows via API, build Benchling Apps, query Data Warehouse, for lab data management automation.

14k tokens
Biopython
by christophacham
×3

Comprehensive molecular biology toolkit. Use for sequence manipulation, file parsing (FASTA/GenBank/PDB), phylogenetics, and programmatic NCBI/PubMed access (Bio.Entrez). Best for batch processing, custom bioinformatics pipelines, BLAST automation. For quick lookups use gget; for multi-service integration use bioservices.

24k tokens

How to use it

Copy the folder

Take oliver-kriska/claude-elixir-phoenix-phx-mix-compression from the repository into ~/.claude/skills for personal use, or into .claude/skills inside a project.

Check the name does not clash

The agent identifies a skill by the name field in its header. Two skills with the same name cannot sit side by side — one of them will be ignored.

Install what it needs

The instructions reference brew. Without those the skill loads but fails at the first command.