txtify CLAUDE.md

txtify CLAUDE.md is an instructions file for coding agents from lkmeta/txtify. It costs 1,409 tokens per session, scanned A, original, Apache-2.0.

A repository guide for Txtify, a FastAPI web app that turns uploaded media or YouTube videos into transcripts, translations, subtitles, and documents.

In plain words
What is it for?
Use it to maintain transcription jobs, media conversion, translation, uploads, cancellation, status handling, templates, and Docker deployment.
Why use it?
It explains the job-processing flow and important limits, helping agents avoid breaking status polling, cancellation, worker handling, or duplicated settings.

Instructions file

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/lkmeta/txtify/claude-md
Clone the repo
git clone --depth 1 https://github.com/lkmeta/txtify

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 txtify CLAUDE.md

README.md
[![agentmods](https://agentmods.dev/badge/instructions/lkmeta/txtify/claude-md.svg)](https://agentmods.dev/instructions/lkmeta/txtify/claude-md)
Your own site
<a href="https://agentmods.dev/instructions/lkmeta/txtify/claude-md"><img src="https://agentmods.dev/badge/instructions/lkmeta/txtify/claude-md.svg" alt="Measured on agentmods" height="20"></a>
Per session 1,409 This file is loaded in full into every session.
When invoked 1,409 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.01409 $0.01409
Opus 5 $0.00705 $0.00705
Sonnet 5 $0.00282 $0.00282
Haiku 4.5 $0.00141 $0.00141

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

Security

Grade A, and why

txtify CLAUDE.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.

CLAUDE.md · 51 lines

How it starts

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

Txtify — agent guide

FastAPI web app that transcribes/translates audio & video: YouTube URL or upload → Whisper via stable-ts → optional DeepL translation → export as txt/srt/vtt/sbv/pdf. Single Docker container on port 8011, Jinja2 templates + vanilla JS frontend, SQLite for job state. Deployed from Docker Hub lkmeta/txtify.

Architecture (read this before touching job flow)

  • src/main.py — all HTTP endpoints. POST /transcribe inserts a DB row (the job id), then handle_transcription spawns a detached worker subprocess and stores its OS pid in the same row. The frontend polls GET /status?pid=<job id> — the query param is named pid for historical reasons but it is the job id, not the OS pid. Keep it that way; the OS pid (row column 12) is only for cancellation/kill.
  • src/utils.py — media download/upload handling, worker spawn, format converters (srt/vtt/sbv/pdf). MAX_UPLOAD_SIZE_MB / MAX_VIDEO_DURATION live here — when changing them, update the copy in templates/index.html and templates/faq.html too.
  • src/transcribe_process.py — worker entrypoint; receives the job id as argv[1]. Never look up "the latest row" — that reintroduces the concurrency race fixed in #15.
  • src/models.py — stable-ts transcription + DeepL translation. DeepL may merge/split lines; save_final_transcription aligns best-effort and must never raise on count mismatch.
  • src/db.py — per-operation SQLite connections with WAL (async handlers + worker subprocesses share the file). Don't add a module-level shared connection.
  • GET /history renders the read-only dashboard of past jobs (db.list_jobs, template history.html + static/history.js for client-side sort/filter/paginate). POST /history/delete and POST /history/clear remove a job's files + DB row (both refuse in-flight jobs). All three 404 when ENABLE_HISTORY=False (default True) — the page lists every job by id and there's no auth.
  • src/status.pysingle source of truth for job status strings and the terminal-state guard. The status values are a contract: the frontend (static/scripts.js) branches on the exact strings via /status's phase (=== 'Completed successfully!', === 'Canceled', .includes('Error'), .startsWith('Error:')), and existing DB rows store them — change a VALUE only with a matching frontend change + migration. Use the constants/predicates (PROCESSING, CANCELED, error(), is_locked(), NOT_LOCKED_SQL), never hardcode a status string or the != 'Canceled' AND NOT LIKE '%Error%' guard. test_status.py asserts is_locked (Python) and NOT_LOCKED_SQL (SQLite) agree on every status.
  • Job outputs live in output/<job id>/; output/ is gitignored and dockerignored — media, transcripts, and .db files must never be committed or baked into the image.

Read the full file on GitHub · 51 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 · 51 lines · 1,409 tokens per session scan A a0ec2c5b3679

Subscribe to this mod's changes

txtify CLAUDE.md is an instructions file published in the GitHub repository lkmeta/txtify (135 stars, last pushed 20d ago), licensed Apache-2.0. It adds 1,409 tokens to every session, about $0.0070 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-30.

Related

Other instructions, from other repositories

full-stack-ai-agent-template CLAUDE.md

Instructions for vstorm-co/full-stack-ai-agent-template, covering claude.md, project overview, commands, install dependencies and run tests.

vstorm-co/full-stack-ai-agent-template · 1,305 tokens

full-stack-ai-agent-template AGENTS.md

Instructions for vstorm-co/full-stack-ai-agent-template, covering agents.md, project overview, commands, cli and architecture.

vstorm-co/full-stack-ai-agent-template · 979 tokens

fastapi-langgraph-agent-production-ready-template AGENTS.md

Instructions for wassim249/fastapi-langgraph-agent-production-ready-template, covering ai agent development guide, quick commands, project structure, project overview and quick reference: critical rules.

wassim249/fastapi-langgraph-agent-production-ready-template · 1,955 tokens

pulse8-ai-cortex-knowledge-vault AGENTS.md

Instructions for synpulse8-opensource/pulse8-ai-cortex-knowledge-vault, covering agents.md — pulse8.ai cortex, repository map, environment variables, essential commands and dependencies.

synpulse8-opensource/pulse8-ai-cortex-knowledge-vault · 974 tokens

GooFish-AIMonitor AGENTS.md

Instructions for tristanwqy/GooFish-AIMonitor, covering agents.md — 给 ai 协作者的工程指南, 黄金规则(先读这条), 验证命令(完成前必跑), 代码地图 and 数据模型要点.

tristanwqy/GooFish-AIMonitor · 1,839 tokens

robs_awesome_python_template AGENTS.md

Instructions for tedivm/robs_awesome_python_template, covering agent instructions and key technologies.

tedivm/robs_awesome_python_template · 219 tokens