@qvac/inference 0.21.1 → 0.23.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/NOTICE +89 -41
- package/README.md +44 -1
- package/dist/api/assess-model-fit.d.ts +4 -4
- package/dist/api/assess-model-fit.js +4 -4
- package/dist/api/audio-gen.d.ts +4 -1
- package/dist/api/audio-gen.js +5 -2
- package/dist/api/batch-completion.js +1 -1
- package/dist/api/completion-stream.d.ts +2 -1
- package/dist/api/completion-stream.js +4 -2
- package/dist/api/decide.d.ts +26 -0
- package/dist/api/decide.js +26 -0
- package/dist/api/diffusion.d.ts +18 -1
- package/dist/api/diffusion.js +18 -1
- package/dist/api/download-asset.js +1 -1
- package/dist/api/finetune.js +1 -1
- package/dist/api/get-model-info.d.ts +1 -1
- package/dist/api/index.d.ts +39 -37
- package/dist/api/index.js +38 -36
- package/dist/api/load-model.js +2 -2
- package/dist/api/logging-stream-registry.js +11 -7
- package/dist/api/logging-stream.d.ts +11 -1
- package/dist/api/logging-stream.js +11 -2
- package/dist/api/registry.d.ts +2 -1
- package/dist/api/registry.js +5 -4
- package/dist/api/rerank.d.ts +17 -0
- package/dist/api/rerank.js +36 -0
- package/dist/api/subscribe-logs.js +5 -3
- package/dist/api/text-to-speech.d.ts +1 -0
- package/dist/api/text-to-speech.js +15 -19
- package/dist/api/transcribe.js +5 -2
- package/dist/api/unload-model.js +1 -1
- package/dist/api/video-request.d.ts +5 -5
- package/dist/api/video.d.ts +5 -4
- package/dist/api/video.js +6 -5
- package/dist/api/vla.js +1 -1
- package/dist/api/world-result.js +1 -1
- package/dist/api/world.d.ts +1 -1
- package/dist/api/world.js +1 -1
- package/dist/config/resolve-config.d.ts +1 -1
- package/dist/config/resolve-config.js +1 -1
- package/dist/constants/index.d.ts +2 -2
- package/dist/constants/index.js +2 -2
- package/dist/dispatch.d.ts +3 -2
- package/dist/dispatch.js +16 -4
- package/dist/errors/index.d.ts +9 -0
- package/dist/errors/index.js +18 -1
- package/dist/handlers/assess-model-fit.d.ts +5 -3
- package/dist/handlers/assess-model-fit.js +84 -32
- package/dist/handlers/cancelHandler.js +1 -1
- package/dist/handlers/completion-orchestrate.js +2 -2
- package/dist/handlers/download-asset.js +2 -2
- package/dist/handlers/finetune.js +1 -1
- package/dist/handlers/get-loaded-model-info.js +3 -5
- package/dist/handlers/get-model-info.js +1 -1
- package/dist/handlers/load-model/coreml-sidecars.d.ts +15 -0
- package/dist/handlers/load-model/coreml-sidecars.js +71 -8
- package/dist/handlers/load-model/download-manager.d.ts +1 -1
- package/dist/handlers/load-model/download-stats.d.ts +2 -2
- package/dist/handlers/load-model/download-stats.js +3 -3
- package/dist/handlers/load-model/handler.js +10 -7
- package/dist/handlers/load-model/http-verify.d.ts +1 -1
- package/dist/handlers/load-model/http.d.ts +1 -1
- package/dist/handlers/load-model/http.js +3 -3
- package/dist/handlers/load-model/hyperdrive.d.ts +1 -1
- package/dist/handlers/load-model/hyperdrive.js +2 -2
- package/dist/handlers/load-model/index.d.ts +2 -2
- package/dist/handlers/load-model/index.js +2 -2
- package/dist/handlers/load-model/registry-companion-set.d.ts +1 -1
- package/dist/handlers/load-model/registry-companion-set.js +1 -1
- package/dist/handlers/load-model/registry-download-utils.d.ts +3 -3
- package/dist/handlers/load-model/registry-download-utils.js +2 -2
- package/dist/handlers/load-model/registry.d.ts +2 -2
- package/dist/handlers/load-model/registry.js +5 -5
- package/dist/handlers/load-model/resolve-session.d.ts +1 -1
- package/dist/handlers/load-model/resolve-session.js +11 -3
- package/dist/handlers/load-model/resolve.d.ts +1 -1
- package/dist/handlers/load-model/resolve.js +5 -5
- package/dist/handlers/load-model/safe-fetch.js +5 -6
- package/dist/handlers/logging-stream.d.ts +2 -1
- package/dist/handlers/logging-stream.js +23 -7
- package/dist/handlers/registry.d.ts +3 -1
- package/dist/handlers/registry.js +7 -5
- package/dist/handlers/types.d.ts +7 -1
- package/dist/handlers/vector-index.js +2 -2
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/dist/logging/addon.d.ts +1 -1
- package/dist/logging/addon.js +1 -1
- package/dist/logging/index.d.ts +5 -5
- package/dist/logging/index.js +4 -4
- package/dist/logging/logger.d.ts +1 -1
- package/dist/logging/logger.js +2 -2
- package/dist/{resources/model-fit → model-fit}/assess.d.ts +18 -26
- package/dist/{resources/model-fit → model-fit}/assess.js +210 -274
- package/dist/{resources/model-fit/native-probe/classify-fit.d.ts → model-fit/classify.d.ts} +2 -2
- package/dist/{resources/model-fit/native-probe/classify-fit.js → model-fit/classify.js} +36 -5
- package/dist/{resources/model-fit/fit-stub/fetch-fit-stub.d.ts → model-fit/description/fetch.d.ts} +4 -2
- package/dist/{resources/model-fit/fit-stub/fetch-fit-stub.js → model-fit/description/fetch.js} +11 -6
- package/dist/{resources/model-fit/fit-stub/project-fit-from-load.d.ts → model-fit/description/project.d.ts} +3 -3
- package/dist/{resources/model-fit/fit-stub/project-fit-from-load.js → model-fit/description/project.js} +4 -2
- package/dist/{resources/model-fit/fit-stub/resolve-load-from-stubs.d.ts → model-fit/description/resolve-load.d.ts} +6 -4
- package/dist/{resources/model-fit/fit-stub/resolve-load-from-stubs.js → model-fit/description/resolve-load.js} +14 -6
- package/dist/model-fit/floor.d.ts +31 -0
- package/dist/{resources/model-fit → model-fit}/floor.js +13 -13
- package/dist/model-fit/kv-cache.d.ts +23 -0
- package/dist/model-fit/kv-cache.js +85 -0
- package/dist/{resources/model-fit/native-probe/advisory-fit.d.ts → model-fit/load-check.d.ts} +17 -14
- package/dist/{resources/model-fit/native-probe/advisory-fit.js → model-fit/load-check.js} +23 -64
- package/dist/model-fit/platform.d.ts +14 -0
- package/dist/model-fit/platform.js +26 -0
- package/dist/{resources/model-fit/native-probe/create-fit-request.d.ts → model-fit/request/create.d.ts} +5 -2
- package/dist/model-fit/request/create.js +61 -0
- package/dist/{resources/model-fit/native-probe → model-fit/request}/engines/asr.d.ts +5 -1
- package/dist/{resources/model-fit/native-probe → model-fit/request}/engines/asr.js +32 -1
- package/dist/{resources/model-fit/native-probe → model-fit/request}/engines/audiogen.d.ts +1 -1
- package/dist/model-fit/request/engines/audiogen.js +63 -0
- package/dist/{resources/model-fit/native-probe → model-fit/request}/engines/diffusion.d.ts +1 -1
- package/dist/model-fit/request/engines/diffusion.js +93 -0
- package/dist/{resources/model-fit/native-probe → model-fit/request}/engines/llama.d.ts +2 -3
- package/dist/model-fit/request/engines/llama.js +44 -0
- package/dist/model-fit/request/engines/nmt.d.ts +8 -0
- package/dist/model-fit/request/engines/nmt.js +11 -0
- package/dist/model-fit/request/engines/ocr.d.ts +9 -0
- package/dist/model-fit/request/engines/ocr.js +13 -0
- package/dist/{resources/model-fit/native-probe → model-fit/request}/engines/tts.d.ts +3 -1
- package/dist/{resources/model-fit/native-probe → model-fit/request}/engines/tts.js +50 -4
- package/dist/{resources/model-fit/native-probe/engine-fit.d.ts → model-fit/run/engine.d.ts} +17 -4
- package/dist/{resources/model-fit/native-probe/engine-fit.js → model-fit/run/engine.js} +2 -2
- package/dist/model-fit/run/run.d.ts +43 -0
- package/dist/model-fit/run/run.js +204 -0
- package/dist/models/registry/index.d.ts +1 -1
- package/dist/models/registry/index.js +2 -2
- package/dist/models/registry/models.d.ts +1072 -815
- package/dist/models/registry/models.js +3704 -3405
- package/dist/models/registry/resource-profiles.d.ts +1 -2
- package/dist/models/registry/resource-profiles.js +406 -3
- package/dist/plugins/builtin/asr-ggml/config.d.ts +7 -1
- package/dist/plugins/builtin/asr-ggml/config.js +6 -0
- package/dist/plugins/builtin/asr-ggml/logging.d.ts +1 -1
- package/dist/plugins/builtin/audiogen-ggml/config.d.ts +1 -0
- package/dist/plugins/builtin/audiogen-ggml/ops/audio-edit-stream.js +29 -11
- package/dist/plugins/builtin/audiogen-ggml/ops/audio-gen-input.d.ts +27 -0
- package/dist/plugins/builtin/audiogen-ggml/ops/audio-gen-input.js +23 -0
- package/dist/plugins/builtin/audiogen-ggml/ops/audio-gen-stream.js +7 -28
- package/dist/plugins/builtin/audiogen-ggml/ops/audio-understand.js +2 -2
- package/dist/plugins/builtin/audiogen-ggml/plugin.d.ts +106 -13
- package/dist/plugins/builtin/audiogen-ggml/plugin.js +5 -4
- package/dist/plugins/builtin/bci-whispercpp-transcription/plugin.d.ts +20 -3
- package/dist/plugins/builtin/bci-whispercpp-transcription/plugin.js +3 -3
- package/dist/plugins/builtin/ggml-classification/plugin.js +1 -1
- package/dist/plugins/builtin/ggml-ocr/params.d.ts +18 -0
- package/dist/plugins/builtin/ggml-ocr/params.js +37 -0
- package/dist/plugins/builtin/ggml-ocr/plugin.d.ts +9 -0
- package/dist/plugins/builtin/ggml-ocr/plugin.js +17 -39
- package/dist/plugins/builtin/ggml-vla/plugin.d.ts +9 -2
- package/dist/plugins/builtin/ggml-vla/plugin.js +4 -4
- package/dist/plugins/builtin/index.d.ts +15 -12
- package/dist/plugins/builtin/index.js +15 -12
- package/dist/plugins/builtin/llamacpp-completion/ops/batch-completion-stream.js +5 -7
- package/dist/plugins/builtin/llamacpp-completion/ops/completion-stats.d.ts +2 -0
- package/dist/plugins/builtin/llamacpp-completion/ops/completion-stats.js +6 -0
- package/dist/plugins/builtin/llamacpp-completion/ops/completion-stream.d.ts +10 -7
- package/dist/plugins/builtin/llamacpp-completion/ops/completion-stream.js +141 -204
- package/dist/plugins/builtin/llamacpp-completion/ops/kv-cache-session.d.ts +36 -92
- package/dist/plugins/builtin/llamacpp-completion/ops/kv-cache-session.js +67 -216
- package/dist/plugins/builtin/llamacpp-completion/ops/kv-cache-state.d.ts +2 -49
- package/dist/plugins/builtin/llamacpp-completion/ops/kv-cache-state.js +2 -46
- package/dist/plugins/builtin/llamacpp-completion/plugin.d.ts +208 -19
- package/dist/plugins/builtin/llamacpp-completion/plugin.js +28 -20
- package/dist/plugins/builtin/llamacpp-completion/transform.js +5 -1
- package/dist/plugins/builtin/llamacpp-decision/helpers.d.ts +5 -0
- package/dist/plugins/builtin/llamacpp-decision/helpers.js +89 -0
- package/dist/plugins/builtin/llamacpp-decision/ops/decide.d.ts +91 -0
- package/dist/plugins/builtin/llamacpp-decision/ops/decide.js +129 -0
- package/dist/plugins/builtin/llamacpp-decision/plugin.d.ts +222 -0
- package/dist/plugins/builtin/llamacpp-decision/plugin.js +44 -0
- package/dist/plugins/builtin/llamacpp-embedding/plugin.d.ts +9 -1
- package/dist/plugins/builtin/llamacpp-embedding/plugin.js +15 -5
- package/dist/plugins/builtin/llamacpp-embedding/transform.js +9 -0
- package/dist/plugins/builtin/llamacpp-rerank/helpers.d.ts +3 -0
- package/dist/plugins/builtin/llamacpp-rerank/helpers.js +16 -0
- package/dist/plugins/builtin/llamacpp-rerank/ops/rerank.d.ts +5 -0
- package/dist/plugins/builtin/llamacpp-rerank/ops/rerank.js +117 -0
- package/dist/plugins/builtin/llamacpp-rerank/plugin.d.ts +91 -0
- package/dist/plugins/builtin/llamacpp-rerank/plugin.js +45 -0
- package/dist/plugins/builtin/moss-transcribe/plugin.d.ts +143 -0
- package/dist/plugins/builtin/moss-transcribe/plugin.js +96 -0
- package/dist/plugins/builtin/nmtcpp-translation/load-files.d.ts +6 -0
- package/dist/plugins/builtin/nmtcpp-translation/load-files.js +70 -0
- package/dist/plugins/builtin/nmtcpp-translation/plugin.d.ts +17 -0
- package/dist/plugins/builtin/nmtcpp-translation/plugin.js +10 -74
- package/dist/plugins/builtin/parakeet-transcription/plugin.d.ts +25 -4
- package/dist/plugins/builtin/parakeet-transcription/plugin.js +20 -5
- package/dist/plugins/builtin/sdcpp-generation/ops/diffusion.d.ts +5 -2
- package/dist/plugins/builtin/sdcpp-generation/ops/diffusion.js +168 -52
- package/dist/plugins/builtin/sdcpp-generation/ops/video.d.ts +5 -2
- package/dist/plugins/builtin/sdcpp-generation/ops/video.js +28 -13
- package/dist/plugins/builtin/sdcpp-generation/plugin.d.ts +83 -1
- package/dist/plugins/builtin/sdcpp-generation/plugin.js +55 -52
- package/dist/plugins/builtin/sdcpp-generation/upscaler-config.d.ts +15 -0
- package/dist/plugins/builtin/sdcpp-generation/upscaler-config.js +19 -0
- package/dist/plugins/builtin/sdcpp-generation/world-config.d.ts +8 -0
- package/dist/plugins/builtin/sdcpp-generation/world-config.js +9 -0
- package/dist/plugins/builtin/tts-ggml/ops/moss-options.d.ts +22 -0
- package/dist/plugins/builtin/tts-ggml/ops/moss-options.js +79 -0
- package/dist/plugins/builtin/tts-ggml/ops/text-to-speech-stream.d.ts +1 -1
- package/dist/plugins/builtin/tts-ggml/ops/text-to-speech-stream.js +5 -2
- package/dist/plugins/builtin/tts-ggml/ops/text-to-speech.js +19 -7
- package/dist/plugins/builtin/tts-ggml/plugin.d.ts +151 -1
- package/dist/plugins/builtin/tts-ggml/plugin.js +39 -2
- package/dist/plugins/builtin/whispercpp-transcription/plugin.d.ts +28 -4
- package/dist/plugins/builtin/whispercpp-transcription/plugin.js +8 -4
- package/dist/plugins/index.d.ts +1 -1
- package/dist/plugins/index.js +2 -2
- package/dist/plugins/ops/kv-cache-utils.d.ts +5 -4
- package/dist/plugins/ops/kv-cache-utils.js +25 -33
- package/dist/plugins/ops/load-model.d.ts +8 -2
- package/dist/plugins/ops/load-model.js +33 -19
- package/dist/plugins/ops/transcribe.js +18 -2
- package/dist/plugins/ops/translate.js +3 -3
- package/dist/plugins/ops/unload-model.js +1 -1
- package/dist/plugins/turbovec-backend.js +5 -5
- package/dist/profiling/aggregator.d.ts +1 -1
- package/dist/profiling/aggregator.js +1 -1
- package/dist/profiling/controller.d.ts +1 -1
- package/dist/profiling/controller.js +2 -2
- package/dist/profiling/events.d.ts +1 -1
- package/dist/profiling/events.js +2 -2
- package/dist/profiling/exporters.d.ts +1 -1
- package/dist/profiling/exporters.js +3 -3
- package/dist/profiling/index.d.ts +13 -13
- package/dist/profiling/index.js +12 -12
- package/dist/profiling/operation-metrics.d.ts +1 -1
- package/dist/profiling/operation-metrics.js +2 -2
- package/dist/profiling/operation-wrappers.js +3 -3
- package/dist/profiling/profiler.js +1 -1
- package/dist/rag/handler.js +1 -1
- package/dist/rag/handlers/close-workspace.js +1 -1
- package/dist/rag/handlers/delete-embeddings.js +1 -1
- package/dist/rag/handlers/delete-workspace.js +1 -1
- package/dist/rag/handlers/ingest.js +1 -1
- package/dist/rag/handlers/list-workspaces.d.ts +1 -1
- package/dist/rag/handlers/list-workspaces.js +1 -1
- package/dist/rag/handlers/reindex.js +1 -1
- package/dist/rag/handlers/save-embeddings.js +1 -1
- package/dist/rag/handlers/search.js +1 -1
- package/dist/rag/index.d.ts +11 -11
- package/dist/rag/index.js +11 -11
- package/dist/rag/rag-workspace-manager.js +1 -1
- package/dist/registry.js +3 -1
- package/dist/resources/collector.d.ts +1 -1
- package/dist/resources/collector.js +1 -1
- package/dist/resources/instance.d.ts +1 -1
- package/dist/resources/instance.js +1 -1
- package/dist/resources/native.d.ts +1 -1
- package/dist/resources/normalize.d.ts +1 -1
- package/dist/rpc/inventory.js +5 -7
- package/dist/runtime/env.d.ts +0 -2
- package/dist/runtime/env.js +2 -9
- package/dist/runtime/index.d.ts +5 -5
- package/dist/runtime/index.js +2 -2
- package/dist/runtime/lifecycle.js +7 -7
- package/dist/runtime/model-config-utils.js +9 -1
- package/dist/runtime/model-registry.d.ts +3 -1
- package/dist/runtime/model-registry.js +2 -1
- package/dist/runtime/registry-client.js +1 -1
- package/dist/runtime/request-context.d.ts +3 -3
- package/dist/runtime/request-context.js +22 -1
- package/dist/runtime/request-registry.d.ts +1 -1
- package/dist/runtime/request-registry.js +1 -1
- package/dist/runtime/state.d.ts +1 -1
- package/dist/runtime/state.js +7 -2
- package/dist/runtime/vector-index-backend.d.ts +2 -2
- package/dist/runtime/vector-index-registry.d.ts +5 -5
- package/dist/runtime/vector-index-registry.js +36 -13
- package/dist/schemas/assess-model-fit.d.ts +106 -43
- package/dist/schemas/assess-model-fit.js +69 -32
- package/dist/schemas/audio-gen.d.ts +199 -19
- package/dist/schemas/audio-gen.js +183 -51
- package/dist/schemas/batch-completion-stream.d.ts +210 -36
- package/dist/schemas/batch-completion-stream.js +3 -3
- package/dist/schemas/bci-config.d.ts +3 -0
- package/dist/schemas/bci-config.js +2 -2
- package/dist/schemas/bci.d.ts +24 -3
- package/dist/schemas/bci.js +2 -2
- package/dist/schemas/cancel.d.ts +10 -0
- package/dist/schemas/cancel.js +2 -0
- package/dist/schemas/common.d.ts +1465 -162
- package/dist/schemas/common.js +37 -31
- package/dist/schemas/completion-event.d.ts +8 -2
- package/dist/schemas/completion-event.js +4 -1
- package/dist/schemas/completion-stream.d.ts +243 -39
- package/dist/schemas/completion-stream.js +100 -29
- package/dist/schemas/config.d.ts +1326 -18
- package/dist/schemas/config.js +30 -8
- package/dist/schemas/decision.d.ts +610 -0
- package/dist/schemas/decision.js +219 -0
- package/dist/schemas/download-asset.d.ts +10 -4
- package/dist/schemas/download-asset.js +1 -1
- package/dist/schemas/engine-addon-map.d.ts +9 -1
- package/dist/schemas/engine-addon-map.js +26 -5
- package/dist/schemas/errors.d.ts +2 -0
- package/dist/schemas/errors.js +11 -1
- package/dist/schemas/index.d.ts +51 -48
- package/dist/schemas/index.js +50 -47
- package/dist/schemas/llamacpp-config.d.ts +222 -6
- package/dist/schemas/llamacpp-config.js +129 -7
- package/dist/schemas/load-model.d.ts +7960 -1492
- package/dist/schemas/load-model.js +122 -10
- package/dist/schemas/mcp-adapter.d.ts +1 -1
- package/dist/schemas/model-config-schemas.d.ts +428 -9
- package/dist/schemas/model-config-schemas.js +16 -11
- package/dist/schemas/model-fit-policy.d.ts +17 -0
- package/dist/schemas/model-fit-policy.js +17 -0
- package/dist/schemas/model-info.d.ts +20 -2
- package/dist/schemas/model-info.js +4 -3
- package/dist/schemas/model-resource-profile.d.ts +4 -4
- package/dist/schemas/model-resource-profile.js +2 -5
- package/dist/schemas/model-src-utils.d.ts +14 -2
- package/dist/schemas/model-src-utils.js +2 -2
- package/dist/schemas/model-types.d.ts +14 -1
- package/dist/schemas/model-types.js +4 -0
- package/dist/schemas/ocr.d.ts +76 -0
- package/dist/schemas/ocr.js +43 -1
- package/dist/schemas/plugin.d.ts +16 -4
- package/dist/schemas/plugin.js +12 -0
- package/dist/schemas/profiling.d.ts +4 -4
- package/dist/schemas/profiling.js +1 -1
- package/dist/schemas/rag.js +1 -1
- package/dist/schemas/registry.d.ts +34 -0
- package/dist/schemas/registry.js +5 -1
- package/dist/schemas/reload-config.d.ts +14 -2
- package/dist/schemas/reload-config.js +2 -2
- package/dist/schemas/rerank.d.ts +131 -0
- package/dist/schemas/rerank.js +102 -0
- package/dist/schemas/rpc-server.js +3 -3
- package/dist/schemas/sdcpp-config.d.ts +82 -0
- package/dist/schemas/sdcpp-config.js +41 -22
- package/dist/schemas/system-resources.d.ts +4 -4
- package/dist/schemas/text-to-speech.d.ts +463 -3
- package/dist/schemas/text-to-speech.js +129 -11
- package/dist/schemas/tools.d.ts +13 -4
- package/dist/schemas/tools.js +18 -6
- package/dist/schemas/transcription-config.d.ts +20 -0
- package/dist/schemas/transcription-config.js +54 -4
- package/dist/schemas/transcription.d.ts +47 -5
- package/dist/schemas/transcription.js +52 -5
- package/dist/schemas/translate.d.ts +2 -2
- package/dist/schemas/translate.js +1 -1
- package/dist/schemas/translation-config.d.ts +40 -10
- package/dist/schemas/translation-config.js +1 -1
- package/dist/schemas/vla.d.ts +9 -2
- package/dist/schemas/vla.js +9 -5
- package/dist/surface.d.ts +3 -2
- package/dist/surface.js +3 -2
- package/dist/utils/addon-responses.d.ts +3 -0
- package/dist/utils/aggregate-events.d.ts +1 -1
- package/dist/utils/aggregate-events.js +2 -2
- package/dist/utils/archive.js +2 -2
- package/dist/utils/asr-events.d.ts +1 -0
- package/dist/utils/asr-events.js +2 -1
- package/dist/utils/audio/decoder.js +3 -1
- package/dist/utils/audio-input.js +1 -1
- package/dist/utils/cache/auto-history.d.ts +2 -1
- package/dist/utils/cache/auto-history.js +2 -2
- package/dist/utils/cache/paths.js +6 -6
- package/dist/utils/cache/types.d.ts +7 -0
- package/dist/utils/checksum.d.ts +2 -0
- package/dist/utils/checksum.js +41 -2
- package/dist/utils/completion-normalizer.js +1 -1
- package/dist/utils/gguf-architecture.d.ts +7 -0
- package/dist/utils/gguf-architecture.js +142 -0
- package/dist/utils/gguf-tensor-extractor.js +1 -1
- package/dist/utils/index.d.ts +13 -13
- package/dist/utils/index.js +13 -13
- package/dist/utils/mcp-adapter.d.ts +1 -1
- package/dist/utils/mcp-adapter.js +13 -9
- package/dist/utils/path-security.js +1 -1
- package/dist/utils/shard-utils.d.ts +5 -0
- package/dist/utils/shard-utils.js +19 -3
- package/dist/utils/tool-helpers.d.ts +1 -1
- package/dist/utils/tool-helpers.js +20 -52
- package/dist/utils/tool-integration.d.ts +1 -0
- package/dist/utils/tool-integration.js +3 -6
- package/dist/utils/tools/defer.d.ts +16 -26
- package/dist/utils/tools/defer.js +50 -41
- package/dist/utils/tools/dialect.d.ts +15 -4
- package/dist/utils/tools/dialect.js +34 -5
- package/dist/utils/tools/index.d.ts +3 -3
- package/dist/utils/tools/index.js +3 -3
- package/dist/utils/tools/parser.js +8 -8
- package/dist/utils/tools/parsers/dsml.d.ts +1 -1
- package/dist/utils/tools/parsers/dsml.js +8 -5
- package/dist/utils/tools/parsers/gemma4native.d.ts +1 -1
- package/dist/utils/tools/parsers/gemma4native.js +1 -1
- package/dist/utils/tools/parsers/harmony.d.ts +1 -1
- package/dist/utils/tools/parsers/harmony.js +1 -1
- package/dist/utils/tools/parsers/hermes.d.ts +1 -1
- package/dist/utils/tools/parsers/hermes.js +1 -1
- package/dist/utils/tools/parsers/json.d.ts +1 -1
- package/dist/utils/tools/parsers/json.js +1 -1
- package/dist/utils/tools/parsers/pythonic.d.ts +1 -1
- package/dist/utils/tools/parsers/pythonic.js +1 -1
- package/dist/utils/tools/parsers/qwen35.d.ts +1 -1
- package/dist/utils/tools/parsers/qwen35.js +7 -4
- package/dist/utils/tools/shared.d.ts +3 -0
- package/dist/utils/tools/shared.js +62 -0
- package/dist/utils/transcribe-metadata.d.ts +8 -1
- package/dist/utils/transcribe-metadata.js +13 -3
- package/dist/utils/tts-stats.d.ts +2 -1
- package/dist/utils/until-aborted.d.ts +7 -0
- package/dist/utils/until-aborted.js +34 -0
- package/package.json +68 -51
- package/dist/resources/model-fit/calibration/darwin-arm64.d.ts +0 -8
- package/dist/resources/model-fit/calibration/darwin-arm64.js +0 -36
- package/dist/resources/model-fit/calibration/darwin-x64.d.ts +0 -8
- package/dist/resources/model-fit/calibration/darwin-x64.js +0 -38
- package/dist/resources/model-fit/calibration/fit.d.ts +0 -73
- package/dist/resources/model-fit/calibration/fit.js +0 -152
- package/dist/resources/model-fit/calibration/index.d.ts +0 -37
- package/dist/resources/model-fit/calibration/index.js +0 -75
- package/dist/resources/model-fit/calibration/linux-arm64.d.ts +0 -8
- package/dist/resources/model-fit/calibration/linux-arm64.js +0 -38
- package/dist/resources/model-fit/calibration/linux-x64-vulkan.d.ts +0 -8
- package/dist/resources/model-fit/calibration/linux-x64-vulkan.js +0 -39
- package/dist/resources/model-fit/calibration/linux-x64.d.ts +0 -8
- package/dist/resources/model-fit/calibration/linux-x64.js +0 -38
- package/dist/resources/model-fit/calibration/win32-x64-vulkan-shared.d.ts +0 -8
- package/dist/resources/model-fit/calibration/win32-x64-vulkan-shared.js +0 -39
- package/dist/resources/model-fit/calibration/win32-x64-vulkan.d.ts +0 -8
- package/dist/resources/model-fit/calibration/win32-x64-vulkan.js +0 -36
- package/dist/resources/model-fit/calibration/win32-x64.d.ts +0 -8
- package/dist/resources/model-fit/calibration/win32-x64.js +0 -38
- package/dist/resources/model-fit/estimators/llm.d.ts +0 -46
- package/dist/resources/model-fit/estimators/llm.js +0 -222
- package/dist/resources/model-fit/estimators/whisper.d.ts +0 -10
- package/dist/resources/model-fit/estimators/whisper.js +0 -76
- package/dist/resources/model-fit/floor.d.ts +0 -31
- package/dist/resources/model-fit/native-probe/child-engine-fit.d.ts +0 -2
- package/dist/resources/model-fit/native-probe/child-engine-fit.js +0 -41
- package/dist/resources/model-fit/native-probe/create-fit-request.js +0 -51
- package/dist/resources/model-fit/native-probe/engines/audiogen.js +0 -35
- package/dist/resources/model-fit/native-probe/engines/diffusion.js +0 -55
- package/dist/resources/model-fit/native-probe/engines/llama.js +0 -145
- package/dist/resources/model-fit/native-probe/fit-outcome.d.ts +0 -16
- package/dist/resources/model-fit/native-probe/fit-outcome.js +0 -1
- package/dist/resources/model-fit/native-probe/fit-process.d.ts +0 -27
- package/dist/resources/model-fit/native-probe/fit-process.js +0 -55
- package/dist/resources/model-fit/native-probe/fit-runner.d.ts +0 -1
- package/dist/resources/model-fit/native-probe/fit-runner.js +0 -58
- package/dist/resources/model-fit/native-probe/run-fit.d.ts +0 -24
- package/dist/resources/model-fit/native-probe/run-fit.js +0 -20
- package/dist/resources/model-fit/native-probe/run-in-process-fit.d.ts +0 -22
- package/dist/resources/model-fit/native-probe/run-in-process-fit.js +0 -108
- package/dist/resources/model-fit/native-probe/run-isolated-fit.d.ts +0 -63
- package/dist/resources/model-fit/native-probe/run-isolated-fit.js +0 -377
- package/dist/resources/model-fit/platform.d.ts +0 -9
- package/dist/resources/model-fit/platform.js +0 -28
- package/dist/resources/model-fit/types.d.ts +0 -120
- package/dist/resources/model-fit/types.js +0 -1
- /package/dist/{resources/model-fit/native-probe/engines → model-fit/request}/gpu.d.ts +0 -0
- /package/dist/{resources/model-fit/native-probe/engines → model-fit/request}/gpu.js +0 -0
|
@@ -0,0 +1,117 @@
|
|
|
1
|
+
var __addDisposableResource = (this && this.__addDisposableResource) || function (env, value, async) {
|
|
2
|
+
if (value !== null && value !== void 0) {
|
|
3
|
+
if (typeof value !== "object" && typeof value !== "function") throw new TypeError("Object expected.");
|
|
4
|
+
var dispose, inner;
|
|
5
|
+
if (async) {
|
|
6
|
+
if (!Symbol.asyncDispose) throw new TypeError("Symbol.asyncDispose is not defined.");
|
|
7
|
+
dispose = value[Symbol.asyncDispose];
|
|
8
|
+
}
|
|
9
|
+
if (dispose === void 0) {
|
|
10
|
+
if (!Symbol.dispose) throw new TypeError("Symbol.dispose is not defined.");
|
|
11
|
+
dispose = value[Symbol.dispose];
|
|
12
|
+
if (async) inner = dispose;
|
|
13
|
+
}
|
|
14
|
+
if (typeof dispose !== "function") throw new TypeError("Object not disposable.");
|
|
15
|
+
if (inner) dispose = function() { try { inner.call(this); } catch (e) { return Promise.reject(e); } };
|
|
16
|
+
env.stack.push({ value: value, dispose: dispose, async: async });
|
|
17
|
+
}
|
|
18
|
+
else if (async) {
|
|
19
|
+
env.stack.push({ async: true });
|
|
20
|
+
}
|
|
21
|
+
return value;
|
|
22
|
+
};
|
|
23
|
+
var __disposeResources = (this && this.__disposeResources) || (function (SuppressedError) {
|
|
24
|
+
return function (env) {
|
|
25
|
+
function fail(e) {
|
|
26
|
+
env.error = env.hasError ? new SuppressedError(e, env.error, "An error was suppressed during disposal.") : e;
|
|
27
|
+
env.hasError = true;
|
|
28
|
+
}
|
|
29
|
+
var r, s = 0;
|
|
30
|
+
function next() {
|
|
31
|
+
while (r = env.stack.pop()) {
|
|
32
|
+
try {
|
|
33
|
+
if (!r.async && s === 1) return s = 0, env.stack.push(r), Promise.resolve().then(next);
|
|
34
|
+
if (r.dispose) {
|
|
35
|
+
var result = r.dispose.call(r.value);
|
|
36
|
+
if (r.async) return s |= 2, Promise.resolve(result).then(next, function(e) { fail(e); return next(); });
|
|
37
|
+
}
|
|
38
|
+
else s |= 1;
|
|
39
|
+
}
|
|
40
|
+
catch (e) {
|
|
41
|
+
fail(e);
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
if (s === 1) return env.hasError ? Promise.reject(env.error) : Promise.resolve();
|
|
45
|
+
if (env.hasError) throw env.error;
|
|
46
|
+
}
|
|
47
|
+
return next();
|
|
48
|
+
};
|
|
49
|
+
})(typeof SuppressedError === "function" ? SuppressedError : function (error, suppressed, message) {
|
|
50
|
+
var e = new Error(message);
|
|
51
|
+
return e.name = "SuppressedError", e.error = error, e.suppressed = suppressed, e;
|
|
52
|
+
});
|
|
53
|
+
import { getModel } from '../../../../runtime/model-registry.js';
|
|
54
|
+
import { getRequestRegistry, withRequestContext } from '../../../../runtime/request-context.js';
|
|
55
|
+
import { generateRandomRequestId } from '../../../../runtime/request-id.js';
|
|
56
|
+
import { InferenceCancelledError, InvalidResponseError } from '../../../../errors/index.js';
|
|
57
|
+
import { getEngineLogger } from '../../../../logging/index.js';
|
|
58
|
+
import { nowMs } from '../../../../profiling/index.js';
|
|
59
|
+
import { attachModelExecutionMs } from '../../../../profiling/model-execution.js';
|
|
60
|
+
import { rerankScoresSchema } from '../../../../schemas/index.js';
|
|
61
|
+
export async function rerank(request) {
|
|
62
|
+
const env_1 = { stack: [], error: void 0, hasError: false };
|
|
63
|
+
try {
|
|
64
|
+
const { modelId, requestId, query, documents } = request;
|
|
65
|
+
const ctx = __addDisposableResource(env_1, await getRequestRegistry().begin({
|
|
66
|
+
requestId: requestId ?? generateRandomRequestId(),
|
|
67
|
+
kind: 'rerank',
|
|
68
|
+
modelId
|
|
69
|
+
}), true);
|
|
70
|
+
const requestLogger = withRequestContext(getEngineLogger(), ctx);
|
|
71
|
+
if (ctx.signal.aborted)
|
|
72
|
+
throw new InferenceCancelledError(ctx.requestId);
|
|
73
|
+
const model = getModel(modelId);
|
|
74
|
+
let cancelPromise;
|
|
75
|
+
const onAbort = () => {
|
|
76
|
+
cancelPromise ??= model.cancel().catch((error) => {
|
|
77
|
+
requestLogger.warn(`Reranker cancel failed: ${error instanceof Error ? error.message : String(error)}`);
|
|
78
|
+
});
|
|
79
|
+
};
|
|
80
|
+
ctx.signal.addEventListener('abort', onAbort, { once: true });
|
|
81
|
+
ctx.scope.defer(async () => {
|
|
82
|
+
ctx.signal.removeEventListener('abort', onAbort);
|
|
83
|
+
// A delayed native cancel must finish before the next job owns this model slot.
|
|
84
|
+
await cancelPromise;
|
|
85
|
+
});
|
|
86
|
+
const started = nowMs();
|
|
87
|
+
try {
|
|
88
|
+
const response = await model.run({ query, documents });
|
|
89
|
+
const outputs = await response.await();
|
|
90
|
+
if (ctx.signal.aborted)
|
|
91
|
+
throw new InferenceCancelledError(ctx.requestId);
|
|
92
|
+
if (outputs.length !== 1)
|
|
93
|
+
throw new InvalidResponseError('rerank');
|
|
94
|
+
const parsed = rerankScoresSchema.safeParse(outputs[0]);
|
|
95
|
+
if (!parsed.success)
|
|
96
|
+
throw new InvalidResponseError('rerank', parsed.error);
|
|
97
|
+
if (parsed.data.length !== documents.length)
|
|
98
|
+
throw new InvalidResponseError('rerank');
|
|
99
|
+
return attachModelExecutionMs({ type: 'rerank', scores: parsed.data }, nowMs() - started);
|
|
100
|
+
}
|
|
101
|
+
catch (error) {
|
|
102
|
+
if (ctx.signal.aborted)
|
|
103
|
+
throw new InferenceCancelledError(ctx.requestId);
|
|
104
|
+
ctx.state = 'failed';
|
|
105
|
+
throw error;
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
catch (e_1) {
|
|
109
|
+
env_1.error = e_1;
|
|
110
|
+
env_1.hasError = true;
|
|
111
|
+
}
|
|
112
|
+
finally {
|
|
113
|
+
const result_1 = __disposeResources(env_1);
|
|
114
|
+
if (result_1)
|
|
115
|
+
await result_1;
|
|
116
|
+
}
|
|
117
|
+
}
|
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
import { Reranker } from '@qvac/embed-llamacpp';
|
|
2
|
+
import { type CreateModelParams } from '../../../schemas/index.js';
|
|
3
|
+
export declare const rerankPlugin: {
|
|
4
|
+
modelType: "llamacpp-rerank";
|
|
5
|
+
displayName: string;
|
|
6
|
+
addonPackage: "@qvac/embed-llamacpp";
|
|
7
|
+
loadConfigSchema: import("zod").ZodPipe<import("zod").ZodObject<{
|
|
8
|
+
device: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
9
|
+
cpu: "cpu";
|
|
10
|
+
gpu: "gpu";
|
|
11
|
+
}>>;
|
|
12
|
+
gpu_layers: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
13
|
+
batch_size: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
14
|
+
backend: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodEnum<{
|
|
15
|
+
auto: "auto";
|
|
16
|
+
cuda: "cuda";
|
|
17
|
+
vulkan: "vulkan";
|
|
18
|
+
metal: "metal";
|
|
19
|
+
opencl: "opencl";
|
|
20
|
+
}>>>;
|
|
21
|
+
poll: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
22
|
+
pollBatch: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
23
|
+
threads: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
24
|
+
'threads-batch': import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
25
|
+
flash_attn: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
26
|
+
auto: "auto";
|
|
27
|
+
on: "on";
|
|
28
|
+
off: "off";
|
|
29
|
+
}>>;
|
|
30
|
+
verbosity: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
31
|
+
'main-gpu': import("zod").ZodOptional<import("zod").ZodUnion<readonly [import("zod").ZodNumber, import("zod").ZodEnum<{
|
|
32
|
+
integrated: "integrated";
|
|
33
|
+
dedicated: "dedicated";
|
|
34
|
+
}>]>>;
|
|
35
|
+
'split-mode': import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
36
|
+
none: "none";
|
|
37
|
+
layer: "layer";
|
|
38
|
+
}>>;
|
|
39
|
+
'tensor-split': import("zod").ZodOptional<import("zod").ZodString>;
|
|
40
|
+
openclCacheDir: import("zod").ZodOptional<import("zod").ZodString>;
|
|
41
|
+
}, import("zod/v4/core").$strict>, import("zod").ZodTransform<{
|
|
42
|
+
device: "cpu" | "gpu";
|
|
43
|
+
gpu_layers?: number | undefined;
|
|
44
|
+
batch_size?: number | undefined;
|
|
45
|
+
backend?: ("auto" | "cuda" | "vulkan" | "metal" | "opencl")[] | undefined;
|
|
46
|
+
poll?: number | undefined;
|
|
47
|
+
pollBatch?: number | undefined;
|
|
48
|
+
threads?: number | undefined;
|
|
49
|
+
'threads-batch'?: number | undefined;
|
|
50
|
+
flash_attn?: "auto" | "on" | "off" | undefined;
|
|
51
|
+
verbosity?: number | undefined;
|
|
52
|
+
'main-gpu'?: number | "integrated" | "dedicated" | undefined;
|
|
53
|
+
'split-mode'?: "none" | "layer" | undefined;
|
|
54
|
+
'tensor-split'?: string | undefined;
|
|
55
|
+
openclCacheDir?: string | undefined;
|
|
56
|
+
}, {
|
|
57
|
+
device?: "cpu" | "gpu" | undefined;
|
|
58
|
+
gpu_layers?: number | undefined;
|
|
59
|
+
batch_size?: number | undefined;
|
|
60
|
+
backend?: ("auto" | "cuda" | "vulkan" | "metal" | "opencl")[] | undefined;
|
|
61
|
+
poll?: number | undefined;
|
|
62
|
+
pollBatch?: number | undefined;
|
|
63
|
+
threads?: number | undefined;
|
|
64
|
+
'threads-batch'?: number | undefined;
|
|
65
|
+
flash_attn?: "auto" | "on" | "off" | undefined;
|
|
66
|
+
verbosity?: number | undefined;
|
|
67
|
+
'main-gpu'?: number | "integrated" | "dedicated" | undefined;
|
|
68
|
+
'split-mode'?: "none" | "layer" | undefined;
|
|
69
|
+
'tensor-split'?: string | undefined;
|
|
70
|
+
openclCacheDir?: string | undefined;
|
|
71
|
+
}>>;
|
|
72
|
+
createModel: (params: CreateModelParams) => {
|
|
73
|
+
model: Reranker;
|
|
74
|
+
};
|
|
75
|
+
handlers: {
|
|
76
|
+
rerank: import("../../../schemas/index.js").PluginHandlerDefinition<import("zod").ZodObject<{
|
|
77
|
+
query: import("zod").ZodString;
|
|
78
|
+
documents: import("zod").ZodArray<import("zod").ZodString>;
|
|
79
|
+
type: import("zod").ZodLiteral<"rerank">;
|
|
80
|
+
requestId: import("zod").ZodOptional<import("zod").ZodString>;
|
|
81
|
+
modelId: import("zod").ZodString;
|
|
82
|
+
}, import("zod/v4/core").$strict>, import("zod").ZodObject<{
|
|
83
|
+
type: import("zod").ZodLiteral<"rerank">;
|
|
84
|
+
scores: import("zod").ZodArray<import("zod").ZodNumber>;
|
|
85
|
+
}, import("zod/v4/core").$strip>>;
|
|
86
|
+
};
|
|
87
|
+
logging: {
|
|
88
|
+
module: () => Promise<typeof import("@qvac/embed-llamacpp/addonLogging")>;
|
|
89
|
+
namespace: "llamacpp-embedding";
|
|
90
|
+
};
|
|
91
|
+
};
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import { Reranker } from '@qvac/embed-llamacpp';
|
|
2
|
+
import { definePlugin, defineHandler, ModelType, ADDON_EMBEDDING, rerankConfigSchema, rerankRequestSchema, rerankResponseSchema } from '../../../schemas/index.js';
|
|
3
|
+
import { createStreamLogger, registerAddonLogger, getEngineLogger } from '../../../logging/index.js';
|
|
4
|
+
import { isMobile } from '../../../runtime/state.js';
|
|
5
|
+
import { stripMultiGpuKeys } from '../../../utils/multi-gpu-mobile.js';
|
|
6
|
+
import { getModelShardFiles } from '../../../utils/shard-utils.js';
|
|
7
|
+
import { rerank } from './ops/rerank.js';
|
|
8
|
+
import { transformRerankConfig } from './helpers.js';
|
|
9
|
+
function createRerankModel(params) {
|
|
10
|
+
const config = { ...transformRerankConfig(rerankConfigSchema.parse(params.modelConfig)) };
|
|
11
|
+
if (isMobile()) {
|
|
12
|
+
const stripped = stripMultiGpuKeys(config);
|
|
13
|
+
if (stripped.length > 0) {
|
|
14
|
+
getEngineLogger().warn(`[${ModelType.llamacppRerank}:${params.modelId}] Multi-GPU parameters (${stripped.join(', ')}) are not supported on mobile. Removing them from config; model will load with single-GPU defaults.`);
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
const logger = createStreamLogger(params.modelId, ModelType.llamacppRerank);
|
|
18
|
+
registerAddonLogger(params.modelId, ModelType.llamacppRerank, logger);
|
|
19
|
+
// Reranker streams every shard, as LayaDecisions does.
|
|
20
|
+
return new Reranker({
|
|
21
|
+
files: { model: getModelShardFiles(params.modelPath) },
|
|
22
|
+
config,
|
|
23
|
+
logger
|
|
24
|
+
});
|
|
25
|
+
}
|
|
26
|
+
export const rerankPlugin = definePlugin({
|
|
27
|
+
modelType: ModelType.llamacppRerank,
|
|
28
|
+
displayName: 'Rerank (llama.cpp)',
|
|
29
|
+
addonPackage: ADDON_EMBEDDING,
|
|
30
|
+
loadConfigSchema: rerankConfigSchema,
|
|
31
|
+
createModel: (params) => ({ model: createRerankModel(params) }),
|
|
32
|
+
handlers: {
|
|
33
|
+
rerank: defineHandler({
|
|
34
|
+
requestSchema: rerankRequestSchema,
|
|
35
|
+
responseSchema: rerankResponseSchema,
|
|
36
|
+
streaming: false,
|
|
37
|
+
cancel: { scope: 'model', hard: true },
|
|
38
|
+
handler: rerank
|
|
39
|
+
})
|
|
40
|
+
},
|
|
41
|
+
logging: {
|
|
42
|
+
module: () => import('@qvac/embed-llamacpp/addonLogging'),
|
|
43
|
+
namespace: ModelType.llamacppEmbedding
|
|
44
|
+
}
|
|
45
|
+
});
|
|
@@ -0,0 +1,143 @@
|
|
|
1
|
+
import { type MossTranscribeConfig, type CreateModelParams, type PluginModelResult, type ResolveResult } from '../../../schemas/index.js';
|
|
2
|
+
export declare const mossTranscribePlugin: {
|
|
3
|
+
modelType: "moss-transcribe";
|
|
4
|
+
displayName: string;
|
|
5
|
+
addonPackage: "@qvac/asr-ggml";
|
|
6
|
+
loadConfigSchema: import("zod").ZodObject<{
|
|
7
|
+
maxThreads: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
8
|
+
useGPU: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
9
|
+
backendsDir: import("zod").ZodOptional<import("zod").ZodString>;
|
|
10
|
+
}, import("zod/v4/core").$strict>;
|
|
11
|
+
assessFit: typeof import("node_modules/@qvac/asr-ggml/lib/fit").assessFit;
|
|
12
|
+
resolveConfig(cfg: MossTranscribeConfig): Promise<ResolveResult<MossTranscribeConfig>>;
|
|
13
|
+
createModel(params: CreateModelParams): PluginModelResult;
|
|
14
|
+
handlers: {
|
|
15
|
+
transcribe: import("../../../schemas/index.js").PluginHandlerDefinition<import("zod").ZodObject<{
|
|
16
|
+
modelId: import("zod").ZodString;
|
|
17
|
+
prompt: import("zod").ZodOptional<import("zod").ZodString>;
|
|
18
|
+
metadata: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
19
|
+
audioChunk: import("zod").ZodDiscriminatedUnion<[import("zod").ZodObject<{
|
|
20
|
+
type: import("zod").ZodLiteral<"base64">;
|
|
21
|
+
value: import("zod").ZodString;
|
|
22
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
23
|
+
type: import("zod").ZodLiteral<"filePath">;
|
|
24
|
+
value: import("zod").ZodString;
|
|
25
|
+
}, import("zod/v4/core").$strip>], "type">;
|
|
26
|
+
hotwords: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodString>>;
|
|
27
|
+
maxNewTokens: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
28
|
+
type: import("zod").ZodLiteral<"transcribe">;
|
|
29
|
+
requestId: import("zod").ZodOptional<import("zod").ZodString>;
|
|
30
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
31
|
+
text: import("zod").ZodOptional<import("zod").ZodString>;
|
|
32
|
+
done: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
33
|
+
stats: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
34
|
+
audioDuration: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
35
|
+
realTimeFactor: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
36
|
+
tokensPerSecond: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
37
|
+
totalTokens: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
38
|
+
totalSegments: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
39
|
+
whisperEncodeTime: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
40
|
+
whisperDecodeTime: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
41
|
+
encoderTime: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
42
|
+
decoderTime: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
43
|
+
melSpecTime: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
44
|
+
backendDevice: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
45
|
+
backendId: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
46
|
+
gpuUnsupported: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
47
|
+
gpuMemTotalMb: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
48
|
+
gpuMemFreeMb: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
49
|
+
totalTime: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
50
|
+
totalWallMs: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
51
|
+
totalSamples: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
52
|
+
processCalls: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
53
|
+
whisperSampleMs: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
54
|
+
whisperBatchdMs: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
55
|
+
whisperPromptMs: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
56
|
+
totalTranscriptions: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
57
|
+
modelLoadMs: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
58
|
+
totalEncodedFrames: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
59
|
+
encoderOnCoreml: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
60
|
+
encoderUsedCoreml: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
61
|
+
}, import("zod/v4/core").$strip>>;
|
|
62
|
+
error: import("zod").ZodOptional<import("zod").ZodString>;
|
|
63
|
+
segment: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
64
|
+
text: import("zod").ZodString;
|
|
65
|
+
startMs: import("zod").ZodNumber;
|
|
66
|
+
endMs: import("zod").ZodNumber;
|
|
67
|
+
append: import("zod").ZodBoolean;
|
|
68
|
+
id: import("zod").ZodNumber;
|
|
69
|
+
speakerId: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
70
|
+
speaker: import("zod").ZodOptional<import("zod").ZodString>;
|
|
71
|
+
speakerSegments: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodObject<{
|
|
72
|
+
speakerId: import("zod").ZodNumber;
|
|
73
|
+
startMs: import("zod").ZodNumber;
|
|
74
|
+
endMs: import("zod").ZodNumber;
|
|
75
|
+
}, import("zod/v4/core").$strip>>>;
|
|
76
|
+
isEndOfTurn: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
77
|
+
startsWord: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
78
|
+
}, import("zod/v4/core").$strip>>;
|
|
79
|
+
vad: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
80
|
+
speakerId: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
81
|
+
speaking: import("zod").ZodBoolean;
|
|
82
|
+
probability: import("zod").ZodNumber;
|
|
83
|
+
source: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
84
|
+
silero: "silero";
|
|
85
|
+
energy: "energy";
|
|
86
|
+
sortformer: "sortformer";
|
|
87
|
+
}>>;
|
|
88
|
+
}, import("zod/v4/core").$strip>>;
|
|
89
|
+
endOfTurn: import("zod").ZodOptional<import("zod").ZodPreprocess<import("zod").ZodDiscriminatedUnion<[import("zod").ZodObject<{
|
|
90
|
+
source: import("zod").ZodLiteral<"whisper">;
|
|
91
|
+
silenceDurationMs: import("zod").ZodNumber;
|
|
92
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
93
|
+
source: import("zod").ZodLiteral<"parakeet">;
|
|
94
|
+
}, import("zod/v4/core").$strip>], "source">, unknown>>;
|
|
95
|
+
diagnostics: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
96
|
+
selectedBackend: import("zod").ZodString;
|
|
97
|
+
selectedDevice: import("zod").ZodEnum<{
|
|
98
|
+
cpu: "cpu";
|
|
99
|
+
gpu: "gpu";
|
|
100
|
+
}>;
|
|
101
|
+
graphicsApi: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
102
|
+
cuda: "cuda";
|
|
103
|
+
vulkan: "vulkan";
|
|
104
|
+
metal: "metal";
|
|
105
|
+
opencl: "opencl";
|
|
106
|
+
rocm: "rocm";
|
|
107
|
+
opengl: "opengl";
|
|
108
|
+
webgpu: "webgpu";
|
|
109
|
+
direct3d11: "direct3d11";
|
|
110
|
+
direct3d12: "direct3d12";
|
|
111
|
+
levelZero: "levelZero";
|
|
112
|
+
}>>;
|
|
113
|
+
driver: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
114
|
+
name: import("zod").ZodString;
|
|
115
|
+
version: import("zod").ZodOptional<import("zod").ZodString>;
|
|
116
|
+
}, import("zod/v4/core").$strip>>;
|
|
117
|
+
gpuId: import("zod").ZodOptional<import("zod").ZodString>;
|
|
118
|
+
fallback: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
119
|
+
requestedBackend: import("zod").ZodOptional<import("zod").ZodString>;
|
|
120
|
+
requestedDevice: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
121
|
+
cpu: "cpu";
|
|
122
|
+
gpu: "gpu";
|
|
123
|
+
}>>;
|
|
124
|
+
reason: import("zod").ZodString;
|
|
125
|
+
}, import("zod/v4/core").$strip>>;
|
|
126
|
+
probe: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
127
|
+
status: import("zod").ZodEnum<{
|
|
128
|
+
unknown: "unknown";
|
|
129
|
+
compatible: "compatible";
|
|
130
|
+
incompatible: "incompatible";
|
|
131
|
+
}>;
|
|
132
|
+
backend: import("zod").ZodString;
|
|
133
|
+
reason: import("zod").ZodOptional<import("zod").ZodString>;
|
|
134
|
+
}, import("zod/v4/core").$strip>>;
|
|
135
|
+
}, import("zod/v4/core").$strip>>;
|
|
136
|
+
type: import("zod").ZodLiteral<"transcribe">;
|
|
137
|
+
}, import("zod/v4/core").$strip>>;
|
|
138
|
+
};
|
|
139
|
+
logging: {
|
|
140
|
+
module: () => Promise<typeof import("@qvac/asr-ggml/addonLogging")>;
|
|
141
|
+
namespace: "@qvac/asr-ggml";
|
|
142
|
+
};
|
|
143
|
+
};
|
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
import ASRGgml from '@qvac/asr-ggml';
|
|
2
|
+
import { definePlugin, defineHandler, transcribeRequestSchema, transcribeResponseSchema, ModelType, mossTranscribeConfigSchema, ADDON_ASR } from '../../../schemas/index.js';
|
|
3
|
+
import { ModelLoadFailedError } from '../../../errors/index.js';
|
|
4
|
+
import { transcribe } from '../../../plugins/ops/transcribe.js';
|
|
5
|
+
import { attachModelExecutionMs } from '../../../profiling/model-execution.js';
|
|
6
|
+
import { attachBackendDiagnostics } from '../../../profiling/backend-diagnostics.js';
|
|
7
|
+
import { buildMossTranscribeEngineConfig } from '../../../plugins/builtin/asr-ggml/config.js';
|
|
8
|
+
import { createAsrModelLogger } from '../../../plugins/builtin/asr-ggml/logging.js';
|
|
9
|
+
function createMossTranscribeModel(params) {
|
|
10
|
+
const config = (params.modelConfig ?? {});
|
|
11
|
+
const modelPath = params.modelPath;
|
|
12
|
+
if (!modelPath) {
|
|
13
|
+
throw new ModelLoadFailedError('MOSS-Transcribe-Diarize requires a GGUF model source');
|
|
14
|
+
}
|
|
15
|
+
const logger = createAsrModelLogger(params.modelId, ModelType.mossTranscribe);
|
|
16
|
+
const model = new ASRGgml({
|
|
17
|
+
files: { model: modelPath },
|
|
18
|
+
config: buildMossTranscribeEngineConfig(config),
|
|
19
|
+
enableStats: true,
|
|
20
|
+
logger
|
|
21
|
+
});
|
|
22
|
+
return { model };
|
|
23
|
+
}
|
|
24
|
+
export const mossTranscribePlugin = definePlugin({
|
|
25
|
+
modelType: ModelType.mossTranscribe,
|
|
26
|
+
displayName: 'MOSS-Transcribe-Diarize',
|
|
27
|
+
addonPackage: ADDON_ASR,
|
|
28
|
+
loadConfigSchema: mossTranscribeConfigSchema,
|
|
29
|
+
assessFit: ASRGgml.assessFit,
|
|
30
|
+
resolveConfig(cfg) {
|
|
31
|
+
return Promise.resolve({ config: cfg });
|
|
32
|
+
},
|
|
33
|
+
createModel(params) {
|
|
34
|
+
return createMossTranscribeModel(params);
|
|
35
|
+
},
|
|
36
|
+
handlers: {
|
|
37
|
+
transcribe: defineHandler({
|
|
38
|
+
requestSchema: transcribeRequestSchema,
|
|
39
|
+
responseSchema: transcribeResponseSchema,
|
|
40
|
+
streaming: true,
|
|
41
|
+
cancel: { scope: 'model', hard: true },
|
|
42
|
+
handler: async function* (request) {
|
|
43
|
+
const metadata = request.metadata === true;
|
|
44
|
+
const stream = metadata
|
|
45
|
+
? transcribe({
|
|
46
|
+
modelId: request.modelId,
|
|
47
|
+
audioChunk: request.audioChunk,
|
|
48
|
+
prompt: request.prompt,
|
|
49
|
+
hotwords: request.hotwords,
|
|
50
|
+
maxNewTokens: request.maxNewTokens,
|
|
51
|
+
metadata: true
|
|
52
|
+
}, request.requestId)
|
|
53
|
+
: transcribe({
|
|
54
|
+
modelId: request.modelId,
|
|
55
|
+
audioChunk: request.audioChunk,
|
|
56
|
+
prompt: request.prompt,
|
|
57
|
+
hotwords: request.hotwords,
|
|
58
|
+
maxNewTokens: request.maxNewTokens
|
|
59
|
+
}, request.requestId);
|
|
60
|
+
try {
|
|
61
|
+
let result = await stream.next();
|
|
62
|
+
while (!result.done) {
|
|
63
|
+
yield metadata
|
|
64
|
+
? {
|
|
65
|
+
type: 'transcribe',
|
|
66
|
+
segment: result.value
|
|
67
|
+
}
|
|
68
|
+
: {
|
|
69
|
+
type: 'transcribe',
|
|
70
|
+
text: result.value
|
|
71
|
+
};
|
|
72
|
+
result = await stream.next();
|
|
73
|
+
}
|
|
74
|
+
const { modelExecutionMs, stats, diagnostics } = result.value;
|
|
75
|
+
// The field is what reaches an RPC client; the symbol is what the
|
|
76
|
+
// profiling layer reads to set `event.backend`, as audiogen does.
|
|
77
|
+
const terminal = attachModelExecutionMs({
|
|
78
|
+
type: 'transcribe',
|
|
79
|
+
text: '',
|
|
80
|
+
done: true,
|
|
81
|
+
...(stats && { stats }),
|
|
82
|
+
...(diagnostics && { diagnostics })
|
|
83
|
+
}, modelExecutionMs);
|
|
84
|
+
yield diagnostics ? attachBackendDiagnostics(terminal, diagnostics) : terminal;
|
|
85
|
+
}
|
|
86
|
+
finally {
|
|
87
|
+
await stream.return?.(undefined);
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
})
|
|
91
|
+
},
|
|
92
|
+
logging: {
|
|
93
|
+
module: () => import('@qvac/asr-ggml/addonLogging'),
|
|
94
|
+
namespace: ADDON_ASR
|
|
95
|
+
}
|
|
96
|
+
});
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import type { TranslationNmtcppConfig, TranslationNmtcppFiles } from '@qvac/translation-nmtcpp';
|
|
2
|
+
import { type NmtConfig } from '../../../schemas/index.js';
|
|
3
|
+
/** The files one translation load opens, shared by the load and its fit request. */
|
|
4
|
+
export declare function nmtFilesFor(modelPath: string, artifacts: Record<string, string>): TranslationNmtcppFiles;
|
|
5
|
+
/** The addon config for one translation load, shared with its fit request. */
|
|
6
|
+
export declare function nmtConfigFor(nmtConfig: NmtConfig, pivotModelPath?: string): TranslationNmtcppConfig;
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
import path from 'bare-path';
|
|
2
|
+
import { BERGAMOT_CJK_LANG_PAIRS } from '../../../schemas/index.js';
|
|
3
|
+
/**
|
|
4
|
+
* Derive absolute vocab paths from a resolved Bergamot model path.
|
|
5
|
+
* Works for both companion-set layout (colocated files) and any layout where
|
|
6
|
+
* vocab follows the standard naming convention beside the model binary.
|
|
7
|
+
* Returns null if modelPath is not a recognisable Bergamot model.
|
|
8
|
+
*/
|
|
9
|
+
function deriveColocatedBergamotVocabPaths(modelPath) {
|
|
10
|
+
const dirPath = path.dirname(modelPath);
|
|
11
|
+
const basePath = path.basename(modelPath);
|
|
12
|
+
const match = basePath.match(/^model\.([a-z]+)\.intgemm\.alphas\.bin$/);
|
|
13
|
+
if (!match?.[1])
|
|
14
|
+
return null;
|
|
15
|
+
const langPair = match[1];
|
|
16
|
+
if (BERGAMOT_CJK_LANG_PAIRS.includes(langPair)) {
|
|
17
|
+
return {
|
|
18
|
+
srcVocabPath: path.join(dirPath, `srcvocab.${langPair}.spm`),
|
|
19
|
+
dstVocabPath: path.join(dirPath, `trgvocab.${langPair}.spm`)
|
|
20
|
+
};
|
|
21
|
+
}
|
|
22
|
+
const sharedPath = path.join(dirPath, `vocab.${langPair}.spm`);
|
|
23
|
+
return { srcVocabPath: sharedPath, dstVocabPath: sharedPath };
|
|
24
|
+
}
|
|
25
|
+
/** The files one translation load opens, shared by the load and its fit request. */
|
|
26
|
+
export function nmtFilesFor(modelPath, artifacts) {
|
|
27
|
+
const derived = deriveColocatedBergamotVocabPaths(modelPath);
|
|
28
|
+
const srcVocabPath = artifacts['srcVocabPath'] ?? derived?.srcVocabPath;
|
|
29
|
+
const dstVocabPath = artifacts['dstVocabPath'] ?? derived?.dstVocabPath;
|
|
30
|
+
const pivotModelPath = artifacts['pivotModelPath'];
|
|
31
|
+
const pivotDerived = pivotModelPath ? deriveColocatedBergamotVocabPaths(pivotModelPath) : null;
|
|
32
|
+
const pivotSrcVocabPath = artifacts['pivotSrcVocabPath'] ?? pivotDerived?.srcVocabPath;
|
|
33
|
+
const pivotDstVocabPath = artifacts['pivotDstVocabPath'] ?? pivotDerived?.dstVocabPath;
|
|
34
|
+
return {
|
|
35
|
+
model: modelPath,
|
|
36
|
+
...(srcVocabPath && { srcVocab: srcVocabPath }),
|
|
37
|
+
...(dstVocabPath && { dstVocab: dstVocabPath }),
|
|
38
|
+
...(pivotModelPath && { pivotModel: pivotModelPath }),
|
|
39
|
+
...(pivotSrcVocabPath && { pivotSrcVocab: pivotSrcVocabPath }),
|
|
40
|
+
...(pivotDstVocabPath && { pivotDstVocab: pivotDstVocabPath })
|
|
41
|
+
};
|
|
42
|
+
}
|
|
43
|
+
/** The addon config for one translation load, shared with its fit request. */
|
|
44
|
+
export function nmtConfigFor(nmtConfig, pivotModelPath) {
|
|
45
|
+
const { engine, beamsize, lengthpenalty, maxlength, repetitionpenalty, norepeatngramsize, temperature, topk, topp } = nmtConfig;
|
|
46
|
+
return {
|
|
47
|
+
modelType: engine,
|
|
48
|
+
beamsize,
|
|
49
|
+
lengthpenalty,
|
|
50
|
+
maxlength,
|
|
51
|
+
repetitionpenalty,
|
|
52
|
+
norepeatngramsize,
|
|
53
|
+
temperature,
|
|
54
|
+
topk,
|
|
55
|
+
topp,
|
|
56
|
+
...(nmtConfig.engine === 'Bergamot' && {
|
|
57
|
+
...(nmtConfig.normalize !== undefined && {
|
|
58
|
+
normalize: nmtConfig.normalize
|
|
59
|
+
}),
|
|
60
|
+
...(nmtConfig.pivotModel &&
|
|
61
|
+
pivotModelPath && {
|
|
62
|
+
pivotConfig: (() => {
|
|
63
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
64
|
+
const { modelSrc, dstVocabSrc, srcVocabSrc, ...pivotGenConfig } = nmtConfig.pivotModel;
|
|
65
|
+
return pivotGenConfig;
|
|
66
|
+
})()
|
|
67
|
+
})
|
|
68
|
+
})
|
|
69
|
+
};
|
|
70
|
+
}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import TranslationNmtcpp from '@qvac/translation-nmtcpp';
|
|
1
2
|
import { type CreateModelParams, type PluginModelResult, type ResolveContext, type ResolveResult } from '../../../schemas/index.js';
|
|
2
3
|
export declare const nmtPlugin: {
|
|
3
4
|
modelType: "nmtcpp-translation";
|
|
@@ -150,10 +151,13 @@ export declare const nmtPlugin: {
|
|
|
150
151
|
"whispercpp-transcription": "whispercpp-transcription";
|
|
151
152
|
"bci-whispercpp-transcription": "bci-whispercpp-transcription";
|
|
152
153
|
"llamacpp-embedding": "llamacpp-embedding";
|
|
154
|
+
"llamacpp-decision": "llamacpp-decision";
|
|
155
|
+
"llamacpp-rerank": "llamacpp-rerank";
|
|
153
156
|
"nmtcpp-translation": "nmtcpp-translation";
|
|
154
157
|
"onnx-tts": "onnx-tts";
|
|
155
158
|
"tts-ggml": "tts-ggml";
|
|
156
159
|
"parakeet-transcription": "parakeet-transcription";
|
|
160
|
+
"moss-transcribe": "moss-transcribe";
|
|
157
161
|
"ggml-ocr": "ggml-ocr";
|
|
158
162
|
"sdcpp-generation": "sdcpp-generation";
|
|
159
163
|
"audiogen-ggml": "audiogen-ggml";
|
|
@@ -189,10 +193,13 @@ export declare const nmtPlugin: {
|
|
|
189
193
|
"whispercpp-transcription": "whispercpp-transcription";
|
|
190
194
|
"bci-whispercpp-transcription": "bci-whispercpp-transcription";
|
|
191
195
|
"llamacpp-embedding": "llamacpp-embedding";
|
|
196
|
+
"llamacpp-decision": "llamacpp-decision";
|
|
197
|
+
"llamacpp-rerank": "llamacpp-rerank";
|
|
192
198
|
"nmtcpp-translation": "nmtcpp-translation";
|
|
193
199
|
"onnx-tts": "onnx-tts";
|
|
194
200
|
"tts-ggml": "tts-ggml";
|
|
195
201
|
"parakeet-transcription": "parakeet-transcription";
|
|
202
|
+
"moss-transcribe": "moss-transcribe";
|
|
196
203
|
"ggml-ocr": "ggml-ocr";
|
|
197
204
|
"sdcpp-generation": "sdcpp-generation";
|
|
198
205
|
"audiogen-ggml": "audiogen-ggml";
|
|
@@ -241,10 +248,13 @@ export declare const nmtPlugin: {
|
|
|
241
248
|
"whispercpp-transcription": "whispercpp-transcription";
|
|
242
249
|
"bci-whispercpp-transcription": "bci-whispercpp-transcription";
|
|
243
250
|
"llamacpp-embedding": "llamacpp-embedding";
|
|
251
|
+
"llamacpp-decision": "llamacpp-decision";
|
|
252
|
+
"llamacpp-rerank": "llamacpp-rerank";
|
|
244
253
|
"nmtcpp-translation": "nmtcpp-translation";
|
|
245
254
|
"onnx-tts": "onnx-tts";
|
|
246
255
|
"tts-ggml": "tts-ggml";
|
|
247
256
|
"parakeet-transcription": "parakeet-transcription";
|
|
257
|
+
"moss-transcribe": "moss-transcribe";
|
|
248
258
|
"ggml-ocr": "ggml-ocr";
|
|
249
259
|
"sdcpp-generation": "sdcpp-generation";
|
|
250
260
|
"audiogen-ggml": "audiogen-ggml";
|
|
@@ -280,10 +290,13 @@ export declare const nmtPlugin: {
|
|
|
280
290
|
"whispercpp-transcription": "whispercpp-transcription";
|
|
281
291
|
"bci-whispercpp-transcription": "bci-whispercpp-transcription";
|
|
282
292
|
"llamacpp-embedding": "llamacpp-embedding";
|
|
293
|
+
"llamacpp-decision": "llamacpp-decision";
|
|
294
|
+
"llamacpp-rerank": "llamacpp-rerank";
|
|
283
295
|
"nmtcpp-translation": "nmtcpp-translation";
|
|
284
296
|
"onnx-tts": "onnx-tts";
|
|
285
297
|
"tts-ggml": "tts-ggml";
|
|
286
298
|
"parakeet-transcription": "parakeet-transcription";
|
|
299
|
+
"moss-transcribe": "moss-transcribe";
|
|
287
300
|
"ggml-ocr": "ggml-ocr";
|
|
288
301
|
"sdcpp-generation": "sdcpp-generation";
|
|
289
302
|
"audiogen-ggml": "audiogen-ggml";
|
|
@@ -319,10 +332,13 @@ export declare const nmtPlugin: {
|
|
|
319
332
|
"whispercpp-transcription": "whispercpp-transcription";
|
|
320
333
|
"bci-whispercpp-transcription": "bci-whispercpp-transcription";
|
|
321
334
|
"llamacpp-embedding": "llamacpp-embedding";
|
|
335
|
+
"llamacpp-decision": "llamacpp-decision";
|
|
336
|
+
"llamacpp-rerank": "llamacpp-rerank";
|
|
322
337
|
"nmtcpp-translation": "nmtcpp-translation";
|
|
323
338
|
"onnx-tts": "onnx-tts";
|
|
324
339
|
"tts-ggml": "tts-ggml";
|
|
325
340
|
"parakeet-transcription": "parakeet-transcription";
|
|
341
|
+
"moss-transcribe": "moss-transcribe";
|
|
326
342
|
"ggml-ocr": "ggml-ocr";
|
|
327
343
|
"sdcpp-generation": "sdcpp-generation";
|
|
328
344
|
"audiogen-ggml": "audiogen-ggml";
|
|
@@ -408,6 +424,7 @@ export declare const nmtPlugin: {
|
|
|
408
424
|
urd_Arab: "urd_Arab";
|
|
409
425
|
}>;
|
|
410
426
|
}, import("zod/v4/core").$strip>], "engine">;
|
|
427
|
+
assessFit: (request: TranslationNmtcpp.FitRequest) => Promise<TranslationNmtcpp.FitResult>;
|
|
411
428
|
resolveConfig(cfg: Record<string, unknown>, ctx: ResolveContext): Promise<ResolveResult<Record<string, unknown>>>;
|
|
412
429
|
createModel(params: CreateModelParams): PluginModelResult;
|
|
413
430
|
handlers: {
|