You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
whisper.cpp/bindings/javascript/whisper.js

22 lines
630 KiB

var whisper_factory = (() => {
var _scriptDir = typeof document !== 'undefined' && document.currentScript ? document.currentScript.src : undefined;
if (typeof __filename !== 'undefined') _scriptDir = _scriptDir || __filename;
return (
function(whisper_factory) {
whisper_factory = whisper_factory || {};
var Module=typeof whisper_factory!=="undefined"?whisper_factory:{};var objAssign=Object.assign;var readyPromiseResolve,readyPromiseReject;Module["ready"]=new Promise(function(resolve,reject){readyPromiseResolve=resolve;readyPromiseReject=reject});if(!Object.getOwnPropertyDescriptor(Module["ready"],"_main")){Object.defineProperty(Module["ready"],"_main",{configurable:true,get:function(){abort("You are getting _main on the Promise object, instead of the instance. Use .then() to get called back with the instance, see the MODULARIZE docs in src/settings.js")}});Object.defineProperty(Module["ready"],"_main",{configurable:true,set:function(){abort("You are setting _main on the Promise object, instead of the instance. Use .then() to get called back with the instance, see the MODULARIZE docs in src/settings.js")}})}if(!Object.getOwnPropertyDescriptor(Module["ready"],"__emscripten_thread_init")){Object.defineProperty(Module["ready"],"__emscripten_thread_init",{configurable:true,get:function(){abort("You are getting __emscripten_thread_init on the Promise object, instead of the instance. Use .then() to get called back with the instance, see the MODULARIZE docs in src/settings.js")}});Object.defineProperty(Module["ready"],"__emscripten_thread_init",{configurable:true,set:function(){abort("You are setting __emscripten_thread_init on the Promise object, instead of the instance. Use .then() to get called back with the instance, see the MODULARIZE docs in src/settings.js")}})}if(!Object.getOwnPropertyDescriptor(Module["ready"],"__emscripten_thread_exit")){Object.defineProperty(Module["ready"],"__emscripten_thread_exit",{configurable:true,get:function(){abort("You are getting __emscripten_thread_exit on the Promise object, instead of the instance. Use .then() to get called back with the instance, see the MODULARIZE docs in src/settings.js")}});Object.defineProperty(Module["ready"],"__emscripten_thread_exit",{configurable:true,set:function(){abort("You are setting __emscripten_thread_exit on the Promise object, instead of the instance. Use .then() to get called back with the instance, see the MODULARIZE docs in src/settings.js")}})}if(!Object.getOwnPropertyDescriptor(Module["ready"],"_emscripten_tls_init")){Object.defineProperty(Module["ready"],"_emscripten_tls_init",{configurable:true,get:function(){abort("You are getting _emscripten_tls_init on the Promise object, instead of the instance. Use .then() to get called back with the instance, see the MODULARIZE docs in src/settings.js")}});Object.defineProperty(Module["ready"],"_emscripten_tls_init",{configurable:true,set:function(){abort("You are setting _emscripten_tls_init on the Promise object, instead of the instance. Use .then() to get called back with the instance, see the MODULARIZE docs in src/settings.js")}})}if(!Object.getOwnPropertyDescriptor(Module["ready"],"_emscripten_current_thread_process_queued_calls")){Object.defineProperty(Module["ready"],"_emscripten_current_thread_process_queued_calls",{configurable:true,get:function(){abort("You are getting _emscripten_current_thread_process_queued_calls on the Promise object, instead of the instance. Use .then() to get called back with the instance, see the MODULARIZE docs in src/settings.js")}});Object.defineProperty(Module["ready"],"_emscripten_current_thread_process_queued_calls",{configurable:true,set:function(){abort("You are setting _emscripten_current_thread_process_queued_calls on the Promise object, instead of the instance. Use .then() to get called back with the instance, see the MODULARIZE docs in src/settings.js")}})}if(!Object.getOwnPropertyDescriptor(Module["ready"],"_pthread_self")){Object.defineProperty(Module["ready"],"_pthread_self",{configurable:true,get:function(){abort("You are getting _pthread_self on the Promise object, instead of the instance. Use .then() to get called back with the instance, see the MODULARIZE docs in src/settings.js")}});Object.defineProperty(Module["ready"],"_pthread_self",{configurable:true,set:function(){abort("You are setting _pthread_self on the Promise object, instead of the instance.
return whisper_factory.ready
}
);
})();
if (typeof exports === 'object' && typeof module === 'object')
module.exports = whisper_factory;
else if (typeof define === 'function' && define['amd'])
define([], function() { return whisper_factory; });
else if (typeof exports === 'object')
exports["whisper_factory"] = whisper_factory;