write-elixir

write-elixir is a skill for Claude Code from leifericf/agentic-sdk. It costs 50 tokens per session (1,574 once invoked), scanned A, original, MIT.

A guide for writing Elixir code using pure functions for core logic and OTP processes for state, messages, files, and network work. Elixir is a programming language built for concurrent, fault-tolerant applications.

In plain words
What is it for?
Use it when creating or editing Elixir modules, GenServers, supervision trees, or NIF-related code.
Why use it?
It separates calculations from side effects and provides consistent rules for stateful processes and native integrations.

Skill for Claude Code

Written for Claude Code: user-invocable in frontmatter.

Good fit Use it when creating or editing Elixir modules, GenServers, supervision trees, or NIF-related code.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/leifericf/agentic-sdk/write-elixir
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 leifericf/agentic-sdk --skill write-elixir
Clone the repo
git clone --depth 1 https://github.com/leifericf/agentic-sdk

Made for: Claude Code.

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 write-elixir

README.md
[![agentmods](https://agentmods.dev/badge/skills/leifericf/agentic-sdk/write-elixir/github.svg)](https://agentmods.dev/skills/leifericf/agentic-sdk/write-elixir)
Your own site
<a href="https://agentmods.dev/skills/leifericf/agentic-sdk/write-elixir"><img src="https://agentmods.dev/badge/skills/leifericf/agentic-sdk/write-elixir/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 write-elixir

Your own site · 80×15
<a href="https://agentmods.dev/skills/leifericf/agentic-sdk/write-elixir"><img src="https://agentmods.dev/badge/skills/leifericf/agentic-sdk/write-elixir.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 50 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,574 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.00050 $0.01574
Opus 5.5 $0.00020 $0.00630
Sonnet 5.5 $0.00010 $0.00315
Haiku 4.5 $0.00005 $0.00157

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

Security

Grade A, and why

write-elixir 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.

skills/write-elixir/SKILL.md · 123 lines

How it starts

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

write-elixir

Write Elixir for the project. The standard is skills/write-elixir/references/elixir-style.md (read it first). The architecture it implements is Functional Core / Imperative Shell; the Elixir expression of that split, and the native boundary contract, live in skills/shared/references/architecture.md. Placement follows the module map (the :architecture :modules entry in the descriptor). The why behind the constraints is the ADR log: scan it before designing against an unexplained rule.

The Elixir expression of the split maps cleanly onto OTP. The pure core is pure functions in modules: they take data (maps, structs, tuples) and return data, do no IO, send no messages, hold no state. Pattern matching and the immutability guarantee do the work the GC does in C and the allocator does in Zig. The imperative shell is GenServers and OTP: processes that hold state, receive messages, talk to the disk and the network. The shell calls the pure core from inside handle_call, handle_cast, and handle_info, and applies the return as the new process state plus any side effects.

Procedure

  1. Place it. Find the owning module from the module map. Pure logic goes in a plain module of functions; a process that holds state, receives messages, or touches the world goes in a GenServer (or the fitting OTP behaviour) under the shell. A function that needs a PID to make sense does not belong in the core.
  2. Elixir discipline. The load-bearing rules:
    • Pure core has no process identity. A core function does not know the PID it runs in; it does not send or receive, it does not read or write the process dictionary, it does not consult the clock. Testing the core is calling it: data in, data out, no setup ceremony.
    • GenServer and OTP are the shell. State, timers, IO, and messaging live in GenServers, Agents, Tasks, and the supervisors that own them. The shell calls the core from a callback and applies the return: the new state from the pure result, the side effects the result describes. The shell carries no logic of its own; it switches on the tagged tuple the core returns.
    • Supervision trees own lifecycle. The shell is a tree of supervisors and workers; the restart strategy (one_for_one, one_for_all, rest_for_one) is explicit and chosen for what a crash invalidates. Pure functions never start or stop processes. A worker and its supervisor land together; a worker without a place in the tree is incomplete.
    • Errors as tagged tuples in the core; let-it-crash at the edge. The core returns {:ok, value} or {:error, reason} tuples a caller branches on with with; it does not raise. The shell raises on programmer error and lets the supervisor restart on runtime failure, because the supervision tree is the recovery strategy.
    • NIF boundary discipline. When a NIF calls C or Zig, the native boundary contract in skills/shared/references/architecture.md applies unchanged: data in, data out, opaque handles, explicit lifetime, errors as values. A NIF is the shell of last resort: only when the BEAM cannot meet the requirement, never as a default. A NIF that blocks the scheduler runs dirty, and that decision is written down next to the loader.
  3. Failure model. The core returns tagged tuples for expected failure and raises only for programmer error (a violated precondition the caller controls). The shell trusts the supervision tree for runtime failure: a crashed worker restarts into a known-good state, and the tree's restart intensity bounds a crash loop. Untrusted input (bytes from the network or disk, a payload that crosses the NIF edge) is validated before it reaches the core and rejected as data when malformed.
  4. Verify like the lanes. The project's cheap lanes from the descriptor: mix format --check-formatted, mix compile --warnings-as-errors, mix test. For NIF or native-edge code, run the integration lane that builds the native side, loads it, and calls it with both a known-good and a malformed input. If you wrote process or supervision code, run the suite that starts the tree and tears it down, so a leak or a missing child fails the test.

Read the full file on GitHub · 123 lines

Files

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.

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 First seen · 123 lines · 50 tokens per session scan A 424ff144da04

Subscribe to this mod's changes

write-elixir is a skill published in the GitHub repository leifericf/agentic-sdk (5 stars, last pushed 2mo ago), licensed MIT. It adds 50 tokens to every session and 1,574 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-09-03.

Related

write-elixir compared with skills from other repositories

write-elixir next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
write-elixirleifericf/agentic-sdkSkill52mo agoMITA50Claude Code
mem0-oss-to-platformmem0ai/mem0Skill70k3d agoApache-2.0A217Claude Code, Codex
tao-run-inference-serviceNVIDIA/skillsSkill4.2ktodayApache-2.0A92Claude Code
azure-mgmt-botservice-dotnetmicrosoft/skillsSkill3.3ktodayMITA78Claude Code
fastapi-router-pymicrosoft/skillsSkill3.3ktodayMITA46Claude Code
dev-runtimelangwatch/langwatchSkill5.1ktodayApache-2.0A172Claude Code
api-designericrisco/rsc-harnessSkill6915d agoMITA105Claude Code, Codex