Speakr is a personal, self-hosted web application designed for transcribing audio recordings
Python
fix: admin vector-store panel reports the real chunking strategy and target size instead of hardcoded 500/50 characters
Murtaza Nasir4a818f154a8b
diff --git a/src/api/admin.py b/src/api/admin.pyindex 10b2879e..caf3abc4 100644--- a/src/api/admin.py+++ b/src/api/admin.py@@ -1557,6 +1557,10 @@ def admin_inquire_status():# Embedding configuration surfaced to the UI'embedding_model': EMBEDDING_MODEL,'embedding_provider': 'api' if USE_API_EMBEDDINGS else 'local',+ # Chunking configuration (segment-aware since the speaker/timestamp+ # chunk metadata rework; 'legacy' = plain 500-char windows)+ 'chunking_strategy': os.environ.get('CHUNKING_STRATEGY', 'segment').strip().lower(),+ 'chunk_target_chars': int(os.environ.get('CHUNK_TARGET_CHARS', '1400')),'embedding_base_url': EMBEDDING_BASE_URL or None,'embedding_dimensions_override': EMBEDDING_DIMENSIONS,'embedding_identifier': EMBEDDING_IDENTIFIER,diff --git a/static/locales/de.json b/static/locales/de.jsonindex b2cbd644..568d8fb8 100644--- a/static/locales/de.json+++ b/static/locales/de.json@@ -147,6 +147,9 @@"budgetWarnings": "Budget-Warnungen","characters": "Zeichen","chunkSize": "Chunk-Größe",+ "chunkingLegacy": "Zeichenfenster (Alt)",+ "chunkingSegmentAware": "Segmentbasiert (Sprecherbeiträge + Zeitstempel)",+ "chunkingStrategy": "Chunking","complete": "abgeschlossen","completedRecordings": "Abgeschlossen","confirmPasswordLabel": "Passwort Bestätigen",diff --git a/static/locales/en.json b/static/locales/en.jsonindex 8a251e0a..38e591aa 100644--- a/static/locales/en.json+++ b/static/locales/en.json@@ -147,6 +147,9 @@"budgetWarnings": "Budget Warnings","characters": "characters","chunkSize": "Chunk Size",+ "chunkingLegacy": "Character windows (legacy)",+ "chunkingSegmentAware": "Segment-aware (speaker turns + timestamps)",+ "chunkingStrategy": "Chunking","complete": "complete","completedRecordings": "Completed","confirmPasswordLabel": "Confirm Password",diff --git a/static/locales/es.json b/static/locales/es.jsonindex 8618f472..db0f4719 100644--- a/static/locales/es.json+++ b/static/locales/es.json@@ -147,6 +147,9 @@"budgetWarnings": "Advertencias de Presupuesto","characters": "caracteres","chunkSize": "Tamaño del Fragmento",+ "chunkingLegacy": "Ventanas de caracteres (heredado)",+ "chunkingSegmentAware": "Por segmentos (turnos de hablante + marcas de tiempo)",+ "chunkingStrategy": "Fragmentación","complete": "completado","completedRecordings": "Completadas","confirmPasswordLabel": "Confirmar contraseña",diff --git a/static/locales/fr.json b/static/locales/fr.jsonindex c6ec740b..986113db 100644--- a/static/locales/fr.json+++ b/static/locales/fr.json@@ -147,6 +147,9 @@"budgetWarnings": "Alertes de Budget","characters": "caractères","chunkSize": "Taille du Morceau",+ "chunkingLegacy": "Fenêtres de caractères (hérité)",+ "chunkingSegmentAware": "Par segments (tours de parole + horodatages)",+ "chunkingStrategy": "Découpage","complete": "terminé","completedRecordings": "Terminés","confirmPasswordLabel": "Confirmer le mot de passe",diff --git a/static/locales/pt-BR.json b/static/locales/pt-BR.jsonindex fb60b518..f3f9a998 100644--- a/static/locales/pt-BR.json+++ b/static/locales/pt-BR.json@@ -147,6 +147,9 @@"budgetWarnings": "Avisos de Orçamento","characters": "caracteres","chunkSize": "Tamanho do Fragmento",+ "chunkingLegacy": "Janelas de caracteres (legado)",+ "chunkingSegmentAware": "Por segmentos (falas + carimbos de tempo)",+ "chunkingStrategy": "Fragmentação","complete": "completo","completedRecordings": "Concluído","confirmPasswordLabel": "Confirmar Senha",diff --git a/static/locales/ru.json b/static/locales/ru.jsonindex ea10b1be..357eee3d 100644--- a/static/locales/ru.json+++ b/static/locales/ru.json@@ -147,6 +147,9 @@"budgetWarnings": "Предупреждения о бюджете","characters": "символов","chunkSize": "Размер фрагмента",+ "chunkingLegacy": "Оконное по символам (устаревшее)",+ "chunkingSegmentAware": "По сегментам (реплики + метки времени)",+ "chunkingStrategy": "Разбиение","complete": "завершено","completedRecordings": "Завершено","confirmPasswordLabel": "Подтвердите пароль",diff --git a/static/locales/zh.json b/static/locales/zh.jsonindex d3d1f58e..193a9859 100644--- a/static/locales/zh.json+++ b/static/locales/zh.json@@ -147,6 +147,9 @@"budgetWarnings": "预算警告","characters": "字符","chunkSize": "块大小",+ "chunkingLegacy": "字符窗口(旧版)",+ "chunkingSegmentAware": "按语段(发言轮次+时间戳)",+ "chunkingStrategy": "分块方式","complete": "完成","completedRecordings": "已完成","confirmPasswordLabel": "确认密码",diff --git a/templates/admin.html b/templates/admin.htmlindex 0e6a501b..046a8efa 100644--- a/templates/admin.html+++ b/templates/admin.html@@ -1110,11 +1110,11 @@ Summarization Instructions:<div class="grid grid-cols-2 gap-4 text-sm"><div><span class="text-[var(--text-muted)]">${t('adminDashboard.chunkSize')}:</span>- <span class="ml-2 text-[var(--text-primary)]">500 ${t('adminDashboard.characters')}</span>+ <span class="ml-2 text-[var(--text-primary)]">${ inquireStatus.chunking_strategy === 'legacy' ? ('500 ' + t('adminDashboard.characters')) : ((inquireStatus.chunk_target_chars || 1400) + ' ' + t('adminDashboard.characters')) }</span></div><div>- <span class="text-[var(--text-muted)]">${t('adminDashboard.overlap')}:</span>- <span class="ml-2 text-[var(--text-primary)]">50 ${t('adminDashboard.characters')}</span>+ <span class="text-[var(--text-muted)]">${t('adminDashboard.chunkingStrategy')}:</span>+ <span class="ml-2 text-[var(--text-primary)]" v-text="inquireStatus.chunking_strategy === 'legacy' ? t('adminDashboard.chunkingLegacy') : t('adminDashboard.chunkingSegmentAware')"></span></div><div><span class="text-[var(--text-muted)]">${t('adminDashboard.embeddingModel')}:</span>