Repository navigation
Expand file tree
/
Copy pathpylon.yaml
More file actions
195 lines (184 loc) · 10 KB
/
Copy pathpylon.yaml
File metadata and controls
195 lines (184 loc) · 10 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
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
# Pylon configuration. Every field is optional — omitted values fall back to
# built-in defaults. ${ENV_VAR} references are expanded from the environment,
# so secrets (API keys) stay out of this file.
# What Pylon says and writes: en, de, es, fr, pt, tr, ru. Empty follows your
# desktop's locale ($LANG) and falls back to English. This is the reply
# language; voice.language below is a different thing — which language the
# microphone is transcribed as.
#
# Settings → Genel and `pylon lang <code>` change the same thing without editing
# this file, and what they set wins over the line below. `pylon lang auto`
# forgets that choice and comes back here.
language: ""
voice:
stt_bin: whisper-cli # whisper.cpp CLI binary (in PATH or absolute)
stt_model: "" # ggml model path, e.g. ~/models/ggml-large-v3.bin
language: auto # auto-detect, or ISO code: tr, en, de, ...
# The capture ends when you stop talking, so record_seconds is a ceiling for a
# runaway recording — not a fixed wait. Silence-stop needs sox (`rec`) on
# Linux/Windows; without it Pylon logs one line and uses the fixed window.
silence_stop: true # end the capture once you go quiet
silence_seconds: 1.0 # how much quiet ends it
silence_threshold: 3.0 # percent of full scale counted as quiet
record_seconds: 15 # ceiling on how long you may talk
# If the capture never starts, your input gain is the first thing to check —
# it matters more than any setting here. Record yourself and look at the level:
# rec -r 16000 -c 1 /tmp/t.wav trim 0 5 && sox /tmp/t.wav -n stat
# Speech should peak around 30-70% of full scale. Much lower and it sits in the
# room's noise floor, where no threshold can separate the two — raise the mic
# instead (Linux/PipeWire: wpctl set-volume @DEFAULT_AUDIO_SOURCE@ 1.0).
# Only then tune silence_threshold: up in a noisy room, down for a soft voice.
# stt_server keeps a whisper.cpp server warm so each turn skips the model load
# (~0.6 s with large-v3-turbo). The daemon owns the process; `pylon listen`
# only talks to it. Leave it out to run stt_bin once per turn instead — and if
# the server is ever unreachable, transcription falls back to stt_bin anyway.
# stt_server:
# bin: /path/whisper.cpp/build/bin/whisper-server
# port: 8910 # host defaults to 127.0.0.1
# args: [] # extra whisper-server flags, e.g. ["-t", "8"]
# tts_cmd: synthesis command — text on stdin, write a WAV to {file}. Engine-
# agnostic. Examples:
# piper: ["piper", "-m", "/path/voice.onnx", "-f", "{file}"]
# edge: ["/path/scripts/edge_tts.sh", "{file}", "tr-TR-EmelNeural"] (Unix)
# Windows (built-in SAPI, no install — Windows PowerShell 5.1):
# ["powershell", "-NoProfile", "-ExecutionPolicy", "Bypass",
# "-File", "C:\\path\\scripts\\tts.ps1", "{file}"]
# XTTS server (natural, GPU): a curl client posting text to the local server:
# ["curl", "-sf", "--data-binary", "@-", "-o", "{file}", "http://127.0.0.1:5067/tts"]
tts_cmd: [] # empty → spoken replies disabled (text still printed)
# record_cmd / play_cmd default per-OS (Linux: `rec` when silence_stop is on,
# else pw-record; pw-play). A record_cmd set here is always used as-is.
# {file}, {seconds} and {silence} are substituted. Examples:
# record_cmd: ["arecord", "-q", "-f", "S16_LE", "-r", "16000", "-c", "1", "-d", "{seconds}", "{file}"]
# play_cmd: ["paplay", "{file}"]
hotkey: "super+p" # informational — bind `pylon listen` in your DE/OS
intent:
router_threshold: 0.8 # local match confidence to skip the API
# LLM fallback chain. Models are tried top-to-bottom; when one hits its quota
# (HTTP 429) or errors, the next is used. Each provider has its own quota
# bucket, so mixing providers spreads load. List one model or many.
models:
- provider: gemini
model: gemini-flash-lite-latest # cheap/fast — first choice
api_key_env: GEMINI_API_KEY
- provider: gemini
model: gemini-flash-latest # used when flash-lite is exhausted
api_key_env: GEMINI_API_KEY
# - provider: openai
# model: gpt-4o-mini
# api_key_env: OPENAI_API_KEY
# - provider: anthropic
# model: claude-haiku-4-5
# api_key_env: ANTHROPIC_API_KEY
persona:
enabled: true
decay_half_life_days: 14 # how fast old style fades
adopt_threshold: 0.3 # min recency-weighted frequency to adopt a trait
style_card_refresh_every: 20 # rebuild style card every N messages
services:
# Google Calendar (Phase 2). End users just run `pylon auth google` and sign in
# — no Google Cloud setup. The project's OAuth client is baked into the build
# (see Makefile GOOGLE_CLIENT_ID). Self-hosters can instead set client_id/
# client_secret here (or point `credentials` at an OAuth client JSON). The
# user's token is written to the encrypted vault (internal/secrets), not to a file.
google:
# client_id: ...
# client_secret: ...
# credentials: ~/.config/pylon/google-credentials.json
calendar_id: primary
# GitHub (Phase 2.2). Personal Access Token — classic needs `repo`+`read:org`,
# or a fine-grained token with PR/issue read. ${ENV} is expanded, so keep the
# token in the environment rather than committing it.
github:
# Secrets are stored encrypted (AES-256-GCM), not here. Save once with
# pylon secret set github
# then reference it as secret:<name>. (Plain values and ${ENV} still work.)
token: secret:github
poll_interval: 15m # background PR poll; empty disables it
commit_reminder: "22:00" # daily "you haven't committed today" nudge
repos: # local repos checked for today's commit
- /path/to/your/repo
# FreshRSS (Phase 2.3) via the Fever API. Enable the API in FreshRSS
# (Settings → Profile → API) and either set api_key directly or give
# username + api_password (key = md5("username:api_password")). ${ENV} expands.
freshrss:
url: "" # e.g. https://rss.example.com — empty disables it
username: ""
api_password: secret:freshrss # save with: pylon secret set freshrss
# Spotify (Phase 2.4) playback control via the Web API. End users just run
# `pylon auth spotify` and connect — no Spotify Dashboard setup. The project's
# OAuth client is baked into the build (see Makefile SPOTIFY_CLIENT_ID) using
# Authorization Code + PKCE, so there is no client secret. Self-hosters can
# instead set client_id here (their app's Redirect URI must exactly match
# http://127.0.0.1:<redirect_port>/callback). The user's token is written to
# the encrypted vault (internal/secrets), not to a file. Playback control
# needs Spotify Premium and an active device.
spotify:
# client_id: ...
redirect_port: 8888
# Weather (Open-Meteo, no API key). Unset location defaults to İstanbul.
weather:
# latitude: 41.0082
# longitude: 28.9784
# name: "İstanbul"
# Docker. Empty socket → /var/run/docker.sock. Recent Docker Desktop on macOS
# does not create that path; use ~/.docker/run/docker.sock (`docker context
# ls` prints the real one).
#
# host is for a daemon reached over the network — and the only way in on
# Windows, where the Engine listens on a named pipe Pylon cannot dial. Write
# it as Docker does; tcp:// is understood and means plain HTTP. token adds a
# Bearer header, for an authenticating proxy in front of the Engine.
docker:
# socket: /var/run/docker.sock
# host: "tcp://localhost:2375"
# token: secret:docker
briefing:
time: "08:00"
timezone: "Europe/Istanbul"
# How the daily briefing is shown. The command receives the text on stdin;
# empty means no banner at all — there is no desktop-notification fallback, so
# the briefing is only printed (and spoken, when tts_cmd is set).
# scripts/briefing_banner.py draws a Wayland layer-shell overlay:
# banner_cmd: ["python3", "/path/scripts/briefing_banner.py"]
# It dismisses itself after 5 seconds; PYLON_BANNER_SECONDS changes that (0
# keeps it up until clicked):
# banner_cmd: ["env", "PYLON_BANNER_SECONDS=10", "python3", "/path/scripts/briefing_banner.py"]
# `pylon briefing` composes one on demand; `pylon briefing --speak` reads it out.
# Work sessions. Pylon records how long each tracked app is open and answers
# "bugün ne kadar çalıştım" from it (`pylon work`, or `pylon work week`). Names
# are process names as the OS reports them — the same form watch_processes uses.
# An empty tracked_apps records nothing; daily_goal_hours: 0 drops the progress
# sentence from the answer. A day starts at midnight in briefing.timezone.
work:
daily_goal_hours: 4
# Stand-up nudge: a banner once a tracked app has been open this long with no
# gap, repeated every 30 minutes while it lasts. 0 turns it off. It measures
# how long the app was open, not how long you were at the keyboard — an editor
# left open over lunch keeps the stretch running.
break_after_hours: 2
tracked_apps:
- code
- cs2
- steam
watch_processes:
- name: code
tasks_on_exit: true
- name: cs2
tasks_on_exit: true
# Runtime paths. Left unset on purpose: the defaults are platform-specific and
# per-user, and pinning one machine's paths into a config that ships everywhere
# helps nobody.
#
# Linux $XDG_RUNTIME_DIR/pylon/pylon.sock (/run/user/<uid>/…)
# fallback /tmp/pylon-<uid>/pylon.sock (macOS, or no XDG_RUNTIME_DIR)
# Windows %LocalAppData%\pylon\pylon.sock
#
# The socket is deliberately not directly in /tmp. That is the one directory
# every other user on the machine can write to, and anything that can reach the
# socket can ask the daemon for a secret or to open the microphone. If you do
# override this, put it somewhere only you can write.
paths:
# socket: /run/user/1000/pylon/pylon.sock
# pid: /run/user/1000/pylon/pylon.pid
# db: /home/you/.config/pylon/pylon.db