Borrowing it
Nothing to install: this file belongs to yyyzl/push-2-talk. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/yyyzl/push-2-talk/main/CLAUDE.mdgit clone --depth 1 https://github.com/yyyzl/push-2-talkWrote 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.
[](https://agentmods.dev/instructions/yyyzl/push-2-talk/claude-md)<a href="https://agentmods.dev/instructions/yyyzl/push-2-talk/claude-md"><img src="https://agentmods.dev/badge/instructions/yyyzl/push-2-talk/claude-md/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.
<a href="https://agentmods.dev/instructions/yyyzl/push-2-talk/claude-md"><img src="https://agentmods.dev/badge/instructions/yyyzl/push-2-talk/claude-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.07744 | $0.07744 |
| Opus 5.5 | $0.03098 | $0.03098 |
| Sonnet 5.5 | $0.01549 | $0.01549 |
| Haiku 4.5 | $0.00774 | $0.00774 |
Grade A, and why
push-2-talk 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 1mo 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.
How it starts
The opening of the file, as written. The whole thing — 680 lines — stays where its author put it; the contents beside it link to each section on GitHub.
CLAUDE.md
This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
平台实现原则
本项目保持 Windows 原生体验,并通过平台适配器开发 macOS 支持。详见 PLATFORM_ARCHITECTURE.md。
- 共用 ASR、LLM、TNL 和业务流程;系统能力通过
platform接口调用。 - Windows 实现继续使用 GetAsyncKeyState、SendInput、UIA、Audio Session,不要求两平台共用底层 API。
- macOS 原生对象、线程约束和权限处理封装在
platform/macos/。 - 业务层只持有不透明 InputTarget,恢复目标失败时禁止继续粘贴。
- 编译与实机测试分别在对应系统执行。macOS 当前为原型,不宣称完整兼容。
版本兼容性原则
本轮升级兼容验收基线是线上最新正式版 v1.6.1(tag 对应 725aab0561f040f6e3203e73256b08a7a3d9ae43,2026-09-28 确认)。升级必须能直接读取该版本配置,保留凭据、提供方/模型、提示词、热键和词库,无需用户重新配置。
- 兼容迁移由后端配置入口负责;读取失败不能退回默认值并覆盖原文件。
- 内部模块、IPC 和前端状态可以随应用一起重构,但不能借机改变已保存设置的语义。
- 配置与数据格式的更改必须经过基线样本的加载、修改、保存、重启行为测试;现有更早迁移逻辑可保留,不额外承诺任意历史版本。
- 架构职责与实施状态见 架构整顿。
Project Overview
PushToTalk is a desktop application built with Tauri 2.0 that enables voice-to-text input and AI-powered assistance via global keyboard shortcuts. The architecture follows a clear separation between:
- React frontend (TypeScript + Tailwind CSS) for UI
- Rust backend (Tauri) for system-level operations
Core Workflows
1. Dictation Mode (按住/松手录音)
- Press Ctrl+Win (or custom hotkey) → Records audio → Release key → Transcribes via ASR API → Optional LLM post-processing → Auto-inserts text into active window
- Supports two recording modes:
- Press Mode: Hold key to record, release to stop (traditional)
- Toggle Mode: Press F2 to start, press F2 again to finish (prevents accidental stops)
2. AI Assistant Mode (智能指令模式)
- Press Alt+Space (or custom hotkey) → Captures selected text → Records voice command → Processes with context-aware LLM → Replaces/inserts text
- Two operating modes:
- Q&A Mode: No text selected, ask questions and get answers
- Text Processing Mode: Text selected, give commands to transform selected text
Key Features
- Dual Recording Modes:
- Press mode (hold to record)
- Toggle/Release mode (press once to start, press again to finish, F2 default)
- AI Assistant Mode: Context-aware text processing with voice commands (Alt+Space default), supports text-based follow-up in result panel
- Custom Hotkey Binding: 73 keys supported (modifiers, letters, numbers, F1-F12, arrows, etc.)
- Multi-ASR Support: Alibaba Qwen (realtime/HTTP), Doubao (realtime/HTTP), Doubao IME, SiliconFlow SenseVoice
- ASR Fallback Strategy: Automatic fallback from Doubao/Qwen to SenseVoice with parallel racing (Doubao IME currently runs without fallback)
- TNL Normalization Layer: Deterministic text normalization between ASR and LLM (pinyin/phonetic matching, single-letter merge, hyphen dictionary rewrite)
- LLM Post-Processing: Optional text polishing, translation, or formatting via OpenAI-compatible APIs
- Visual Feedback: Overlay window shows recording status with real-time waveform visualization
- Audio Feedback: Start/stop beep sounds via rodio player
- Transcription History: Automatic history tracking with search and copy functionality
- Builtin Dictionary Runtime Refresh: Background pull + atomic cache update + frontend dynamic refresh event
- System Tray: Minimize to tray on close, auto-start on boot, and quick runtime switches for ASR/post-processing/dictionary enhancement
- Multi-Configuration: Save and switch between different LLM prompt presets
- Auto-Update: Tauri Plugin Updater v2 with 6 mirror endpoints and cross-version release notes aggregation
- Personal Dictionary: Custom hotword list for improved recognition of professional terms
- VAD (Voice Activity Detection): Smart silence detection with hangover mechanism to prevent word clipping
- AGC (Automatic Gain Control): Auto volume adjustment for better recognition of soft speech
- Mute Other Apps: Optional feature to mute other applications during recording
- Multi-Monitor Support: Overlay window automatically adapts to multi-display environments
- Auto Vocabulary Learning: Monitors user corrections to ASR errors and automatically learns proper nouns and terms
- UIA Text Reading: Uses Windows UI Automation API for non-intrusive text capture (replaces clipboard method)
- LLM Provider Registry: Multi-provider management with connection testing and latency display
- Theme Support: Light/dark theme switching
- Global Notice Capsule: Fixed top-layer status capsule (
GlobalNoticeHost+NoticeCapsule) decoupled from layout flow
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.
- 1mo ago Changed · -93 lines · -1,199 tokens per session 35603be4bae8
- 2mo ago First seen · 773 lines · 8,943 tokens per session scan A 7db2251eef6d
push-2-talk CLAUDE.md is an instructions file published in the GitHub repository yyyzl/push-2-talk (185 stars, last pushed 1mo ago), licensed MIT. It adds 7,744 tokens to every session, about $0.0310 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-08-30.
push-2-talk CLAUDE.md compared with instructions from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| push-2-talk CLAUDE.mdyyyzl/push-2-talk | Instructions file | 185 | 1mo ago | MIT | A | 7,744 | Claude Code |
| vscode buildNext.instructions.mdmicrosoft/vscode | Instructions file | 195k | yesterday | MIT | A | 9,719 | GitHub Copilot |
| next.js AGENTS.mdvercel/next.js | Instructions file | 143k | yesterday | MIT | A | 7,461 | Codex, OpenCode |
| langchain AGENTS.mdlangchain-ai/langchain | Instructions file | 149k | yesterday | MIT | A | 4,680 | Codex, OpenCode |
| vscode oss-third-party-notices.instructions.mdmicrosoft/vscode | Instructions file | 195k | yesterday | MIT | A | 5,516 | GitHub Copilot |
| vscode copilot-instructions.mdmicrosoft/vscode | Instructions file | 195k | yesterday | MIT | A | 3,093 | GitHub Copilot |
| deepseek-harness AGENTS.mddeepseek-ai/deepseek-harness | Instructions file | 274k | 2d ago | MIT | A | 4,313 | Codex, OpenCode |