m4b-audiobook

m4b-audiobook is a skill for Claude Code from lexfrei/ccc. It costs 25 tokens per session (1,353 once invoked), scanned A, original, BSD-3-Clause.

A workflow for combining audio files into one M4B audiobook file, with chapter markers, descriptive information, and cover art. M4B is an audiobook format that supports chapters.

In plain words
What is it for?
Use it on a folder containing supported audio files and optional cover images. It uses ffmpeg and ffprobe, determines a likely chapter order, and asks for confirmation before continuing.
Why use it?
It removes the manual work of ordering tracks and assembling the audiobook with its supporting details.

Skill for Claude Code

Written for Claude Code: allowed-tools in frontmatter. Also seen: names the AskUserQuestion tool.

Part of the m4b-audiobook plugin — 1 skill shipped together

Good fit Use it on a folder containing supported audio files and optional cover images. It uses ffmpeg and ffprobe, determines a likely chapter order, and asks for confirmation before continuing.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/lexfrei/ccc/m4b-audiobook
View source ↗ lexfrei/ccc
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 lexfrei/ccc --skill m4b-audiobook
Clone the repo
git clone --depth 1 https://github.com/lexfrei/ccc

Made for: Claude Code.

Or install m4b-audiobook, the plugin that ships this one along with the rest of its 1 skill.

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 m4b-audiobook

README.md
[![agentmods](https://agentmods.dev/badge/skills/lexfrei/ccc/m4b-audiobook.svg)](https://agentmods.dev/skills/lexfrei/ccc/m4b-audiobook)
Your own site
<a href="https://agentmods.dev/skills/lexfrei/ccc/m4b-audiobook"><img src="https://agentmods.dev/badge/skills/lexfrei/ccc/m4b-audiobook.svg" alt="Measured on agentmods" height="20"></a>
Per session 25 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,353 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.00025 $0.01353
Opus 5 $0.00013 $0.00677
Sonnet 5 $0.00005 $0.00271
Haiku 4.5 $0.00003 $0.00135

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

Security

Grade A, and why

m4b-audiobook 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.

skills/m4b-audiobook/skills/m4b-audiobook/SKILL.md · 186 lines

How it starts

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

Assemble a single .m4b audiobook from a directory of audio files. Adds chapter markers, metadata, and cover art.

Prerequisites

  • ffmpeg and ffprobe must be installed

Arguments

  • directory — path to the directory with audio files. If omitted, use the current working directory.

Process

1. Inventory

List all audio files in the directory. Supported formats: .m4a, .mp3, .aac, .ogg, .opus, .flac, .wav.

Also look for a cover image: .jpg, .jpeg, .png files with names suggesting cover art (e.g., cover, folder, front, or any single image file present).

2. Determine file order

Analyze filenames to determine the correct playback order. Common patterns:

  • Numeric prefixes: 01 - Title.m4a, 1.1. Title.m4a
  • Chapter/part indicators: Chapter 1, Part 1, Глава 1, Часть 1
  • Structured names: Week 1. 1.1. Title, Неделя 1. 1.1. Title

Sort rules:

  • Group by logical sections (introduction, parts/chapters/weeks, ending/epilogue)
  • Within each group, sort by numeric indicators
  • Files without clear numbering: sort alphabetically within their group

Present the proposed order to the user. Ask for confirmation before proceeding.

3. Determine metadata

Try to extract metadata from:

  • Directory name
  • Existing tags in audio files (ffprobe output)
  • File naming patterns

Required metadata fields:

  • title — book title
  • artist / album_artist — author name
  • album — same as title (convention for audiobooks)
  • genre — set to Audiobook
  • date — year if determinable from file metadata
  • language — detected from content/filenames (e.g., rus, eng)

Present proposed metadata to user. Ask for confirmation or corrections.

4. Probe audio formats

Run ffprobe on each file to determine:

  • Codec (aac, mp3, flac, etc.)
  • Sample rate
  • Channels
  • Bitrate

If all files share the same codec and parameters: use -c:a copy (no re-encoding — fast and lossless).

If formats differ: re-encode to AAC-LC. Choose parameters:

Read the full file on GitHub · 186 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 · 186 lines · 25 tokens per session scan A 1bf79b4cbe24

Subscribe to this mod's changes

m4b-audiobook is a skill published in the GitHub repository lexfrei/ccc (10 stars, last pushed 4d ago), licensed BSD-3-Clause. It adds 25 tokens to every session and 1,353 once invoked, about $0.0001 per session on Opus 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-31.

Related

Other skills, from other repositories

webgl-holographic-foil

A self-contained WebGL2 hero: thin-film interference over a crushed-foil surface whose palette shifts with the viewing angle; move the cursor to tilt the film.

nexu-io/open-design · 41 tokens

general-video

Author or edit a custom HyperFrames composition when no specialized workflow fits, or when BRIEF.md sets flow: companion. Use for longer or multi-scene pieces, brand and sizzle reels, montages, static loops, static title cards, footage remixes, and freeform builds. Use motion-graphics instead for a short unnarrated…

heygen-com/hyperframes · 92 tokens

html-ppt-hermes-cyber-terminal

OpenDesign + BYOK: choosing and wiring your own model, hands-on — cost, quality, and the routing decision. Built as a decision-grade AI literacy deck for engineers, IT, applied-AI teams.

nexu-io/open-design · 53 tokens

html-ppt-taste-brutalist

16:9 HTML deck in tactical-telemetry / CRT-terminal taste. Deactivated-CRT charcoal slides, white-phosphor monospace, hazard-red accent, scanline overlay, ASCII syntax, density over decoration. Distilled from Leonxlnx/taste-skill brutalist-skill (Tactical Telemetry mode).

nexu-io/open-design · 78 tokens

diagnostic-stem-delivery

Audio production with diagnostic analysis, timecode parsing from documents, and verified export workflow.

HKUDS/OpenSpace · 23 tokens

chengfeng-check-updates

An environment manager for a video-editing system. It checks whether its skills and runtime—the software needed to run them—are installed and compatible.

Agentchengfeng/chengfeng-videocut-skills · 120 tokens