Spaces:
Running
Running
GitHub Actions commited on
Commit ·
33040d2
1
Parent(s): 8da917e
Deploy 0d0cd6c
Browse files- app/models/chat.py +3 -0
- app/models/pipeline.py +2 -0
app/models/chat.py
CHANGED
|
@@ -22,6 +22,9 @@ class ChatRequest(BaseModel):
|
|
| 22 |
# Bypasses the Gemini fast-path unconditionally so pill follow-ups
|
| 23 |
# always produce cited, chunk-grounded answers rather than TOON summaries.
|
| 24 |
is_followup: bool = False
|
|
|
|
|
|
|
|
|
|
| 25 |
|
| 26 |
|
| 27 |
class ChatResponse(BaseModel):
|
|
|
|
| 22 |
# Bypasses the Gemini fast-path unconditionally so pill follow-ups
|
| 23 |
# always produce cited, chunk-grounded answers rather than TOON summaries.
|
| 24 |
is_followup: bool = False
|
| 25 |
+
# True when submitted from microphone/transcription path.
|
| 26 |
+
# Used only for response-style tuning (audio UX), never for retrieval scope.
|
| 27 |
+
audio_mode: bool = False
|
| 28 |
|
| 29 |
|
| 30 |
class ChatResponse(BaseModel):
|
app/models/pipeline.py
CHANGED
|
@@ -82,6 +82,8 @@ class PipelineState(TypedDict):
|
|
| 82 |
# Stage 1: True when submitted via a follow-up pill button.
|
| 83 |
# Bypasses Gemini fast-path so pill follow-ups always produce cited RAG answers.
|
| 84 |
is_followup: bool
|
|
|
|
|
|
|
| 85 |
latency_ms: int
|
| 86 |
error: Optional[str]
|
| 87 |
interaction_id: Optional[int]
|
|
|
|
| 82 |
# Stage 1: True when submitted via a follow-up pill button.
|
| 83 |
# Bypasses Gemini fast-path so pill follow-ups always produce cited RAG answers.
|
| 84 |
is_followup: bool
|
| 85 |
+
# True when request came from speech-to-text path.
|
| 86 |
+
is_audio_mode: bool
|
| 87 |
latency_ms: int
|
| 88 |
error: Optional[str]
|
| 89 |
interaction_id: Optional[int]
|