Files
Nighthawk 1cafbec4bc Major Rewrite
A rewrite incorporating developments from the last few days.
2025-03-25 01:52:12 -04:00

89 lines
4.2 KiB
YAML

# -------------------------------
# Configuration for Whisper STT
# -------------------------------
whisper:
model: "small.en" # Name of the Whisper model to use for speech-to-text.
sample_rate: 16000 # Audio sample rate (in Hz) for recording and transcription.
# -------------------------------
# Configuration for LM Studio (Chat & TTS)
# -------------------------------
lm:
api_url: "http://127.0.0.1:1234/v1" # Base URL for the LM Studio inference server.
chat:
endpoint: "/chat/completions" # API endpoint for chat-based text generation.
model: "gemma-3-12b-it" # Model identifier for chat generation.
system_prompt: "You are a helpful assistant." # System prompt to set the context.
max_tokens: 256 # Increased for more coherent responses.
temperature: 0.7 # Sampling temperature; controls randomness.
top_p: 0.9 # Top-p (nucleus sampling) value.
repetition_penalty: 1.1 # Penalty factor to reduce repetitive outputs.
max_response_time: 10.0 # Increased timeout (in seconds) for slower responses.
tts:
endpoint: "/completions" # API endpoint for text-to-speech synthesis.
model: "orpheus-3b-ft.gguf@q2_k" # Model identifier for TTS synthesis.
default_voice: "tara" # Default voice for TTS output.
max_tokens: 4096 # Optimal for Orpheus.
temperature: 0.6 # Sampling temperature for TTS.
top_p: 0.9 # Top-p sampling value for TTS generation.
repetition_penalty: 1.0 # Penalty to prevent repetitive TTS output.
speed: 1.0 # More natural speed.
max_segment_duration: 20 # Increased maximum seconds per TTS segment.
# -------------------------------
# TTS Audio Output Configuration
# -------------------------------
tts:
sample_rate: 24000 # Sample rate (in Hz) for the generated TTS audio.
# -------------------------------
# Audio Device Configuration
# -------------------------------
audio:
input_device: null # Specify input device ID, or leave null to use the system default.
output_device: null # Specify output device ID, or leave null to use the system default.
hotword_sample_rate: 16000 # Sample rate for hotword detection.
# -------------------------------
# Voice Activity Detection (VAD) Configuration
# -------------------------------
vad:
mode: 2 # VAD aggressiveness (0 is least, 3 is most aggressive).
frame_duration_ms: 30 # Duration of each audio frame (in ms) for VAD analysis.
silence_threshold_ms: 1000 # Duration (in ms) of consecutive silence to stop recording.
min_record_time_ms: 2000 # Minimum recording duration (in ms).
# -------------------------------
# Hotword Detection Configuration
# -------------------------------
hotword:
enabled: true # Whether hotword detection is enabled.
phrase: "Hey Cassie" # Hotword phrase (case insensitive).
sensitivity: 0.7 # Sensitivity (0-1); higher is more strict.
timeout_sec: 5 # Time (in seconds) to listen for hotword before timeout.
retries: 3 # Maximum attempts to detect the hotword.
# -------------------------------
# Segmentation Configuration for TTS
# -------------------------------
segmentation:
max_words: 60 # Maximum number of words per segment when splitting long TTS responses.
# -------------------------------
# Speech Quality Configuration
# -------------------------------
speech:
normalize_audio: false # Whether to normalize audio volume.
default_pitch: 0 # Pitch adjustment (-20 to +20).
min_speech_confidence: 0.5 # Minimum confidence for accepting speech.
max_retries: 3 # Maximum retries for API calls.
# -------------------------------
# Interaction Configuration
# -------------------------------
interaction:
mode: "both" # Options: "push_to_talk", "hotword", or "both" to enable both simultaneously.
post_audio_delay: 0.5 # Delay (in seconds) after audio playback before next activation.