ax-audio

ax-audio is a skill for Claude Code, Codex from ax-llm/ax. It costs 85 tokens per session (2,667 once invoked), scanned A, original, Apache-2.0.

A guide for adding audio input and output to Ax applications. It explains batch speech-to-text, text-to-speech, structured audio results, and conversational audio sessions.

In plain words
What is it for?
Use it to transcribe recordings, generate spoken audio, build audio-capable agents, or support realtime voice conversations.
Why use it?
Audio data needs different handling from ordinary text, including transcription before an agent can work with it and synthesis after an answer is produced. The guide helps select the audio interface that matches the application.

Skill for Claude CodeCodex

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

Good fit Use it to transcribe recordings, generate spoken audio, build audio-capable agents, or…

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/ax-llm/ax/ax-audio
About the project

Ax is a TypeScript-first programming framework for building applications with large language models through typed generation, agents, workflows, and optimization tools. It is intended for developers who want one model for LLM programs across TypeScript, Python, Java, C++, Go, Rust, and other runtimes.

ax-llm/ax · 2,892 stars · on GitHub · axllm.dev

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 ax-llm/ax --skill ax-audio
Clone the repo
git clone --depth 1 https://github.com/ax-llm/ax

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 ax-audio

README.md
[![agentmods](https://agentmods.dev/badge/skills/ax-llm/ax/ax-audio.svg)](https://agentmods.dev/skills/ax-llm/ax/ax-audio)
Your own site
<a href="https://agentmods.dev/skills/ax-llm/ax/ax-audio"><img src="https://agentmods.dev/badge/skills/ax-llm/ax/ax-audio.svg" alt="Measured on agentmods" height="20"></a>
Per session 85 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,667 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.00085 $0.02667
Opus 5 $0.00043 $0.01333
Sonnet 5 $0.00017 $0.00533
Haiku 4.5 $0.00009 $0.00267

Measured 3d ago against content hash 608b8cd8297d, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-06, from the pricing page.

Security

Grade A, and why

ax-audio 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 3d 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

Copies of this mod

1 near-identical copy found in the catalogue:

  • ax-audio — 100% identical, 0 lines differ
website/static/typescript/.well-known/agent-skills/ax-audio/SKILL.md · 374 lines

How it starts

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

Audio I/O Codegen Rules (@ax-llm/ax)

Use this skill for audio in Ax. Pick the smallest audio surface that matches the job:

  • Use ai.transcribe(...) for batch speech-to-text.
  • Use ai.speak(...) for batch text-to-speech.
  • Use speech:audio signature outputs for structured programs that should return synthesized audio artifacts.
  • Use .chat() audio config for conversational or realtime audio turns.

Core Rules

  • Input :audio is an audio input value: { data, format?, mimeType?, sampleRate?, channels? }.
  • Output :audio is a scripted audio artifact. The model returns plain text for that field; Ax synthesizes it after structured output parsing.
  • Output audio JSON schema is model-facing string, not a binary object.
  • Agents transcribe input audio fields before planner/executor/responder stages by default, so agent stages see text instead of base64 audio.
  • Realtime and conversational audio still use .chat() and modelConfig.audio.
  • Batch signature audio artifacts use forward-time speech options, not modelConfig.audio.

Direct Batch APIs

import { ai } from '@ax-llm/ax';

const llm = ai({ name: 'openai', apiKey: process.env.OPENAI_APIKEY! });

const transcript = await llm.transcribe({
  audio: { data: base64Wav, format: 'wav' },
  model: 'gpt-4o-mini-transcribe',
  language: 'en',
  prompt: 'Product support call',
});

const speech = await llm.speak({
  text: transcript.text,
  model: 'gpt-4o-mini-tts',
  voice: 'alloy',
  format: 'mp3',
});

console.log(transcript.text);
console.log(speech.data);
console.log(speech.transcript);

Providers without the requested batch audio capability throw AxMediaNotSupportedError.

Signature Audio Artifacts

import { ai, ax } from '@ax-llm/ax';

const llm = ai({ name: 'openai', apiKey: process.env.OPENAI_APIKEY! });
const say = ax('question:string -> speech:audio, summary:string');

const result = await say.forward(
  llm,
  { question: 'Explain retries in one sentence.' },
  {
    speech: {
      speak: { voice: 'alloy', format: 'mp3' },
      fields: {
        speech: { voice: 'alloy' },
      },
    },
  }
);

console.log(result.summary);
console.log(result.speech.data);
console.log(result.speech.mimeType);
console.log(result.speech.transcript);

Read the full file on GitHub · 374 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. 3d ago First seen · 374 lines · 85 tokens per session scan A 608b8cd8297d

Subscribe to this mod's changes

ax-audio is a skill published in the GitHub repository ax-llm/ax (2,892 stars, last pushed yesterday), licensed Apache-2.0. It adds 85 tokens to every session and 2,667 once invoked, about $0.0004 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-09-03.

Related

Other skills, from other repositories

dspy

Build complex AI systems with declarative programming, optimize prompts automatically, create modular RAG systems and agents with DSPy - Stanford NLP's framework for systematic LM programming.

davila7/claude-code-templates · 35 tokens

langchain

Framework for building LLM-powered applications with agents, chains, and RAG. Supports multiple providers (OpenAI, Anthropic, Google), 500+ integrations, ReAct agents, tool calling, memory management, and vector store retrieval. Use for building chatbots, question-answering systems, autonomous agents, or RAG…

davila7/claude-code-templates · 79 tokens

llamaindex

Data framework for building LLM applications with RAG. Specializes in document ingestion (300+ connectors), indexing, and querying. Features vector indices, query engines, agents, and multi-modal support. Use for document Q&A, chatbots, knowledge retrieval, or building RAG pipelines. Best for data-centric LLM…

davila7/claude-code-templates · 70 tokens

sglang

Fast structured generation and serving for LLMs with RadixAttention prefix caching. Use for JSON/regex outputs, constrained decoding, agentic workflows with tool calls, or when you need 5× faster inference than vLLM with prefix sharing. Powers 300,000+ GPUs at xAI, AMD, NVIDIA, and LinkedIn.

davila7/claude-code-templates · 72 tokens

spark-environment-setup

Set up a working ML training/inference environment on NVIDIA DGX Spark (GB10, aarch64, CUDA 13). Use when installing PyTorch/Unsloth/TRL/vLLM on DGX Spark, hitting libcudart or wheel-ABI errors on aarch64, or choosing between NGC containers and bare pip installs.

wshobson/agents · 76 tokens

spark-memory-thermal-ops

Manage unified memory and thermals during long-running ML jobs on NVIDIA DGX Spark. Use when planning memory headroom for a training run on GB10, when a job OOMs on unified memory, or when monitoring temperature and power during multi-hour training.

wshobson/agents · 59 tokens