@usewhisper/mcp-server 0.3.0 → 0.5.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/README.md +182 -154
- package/dist/autosubscribe-6EDKPBE2.js +4068 -4068
- package/dist/autosubscribe-GHO6YR5A.js +4068 -4068
- package/dist/autosubscribe-ISDETQIB.js +435 -435
- package/dist/chunk-3WGYBAYR.js +8387 -8387
- package/dist/chunk-52VJYCZ7.js +455 -455
- package/dist/chunk-5KBZQHDL.js +189 -189
- package/dist/chunk-5KIJNY6Z.js +370 -370
- package/dist/chunk-7SN3CKDK.js +1076 -1076
- package/dist/chunk-B3VWOHUA.js +271 -271
- package/dist/chunk-C57DHKTL.js +459 -459
- package/dist/chunk-EI5CE3EY.js +616 -616
- package/dist/chunk-FTWUJBAH.js +386 -386
- package/dist/chunk-H3HSKH2P.js +4841 -4841
- package/dist/chunk-JO3ORBZD.js +616 -616
- package/dist/chunk-L6DXSM2U.js +456 -456
- package/dist/chunk-LMEYV4JD.js +368 -368
- package/dist/chunk-MEFLJ4PV.js +8385 -8385
- package/dist/chunk-OBLI4FE4.js +275 -275
- package/dist/chunk-PPGYJJED.js +271 -271
- package/dist/chunk-QGM4M3NI.js +37 -37
- package/dist/chunk-T7KMSTWP.js +399 -399
- package/dist/chunk-TWEIYHI6.js +399 -399
- package/dist/chunk-UYWE7HSU.js +368 -368
- package/dist/chunk-X2DL2GWT.js +32 -32
- package/dist/chunk-X7HNNNJJ.js +1079 -1079
- package/dist/consolidation-2GCKI4RE.js +220 -220
- package/dist/consolidation-4JOPW6BG.js +220 -220
- package/dist/consolidation-FOVQTWNQ.js +222 -222
- package/dist/consolidation-IFQ52E44.js +209 -209
- package/dist/context-sharing-4ITCNKG4.js +307 -307
- package/dist/context-sharing-6CCFIAKL.js +275 -275
- package/dist/context-sharing-GYKLXHZA.js +307 -307
- package/dist/context-sharing-PH64JTXS.js +308 -308
- package/dist/context-sharing-Y6LTZZOF.js +307 -307
- package/dist/cost-optimization-6OIKRSBV.js +195 -195
- package/dist/cost-optimization-7DVSTL6R.js +307 -307
- package/dist/cost-optimization-BH5NAX33.js +286 -286
- package/dist/cost-optimization-F3L5BS5F.js +303 -303
- package/dist/ingest-2LPTWUUM.js +16 -16
- package/dist/ingest-7T5FAZNC.js +15 -15
- package/dist/ingest-EBNIE7XB.js +15 -15
- package/dist/ingest-FSHT5BCS.js +15 -15
- package/dist/ingest-QE2BTV72.js +14 -14
- package/dist/oracle-3RLQF3DP.js +259 -259
- package/dist/oracle-FKRTQUUG.js +282 -282
- package/dist/oracle-J47QCSEW.js +263 -263
- package/dist/oracle-MDP5MZRC.js +256 -256
- package/dist/search-BLVHWLWC.js +14 -14
- package/dist/search-CZ5NYL5B.js +12 -12
- package/dist/search-EG6TYWWW.js +13 -13
- package/dist/search-I22QQA7T.js +13 -13
- package/dist/search-T7H5G6DW.js +13 -13
- package/dist/server.d.ts +2 -2
- package/dist/server.js +1973 -169
- package/dist/server.js.map +1 -1
- package/package.json +51 -51
package/dist/chunk-X2DL2GWT.js
CHANGED
|
@@ -1,33 +1,33 @@
|
|
|
1
|
-
// src/db/index.ts
|
|
2
|
-
import { PrismaClient } from "@prisma/client";
|
|
3
|
-
import { Prisma } from "@prisma/client";
|
|
4
|
-
var globalForPrisma = globalThis;
|
|
5
|
-
var db = globalForPrisma.prisma ?? new PrismaClient();
|
|
6
|
-
var prisma = db;
|
|
7
|
-
if (process.env.NODE_ENV !== "production") {
|
|
8
|
-
globalForPrisma.prisma = db;
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
// src/engine/embeddings.ts
|
|
12
|
-
import OpenAI from "openai";
|
|
13
|
-
var openai = new OpenAI({ apiKey: process.env.OPENAI_API_KEY });
|
|
14
|
-
async function embed(texts) {
|
|
15
|
-
const res = await openai.embeddings.create({
|
|
16
|
-
model: "text-embedding-3-small",
|
|
17
|
-
input: texts,
|
|
18
|
-
dimensions: 1536
|
|
19
|
-
});
|
|
20
|
-
return res.data.map((d) => d.embedding);
|
|
21
|
-
}
|
|
22
|
-
async function embedSingle(text) {
|
|
23
|
-
const [embedding] = await embed([text]);
|
|
24
|
-
return embedding;
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
export {
|
|
28
|
-
db,
|
|
29
|
-
prisma,
|
|
30
|
-
embed,
|
|
31
|
-
embedSingle
|
|
32
|
-
};
|
|
1
|
+
// src/db/index.ts
|
|
2
|
+
import { PrismaClient } from "@prisma/client";
|
|
3
|
+
import { Prisma } from "@prisma/client";
|
|
4
|
+
var globalForPrisma = globalThis;
|
|
5
|
+
var db = globalForPrisma.prisma ?? new PrismaClient();
|
|
6
|
+
var prisma = db;
|
|
7
|
+
if (process.env.NODE_ENV !== "production") {
|
|
8
|
+
globalForPrisma.prisma = db;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
// src/engine/embeddings.ts
|
|
12
|
+
import OpenAI from "openai";
|
|
13
|
+
var openai = new OpenAI({ apiKey: process.env.OPENAI_API_KEY });
|
|
14
|
+
async function embed(texts) {
|
|
15
|
+
const res = await openai.embeddings.create({
|
|
16
|
+
model: "text-embedding-3-small",
|
|
17
|
+
input: texts,
|
|
18
|
+
dimensions: 1536
|
|
19
|
+
});
|
|
20
|
+
return res.data.map((d) => d.embedding);
|
|
21
|
+
}
|
|
22
|
+
async function embedSingle(text) {
|
|
23
|
+
const [embedding] = await embed([text]);
|
|
24
|
+
return embedding;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
export {
|
|
28
|
+
db,
|
|
29
|
+
prisma,
|
|
30
|
+
embed,
|
|
31
|
+
embedSingle
|
|
32
|
+
};
|
|
33
33
|
//# sourceMappingURL=chunk-X2DL2GWT.js.map
|