feat(backend): integrate document deletion and grounded speech providers
Enable replay-safe document deletion and public deployment model identifiers with the forward voice-model schema revision. Add GapGPT dialogue and ElevenLabs speech routing, strict extractive grounding, ten-source retrieval and regression coverage. Validation: 199 targeted provider-free tests passed. The full provider-free run stalled and was interrupted; PostgreSQL acceptance was not run because TEST_DATABASE_URL is unset.
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
"""Public identifiers only; deployment owns the single model for each role."""
|
||||
|
||||
|
||||
def model_catalog(ingest, voice):
|
||||
rows = []
|
||||
for role, label, model in (
|
||||
('embedding', 'مدل امبدینگ', ingest.embedding_model),
|
||||
('ocr', 'مدل استخراج اسناد', ingest.vision_model),
|
||||
):
|
||||
if model:
|
||||
rows.append(dict(id=role, label=label, model=model))
|
||||
if 'local_s2s' in {voice.provider, *voice.voice_selectable_providers} and voice.local_s2s_enabled:
|
||||
for role, label, model in (
|
||||
('dialogue', 'مدل گفتگوی سرویس لوکال', voice.local_s2s_llm_model),
|
||||
('stt', 'تبدیل گفتار به متن سرویس لوکال', voice.local_s2s_stt_model),
|
||||
('tts', 'تبدیل متن به گفتار سرویس لوکال', voice.local_s2s_tts_model),
|
||||
):
|
||||
if model:
|
||||
rows.append(dict(id=role, label=label, model=model))
|
||||
for provider in ('openai', 'gemini'):
|
||||
if provider in {voice.provider, *voice.voice_selectable_providers}:
|
||||
model = voice.openai_realtime_model if provider == 'openai' else voice.gemini_model
|
||||
rows.append(dict(id=provider, label='مدل صوتی ' + provider, model=model))
|
||||
return rows
|
||||
Reference in New Issue
Block a user