Skip to content

OperationSettingsContext

Profile-scoped operation settings: the curated Whisper transcription options, the default clean_audio flag, and the conversion options that the single-op and batch flows send to the server. Persisted per profile in localStorage. An unset Whisper field is omitted from requests, so the server keeps its own tuned default rather than being overridden.

Interfaces

OperationSettings

Defined in: src/contexts/OperationSettingsContext.tsx:23

The full client-side operation settings for one profile.

Properties

Property Type Description Defined in
cleanAudio boolean Default clean_audio for transcribe jobs. src/contexts/OperationSettingsContext.tsx:27
convert ConvertOpts Conversion opts for convert jobs. src/contexts/OperationSettingsContext.tsx:29
transcribe TranscribeOpts Curated Whisper opts, shared by transcribe and generate_srt. src/contexts/OperationSettingsContext.tsx:25

OperationSettingsContextType

Defined in: src/contexts/OperationSettingsContext.tsx:75

OperationSettingsContextType Shape of the operation-settings context.

Properties

Property Type Description Defined in
convertOpts () => Record\<string, unknown> Opts payload for a convert job. src/contexts/OperationSettingsContext.tsx:85
replace (next) => void Commits a new settings object (persists it for the active profile). src/contexts/OperationSettingsContext.tsx:78
settings OperationSettings - src/contexts/OperationSettingsContext.tsx:76
whisperOpts () => Record\<string, unknown> The curated Whisper opts (unset fields dropped), shared by transcribe and generate_srt. Callers add clean_audio for transcribe. src/contexts/OperationSettingsContext.tsx:83

Functions

defaultOperationSettings()

function defaultOperationSettings(): OperationSettings;

Defined in: src/contexts/OperationSettingsContext.tsx:38

A fresh copy of the defaults: everything unset, so every operation falls back to the server's own tuned default until the user overrides it.

Returns

OperationSettings


OperationSettingsProvider()

function OperationSettingsProvider(props): Element;

Defined in: src/contexts/OperationSettingsContext.tsx:96

A provider for the OperationSettingsContext.

Parameters

Parameter Type Description
props { children: ReactNode; } The provider children.
props.children ReactNode -

Returns

Element

The provider.


useOperationSettings()

function useOperationSettings(): OperationSettingsContextType;

Defined in: src/contexts/OperationSettingsContext.tsx:150

Hook for consuming the operation-settings context.

Returns

OperationSettingsContextType

The operation-settings context.