Metadata-Version: 2.4
Name: talktype
Version: 0.2.0
Summary: Local-first dictation for macOS — press a hotkey, talk, text appears at your cursor
Project-URL: Homepage, https://github.com/strangeloopcanon/talk
Project-URL: Repository, https://github.com/strangeloopcanon/talk
Project-URL: Issues, https://github.com/strangeloopcanon/talk/issues
Author: Rohit Krishnan
License: MIT
Keywords: dictation,macos,mlx,parakeet,speech-to-text,transcription
Classifier: Development Status :: 4 - Beta
Classifier: Environment :: MacOS X
Classifier: Intended Audience :: Developers
Classifier: Operating System :: MacOS
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Topic :: Multimedia :: Sound/Audio :: Speech
Requires-Python: >=3.11
Requires-Dist: numpy>=1.26
Requires-Dist: openai>=1.108.0
Requires-Dist: parakeet-mlx>=0.4.2
Requires-Dist: pynput>=1.8.1
Requires-Dist: python-dotenv>=1.1.1
Requires-Dist: rumps>=0.4.0
Requires-Dist: sounddevice>=0.5.2
Description-Content-Type: text/markdown

# talk

> **macOS only** (Apple Silicon recommended). Requires Python 3.11+.

Local-first dictation for macOS.
Press a hotkey, talk, text appears at your cursor.

- Parakeet local transcription by default (zero API cost on Apple Silicon).
- OpenAI `gpt-4o-transcribe` fallback with one env switch.
- Automatic paste at cursor (clipboard-safe restore).

## Install

```bash
pip install talktype
```

That's it. On first run, Parakeet model weights (~1.2 GB) download automatically.

### Alternative: from source

```bash
git clone https://github.com/strangeloopcanon/talk.git
cd talk
./scripts/install_macos.sh
./scripts/doctor_macos.sh
./scripts/run_macos.sh
```

## Usage

```bash
talk run
```

- Press `Ctrl+Option+D` to start recording.
- Press `Ctrl+Option+D` again to stop, transcribe, and paste.
- Press `Ctrl+Option+Q` to quit.

### Preflight checks

```bash
talk doctor
```

### File transcription

```bash
talk transcribe-file /path/to/sample.wav
```

## macOS permissions

You must grant your terminal app:

- **Microphone** -- for audio recording
- **Accessibility** -- for paste keystroke automation
- **Input Monitoring** -- for global hotkeys

If paste fails but transcription works, Accessibility permission is usually the issue.

## Configuration

Works out of the box with zero configuration. To customize, create `~/.config/talk/.env`:

```bash
mkdir -p ~/.config/talk
```

Key options (all have sensible defaults):

| Variable | Default | Notes |
|----------|---------|-------|
| `DICTATE_BACKEND` | `parakeet` | `parakeet` (local) or `openai` (cloud) |
| `DICTATE_HOTKEY` | `<ctrl>+<alt>+d` | Toggle recording |
| `DICTATE_QUIT_HOTKEY` | `<ctrl>+<alt>+q` | Quit the app |
| `DICTATE_AUTOPASTE` | `true` | Paste transcription at cursor |
| `PARAKEET_MODEL` | `mlx-community/parakeet-tdt-0.6b-v3` | Local model |
| `OPENAI_API_KEY` | *(empty)* | Required if backend=openai |

See `.env.example` for the full list.

## Switching backend

```bash
# In ~/.config/talk/.env or as env vars:
DICTATE_BACKEND=openai
OPENAI_API_KEY=sk-...
```

## Cleanup

Parakeet model weights are cached in `~/.cache/huggingface/hub/`. To reclaim disk space:

```bash
rm -rf ~/.cache/huggingface/hub/models--mlx-community--parakeet-tdt-0.6b-v3
```
