arc53 / arc53/DocsGPT

fix: STT_ENABLE_DIARIZATION setting is wired through but silently discarded in both STT providers

Open Beginner friendly
#2,563 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
18.3k
Forks
2.1k
Avg merge
1d 2h
Merged PRs (30d)
29

Description

## Bug Description

`application/core/settings.py` exposes `STT_ENABLE_DIARIZATION: bool = False` and it is correctly passed through the call chain — `attachments/routes.py:314` and `audio_parser.py:29` both pass `diarize=settings.STT_ENABLE_DIARIZATION` to `stt.transcribe()`. The `BaseSTT` abstract method also declares the parameter.

However both concrete implementations silently discard it:

```python
# openai_stt.py:29 AND faster_whisper_stt.py:42
_ = diarize # no-op
```

Users who set `STT_ENABLE_DIARIZATION=true` receive no diarization and no error or warning.

## Expected Behavior

When `diarize=True` is passed but the provider does not support it, a `logger.warning()` should be emitted so operators know the configuration has no effect.

## Proposed Fix

Replace `_ = diarize` in both providers with a conditional `logger.warning()` block.

Contributor guide

Open the contributing guide

Research direction

Read openai_stt.py:29 and faster_whisper_stt.py:42, then trace the existing logger usage in each provider. Replace the discarded diarize value with a warning when diarize=True, and verify both providers warn that diarization is unsupported while preserving current transcription behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
ai, backend
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Quiet
Clarity
Clearly specified
Newbie friendliness
78/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.