-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.env.example
More file actions
130 lines (120 loc) · 6.85 KB
/
Copy path.env.example
File metadata and controls
130 lines (120 loc) · 6.85 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
# Pocket Casts Ad-Free Pipeline — environment template
#
# ─── Quick start ────────────────────────────────────────────────────────────
# 1. cp .env.example .env
# 2. Fill in POCKETCASTS_EMAIL and POCKETCASTS_PASSWORD below. (Required.)
# 3. (Optional) Pick an LLM backend. Defaults to local Ollama — no key needed.
# 4. source .env (or run `start_services.sh`, which sources it for you.)
#
# ─── Which LLM backend should I pick? ──────────────────────────────────────
# • Local Ollama — RECOMMENDED for most users. Free, private,
# needs 16-48 GB RAM. Works out of the box.
# • OpenRouter (cloud) — CHEAPEST if you don't have a beefy Mac.
# ~$0.001 per episode with deepseek-v4-flash.
# • OpenAI / Groq / self-host — any OpenAI-compatible endpoint.
# • Anthropic Claude — most accurate, priciest.
# Pick ONE block from "LLM BACKEND" below and uncomment it.
# See README "Choosing an LLM backend" for the full comparison.
#
# Never commit your real .env — it's already in .gitignore.
# ============================================================================
# REQUIRED — set these two values, the rest has sensible defaults
# ============================================================================
export POCKETCASTS_EMAIL='you@example.com'
export POCKETCASTS_PASSWORD='your-pocket-casts-password'
# ============================================================================
# LLM BACKEND — pick ONE block, uncomment, fill in if needed.
# Leave everything commented to use the default (local Ollama).
# ============================================================================
# --- Option A: Local Ollama (RECOMMENDED for most users) ------------------
# Works out of the box if `ollama serve` is running locally.
# Pick a model that fits your machine — see README "Model recommendations".
# ≥ 48 GB free RAM: qwen3:32b or qwen3.5:35b-a3b
# 24-48 GB: qwen3:14b (recommended for 36 GB Macs)
# 8-24 GB: llama3.1:8b
#
# export LLM_PROVIDER='ollama'
# export OPENAI_MODEL='qwen3:14b'
# export OPENAI_BASE_URL='http://localhost:11434/v1'
# --- Option B: OpenRouter (CHEAPEST cloud) --------------------------------
# Get an API key at https://openrouter.ai/keys
#
# export LLM_PROVIDER='openrouter'
# export OPENROUTER_API_KEY='sk-or-v1-your-key-here'
# export OPENAI_MODEL='deepseek/deepseek-v4-flash'
# Pin the cheapest host: copy the slugs from the model's Providers tab on
# openrouter.ai. Without this, OpenRouter load-balances at ~3× the price.
# export OPENROUTER_PROVIDER_ORDER='GMICloud,Novita,Alibaba'
# export OPENROUTER_ALLOW_FALLBACKS='false'
# Or auto-pick the cheapest host per request (no manual pinning):
# export OPENROUTER_PROVIDER_SORT='price'
# --- Option C: Any OpenAI-compatible API (OpenAI, Groq, vLLM, Together) -
#
# export LLM_PROVIDER='openai-compatible'
# export OPENAI_BASE_URL='https://api.openai.com/v1'
# export OPENAI_API_KEY='sk-your-key'
# export OPENAI_MODEL='gpt-4o-mini'
# --- Option D: Anthropic Claude (direct API) ------------------------------
#
# export LLM_PROVIDER='anthropic'
# export ANTHROPIC_API_KEY='sk-ant-your-key-here'
# ============================================================================
# OPTIONAL — ad-cut padding (defaults work for typical host-read ads)
# ============================================================================
# These adjust how MinusPod slices ads around detected boundaries.
# Override only if you're seeing missed cuts or false positives.
#
# Pre-roll / standard post-roll padding in seconds.
# • Change if: ads bleed into the show (lower these) or you get false
# positives at the edges of episodes (raise these).
# export AD_START_PAD=1.5
# export AD_END_PAD=2.0
# Extra padding when an ad ends at the very end of the file
# (catches musical outros that Whisper failed to transcribe).
# • Change if: post-roll ads aren't being cut and you hear music at the end.
# export AD_END_PAD_TAIL=5.0
# Minimum untranscribed-tail length (seconds) before we treat it as a post-roll.
# • Change if: episodes with long silent endings are getting extra cuts.
# export TAIL_GAP_MIN_SECONDS=60
# ============================================================================
# OPTIONAL — MinusPod runtime tuning (LLM windowing, parallelism)
# ============================================================================
# Window size / overlap for ad-detection LLM analysis. Smaller = faster but
# more LLM calls; larger = fewer calls but more tokens per call.
# • Change if: small/cheap models (e.g. llama3.1:8b) hit context limits —
# lower WINDOW_SIZE_SECONDS so each window fits.
# export WINDOW_SIZE_SECONDS=600
# export WINDOW_OVERLAP_SECONDS=120
# export AD_DETECTION_MAX_TOKENS=4096
# In-flight LLM slot count. Each slot duplicates the KV cache.
# • Change if: you have ≥ 48 GB free RAM AND aren't running a browser/IDE.
# export OLLAMA_NUM_PARALLEL=1
# Max models Ollama keeps resident. Bumping >1 silently doubles memory if
# MinusPod swaps detection ↔ verification ↔ chapters models.
# export OLLAMA_MAX_LOADED_MODELS=1
# How long Ollama keeps the model loaded after the last request
# (`30s` / `5m` / `0` to evict immediately).
# • Short values: quiet the fans between episodes.
# • Long values: save the ~30s reload cost per episode.
# export OLLAMA_KEEP_ALIVE=30s
# ============================================================================
# OPTIONAL — pipeline safety nets (queue-unblocking, stall detection)
# ============================================================================
# Hard cap on a single episode in seconds. If exceeded, the orchestrator
# gives up and moves to the next so the queue stays unblocked.
# • Change if: very long episodes (3+ hours) hit the cap, or you want
# tighter queue throughput.
# export EPISODE_MAX_WALLCLOCK_SECONDS=5400
# If MinusPod's reported stage doesn't change for this many seconds,
# restart whisper-server (the same threshold a second time aborts the episode).
# export EPISODE_STALL_THRESHOLD_SECONDS=900
# Longer cap while MinusPod is on ad-detection LLM windows (default 45 min).
# export EPISODE_STALL_THRESHOLD_LLM_SECONDS=2700
# Per-request timeout for local Ollama during ad detection (MinusPod default 1200s).
# export LLM_TIMEOUT_LOCAL=1200
# ============================================================================
# OPTIONAL — whisper.cpp runtime (set by start_services.sh; rarely overridden)
# ============================================================================
# export HTTP_TIMEOUT_WHISPER=1800
# export API_CHUNK_DURATION_SECONDS=300
# export WHISPER_SKIP_PREPROCESS=1