Skip to content

Commit 868c300

Browse files
author
jakmro
committed
docs: clarify model object structure
1 parent bdfc941 commit 868c300

8 files changed

Lines changed: 8 additions & 8 deletions

File tree

docs/docs/02-hooks/01-natural-language-processing/useSpeechToText.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ Given that STT models can process audio no longer than 30 seconds, there is a ne
6868

6969
**`model`** - Object containing the model name, encoder source, decoder source, and tokenizer source.
7070

71-
- **`modelName`** - A literal of `"moonshine" | "whisper" | "whisperMultilingual` which serves as an identifier for which model should be used.
71+
- **`modelName`** - An enum `AvailableModels` value that serves as an identifier for which model should be used.
7272

7373
- **`encoderSource?`** - A string that specifies the location of a .pte file for the encoder. Defaults to [constants](https://github.com/software-mansion/react-native-executorch/blob/main/packages/react-native-executorch/src/constants/modelUrls.ts) for given model.
7474

docs/docs/02-hooks/02-computer-vision/useOCR.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ interface OCRDetection {
118118

119119
### Arguments
120120

121-
**`model`** - Object containing the model source.
121+
**`model`** - Object containing the detector source, recognizers sources, and language.
122122

123123
- **`detectorSource`** - A string that specifies the location of the detector binary.
124124
- **`recognizerLarge`** - A string that specifies the location of the recognizer binary file which accepts input images with a width of 512 pixels.

docs/docs/02-hooks/02-computer-vision/useVerticalOCR.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ interface OCRDetection {
129129

130130
### Arguments
131131

132-
**`model`** - Object containing the model source.
132+
**`model`** - Object containing the detectors sources, recognizers sources, and language.
133133

134134
- **`detectorLarge`** - A string that specifies the location of the recognizer binary file which accepts input images with a width of 1280 pixels.
135135
- **`detectorNarrow`** - A string that specifies the location of the detector binary file which accepts input images with a width of 320 pixels.

docs/docs/03-typescript-api/01-natural-language-processing/LLMModule.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ To create a new instance of LLMModule, use the constructor with optional callbac
9090

9191
Then, to load the model, use the `load` method. It accepts an object with the following fields:
9292

93-
**`model`** - An object with the following fields:
93+
**`model`** - Object containing the model source, tokenizer source, and tokenizer config source.
9494

9595
- **`modelSource`** - `ResourceSource` specifying the location of the model binary.
9696

docs/docs/03-typescript-api/01-natural-language-processing/SpeechToTextModule.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -167,7 +167,7 @@ To create a new instance of SpeechToTextModule, use the constructor with optiona
167167

168168
Then, to load the model, use the `load` method. It accepts an object with the following fields:
169169

170-
**`model`** - Object containing the following fields:
170+
**`model`** - Object containing the model name, encoder source, decoder source, and tokenizer source.
171171

172172
- **`modelName`** - Identifier for which model to use ('whisper', 'moonshine', or 'whisperMultilingual').
173173

docs/docs/03-typescript-api/01-natural-language-processing/TextEmbeddingsModule.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ type ResourceSource = string | number | object;
4141

4242
To load the model, use the `load` method. It accepts an object:
4343

44-
**`model`** - Object containing the model source.
44+
**`model`** - Object containing the model source and tokenizer source.
4545

4646
- **`modelSource`** - A string that specifies the location of the model binary.
4747
- **`tokenizerSource`** - A string that specifies the location of the tokenizer JSON file.

docs/docs/03-typescript-api/02-computer-vision/OCRModule.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ interface OCRDetection {
113113

114114
To load the model, use the `load` method. It accepts an object:
115115

116-
**`model`** - Object containing the model source.
116+
**`model`** - Object containing the detector source, recognizers sources, and language.
117117

118118
- **`detectorSource`** - A string that specifies the location of the detector binary.
119119
- **`recognizerLarge`** - A string that specifies the location of the recognizer binary file which accepts input images with a width of 512 pixels.

docs/docs/03-typescript-api/02-computer-vision/VerticalOCRModule.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@ interface OCRDetection {
124124

125125
To load the model, use the `load` method. It accepts:
126126

127-
**`model`** - Object containing the model source.
127+
**`model`** - Object containing the detectors sources, recognizers sources, and language.
128128

129129
- **`detectorLarge`** - A string that specifies the location of the recognizer binary file which accepts input images with a width of 1280 pixels.
130130
- **`detectorNarrow`** - A string that specifies the location of the detector binary file which accepts input images with a width of 320 pixels.

0 commit comments

Comments
 (0)