feat: expand local speech models
This commit is contained in:
@@ -29,6 +29,9 @@ type SherpaRecognizerConfig = {
|
||||
language: string
|
||||
useInverseTextNormalization: number
|
||||
}
|
||||
paraformer?: {
|
||||
model: string
|
||||
}
|
||||
whisper?: {
|
||||
encoder: string
|
||||
decoder: string
|
||||
@@ -124,6 +127,17 @@ export function createSherpaRecognizerConfig(
|
||||
}
|
||||
}
|
||||
}
|
||||
if (model.family === 'paraformer') {
|
||||
return {
|
||||
...base,
|
||||
modelConfig: {
|
||||
...base.modelConfig,
|
||||
paraformer: {
|
||||
model: requiredFile(model, 'model')
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return {
|
||||
...base,
|
||||
modelConfig: {
|
||||
|
||||
Reference in New Issue
Block a user