transcribe-cpp 0.2.0 → 0.2.2
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/README.md +16 -3
- package/dist/ffi.js +11 -0
- package/dist/index.d.ts +3 -1
- package/dist/index.js +37 -19
- package/dist/loader.js +48 -4
- package/dist/types.d.ts +13 -1
- package/package.json +6 -6
package/README.md
CHANGED
|
@@ -27,7 +27,7 @@ const model = await TranscribeModel.load("whisper-tiny-Q5_K_M.gguf");
|
|
|
27
27
|
const result = await model.transcribe(pcm, { timestamps: "segment" });
|
|
28
28
|
|
|
29
29
|
console.log(result.text);
|
|
30
|
-
console.log(result.language); // detected or
|
|
30
|
+
console.log(result.language); // model-detected, or "" when unavailable/a hint was supplied
|
|
31
31
|
for (const seg of result.segments) {
|
|
32
32
|
console.log(`[${seg.t0Ms}–${seg.t1Ms}ms] ${seg.text}`);
|
|
33
33
|
}
|
|
@@ -35,6 +35,17 @@ for (const seg of result.segments) {
|
|
|
35
35
|
model.dispose();
|
|
36
36
|
```
|
|
37
37
|
|
|
38
|
+
### Punctuation, capitalization, and text normalization
|
|
39
|
+
|
|
40
|
+
`pnc` and `itn` default to `"default"`, preserving each model family's shipped
|
|
41
|
+
behavior. Probe `model.supports("pnc")` or `model.supports("itn")` before
|
|
42
|
+
selecting `"off"`/`"on"`. Both options are available on single runs, batches,
|
|
43
|
+
and streams.
|
|
44
|
+
|
|
45
|
+
```ts
|
|
46
|
+
const result = await model.transcribe(pcm, { pnc: "off", itn: "on" });
|
|
47
|
+
```
|
|
48
|
+
|
|
38
49
|
### Streaming
|
|
39
50
|
|
|
40
51
|
```ts
|
|
@@ -47,6 +58,7 @@ for (const chunk of pcmChunks) {
|
|
|
47
58
|
render(committed, tentative);
|
|
48
59
|
}
|
|
49
60
|
await stream.finalize();
|
|
61
|
+
const snapshot = stream.snapshot; // text, language, segments, words, tokens, timings
|
|
50
62
|
stream.reset();
|
|
51
63
|
```
|
|
52
64
|
|
|
@@ -146,8 +158,9 @@ the teardown — is refused with `Busy`, by design.
|
|
|
146
158
|
Because the compute is genuinely on another thread, **do not touch a session
|
|
147
159
|
while a call against it is in flight** — it is single-threaded in the C library:
|
|
148
160
|
|
|
149
|
-
- Reading a stream's `text`/`state`/`revision`/`lastStatus`, or a
|
|
150
|
-
`limits`/`wasAborted`, during an un-awaited
|
|
161
|
+
- Reading a stream's `text`/`snapshot`/`state`/`revision`/`lastStatus`, or a
|
|
162
|
+
session's `limits`/`wasAborted`, during an un-awaited
|
|
163
|
+
`feed`/`finalize`/`run`/`runBatch` **throws**.
|
|
151
164
|
- `reset()` and `dispose()` are safe to call any time: the native teardown is
|
|
152
165
|
deferred behind any in-flight call, so it never frees a session mid-compute.
|
|
153
166
|
- Disposing a `Session` or `TranscribeModel` while a stream is still active
|
package/dist/ffi.js
CHANGED
|
@@ -9,6 +9,17 @@
|
|
|
9
9
|
*/
|
|
10
10
|
import koffi from "koffi";
|
|
11
11
|
import { defineTypes } from "./_generated.js";
|
|
12
|
+
// Koffi defaults async FFI workers to a 128 KiB stack. That is too small for
|
|
13
|
+
// ggml Vulkan model initialization on Windows (observed as an uncatchable
|
|
14
|
+
// 0xC0000005 access violation on Intel Iris Xe). Keep calls asynchronous, but
|
|
15
|
+
// raise the stack floor with headroom for other models and compiler changes.
|
|
16
|
+
// Preserve a larger application-provided value because Koffi configuration is
|
|
17
|
+
// process-global.
|
|
18
|
+
const MIN_ASYNC_STACK_SIZE = 512 * 1024;
|
|
19
|
+
const koffiConfig = koffi.config();
|
|
20
|
+
if ((koffiConfig.async_stack_size ?? 0) < MIN_ASYNC_STACK_SIZE) {
|
|
21
|
+
koffi.config({ async_stack_size: MIN_ASYNC_STACK_SIZE });
|
|
22
|
+
}
|
|
12
23
|
export function bindLibrary(libraryPath) {
|
|
13
24
|
const lib = koffi.load(libraryPath);
|
|
14
25
|
const T = defineTypes(koffi);
|
package/dist/index.d.ts
CHANGED
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
*/
|
|
8
8
|
import { setLogHandler, type LogHandler } from "./native.js";
|
|
9
9
|
import { TranscribeError } from "./errors.js";
|
|
10
|
-
import type { Backend, BackendInfo, BatchItem, Capabilities, FamilyExtension, Feature, ModelOptions, PcmLike, SessionLimits, SessionOptions, StreamOptions, StreamState, StreamText, StreamUpdate, TranscribeOptions, TranscriptionResult } from "./types.js";
|
|
10
|
+
import type { Backend, BackendInfo, BatchItem, Capabilities, FamilyExtension, Feature, ModelOptions, PcmLike, SessionLimits, SessionOptions, StreamOptions, StreamState, StreamText, StreamUpdate, Transcript, TranscribeOptions, TranscriptionResult } from "./types.js";
|
|
11
11
|
export * from "./types.js";
|
|
12
12
|
export * from "./errors.js";
|
|
13
13
|
export { setLogHandler, type LogHandler };
|
|
@@ -65,6 +65,8 @@ export declare class Stream {
|
|
|
65
65
|
finalize(): Promise<StreamUpdate>;
|
|
66
66
|
/** Current text snapshot (copied at the boundary). */
|
|
67
67
|
get text(): StreamText;
|
|
68
|
+
/** Full structured snapshot of the current hypothesis (owned copies). */
|
|
69
|
+
get snapshot(): Transcript;
|
|
68
70
|
get state(): StreamState;
|
|
69
71
|
get revision(): number;
|
|
70
72
|
/**
|
package/dist/index.js
CHANGED
|
@@ -39,6 +39,16 @@ const TIMESTAMPS = {
|
|
|
39
39
|
token: g.TRANSCRIBE_TIMESTAMPS_TOKEN,
|
|
40
40
|
};
|
|
41
41
|
const TIMESTAMP_NAMES = Object.fromEntries(Object.entries(TIMESTAMPS).map(([k, v]) => [v, k]));
|
|
42
|
+
const PNC = {
|
|
43
|
+
default: g.TRANSCRIBE_PNC_MODE_DEFAULT,
|
|
44
|
+
off: g.TRANSCRIBE_PNC_MODE_OFF,
|
|
45
|
+
on: g.TRANSCRIBE_PNC_MODE_ON,
|
|
46
|
+
};
|
|
47
|
+
const ITN = {
|
|
48
|
+
default: g.TRANSCRIBE_ITN_MODE_DEFAULT,
|
|
49
|
+
off: g.TRANSCRIBE_ITN_MODE_OFF,
|
|
50
|
+
on: g.TRANSCRIBE_ITN_MODE_ON,
|
|
51
|
+
};
|
|
42
52
|
const DIARIZE = {
|
|
43
53
|
default: g.TRANSCRIBE_DIARIZE_MODE_DEFAULT,
|
|
44
54
|
off: g.TRANSCRIBE_DIARIZE_MODE_OFF,
|
|
@@ -564,6 +574,7 @@ export class Session {
|
|
|
564
574
|
if (this.#inFlight === kind)
|
|
565
575
|
this.#inFlight = null;
|
|
566
576
|
},
|
|
577
|
+
currentCompute: () => this.#inFlight,
|
|
567
578
|
isCurrentStream: (stream) => this.#activeStream === stream,
|
|
568
579
|
replaceCurrentStream: (stream) => {
|
|
569
580
|
if (this.#activeStream && this.#activeStream !== stream) {
|
|
@@ -657,6 +668,8 @@ export class Session {
|
|
|
657
668
|
// whisper resolves it to "segment" (its robust path), no-timestamp
|
|
658
669
|
// families resolve to "none".
|
|
659
670
|
p.timestamps = lookup(TIMESTAMPS, opts.timestamps ?? "auto", "timestamps");
|
|
671
|
+
p.pnc = lookup(PNC, opts.pnc ?? "default", "pnc");
|
|
672
|
+
p.itn = lookup(ITN, opts.itn ?? "default", "itn");
|
|
660
673
|
p.diarize = lookup(DIARIZE, opts.diarize ?? "default", "diarize");
|
|
661
674
|
if (opts.language !== undefined)
|
|
662
675
|
p.language = opts.language;
|
|
@@ -744,6 +757,8 @@ export class Session {
|
|
|
744
757
|
language: opts.language,
|
|
745
758
|
targetLanguage: opts.targetLanguage,
|
|
746
759
|
timestamps: opts.timestamps,
|
|
760
|
+
pnc: opts.pnc,
|
|
761
|
+
itn: opts.itn,
|
|
747
762
|
diarize: opts.diarize,
|
|
748
763
|
keepSpecialTags: opts.keepSpecialTags,
|
|
749
764
|
specKDrafts: -1,
|
|
@@ -840,7 +855,6 @@ export class Stream {
|
|
|
840
855
|
#keepalive;
|
|
841
856
|
#active = true;
|
|
842
857
|
#stale = false; // true once the session has begun a newer native stream
|
|
843
|
-
#inFlight = false; // true while a feed/finalize native call runs on a worker
|
|
844
858
|
#holdsLease = true; // born holding the model's compute lease (claimed at begin)
|
|
845
859
|
/** @internal */
|
|
846
860
|
constructor(n, session, lock, keepalive) {
|
|
@@ -904,9 +918,8 @@ export class Stream {
|
|
|
904
918
|
// The native feed runs on a libuv worker. While it is in flight the
|
|
905
919
|
// session must not be touched from the main thread — the C session API
|
|
906
920
|
// is single-threaded (transcribe.h), and stream_get_text hands back
|
|
907
|
-
// pointers the feed may free/realloc. Flag
|
|
908
|
-
// fast instead of racing into a use-after-free.
|
|
909
|
-
this.#inFlight = true;
|
|
921
|
+
// pointers the feed may free/realloc. Flag the owning session so every
|
|
922
|
+
// result getter fails fast instead of racing into a use-after-free.
|
|
910
923
|
this.#sessionControl.enterCompute("feed()/finalize()");
|
|
911
924
|
try {
|
|
912
925
|
const status = await callAsync(n.F.streamFeed, h, samples, samples.length, u);
|
|
@@ -919,7 +932,6 @@ export class Stream {
|
|
|
919
932
|
check(n, status, "transcribe_stream_feed");
|
|
920
933
|
}
|
|
921
934
|
finally {
|
|
922
|
-
this.#inFlight = false;
|
|
923
935
|
this.#sessionControl.leaveCompute("feed()/finalize()");
|
|
924
936
|
}
|
|
925
937
|
return toStreamUpdate(u);
|
|
@@ -935,13 +947,11 @@ export class Stream {
|
|
|
935
947
|
return this.#lock.run(async () => {
|
|
936
948
|
const u = {};
|
|
937
949
|
n.F.streamUpdateInit(u);
|
|
938
|
-
this.#inFlight = true; // see feed(): worker-thread compute, no concurrent reads
|
|
939
950
|
this.#sessionControl.enterCompute("feed()/finalize()");
|
|
940
951
|
try {
|
|
941
952
|
check(n, await callAsync(n.F.streamFinalize, h, u), "transcribe_stream_finalize");
|
|
942
953
|
}
|
|
943
954
|
finally {
|
|
944
|
-
this.#inFlight = false;
|
|
945
955
|
this.#sessionControl.leaveCompute("feed()/finalize()");
|
|
946
956
|
// Finalize ends the active stream (FINISHED on success, FAILED on
|
|
947
957
|
// error), so the model is free again — release the lease either way.
|
|
@@ -951,22 +961,21 @@ export class Stream {
|
|
|
951
961
|
});
|
|
952
962
|
}
|
|
953
963
|
/**
|
|
954
|
-
* Reads borrow session-owned snapshot memory, so they are forbidden while
|
|
955
|
-
*
|
|
956
|
-
*
|
|
957
|
-
* `await stream.feed(chunk)` then read — is unaffected; this only rejects a
|
|
958
|
-
* read issued against an un-awaited feed.
|
|
964
|
+
* Reads borrow session-owned snapshot memory, so they are forbidden while
|
|
965
|
+
* any worker call is computing on this session (concurrent use is undefined
|
|
966
|
+
* per transcribe.h). The natural await-then-read pattern is unaffected.
|
|
959
967
|
*/
|
|
960
|
-
#
|
|
961
|
-
|
|
962
|
-
|
|
968
|
+
#assertNotComputing(what) {
|
|
969
|
+
const compute = this.#sessionControl.currentCompute();
|
|
970
|
+
if (compute) {
|
|
971
|
+
throw new TranscribeError(`cannot read stream ${what} while ${compute} is in flight; await it first`);
|
|
963
972
|
}
|
|
964
973
|
}
|
|
965
974
|
/** Current text snapshot (copied at the boundary). */
|
|
966
975
|
get text() {
|
|
967
976
|
const h = this.#session.handle; // throws if the session was disposed
|
|
968
977
|
this.#assertCurrent("read stream text");
|
|
969
|
-
this.#
|
|
978
|
+
this.#assertNotComputing("text");
|
|
970
979
|
const n = this.#n;
|
|
971
980
|
const t = {};
|
|
972
981
|
n.F.streamTextInit(t);
|
|
@@ -977,18 +986,27 @@ export class Stream {
|
|
|
977
986
|
tentative: t.tentative_text ?? "",
|
|
978
987
|
};
|
|
979
988
|
}
|
|
989
|
+
/** Full structured snapshot of the current hypothesis (owned copies). */
|
|
990
|
+
get snapshot() {
|
|
991
|
+
const h = this.#session.handle; // throws if the session was disposed
|
|
992
|
+
this.#assertCurrent("read stream snapshot");
|
|
993
|
+
if (!this.#active)
|
|
994
|
+
throw new TranscribeError("stream has been reset");
|
|
995
|
+
this.#assertNotComputing("snapshot");
|
|
996
|
+
return materialize(this.#n, singleAccessors(this.#n, h));
|
|
997
|
+
}
|
|
980
998
|
get state() {
|
|
981
999
|
const h = this.#session.handle; // throws if the session was disposed
|
|
982
1000
|
this.#assertCurrent("read stream state");
|
|
983
1001
|
if (!this.#active)
|
|
984
1002
|
return "idle"; // reset() returns to idle; native reset may still be queued
|
|
985
|
-
this.#
|
|
1003
|
+
this.#assertNotComputing("state");
|
|
986
1004
|
return STREAM_STATES[this.#n.F.streamGetState(h)] ?? "idle";
|
|
987
1005
|
}
|
|
988
1006
|
get revision() {
|
|
989
1007
|
const h = this.#session.handle; // throws if the session was disposed
|
|
990
1008
|
this.#assertCurrent("read stream revision");
|
|
991
|
-
this.#
|
|
1009
|
+
this.#assertNotComputing("revision");
|
|
992
1010
|
return this.#n.F.streamRevision(h);
|
|
993
1011
|
}
|
|
994
1012
|
/**
|
|
@@ -999,7 +1017,7 @@ export class Stream {
|
|
|
999
1017
|
get lastStatus() {
|
|
1000
1018
|
const h = this.#session.handle; // throws if the session was disposed
|
|
1001
1019
|
this.#assertCurrent("read stream lastStatus");
|
|
1002
|
-
this.#
|
|
1020
|
+
this.#assertNotComputing("lastStatus");
|
|
1003
1021
|
const n = this.#n;
|
|
1004
1022
|
const status = n.F.streamLastStatus(h);
|
|
1005
1023
|
if (status === g.TRANSCRIBE_OK)
|
package/dist/loader.js
CHANGED
|
@@ -103,8 +103,13 @@ function tryPlatformPackage() {
|
|
|
103
103
|
}
|
|
104
104
|
// A contract mismatch is fatal, not a fall-through.
|
|
105
105
|
const contract = validateContract(dir, provider);
|
|
106
|
+
const libraryPath = path.join(dir, LIB_NAME);
|
|
107
|
+
if (!fs.existsSync(libraryPath)) {
|
|
108
|
+
throw new BackendError(`provider ${provider} at ${dir} is missing ${LIB_NAME} — the package is ` +
|
|
109
|
+
`partially installed. Delete node_modules and reinstall.`);
|
|
110
|
+
}
|
|
106
111
|
return {
|
|
107
|
-
libraryPath
|
|
112
|
+
libraryPath,
|
|
108
113
|
artifactDir: dir,
|
|
109
114
|
provider,
|
|
110
115
|
backends: contract.backends ?? [],
|
|
@@ -112,6 +117,45 @@ function tryPlatformPackage() {
|
|
|
112
117
|
}
|
|
113
118
|
return null;
|
|
114
119
|
}
|
|
120
|
+
/**
|
|
121
|
+
* Explain why no provider package resolved, distinguishing "never installed"
|
|
122
|
+
* from "partially installed". The partial state is real: an interrupted
|
|
123
|
+
* optional-dependency extraction (the provider is by far the largest artifact
|
|
124
|
+
* in the tree) leaves an empty or missing directory that npm's hidden lockfile
|
|
125
|
+
* (node_modules/.package-lock.json) still records as installed. npm then
|
|
126
|
+
* trusts that lockfile on later installs, computes an empty diff, and never
|
|
127
|
+
* repairs the tree — only deleting node_modules (or the hidden lockfile)
|
|
128
|
+
* heals it, so the error must say which state the tree is in.
|
|
129
|
+
*/
|
|
130
|
+
function diagnoseMissingProvider() {
|
|
131
|
+
const tuple = platformTuple();
|
|
132
|
+
if (!tuple) {
|
|
133
|
+
return `no prebuilt @transcribe-cpp provider exists for ${process.platform}-${process.arch}.`;
|
|
134
|
+
}
|
|
135
|
+
const provider = `@transcribe-cpp/${tuple}`;
|
|
136
|
+
const require = createRequire(import.meta.url);
|
|
137
|
+
for (const nm of require.resolve.paths(provider) ?? []) {
|
|
138
|
+
const providerDir = path.join(nm, "@transcribe-cpp", tuple);
|
|
139
|
+
let recorded = false;
|
|
140
|
+
try {
|
|
141
|
+
const hidden = JSON.parse(fs.readFileSync(path.join(nm, ".package-lock.json"), "utf8"));
|
|
142
|
+
recorded = `node_modules/@transcribe-cpp/${tuple}` in (hidden.packages ?? {});
|
|
143
|
+
}
|
|
144
|
+
catch {
|
|
145
|
+
// No readable hidden lockfile (pnpm/bun/yarn, or not this tree) — the
|
|
146
|
+
// directory probe below still catches a partially extracted provider.
|
|
147
|
+
}
|
|
148
|
+
if (fs.existsSync(providerDir) || recorded) {
|
|
149
|
+
return (`${provider}@${OUR_VERSION} under ${nm} is partially installed — its files ` +
|
|
150
|
+
`are missing even though the install recorded it as complete (typically an ` +
|
|
151
|
+
`interrupted download of this large optional dependency). A plain \`npm install\` ` +
|
|
152
|
+
`will NOT repair this; delete node_modules and reinstall.`);
|
|
153
|
+
}
|
|
154
|
+
}
|
|
155
|
+
return (`${provider}@${OUR_VERSION} is not installed. It is an optional dependency of ` +
|
|
156
|
+
`transcribe-cpp, and package managers skip optional dependencies silently when ` +
|
|
157
|
+
`they are disabled or a download fails; reinstall with \`npm install --include=optional\`.`);
|
|
158
|
+
}
|
|
115
159
|
/** A library produced by the source build (`npm run build:native`). */
|
|
116
160
|
function tryLocalPrebuild() {
|
|
117
161
|
const tuple = platformTuple();
|
|
@@ -177,8 +221,8 @@ export function resolveLibrary() {
|
|
|
177
221
|
tryLocalPrebuild() ??
|
|
178
222
|
tryDevTree() ??
|
|
179
223
|
(() => {
|
|
180
|
-
throw new BackendError(
|
|
181
|
-
"
|
|
182
|
-
`
|
|
224
|
+
throw new BackendError(`No transcribe.cpp native library found: ${diagnoseMissingProvider()} ` +
|
|
225
|
+
"Alternatively set TRANSCRIBE_LIBRARY, run `npm run build:native` to build " +
|
|
226
|
+
`from source, or build the shared library (build-shared/src/${LIB_NAME}).`);
|
|
183
227
|
})());
|
|
184
228
|
}
|
package/dist/types.d.ts
CHANGED
|
@@ -4,6 +4,8 @@ export type Backend = "auto" | "cpu" | "cpu_accel" | "cuda" | "rocm" | "vulkan"
|
|
|
4
4
|
export type KvType = "auto" | "f32" | "f16";
|
|
5
5
|
export type Task = "transcribe" | "translate";
|
|
6
6
|
export type TimestampKind = "none" | "auto" | "segment" | "word" | "token";
|
|
7
|
+
export type Pnc = "default" | "off" | "on";
|
|
8
|
+
export type Itn = "default" | "off" | "on";
|
|
7
9
|
export type Diarize = "default" | "off" | "on";
|
|
8
10
|
export type Feature = "initial_prompt" | "temperature_fallback" | "long_form" | "cancellation" | "pnc" | "itn" | "diarization";
|
|
9
11
|
/** Mono float32 PCM at the model's native sample rate (16 kHz for v1). */
|
|
@@ -65,12 +67,13 @@ export interface SessionLimits {
|
|
|
65
67
|
effectiveMaxAudioMs: number;
|
|
66
68
|
maxKvBytes: number;
|
|
67
69
|
}
|
|
68
|
-
export interface
|
|
70
|
+
export interface Transcript {
|
|
69
71
|
text: string;
|
|
70
72
|
/** The model's decoded output before family post-processing (diarization
|
|
71
73
|
* markers, timestamp/special tokens, tag filtering, whitespace trims).
|
|
72
74
|
* Equal to `text` modulo whitespace for families that emit clean text. */
|
|
73
75
|
rawText: string;
|
|
76
|
+
/** Model-detected language, or an empty string when none applies. */
|
|
74
77
|
language: string;
|
|
75
78
|
timestampKind: TimestampKind;
|
|
76
79
|
segments: Segment[];
|
|
@@ -78,6 +81,9 @@ export interface TranscriptionResult {
|
|
|
78
81
|
words: Word[];
|
|
79
82
|
tokens: Token[];
|
|
80
83
|
timings: Timings;
|
|
84
|
+
}
|
|
85
|
+
/** An offline transcript plus terminal run status flags. */
|
|
86
|
+
export interface TranscriptionResult extends Transcript {
|
|
81
87
|
aborted: boolean;
|
|
82
88
|
truncated: boolean;
|
|
83
89
|
}
|
|
@@ -125,6 +131,10 @@ export interface TranscribeOptions {
|
|
|
125
131
|
targetLanguage?: string;
|
|
126
132
|
/** Default "auto" (richest the model supports, per-family). */
|
|
127
133
|
timestamps?: TimestampKind;
|
|
134
|
+
/** Punctuation and capitalization control; default preserves the family default. */
|
|
135
|
+
pnc?: Pnc;
|
|
136
|
+
/** Inverse text normalization control; default preserves the family default. */
|
|
137
|
+
itn?: Itn;
|
|
128
138
|
/** Default "default" (speaker attribution off for every family). */
|
|
129
139
|
diarize?: Diarize;
|
|
130
140
|
keepSpecialTags?: boolean;
|
|
@@ -171,6 +181,8 @@ export interface StreamOptions {
|
|
|
171
181
|
language?: string;
|
|
172
182
|
targetLanguage?: string;
|
|
173
183
|
timestamps?: TimestampKind;
|
|
184
|
+
pnc?: Pnc;
|
|
185
|
+
itn?: Itn;
|
|
174
186
|
diarize?: Diarize;
|
|
175
187
|
keepSpecialTags?: boolean;
|
|
176
188
|
commitPolicy?: CommitPolicy;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "transcribe-cpp",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.2",
|
|
4
4
|
"description": "TypeScript/Node.js bindings for transcribe.cpp — a C/C++ speech-to-text library built on ggml",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"exports": {
|
|
@@ -51,11 +51,11 @@
|
|
|
51
51
|
"koffi": "^3.0.2"
|
|
52
52
|
},
|
|
53
53
|
"optionalDependencies": {
|
|
54
|
-
"@transcribe-cpp/darwin-arm64-metal": "0.2.
|
|
55
|
-
"@transcribe-cpp/darwin-x64-cpu": "0.2.
|
|
56
|
-
"@transcribe-cpp/linux-x64-cpu-vulkan": "0.2.
|
|
57
|
-
"@transcribe-cpp/linux-arm64-cpu-vulkan": "0.2.
|
|
58
|
-
"@transcribe-cpp/win32-x64-cpu-vulkan": "0.2.
|
|
54
|
+
"@transcribe-cpp/darwin-arm64-metal": "0.2.2",
|
|
55
|
+
"@transcribe-cpp/darwin-x64-cpu": "0.2.2",
|
|
56
|
+
"@transcribe-cpp/linux-x64-cpu-vulkan": "0.2.2",
|
|
57
|
+
"@transcribe-cpp/linux-arm64-cpu-vulkan": "0.2.2",
|
|
58
|
+
"@transcribe-cpp/win32-x64-cpu-vulkan": "0.2.2"
|
|
59
59
|
},
|
|
60
60
|
"devDependencies": {
|
|
61
61
|
"@types/node": "^22.0.0",
|