speech-mcp AGENTS.md

speech-mcp AGENTS.md is an instructions file for Codex, OpenCode from sandraschi/speech-mcp. It costs 1,384 tokens per session, scanned A, original, MIT.

A repository instruction file for speech-mcp, a speech gateway that connects coding agents and applications to speech, voice-cloning, wake-word, and retrieval services. It describes the project's architecture, providers, ports, environment variables, and coding rules.

In plain words
What is it for?
Use it when working on the speech-mcp repository. It helps locate the Vite front end, FastAPI back end, MCP SSE endpoint, provider configuration, LanceDB retrieval data, and local wake-word service.
Why use it?
It gives coding agents the project context needed to change the repository without guessing how its front end, back end, MCP connection, speech providers, and database fit together. It also records required language and style conventions.

Instructions file for CodexOpenCode

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.

agentmods
npx agentmods add instructions/sandraschi/speech-mcp/agents-md
Clone the repo
git clone --depth 1 https://github.com/sandraschi/speech-mcp

Made for: Codex, OpenCode.

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 speech-mcp AGENTS.md

README.md
[![agentmods](https://agentmods.dev/badge/instructions/sandraschi/speech-mcp/agents-md.svg)](https://agentmods.dev/instructions/sandraschi/speech-mcp/agents-md)
Your own site
<a href="https://agentmods.dev/instructions/sandraschi/speech-mcp/agents-md"><img src="https://agentmods.dev/badge/instructions/sandraschi/speech-mcp/agents-md.svg" alt="Measured on agentmods" height="20"></a>
Per session 1,384 This file is loaded in full into every session.
When invoked 1,384 The same file — it is already loaded in full.
Security scan A 0 findings. Scan, not verified.
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 $0.01384 $0.01384
Opus 5 $0.00692 $0.00692
Sonnet 5 $0.00277 $0.00277
Haiku 4.5 $0.00138 $0.00138

Measured 4d ago against content hash b17b466c13b2, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

speech-mcp AGENTS.md 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 4d 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.

AGENTS.md · 125 lines

How it starts

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

AGENTS.md — speech-mcp

Rules for AI coding agents (Claude, Cursor, Windsurf, Goose) working on this repo.

Project Identity

  • Name: speech-mcp
  • Purpose: Multi-provider speech gateway — Gemini Live, Hume AI, ElevenLabs TTS + voice cloning
  • Owner: Sandra Schipal, Vienna
  • Fleet role: Voice AI bridge for the entire fleet — TTS, STT, wake word, RAG

Architecture Quick Reference

FastMCP stdio server  <──>  Claude Desktop / MCP clients
       │
FastAPI REST :10909  <──>  React/Vite frontend :10908
       │
MCP SSE :10909/mcp  <──>  Bridge target for ProxyProvider
       │
Providers (configured via .env)
  ├── Gemini 3.1 Flash TTS      (GOOGLE_API_KEY)
  ├── Hume AI Octave + EVI      (HUME_API_KEY)
  ├── ElevenLabs TTS + Cloning  (ELEVENLABS_API_KEY)
  ├── Gemma 4 local             (no key required)
  └── Windows SAPI5             (no key required)
       │
LanceDB (RAG)  ←  data/lancedb/
       │
openWakeWord (local wake word)  ←  no API key required

Ports

Service Port
Frontend (Vite) 10908
Backend (FastAPI + MCP SSE) 10909

Code Rules

Python

  • Python 3.12+ — use modern type hints (str | None, TypeAlias)
  • Async-first: all MCP tools must be async def — no blocking on event loop
  • Type annotations: all tool params use Annotated[T, Field(description="...")] — no Args: blocks
  • No global state except _timers and _log_queue in server.py
  • Logging: use logging.getLogger(__name__) — never print()
  • Line length: 120 chars (ruff enforces)

Tool Registration

  • Tools registered via @mcp.tool() decorator in domain modules under src/speech_mcp/tools/
  • Portmanteau imports re-exported in src/speech_mcp/tools/__init__.py
  • All tools return {"success": bool, ...} dict
  • List/status/stats tools use @mcp.tool(app=True) with Prefab UI
  • Long-running tools use @mcp.tool(task=True) (background tasks)

Docstrings

  • Summary: 1-3 lines
  • ## Return Format: explicit JSON structure
  • ## Examples: 1-3 concrete calls
  • No Args: blocks — use Annotated in signatures

Read the full file on GitHub · 125 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. 4d ago First seen · 125 lines · 1,384 tokens per session scan A b17b466c13b2

Subscribe to this mod's changes

speech-mcp AGENTS.md is an instructions file published in the GitHub repository sandraschi/speech-mcp (2 stars, last pushed 16d ago), licensed MIT. It adds 1,384 tokens to every session, about $0.0069 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.