Configure model path for all libraries
Some checks failed
Publish Library / Tag Version (push) Has been cancelled
Publish Library / Build NPM Project (push) Has been cancelled

This commit is contained in:
2025-12-22 11:02:24 -05:00
parent bb6933f0d5
commit 3cd7b12f5f
3 changed files with 5 additions and 4 deletions

View File

@@ -15,7 +15,7 @@ export class Vision {
return {
abort: () => { worker?.terminate(); },
response: new Promise(async res => {
worker = await createWorker('eng');
worker = await createWorker('eng', 1, {langPath: this.ai.options.path});
const {data} = await worker.recognize(path);
await worker.terminate();
res(data.text.trim() || null);