This commit is contained in:
Saufi
2026-06-02 17:35:45 +08:00
commit 4ef99b1f81
148 changed files with 21134 additions and 0 deletions

60
config/speech2text.php Normal file
View File

@@ -0,0 +1,60 @@
<?php
return [
/*
|--------------------------------------------------------------------------
| Transcription Engine
|--------------------------------------------------------------------------
*/
'transcription' => [
'engine' => env('TRANSCRIPTION_ENGINE', 'faster-whisper'),
'worker_url' => env('TRANSCRIPTION_WORKER_URL', 'http://transcription-worker:8000'),
'model' => env('WHISPER_MODEL', 'small'),
'language' => env('WHISPER_LANGUAGE', 'ms'),
],
/*
|--------------------------------------------------------------------------
| Upload Limits
|--------------------------------------------------------------------------
*/
'upload' => [
'max_mb' => (int) env('PRIVATE_AUDIO_MAX_MB', 200),
'allowed_mimes' => [
'audio/mpeg',
'audio/mp3',
'audio/wav',
'audio/x-wav',
'audio/mp4',
'audio/x-m4a',
'audio/aac',
'video/mp4',
'audio/ogg',
'audio/flac',
'audio/webm',
],
'allowed_extensions' => ['mp3', 'wav', 'm4a', 'mp4', 'aac', 'ogg', 'flac', 'webm'],
],
/*
|--------------------------------------------------------------------------
| Ollama Optional Post-processing
|--------------------------------------------------------------------------
*/
'ollama' => [
'enabled' => env('OLLAMA_ENABLED', false),
'base_url' => env('OLLAMA_BASE_URL', 'http://ollama:11434'),
'model' => env('OLLAMA_MODEL', 'llama3.1'),
],
/*
|--------------------------------------------------------------------------
| Storage Path Templates
|--------------------------------------------------------------------------
*/
'storage' => [
'audio_path' => 'transcriptions/{uuid}/audio',
],
];