Skip to content

Voice-to-text dictation app with local (Nvidia Parakeet/Whisper) and cloud models (BYOK). Privacy-first and available cross-platform.

fix(reasoning): propagate disableThinking on cleanup and agent routes (#819)

Gabriel Steincf4be1c0fd36
diff --git a/src/helpers/audioManager.js b/src/helpers/audioManager.js
index 0d0bb3c02..aa08f105e 100644
--- a/src/helpers/audioManager.js
+++ b/src/helpers/audioManager.js
@@ -42,6 +42,7 @@ function resolveReasoningRoute(text, settings, agentName) {
isCustomAgent || isSelfHostedAgent
? settings.dictationAgentCustomApiKey || undefined
: undefined,
+ disableThinking: settings.dictationAgentDisableThinking,
systemPrompt: resolvePrompt("dictationAgent", {
agentName,
language: settings.preferredLanguage,
@@ -51,7 +52,12 @@ function resolveReasoningRoute(text, settings, agentName) {
},
};
}
- if (cleanupReachable) return { kind: "cleanup" };
+ if (cleanupReachable) {
+ return {
+ kind: "cleanup",
+ config: { disableThinking: settings.cleanupDisableThinking },
+ };
+ }
return { kind: "skip" };
}
@@ -1075,13 +1081,14 @@ registerProcessor("pcm-streaming-processor", PCMStreamingProcessor);
if (route.kind === "skip") return normalizedText;
const targetModel = route.kind === "agent" ? route.model : cleanupModel;
- const reasoningConfig = route.kind === "agent" ? route.config : undefined;
+ const reasoningConfig = route.config;
logger.logReasoning("SENDING_TO_REASONING", {
preparedTextLength: normalizedText.length,
model: targetModel,
provider: route.config?.provider || cleanupProvider,
path: route.kind,
+ disableThinking: reasoningConfig?.disableThinking,
});
const result = await this.processWithReasoningModel(
@@ -1358,7 +1365,8 @@ registerProcessor("pcm-streaming-processor", PCMStreamingProcessor);
const reasoned = await this.processWithReasoningModel(
processedText,
effectiveModel,
- agentName
+ agentName,
+ route.config
);
if (reasoned) processedText = reasoned;
}
@@ -2575,7 +2583,8 @@ registerProcessor("pcm-streaming-processor", PCMStreamingProcessor);
const reasoned = await this.processWithReasoningModel(
finalText,
effectiveModel,
- agentName
+ agentName,
+ route.config
);
if (reasoned) finalText = reasoned;
logger.info(