@bendyline/docblocks 2.7.15 → 2.7.16
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/dist/{capabilities-98WbPTSj.d.ts → capabilities-rfOUYj1Y.d.ts} +23 -1
- package/dist/{chunk-OIBDXKQN.js → chunk-OXEMTJRJ.js} +103 -13
- package/dist/{chunk-P5VP6XMH.js → chunk-WIC3ASFS.js} +1 -1
- package/dist/{chunk-C6J65F5C.js → chunk-XC7766WT.js} +2 -2
- package/dist/filesystem/electron.d.ts +1 -1
- package/dist/filesystem/electron.js +3 -3
- package/dist/filesystem/host.js +2 -2
- package/dist/filesystem/index.d.ts +1 -1
- package/dist/filesystem/index.js +3 -3
- package/dist/host/index.d.ts +110 -3
- package/dist/host/index.js +15 -3
- package/dist/index.d.ts +3 -3
- package/dist/index.js +16 -4
- package/dist/{reconcile-electron-MzNvYOp2.d.ts → reconcile-electron-DtP-HC39.d.ts} +1 -1
- package/dist/workspace/index.d.ts +2 -2
- package/package.json +1 -1
|
@@ -322,6 +322,23 @@ interface AiModelInfo {
|
|
|
322
322
|
readonly availability?: 'available' | 'unavailable' | 'download-required' | 'downloading';
|
|
323
323
|
/** Native readiness explanation, suitable for the model picker. */
|
|
324
324
|
readonly unavailableReason?: string;
|
|
325
|
+
/** How well this model does DocBlocks' own work, when the provider has measured it. */
|
|
326
|
+
readonly docbench?: AiModelDocbench;
|
|
327
|
+
}
|
|
328
|
+
/**
|
|
329
|
+
* A model's docbench result: a judged 0–100 score for DocBlocks' document
|
|
330
|
+
* work (review, writing, diagrams, slides, study aids, narration), measured
|
|
331
|
+
* per build and engine by the provider's published benchmark.
|
|
332
|
+
*/
|
|
333
|
+
interface AiModelDocbench {
|
|
334
|
+
/** 0–100. */
|
|
335
|
+
readonly score: number;
|
|
336
|
+
/** Rank band within its round; models in one band are not reliably different. */
|
|
337
|
+
readonly band: number;
|
|
338
|
+
/** The docbench version that measured it; scores compare only within one. */
|
|
339
|
+
readonly version: string;
|
|
340
|
+
/** Per-family scores, 0–100, keyed by family id (`review`, `writing`, …). */
|
|
341
|
+
readonly families: Readonly<Record<string, number>>;
|
|
325
342
|
}
|
|
326
343
|
/**
|
|
327
344
|
* How a downloadable model fits this device's memory, as the provider judged
|
|
@@ -349,6 +366,11 @@ interface AiModelDownloadInfo {
|
|
|
349
366
|
readonly score: number | null;
|
|
350
367
|
/** The provider's one recommendation for this device. */
|
|
351
368
|
readonly recommended: boolean;
|
|
369
|
+
/**
|
|
370
|
+
* Measured quality on DocBlocks' work. When the provider has measured any
|
|
371
|
+
* candidate, `score` and `recommended` rank by it among models that fit.
|
|
372
|
+
*/
|
|
373
|
+
readonly docbench?: AiModelDocbench;
|
|
352
374
|
}
|
|
353
375
|
type AiStatus = {
|
|
354
376
|
readonly kind: 'unavailable';
|
|
@@ -1591,4 +1613,4 @@ declare function parseHostEnvironment(value: unknown): HostEnvironment | null;
|
|
|
1591
1613
|
*/
|
|
1592
1614
|
declare function deriveHostCapabilities(host: unknown): HostCapabilities;
|
|
1593
1615
|
|
|
1594
|
-
export { type
|
|
1616
|
+
export { type AiResult as $, AI_IMAGE_ASPECTS as A, type AiImageModelFit as B, type AiImagePhase as C, type AiImagePreferences as D, type AiImagePreferencesPatch as E, type AiImageProgress as F, type AiImageRequest as G, type AiImageResult as H, type AiImageStyle as I, type AiImageUnavailableReason as J, type AiImagesAPI as K, type AiKnowledgeAPI as L, type AiKnowledgeAction as M, type AiKnowledgeCatalog as N, type AiKnowledgePassage as O, type AiKnowledgeState as P, type AiModelDocbench as Q, type AiModelDownloadInfo as R, type AiModelFit as S, type AiModelInfo as T, type AiModelInstallEvent as U, type AiModelInstallHandle as V, type AiPreferences as W, type AiPreferencesPatch as X, type AiProgress as Y, type AiProviderInfo as Z, type AiResponseFormat as _, AI_IMAGE_FIT_VERDICTS as a, type SpeechModelKind as a$, type AiReviewMode as a0, type AiSearchHit as a1, type AiSearchQuery as a2, type AiSearchResult as a3, type AiSpeechAudio as a4, type AiStatus as a5, type AiSynthesizeRequest as a6, type AiTranscribeRequest as a7, type AiTranscript as a8, type AiUnavailableReason as a9, type GitLogOptions as aA, type GitRemoteInfo as aB, type GitRepoDetection as aC, type GitResult as aD, type GitRevision as aE, type GitStatus as aF, HOST_PLATFORMS as aG, HOST_SURFACE_KINDS as aH, type HostCapabilities as aI, type HostCloseReason as aJ, type HostEnvironment as aK, type HostExportTargetGrant as aL, type HostPinnedDocument as aM, type HostPlatform as aN, type HostPrepareCloseRequest as aO, type HostPrepareCloseResult as aP, type HostSurfaceKind as aQ, type MenuCommand as aR, NO_HOST_CAPABILITIES as aS, type OpenRequest as aT, type SpeechAudioChunk as aU, type SpeechCatalog as aV, type SpeechError as aW, type SpeechErrorCode as aX, type SpeechInstallEvent as aY, type SpeechInstallHandle as aZ, type SpeechModelInfo as a_, type DocBlocksHostAPI as aa, type DocBlocksHostAiAPI as ab, type DocBlocksHostClipboardAPI as ac, type DocBlocksHostExportAPI as ad, type DocBlocksHostExternalAPI as ae, type DocBlocksHostFfmpegAPI as af, type DocBlocksHostFsAPI as ag, type DocBlocksHostGitAPI as ah, type DocBlocksHostLifecycleAPI as ai, type DocBlocksHostMenuAPI as aj, type DocBlocksHostShellAPI as ak, type DocBlocksHostSpeechAPI as al, type DocBlocksHostUpdaterAPI as am, type DocBlocksHostWorkspacesAPI as an, type ElectronWorkspaceInfo as ao, type ExternalBinaryCommitResult as ap, type GitBranchInfo as aq, type GitCapabilities as ar, type GitCloneHandle as as, type GitCloneProgress as at, type GitError as au, type GitErrorCode as av, type GitFileAtRevision as aw, type GitFileChange as ax, type GitFileStatusCode as ay, type GitLogEntry as az, AI_IMAGE_WIRE_LIMITS as b, type SpeechPreferences as b0, type SpeechPreferencesPatch as b1, type SpeechProgress as b2, type SpeechReadiness as b3, type SpeechReadinessState as b4, type SpeechResult as b5, type SpeechSegment as b6, type SpeechStatus as b7, type SpeechSynthesisHandle as b8, type SpeechSynthesisSummary as b9, parseAiKnowledgeAction as bA, parseAiKnowledgeState as bB, parseHostEnvironment as bC, type SpeechSynthesizeEvent as ba, type SpeechSynthesizeRequest as bb, type SpeechTranscribeRequest as bc, type SpeechTranscript as bd, type SpeechVoiceInfo as be, type SpeechWord as bf, type SpeechWordTiming as bg, type UpdateCheckResult as bh, type UpdateInstallResult as bi, type UpdaterStatus as bj, deriveHostCapabilities as bk, isAiImageAspect as bl, isAiImageModelId as bm, knowledgeChatEvent as bn, knowledgeSources as bo, parseAiImageAccess as bp, parseAiImageEvent as bq, parseAiImageInstallEvent as br, parseAiImageModel as bs, parseAiImageModelList as bt, parseAiImagePreferences as bu, parseAiImagePreferencesPatch as bv, parseAiImageRequest as bw, parseAiImageResult as bx, parseAiImageStyle as by, parseAiImageStyleList as bz, type AiChatCompletion as c, type AiChatEvent as d, type AiChatEvidence as e, type AiChatHandle as f, type AiChatKnowledge as g, type AiChatKnowledgeSource as h, type AiChatMessage as i, type AiChatProgress as j, type AiChatPurpose as k, type AiChatRequest as l, type AiConnectionStep as m, type AiEnsureWorkspaceHandle as n, type AiError as o, type AiErrorCode as p, type AiFactCheck as q, type AiFactCheckRequest as r, type AiFactCheckSentence as s, type AiImageAccess as t, type AiImageAspect as u, type AiImageEvent as v, type AiImageHandle as w, type AiImageInstallEvent as x, type AiImageInstallHandle as y, type AiImageModel as z };
|
|
@@ -173,6 +173,8 @@ var AI_WIRE_LIMITS = Object.freeze({
|
|
|
173
173
|
factCheckSentenceCharacters: 1e3,
|
|
174
174
|
factCheckDetails: 16,
|
|
175
175
|
modelEntries: 200,
|
|
176
|
+
/** docbench families per model; the v1 pack has six. */
|
|
177
|
+
docbenchFamilies: 16,
|
|
176
178
|
contextWindowCeiling: 8e6,
|
|
177
179
|
downloadBytesCeiling: Number.MAX_SAFE_INTEGER
|
|
178
180
|
});
|
|
@@ -264,14 +266,41 @@ function parseAiProgress(value) {
|
|
|
264
266
|
if (value.percent !== null && !isFiniteInRange(value.percent, 0, 100)) return null;
|
|
265
267
|
return { phase: value.phase, message: value.message, percent: value.percent };
|
|
266
268
|
}
|
|
269
|
+
function parseAiModelDocbench(value) {
|
|
270
|
+
if (!isRecord2(value) || !hasExactKeys(value, ["score", "band", "version", "families"])) {
|
|
271
|
+
return null;
|
|
272
|
+
}
|
|
273
|
+
if (!isFiniteInRange(value.score, 0, 100)) return null;
|
|
274
|
+
if (!isNonNegativeInteger(value.band, AI_WIRE_LIMITS.modelEntries) || value.band === 0) {
|
|
275
|
+
return null;
|
|
276
|
+
}
|
|
277
|
+
if (!isBoundedString(value.version, AI_WIRE_LIMITS.progressPhaseCharacters, 1)) return null;
|
|
278
|
+
if (!isRecord2(value.families)) return null;
|
|
279
|
+
const entries = Object.entries(value.families);
|
|
280
|
+
if (entries.length > AI_WIRE_LIMITS.docbenchFamilies) return null;
|
|
281
|
+
const families = {};
|
|
282
|
+
for (const [id, score] of entries) {
|
|
283
|
+
if (!isBoundedString(id, AI_WIRE_LIMITS.progressPhaseCharacters, 1)) return null;
|
|
284
|
+
if (!isFiniteInRange(score, 0, 100)) return null;
|
|
285
|
+
families[id] = score;
|
|
286
|
+
}
|
|
287
|
+
return { score: value.score, band: value.band, version: value.version, families };
|
|
288
|
+
}
|
|
289
|
+
function docbenchField(value) {
|
|
290
|
+
if (value.docbench === void 0) return {};
|
|
291
|
+
const docbench = parseAiModelDocbench(value.docbench);
|
|
292
|
+
return docbench ? { docbench } : null;
|
|
293
|
+
}
|
|
267
294
|
function parseAiModelInfo(value) {
|
|
268
295
|
if (!isRecord2(value)) return null;
|
|
269
296
|
if (!hasKeysWithin(
|
|
270
297
|
value,
|
|
271
298
|
["id", "label", "local", "contextWindow", "isDefault"],
|
|
272
|
-
["availability", "unavailableReason"]
|
|
299
|
+
["availability", "unavailableReason", "docbench"]
|
|
273
300
|
))
|
|
274
301
|
return null;
|
|
302
|
+
const docbench = docbenchField(value);
|
|
303
|
+
if (!docbench) return null;
|
|
275
304
|
if (!isBoundedString(value.id, HOST_WIRE_LIMITS.identifierCharacters, 1)) return null;
|
|
276
305
|
if (!isBoundedString(value.label, HOST_WIRE_LIMITS.labelCharacters, 1)) return null;
|
|
277
306
|
if (typeof value.local !== "boolean") return null;
|
|
@@ -298,7 +327,8 @@ function parseAiModelInfo(value) {
|
|
|
298
327
|
},
|
|
299
328
|
...value.unavailableReason === void 0 ? {} : {
|
|
300
329
|
unavailableReason: value.unavailableReason
|
|
301
|
-
}
|
|
330
|
+
},
|
|
331
|
+
...docbench
|
|
302
332
|
};
|
|
303
333
|
}
|
|
304
334
|
function parseAiModelInfoList(value) {
|
|
@@ -320,18 +350,15 @@ function parseAiModelFit(value) {
|
|
|
320
350
|
}
|
|
321
351
|
function parseAiModelDownloadInfo(value) {
|
|
322
352
|
if (!isRecord2(value)) return null;
|
|
323
|
-
if (!
|
|
324
|
-
|
|
325
|
-
"label",
|
|
326
|
-
"
|
|
327
|
-
|
|
328
|
-
"state",
|
|
329
|
-
"fit",
|
|
330
|
-
"score",
|
|
331
|
-
"recommended"
|
|
332
|
-
])) {
|
|
353
|
+
if (!hasKeysWithin(
|
|
354
|
+
value,
|
|
355
|
+
["id", "label", "contextWindow", "downloadBytes", "state", "fit", "score", "recommended"],
|
|
356
|
+
["docbench"]
|
|
357
|
+
)) {
|
|
333
358
|
return null;
|
|
334
359
|
}
|
|
360
|
+
const docbench = docbenchField(value);
|
|
361
|
+
if (!docbench) return null;
|
|
335
362
|
const fit = value.fit === null ? null : parseAiModelFit(value.fit);
|
|
336
363
|
if (value.fit !== null && !fit) return null;
|
|
337
364
|
if (value.score !== null && !isNonNegativeInteger(value.score, 100)) return null;
|
|
@@ -353,7 +380,8 @@ function parseAiModelDownloadInfo(value) {
|
|
|
353
380
|
state: value.state,
|
|
354
381
|
fit,
|
|
355
382
|
score: value.score,
|
|
356
|
-
recommended: value.recommended
|
|
383
|
+
recommended: value.recommended,
|
|
384
|
+
...docbench
|
|
357
385
|
};
|
|
358
386
|
}
|
|
359
387
|
function parseAiModelDownloadInfoList(value) {
|
|
@@ -1678,6 +1706,62 @@ function parseAiImageInstallEvent(value, parse = parseAiImageModel) {
|
|
|
1678
1706
|
return null;
|
|
1679
1707
|
}
|
|
1680
1708
|
|
|
1709
|
+
// src/host/ai-transport.ts
|
|
1710
|
+
var LOCAL_ENGINE_MODEL = /^(?:mlx|llama-cpp|ollama|ds4):/u;
|
|
1711
|
+
function isLocalEngineModel(model) {
|
|
1712
|
+
return LOCAL_ENGINE_MODEL.test(model);
|
|
1713
|
+
}
|
|
1714
|
+
function buildChatCompletionBody(request, options = {}) {
|
|
1715
|
+
const maxTokens = request.maxTokens ?? (request.purpose === "write" && isLocalEngineModel(request.model) ? request.contextWindow : void 0);
|
|
1716
|
+
return {
|
|
1717
|
+
model: request.model,
|
|
1718
|
+
messages: [...request.messages],
|
|
1719
|
+
...request.purpose === "write" ? {} : { reasoning_effort: "none" },
|
|
1720
|
+
...request.temperature === void 0 ? {} : { temperature: request.temperature },
|
|
1721
|
+
...maxTokens == null ? {} : { max_tokens: maxTokens },
|
|
1722
|
+
...options.seed === void 0 ? {} : { seed: options.seed },
|
|
1723
|
+
...request.responseFormat ? {
|
|
1724
|
+
response_format: {
|
|
1725
|
+
type: "json_schema",
|
|
1726
|
+
json_schema: {
|
|
1727
|
+
name: request.responseFormat.name,
|
|
1728
|
+
schema: { ...request.responseFormat.schema },
|
|
1729
|
+
strict: true
|
|
1730
|
+
}
|
|
1731
|
+
}
|
|
1732
|
+
} : {}
|
|
1733
|
+
};
|
|
1734
|
+
}
|
|
1735
|
+
|
|
1736
|
+
// src/host/ai-provider-models.ts
|
|
1737
|
+
function readRanking(value) {
|
|
1738
|
+
if (typeof value !== "object" || value === null) return null;
|
|
1739
|
+
const { score, recommended } = value;
|
|
1740
|
+
return {
|
|
1741
|
+
score: typeof score === "number" && Number.isInteger(score) && score >= 0 && score <= 100 ? score : null,
|
|
1742
|
+
recommended: recommended === true
|
|
1743
|
+
};
|
|
1744
|
+
}
|
|
1745
|
+
function providerModelRanking(entry) {
|
|
1746
|
+
return readRanking(entry.docbench_recommendation) ?? readRanking(entry.recommendation) ?? { score: null, recommended: false };
|
|
1747
|
+
}
|
|
1748
|
+
function providerModelDocbench(entry) {
|
|
1749
|
+
const value = entry.docbench;
|
|
1750
|
+
if (typeof value !== "object" || value === null) return void 0;
|
|
1751
|
+
const { score, band, version, families } = value;
|
|
1752
|
+
return parseAiModelDocbench({
|
|
1753
|
+
score,
|
|
1754
|
+
band,
|
|
1755
|
+
version,
|
|
1756
|
+
families: families === void 0 ? {} : families
|
|
1757
|
+
}) ?? void 0;
|
|
1758
|
+
}
|
|
1759
|
+
function sortModelDownloads(models) {
|
|
1760
|
+
return [...models].sort(
|
|
1761
|
+
(a, b) => Number(b.recommended) - Number(a.recommended) || (b.score ?? -1) - (a.score ?? -1)
|
|
1762
|
+
);
|
|
1763
|
+
}
|
|
1764
|
+
|
|
1681
1765
|
// src/host/index.ts
|
|
1682
1766
|
function rawHost() {
|
|
1683
1767
|
if (typeof globalThis === "undefined") return null;
|
|
@@ -1720,6 +1804,7 @@ export {
|
|
|
1720
1804
|
AI_WIRE_LIMITS,
|
|
1721
1805
|
parseAiError,
|
|
1722
1806
|
parseAiProgress,
|
|
1807
|
+
parseAiModelDocbench,
|
|
1723
1808
|
parseAiModelInfo,
|
|
1724
1809
|
parseAiModelInfoList,
|
|
1725
1810
|
parseAiModelDownloadInfo,
|
|
@@ -1777,6 +1862,11 @@ export {
|
|
|
1777
1862
|
parseAiImageResult,
|
|
1778
1863
|
parseAiImageEvent,
|
|
1779
1864
|
parseAiImageInstallEvent,
|
|
1865
|
+
isLocalEngineModel,
|
|
1866
|
+
buildChatCompletionBody,
|
|
1867
|
+
providerModelRanking,
|
|
1868
|
+
providerModelDocbench,
|
|
1869
|
+
sortModelDownloads,
|
|
1780
1870
|
hasDocBlocksHost,
|
|
1781
1871
|
getHostCapabilities,
|
|
1782
1872
|
hostSupports,
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import {
|
|
2
2
|
HostFileSystemProviderV2
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-WIC3ASFS.js";
|
|
4
4
|
import {
|
|
5
5
|
ELECTRON_FILE_SYSTEM_V2_CAPABILITIES,
|
|
6
6
|
maybeGetDocBlocksHost
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-OXEMTJRJ.js";
|
|
8
8
|
|
|
9
9
|
// src/filesystem/electron-provider-v2.ts
|
|
10
10
|
var ElectronFileSystemProviderV2 = class extends HostFileSystemProviderV2 {
|
|
@@ -4,7 +4,7 @@ export { isElectronHost } from '../host/index.js';
|
|
|
4
4
|
import '../v2-pBdrFAlW.js';
|
|
5
5
|
import '../workspace-path-CWVrcuPL.js';
|
|
6
6
|
import '../filesystem-v2-CYPHqoIw.js';
|
|
7
|
-
import '../capabilities-
|
|
7
|
+
import '../capabilities-rfOUYj1Y.js';
|
|
8
8
|
|
|
9
9
|
/** Compatibility entry point retaining the Electron backend's exact guarantees. */
|
|
10
10
|
declare class ElectronFileSystemProviderV2 extends HostFileSystemProviderV2 {
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import {
|
|
2
2
|
ElectronFileSystemProvider,
|
|
3
3
|
ElectronFileSystemProviderV2
|
|
4
|
-
} from "../chunk-
|
|
5
|
-
import "../chunk-
|
|
4
|
+
} from "../chunk-XC7766WT.js";
|
|
5
|
+
import "../chunk-WIC3ASFS.js";
|
|
6
6
|
import {
|
|
7
7
|
isElectronHost
|
|
8
|
-
} from "../chunk-
|
|
8
|
+
} from "../chunk-OXEMTJRJ.js";
|
|
9
9
|
import "../chunk-245W57QP.js";
|
|
10
10
|
import "../chunk-V5SWLUZY.js";
|
|
11
11
|
import "../chunk-73OOROXH.js";
|
package/dist/filesystem/host.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import {
|
|
2
2
|
HostFileSystemProviderV2
|
|
3
|
-
} from "../chunk-
|
|
3
|
+
} from "../chunk-WIC3ASFS.js";
|
|
4
4
|
import {
|
|
5
5
|
ELECTRON_FILE_SYSTEM_V2_CAPABILITIES,
|
|
6
6
|
maybeGetDocBlocksHost
|
|
7
|
-
} from "../chunk-
|
|
7
|
+
} from "../chunk-OXEMTJRJ.js";
|
|
8
8
|
import "../chunk-245W57QP.js";
|
|
9
9
|
import "../chunk-V5SWLUZY.js";
|
|
10
10
|
import "../chunk-73OOROXH.js";
|
|
@@ -15,7 +15,7 @@ export { ElectronFileSystemProvider, ElectronFileSystemProviderV2 } from './elec
|
|
|
15
15
|
export { isElectronHost } from '../host/index.js';
|
|
16
16
|
import '../host-provider-v2-C2g9R17A.js';
|
|
17
17
|
import '../filesystem-v2-CYPHqoIw.js';
|
|
18
|
-
import '../capabilities-
|
|
18
|
+
import '../capabilities-rfOUYj1Y.js';
|
|
19
19
|
|
|
20
20
|
/** Immediate article/folder suggestions from an already bounded listing. */
|
|
21
21
|
declare function suggestWikiArticles(files: readonly {
|
package/dist/filesystem/index.js
CHANGED
|
@@ -50,11 +50,11 @@ import "../chunk-3GSMJ4MQ.js";
|
|
|
50
50
|
import {
|
|
51
51
|
ElectronFileSystemProvider,
|
|
52
52
|
ElectronFileSystemProviderV2
|
|
53
|
-
} from "../chunk-
|
|
54
|
-
import "../chunk-
|
|
53
|
+
} from "../chunk-XC7766WT.js";
|
|
54
|
+
import "../chunk-WIC3ASFS.js";
|
|
55
55
|
import {
|
|
56
56
|
isElectronHost
|
|
57
|
-
} from "../chunk-
|
|
57
|
+
} from "../chunk-OXEMTJRJ.js";
|
|
58
58
|
import "../chunk-245W57QP.js";
|
|
59
59
|
import "../chunk-V5SWLUZY.js";
|
|
60
60
|
import "../chunk-73OOROXH.js";
|
package/dist/host/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { d as AiChatEvent, g as AiChatKnowledge, j as AiChatProgress, l as AiChatRequest, o as AiError, q as AiFactCheck, r as AiFactCheckRequest, Q as AiModelDownloadInfo,
|
|
2
|
-
export { A as AI_IMAGE_ASPECTS, a as AI_IMAGE_FIT_VERDICTS, b as AI_IMAGE_WIRE_LIMITS, c as AiChatCompletion, e as AiChatEvidence, f as AiChatHandle, h as AiChatKnowledgeSource, i as AiChatMessage,
|
|
1
|
+
import { d as AiChatEvent, g as AiChatKnowledge, j as AiChatProgress, l as AiChatRequest, o as AiError, q as AiFactCheck, r as AiFactCheckRequest, Q as AiModelDocbench, R as AiModelDownloadInfo, T as AiModelInfo, U as AiModelInstallEvent, W as AiPreferences, X as AiPreferencesPatch, Y as AiProgress, a5 as AiStatus, aU as SpeechAudioChunk, aV as SpeechCatalog, aW as SpeechError, aY as SpeechInstallEvent, a_ as SpeechModelInfo, a$ as SpeechModelKind, b5 as SpeechResult, b0 as SpeechPreferences, b1 as SpeechPreferencesPatch, b2 as SpeechProgress, b3 as SpeechReadiness, b7 as SpeechStatus, b9 as SpeechSynthesisSummary, ba as SpeechSynthesizeEvent, bb as SpeechSynthesizeRequest, bc as SpeechTranscribeRequest, bd as SpeechTranscript, be as SpeechVoiceInfo, aT as OpenRequest, aM as HostPinnedDocument, k as AiChatPurpose, _ as AiResponseFormat, aa as DocBlocksHostAPI, aI as HostCapabilities, aK as HostEnvironment } from '../capabilities-rfOUYj1Y.js';
|
|
2
|
+
export { A as AI_IMAGE_ASPECTS, a as AI_IMAGE_FIT_VERDICTS, b as AI_IMAGE_WIRE_LIMITS, c as AiChatCompletion, e as AiChatEvidence, f as AiChatHandle, h as AiChatKnowledgeSource, i as AiChatMessage, m as AiConnectionStep, n as AiEnsureWorkspaceHandle, p as AiErrorCode, s as AiFactCheckSentence, t as AiImageAccess, u as AiImageAspect, v as AiImageEvent, w as AiImageHandle, x as AiImageInstallEvent, y as AiImageInstallHandle, z as AiImageModel, B as AiImageModelFit, C as AiImagePhase, D as AiImagePreferences, E as AiImagePreferencesPatch, F as AiImageProgress, G as AiImageRequest, H as AiImageResult, I as AiImageStyle, J as AiImageUnavailableReason, K as AiImagesAPI, L as AiKnowledgeAPI, M as AiKnowledgeAction, N as AiKnowledgeCatalog, O as AiKnowledgePassage, P as AiKnowledgeState, S as AiModelFit, V as AiModelInstallHandle, Z as AiProviderInfo, $ as AiResult, a0 as AiReviewMode, a1 as AiSearchHit, a2 as AiSearchQuery, a3 as AiSearchResult, a4 as AiSpeechAudio, a6 as AiSynthesizeRequest, a7 as AiTranscribeRequest, a8 as AiTranscript, a9 as AiUnavailableReason, ab as DocBlocksHostAiAPI, ac as DocBlocksHostClipboardAPI, ad as DocBlocksHostExportAPI, ae as DocBlocksHostExternalAPI, af as DocBlocksHostFfmpegAPI, ag as DocBlocksHostFsAPI, ah as DocBlocksHostGitAPI, ai as DocBlocksHostLifecycleAPI, aj as DocBlocksHostMenuAPI, ak as DocBlocksHostShellAPI, al as DocBlocksHostSpeechAPI, am as DocBlocksHostUpdaterAPI, an as DocBlocksHostWorkspacesAPI, ao as ElectronWorkspaceInfo, ap as ExternalBinaryCommitResult, aq as GitBranchInfo, ar as GitCapabilities, as as GitCloneHandle, at as GitCloneProgress, au as GitError, av as GitErrorCode, aw as GitFileAtRevision, ax as GitFileChange, ay as GitFileStatusCode, az as GitLogEntry, aA as GitLogOptions, aB as GitRemoteInfo, aC as GitRepoDetection, aD as GitResult, aE as GitRevision, aF as GitStatus, aG as HOST_PLATFORMS, aH as HOST_SURFACE_KINDS, aJ as HostCloseReason, aL as HostExportTargetGrant, aN as HostPlatform, aO as HostPrepareCloseRequest, aP as HostPrepareCloseResult, aQ as HostSurfaceKind, aR as MenuCommand, aS as NO_HOST_CAPABILITIES, aX as SpeechErrorCode, aZ as SpeechInstallHandle, b4 as SpeechReadinessState, b6 as SpeechSegment, b8 as SpeechSynthesisHandle, bf as SpeechWord, bg as SpeechWordTiming, bh as UpdateCheckResult, bi as UpdateInstallResult, bj as UpdaterStatus, bk as deriveHostCapabilities, bl as isAiImageAspect, bm as isAiImageModelId, bn as knowledgeChatEvent, bo as knowledgeSources, bp as parseAiImageAccess, bq as parseAiImageEvent, br as parseAiImageInstallEvent, bs as parseAiImageModel, bt as parseAiImageModelList, bu as parseAiImagePreferences, bv as parseAiImagePreferencesPatch, bw as parseAiImageRequest, bx as parseAiImageResult, by as parseAiImageStyle, bz as parseAiImageStyleList, bA as parseAiKnowledgeAction, bB as parseAiKnowledgeState, bC as parseHostEnvironment } from '../capabilities-rfOUYj1Y.js';
|
|
3
3
|
export { D as DocBlocksHostFsV2API, E as ELECTRON_FILE_SYSTEM_V2_CAPABILITIES, F as FILE_SYSTEM_TRANSFER_LIMITS, H as HostFileSystemReadTransfer, a as HostFileSystemV2OpenRequest, b as HostFileSystemV2Result, c as HostFileSystemV2WatchMessage } from '../filesystem-v2-CYPHqoIw.js';
|
|
4
4
|
import '../types-BIaQ_gYW.js';
|
|
5
5
|
import '../v2-pBdrFAlW.js';
|
|
@@ -46,11 +46,15 @@ declare const AI_WIRE_LIMITS: Readonly<{
|
|
|
46
46
|
factCheckSentenceCharacters: 1000;
|
|
47
47
|
factCheckDetails: 16;
|
|
48
48
|
modelEntries: 200;
|
|
49
|
+
/** docbench families per model; the v1 pack has six. */
|
|
50
|
+
docbenchFamilies: 16;
|
|
49
51
|
contextWindowCeiling: 8000000;
|
|
50
52
|
downloadBytesCeiling: number;
|
|
51
53
|
}>;
|
|
52
54
|
declare function parseAiError(value: unknown): AiError | null;
|
|
53
55
|
declare function parseAiProgress(value: unknown): AiProgress | null;
|
|
56
|
+
/** A measured docbench result: bounded scores, a positive band, and a version. */
|
|
57
|
+
declare function parseAiModelDocbench(value: unknown): AiModelDocbench | null;
|
|
54
58
|
declare function parseAiModelInfo(value: unknown): AiModelInfo | null;
|
|
55
59
|
declare function parseAiModelInfoList(value: unknown): AiModelInfo[] | null;
|
|
56
60
|
declare function parseAiModelDownloadInfo(value: unknown): AiModelDownloadInfo | null;
|
|
@@ -174,6 +178,109 @@ declare function parseOpenExternalUrl(value: unknown): string | null;
|
|
|
174
178
|
/** True only for the packaged renderer origin or the exact configured dev origin. */
|
|
175
179
|
declare function isTrustedRendererUrl(value: unknown, developmentOrigin?: string): boolean;
|
|
176
180
|
|
|
181
|
+
/**
|
|
182
|
+
* The OpenAI-compatible chat body DocBlocks sends for one {@link AiChatRequest}.
|
|
183
|
+
*
|
|
184
|
+
* The desktop host sends it to Gezel, and the docbench task pack sends it to
|
|
185
|
+
* the model under test, so a benchmark measures exactly the request a person's
|
|
186
|
+
* editor makes. The rules here are product policy, each evaluated against real
|
|
187
|
+
* models before it was adopted:
|
|
188
|
+
*
|
|
189
|
+
* - Only `write` may reason. Every other purpose sends `reasoning_effort:
|
|
190
|
+
* 'none'`: a thinking model asked for a quiz or a review spent its whole
|
|
191
|
+
* explicit cap reasoning and returned no JSON.
|
|
192
|
+
* - A local writing request without its own cap may use the whole context
|
|
193
|
+
* window, so a long draft is not cut short by an engine default.
|
|
194
|
+
* - Structured output is asked for only when the caller gave a schema.
|
|
195
|
+
*
|
|
196
|
+
* Streaming options and knowledge passages are the transport's business, not
|
|
197
|
+
* the body's; callers add them.
|
|
198
|
+
*/
|
|
199
|
+
|
|
200
|
+
/** A chat message as DocBlocks writes one; a transport may carry a wider message type. */
|
|
201
|
+
interface ChatCompletionMessage {
|
|
202
|
+
readonly role: 'system' | 'user' | 'assistant';
|
|
203
|
+
readonly content: string;
|
|
204
|
+
}
|
|
205
|
+
interface ChatCompletionBodyInput<Message = ChatCompletionMessage> {
|
|
206
|
+
/** Qualified provider model id, such as `llama-cpp:gemma4-e4b-q4`. */
|
|
207
|
+
readonly model: string;
|
|
208
|
+
/** Sent as given: the body copies the list, never the messages. */
|
|
209
|
+
readonly messages: readonly Message[];
|
|
210
|
+
readonly purpose?: AiChatPurpose;
|
|
211
|
+
readonly temperature?: number;
|
|
212
|
+
readonly maxTokens?: number;
|
|
213
|
+
readonly responseFormat?: AiResponseFormat;
|
|
214
|
+
/** The model's context window, used as a local writing request's default cap. */
|
|
215
|
+
readonly contextWindow?: number | null;
|
|
216
|
+
}
|
|
217
|
+
interface ChatCompletionBodyOptions {
|
|
218
|
+
/**
|
|
219
|
+
* A sampling seed. The product never sends one; a benchmark does, so a
|
|
220
|
+
* repeated trial is a different sample and a re-run is the same one.
|
|
221
|
+
*/
|
|
222
|
+
readonly seed?: number;
|
|
223
|
+
}
|
|
224
|
+
interface ChatCompletionBody<Message = ChatCompletionMessage> {
|
|
225
|
+
model: string;
|
|
226
|
+
messages: Message[];
|
|
227
|
+
reasoning_effort?: 'none';
|
|
228
|
+
temperature?: number;
|
|
229
|
+
max_tokens?: number;
|
|
230
|
+
seed?: number;
|
|
231
|
+
response_format?: {
|
|
232
|
+
type: 'json_schema';
|
|
233
|
+
json_schema: {
|
|
234
|
+
name: string;
|
|
235
|
+
schema: Record<string, unknown>;
|
|
236
|
+
strict: true;
|
|
237
|
+
};
|
|
238
|
+
};
|
|
239
|
+
}
|
|
240
|
+
/** Whether a qualified model id names an on-device engine. */
|
|
241
|
+
declare function isLocalEngineModel(model: string): boolean;
|
|
242
|
+
/** The request body for `request`, without streaming options. */
|
|
243
|
+
declare function buildChatCompletionBody<Message = ChatCompletionMessage>(request: ChatCompletionBodyInput<Message>, options?: ChatCompletionBodyOptions): ChatCompletionBody<Message>;
|
|
244
|
+
|
|
245
|
+
/**
|
|
246
|
+
* Reading Gezel's model ratings into the AI wire types.
|
|
247
|
+
*
|
|
248
|
+
* Every host that lists Gezel models for Settings (the desktop connector, the
|
|
249
|
+
* mobile host) reads the same three things from each entry: Gezel's general
|
|
250
|
+
* `recommendation`, its `docbench_recommendation` (the same question ranked
|
|
251
|
+
* by measured quality on DocBlocks' own work), and the `docbench` result.
|
|
252
|
+
* They read them here, so the two surfaces cannot disagree about which
|
|
253
|
+
* ranking wins or what a malformed field becomes.
|
|
254
|
+
*/
|
|
255
|
+
|
|
256
|
+
/** How a provider rates one model for this device. */
|
|
257
|
+
interface ProviderModelRanking {
|
|
258
|
+
/** 0–100, or null when the provider sent no usable rating. */
|
|
259
|
+
readonly score: number | null;
|
|
260
|
+
readonly recommended: boolean;
|
|
261
|
+
}
|
|
262
|
+
/** The rating fields a Gezel model entry may carry; unknown until read. */
|
|
263
|
+
interface ProviderModelRatings {
|
|
264
|
+
readonly recommendation?: unknown;
|
|
265
|
+
readonly docbench_recommendation?: unknown;
|
|
266
|
+
readonly docbench?: unknown;
|
|
267
|
+
}
|
|
268
|
+
/**
|
|
269
|
+
* Gezel's rating of a model for this device. The docbench ranking wins when
|
|
270
|
+
* Gezel sent one (it does once anything in the catalog is measured): the
|
|
271
|
+
* general ranking weighs the curated agent-work score, and DocBlocks never
|
|
272
|
+
* runs an agent.
|
|
273
|
+
*/
|
|
274
|
+
declare function providerModelRanking(entry: ProviderModelRatings): ProviderModelRanking;
|
|
275
|
+
/**
|
|
276
|
+
* The model's docbench result, bounded as it must be to cross the host
|
|
277
|
+
* boundary; undefined when absent or malformed. A result without family
|
|
278
|
+
* scores still reads, with none.
|
|
279
|
+
*/
|
|
280
|
+
declare function providerModelDocbench(entry: ProviderModelRatings): AiModelDocbench | undefined;
|
|
281
|
+
/** Best match first: the recommendation, then by score. Unrated entries keep the provider's order. */
|
|
282
|
+
declare function sortModelDownloads<T extends Pick<AiModelDownloadInfo, 'recommended' | 'score'>>(models: readonly T[]): T[];
|
|
283
|
+
|
|
177
284
|
/**
|
|
178
285
|
* Host bridge — shared types + runtime access for the Electron desktop
|
|
179
286
|
* host. The renderer calls `getDocBlocksHost()` to reach the preload
|
|
@@ -202,4 +309,4 @@ declare function getDocBlocksHost(): DocBlocksHostAPI;
|
|
|
202
309
|
/** Return the host API, or null if not running under Electron. */
|
|
203
310
|
declare function maybeGetDocBlocksHost(): DocBlocksHostAPI | null;
|
|
204
311
|
|
|
205
|
-
export { AI_WIRE_LIMITS, AiChatEvent, AiChatKnowledge, AiChatProgress, AiChatRequest, AiError, AiFactCheck, AiFactCheckRequest, AiModelDownloadInfo, AiModelInfo, AiModelInstallEvent, AiPreferences, AiPreferencesPatch, AiProgress, AiStatus, DocBlocksHostAPI, EXPORT_TRANSFER_LIMITS, HOST_WIRE_LIMITS, HostCapabilities, HostEnvironment, HostPinnedDocument, MAX_HOST_PINNED_DOCUMENTS, OpenRequest, SPEECH_WIRE_LIMITS, SUPPORT_EMAIL_ADDRESS, SpeechAudioChunk, SpeechCatalog, SpeechError, SpeechInstallEvent, SpeechModelInfo, SpeechModelKind, SpeechPreferences, SpeechPreferencesPatch, SpeechProgress, SpeechReadiness, SpeechResult, SpeechStatus, SpeechSynthesisSummary, SpeechSynthesizeEvent, SpeechSynthesizeRequest, SpeechTranscribeRequest, SpeechTranscript, SpeechVoiceInfo, getDocBlocksHost, getHostCapabilities, getHostEnvironment, hasDocBlocksHost, hostSupports, isBoundedBytePayload, isBoundedString, isElectronHost, isSpeechModelId, isTrustedRendererUrl, maybeGetDocBlocksHost, parseAiChatEvent, parseAiChatKnowledge, parseAiChatProgress, parseAiChatRequest, parseAiError, parseAiFactCheck, parseAiFactCheckRequest, parseAiModelDownloadInfo, parseAiModelDownloadInfoList, parseAiModelInfo, parseAiModelInfoList, parseAiModelInstallEvent, parseAiPreferences, parseAiPreferencesPatch, parseAiProgress, parseAiStatus, parseExternalHttpUrl, parseOpenExternalUrl, parseOpenRequest, parsePinnedMenuDocuments, parseSpeechAudioChunk, parseSpeechCatalog, parseSpeechError, parseSpeechInstallEvent, parseSpeechModelInfo, parseSpeechModelKind, parseSpeechNullResult, parseSpeechPreferences, parseSpeechPreferencesPatch, parseSpeechProgress, parseSpeechReadiness, parseSpeechResult, parseSpeechStatus, parseSpeechSynthesisSummary, parseSpeechSynthesizeEvent, parseSpeechSynthesizeRequest, parseSpeechTranscribeRequest, parseSpeechTranscript, parseSpeechVoiceInfo, parseSupportMailtoUrl };
|
|
312
|
+
export { AI_WIRE_LIMITS, AiChatEvent, AiChatKnowledge, AiChatProgress, AiChatPurpose, AiChatRequest, AiError, AiFactCheck, AiFactCheckRequest, AiModelDocbench, AiModelDownloadInfo, AiModelInfo, AiModelInstallEvent, AiPreferences, AiPreferencesPatch, AiProgress, AiResponseFormat, AiStatus, type ChatCompletionBody, type ChatCompletionBodyInput, type ChatCompletionBodyOptions, type ChatCompletionMessage, DocBlocksHostAPI, EXPORT_TRANSFER_LIMITS, HOST_WIRE_LIMITS, HostCapabilities, HostEnvironment, HostPinnedDocument, MAX_HOST_PINNED_DOCUMENTS, OpenRequest, type ProviderModelRanking, type ProviderModelRatings, SPEECH_WIRE_LIMITS, SUPPORT_EMAIL_ADDRESS, SpeechAudioChunk, SpeechCatalog, SpeechError, SpeechInstallEvent, SpeechModelInfo, SpeechModelKind, SpeechPreferences, SpeechPreferencesPatch, SpeechProgress, SpeechReadiness, SpeechResult, SpeechStatus, SpeechSynthesisSummary, SpeechSynthesizeEvent, SpeechSynthesizeRequest, SpeechTranscribeRequest, SpeechTranscript, SpeechVoiceInfo, buildChatCompletionBody, getDocBlocksHost, getHostCapabilities, getHostEnvironment, hasDocBlocksHost, hostSupports, isBoundedBytePayload, isBoundedString, isElectronHost, isLocalEngineModel, isSpeechModelId, isTrustedRendererUrl, maybeGetDocBlocksHost, parseAiChatEvent, parseAiChatKnowledge, parseAiChatProgress, parseAiChatRequest, parseAiError, parseAiFactCheck, parseAiFactCheckRequest, parseAiModelDocbench, parseAiModelDownloadInfo, parseAiModelDownloadInfoList, parseAiModelInfo, parseAiModelInfoList, parseAiModelInstallEvent, parseAiPreferences, parseAiPreferencesPatch, parseAiProgress, parseAiStatus, parseExternalHttpUrl, parseOpenExternalUrl, parseOpenRequest, parsePinnedMenuDocuments, parseSpeechAudioChunk, parseSpeechCatalog, parseSpeechError, parseSpeechInstallEvent, parseSpeechModelInfo, parseSpeechModelKind, parseSpeechNullResult, parseSpeechPreferences, parseSpeechPreferencesPatch, parseSpeechProgress, parseSpeechReadiness, parseSpeechResult, parseSpeechStatus, parseSpeechSynthesisSummary, parseSpeechSynthesizeEvent, parseSpeechSynthesizeRequest, parseSpeechTranscribeRequest, parseSpeechTranscript, parseSpeechVoiceInfo, parseSupportMailtoUrl, providerModelDocbench, providerModelRanking, sortModelDownloads };
|
package/dist/host/index.js
CHANGED
|
@@ -9,6 +9,7 @@ import {
|
|
|
9
9
|
HOST_SURFACE_KINDS,
|
|
10
10
|
NO_HOST_CAPABILITIES,
|
|
11
11
|
SPEECH_WIRE_LIMITS,
|
|
12
|
+
buildChatCompletionBody,
|
|
12
13
|
deriveHostCapabilities,
|
|
13
14
|
getDocBlocksHost,
|
|
14
15
|
getHostCapabilities,
|
|
@@ -18,6 +19,7 @@ import {
|
|
|
18
19
|
isAiImageAspect,
|
|
19
20
|
isAiImageModelId,
|
|
20
21
|
isElectronHost,
|
|
22
|
+
isLocalEngineModel,
|
|
21
23
|
isSpeechModelId,
|
|
22
24
|
knowledgeChatEvent,
|
|
23
25
|
knowledgeSources,
|
|
@@ -42,6 +44,7 @@ import {
|
|
|
42
44
|
parseAiImageStyleList,
|
|
43
45
|
parseAiKnowledgeAction,
|
|
44
46
|
parseAiKnowledgeState,
|
|
47
|
+
parseAiModelDocbench,
|
|
45
48
|
parseAiModelDownloadInfo,
|
|
46
49
|
parseAiModelDownloadInfoList,
|
|
47
50
|
parseAiModelInfo,
|
|
@@ -70,8 +73,11 @@ import {
|
|
|
70
73
|
parseSpeechSynthesizeRequest,
|
|
71
74
|
parseSpeechTranscribeRequest,
|
|
72
75
|
parseSpeechTranscript,
|
|
73
|
-
parseSpeechVoiceInfo
|
|
74
|
-
|
|
76
|
+
parseSpeechVoiceInfo,
|
|
77
|
+
providerModelDocbench,
|
|
78
|
+
providerModelRanking,
|
|
79
|
+
sortModelDownloads
|
|
80
|
+
} from "../chunk-OXEMTJRJ.js";
|
|
75
81
|
import {
|
|
76
82
|
EXPORT_TRANSFER_LIMITS,
|
|
77
83
|
HOST_WIRE_LIMITS,
|
|
@@ -101,6 +107,7 @@ export {
|
|
|
101
107
|
NO_HOST_CAPABILITIES,
|
|
102
108
|
SPEECH_WIRE_LIMITS,
|
|
103
109
|
SUPPORT_EMAIL_ADDRESS,
|
|
110
|
+
buildChatCompletionBody,
|
|
104
111
|
deriveHostCapabilities,
|
|
105
112
|
getDocBlocksHost,
|
|
106
113
|
getHostCapabilities,
|
|
@@ -112,6 +119,7 @@ export {
|
|
|
112
119
|
isBoundedBytePayload,
|
|
113
120
|
isBoundedString,
|
|
114
121
|
isElectronHost,
|
|
122
|
+
isLocalEngineModel,
|
|
115
123
|
isSpeechModelId,
|
|
116
124
|
isTrustedRendererUrl,
|
|
117
125
|
knowledgeChatEvent,
|
|
@@ -137,6 +145,7 @@ export {
|
|
|
137
145
|
parseAiImageStyleList,
|
|
138
146
|
parseAiKnowledgeAction,
|
|
139
147
|
parseAiKnowledgeState,
|
|
148
|
+
parseAiModelDocbench,
|
|
140
149
|
parseAiModelDownloadInfo,
|
|
141
150
|
parseAiModelDownloadInfoList,
|
|
142
151
|
parseAiModelInfo,
|
|
@@ -170,5 +179,8 @@ export {
|
|
|
170
179
|
parseSpeechTranscribeRequest,
|
|
171
180
|
parseSpeechTranscript,
|
|
172
181
|
parseSpeechVoiceInfo,
|
|
173
|
-
parseSupportMailtoUrl
|
|
182
|
+
parseSupportMailtoUrl,
|
|
183
|
+
providerModelDocbench,
|
|
184
|
+
providerModelRanking,
|
|
185
|
+
sortModelDownloads
|
|
174
186
|
};
|
package/dist/index.d.ts
CHANGED
|
@@ -7,10 +7,10 @@ export { IndexedDBContentContainer, IndexedDBFileSystemProvider, IndexedDBFileSy
|
|
|
7
7
|
export { NativeFileSystemMovePathState, NativeFileSystemMoveRecoveryError, NativeFileSystemMoveRecoveryState, NativeFileSystemProvider, NativeFileSystemProviderV2, isNativeFileSystemSupported, loadDirectoryHandle, openNativeFolder, removeDirectoryHandle, restoreNativeFolder, storeDirectoryHandle } from './filesystem/native.js';
|
|
8
8
|
export { ElectronFileSystemProvider, ElectronFileSystemProviderV2 } from './filesystem/electron.js';
|
|
9
9
|
export { DOCUMENT_RECOVERY_JOURNAL_SCHEMA_VERSION, DOCUMENT_RECOVERY_JOURNAL_STORAGE_KEY, DocumentCommitConflictError, DocumentCommitRequest, DocumentCommitResult, DocumentCommitTarget, DocumentConflictStrategy, DocumentExternalChangeResult, DocumentExternalSnapshot, DocumentExternalVersion, DocumentRecoveryAcknowledgement, DocumentRecoveryJournal, DocumentRecoveryJournalOptions, DocumentRecoveryRecord, DocumentRecoveryStorage, DocumentRecoveryWrite, DocumentRecoveryWriteFailure, DocumentRecoveryWriteResult, DocumentSaveReason, DocumentSession, DocumentSessionConflict, DocumentSessionConflictError, DocumentSessionEditScope, DocumentSessionLifecycle, DocumentSessionOptions, DocumentSessionSnapshot, DocumentSessionStatus, DocumentSessionTransition, FileSystemDocumentTargetOptions, createFileSystemDocumentTarget, getDefaultDocumentRecoveryStorage } from './document/index.js';
|
|
10
|
-
export { D as DEFAULT_WORKSPACE_ID, E as ElectronWorkspaceReconciliation, T as TransientOrigin, W as WorkspaceDescriptor, e as ensureDefaultWorkspace, g as getTransientWorkspace, a as getWorkspace, l as listWorkspaces, p as parsePersistedWorkspaceList, r as reconcileElectronWorkspaceDescriptors, b as registerTransientWorkspace, c as removeWorkspace, s as saveWorkspace, t as touchWorkspace, u as unregisterTransientWorkspace } from './reconcile-electron-
|
|
11
|
-
export { AI_WIRE_LIMITS, EXPORT_TRANSFER_LIMITS, HOST_WIRE_LIMITS, MAX_HOST_PINNED_DOCUMENTS, SPEECH_WIRE_LIMITS, SUPPORT_EMAIL_ADDRESS, getDocBlocksHost, getHostCapabilities, getHostEnvironment, hasDocBlocksHost, hostSupports, isBoundedBytePayload, isBoundedString, isElectronHost, isSpeechModelId, isTrustedRendererUrl, maybeGetDocBlocksHost, parseAiChatEvent, parseAiChatKnowledge, parseAiChatProgress, parseAiChatRequest, parseAiError, parseAiFactCheck, parseAiFactCheckRequest, parseAiModelDownloadInfo, parseAiModelDownloadInfoList, parseAiModelInfo, parseAiModelInfoList, parseAiModelInstallEvent, parseAiPreferences, parseAiPreferencesPatch, parseAiProgress, parseAiStatus, parseExternalHttpUrl, parseOpenExternalUrl, parseOpenRequest, parsePinnedMenuDocuments, parseSpeechAudioChunk, parseSpeechCatalog, parseSpeechError, parseSpeechInstallEvent, parseSpeechModelInfo, parseSpeechModelKind, parseSpeechNullResult, parseSpeechPreferences, parseSpeechPreferencesPatch, parseSpeechProgress, parseSpeechReadiness, parseSpeechResult, parseSpeechStatus, parseSpeechSynthesisSummary, parseSpeechSynthesizeEvent, parseSpeechSynthesizeRequest, parseSpeechTranscribeRequest, parseSpeechTranscript, parseSpeechVoiceInfo, parseSupportMailtoUrl } from './host/index.js';
|
|
10
|
+
export { D as DEFAULT_WORKSPACE_ID, E as ElectronWorkspaceReconciliation, T as TransientOrigin, W as WorkspaceDescriptor, e as ensureDefaultWorkspace, g as getTransientWorkspace, a as getWorkspace, l as listWorkspaces, p as parsePersistedWorkspaceList, r as reconcileElectronWorkspaceDescriptors, b as registerTransientWorkspace, c as removeWorkspace, s as saveWorkspace, t as touchWorkspace, u as unregisterTransientWorkspace } from './reconcile-electron-DtP-HC39.js';
|
|
11
|
+
export { AI_WIRE_LIMITS, ChatCompletionBody, ChatCompletionBodyInput, ChatCompletionBodyOptions, ChatCompletionMessage, EXPORT_TRANSFER_LIMITS, HOST_WIRE_LIMITS, MAX_HOST_PINNED_DOCUMENTS, ProviderModelRanking, ProviderModelRatings, SPEECH_WIRE_LIMITS, SUPPORT_EMAIL_ADDRESS, buildChatCompletionBody, getDocBlocksHost, getHostCapabilities, getHostEnvironment, hasDocBlocksHost, hostSupports, isBoundedBytePayload, isBoundedString, isElectronHost, isLocalEngineModel, isSpeechModelId, isTrustedRendererUrl, maybeGetDocBlocksHost, parseAiChatEvent, parseAiChatKnowledge, parseAiChatProgress, parseAiChatRequest, parseAiError, parseAiFactCheck, parseAiFactCheckRequest, parseAiModelDocbench, parseAiModelDownloadInfo, parseAiModelDownloadInfoList, parseAiModelInfo, parseAiModelInfoList, parseAiModelInstallEvent, parseAiPreferences, parseAiPreferencesPatch, parseAiProgress, parseAiStatus, parseExternalHttpUrl, parseOpenExternalUrl, parseOpenRequest, parsePinnedMenuDocuments, parseSpeechAudioChunk, parseSpeechCatalog, parseSpeechError, parseSpeechInstallEvent, parseSpeechModelInfo, parseSpeechModelKind, parseSpeechNullResult, parseSpeechPreferences, parseSpeechPreferencesPatch, parseSpeechProgress, parseSpeechReadiness, parseSpeechResult, parseSpeechStatus, parseSpeechSynthesisSummary, parseSpeechSynthesizeEvent, parseSpeechSynthesizeRequest, parseSpeechTranscribeRequest, parseSpeechTranscript, parseSpeechVoiceInfo, parseSupportMailtoUrl, providerModelDocbench, providerModelRanking, sortModelDownloads } from './host/index.js';
|
|
12
12
|
export { SHARED_DOCUMENT_LIMITS, SharedDocumentHashParseResult, SharedDocumentMode, SharedDocumentPayload, createSharedDocumentHash, createSharedDocumentUrl, parseSharedDocumentHash } from './share/index.js';
|
|
13
|
-
export { A as AI_IMAGE_ASPECTS, a as AI_IMAGE_FIT_VERDICTS, b as AI_IMAGE_WIRE_LIMITS, c as AiChatCompletion, d as AiChatEvent, e as AiChatEvidence, f as AiChatHandle, g as AiChatKnowledge, h as AiChatKnowledgeSource, i as AiChatMessage, j as AiChatProgress, k as AiChatPurpose, l as AiChatRequest, m as AiConnectionStep, n as AiEnsureWorkspaceHandle, o as AiError, p as AiErrorCode, q as AiFactCheck, r as AiFactCheckRequest, s as AiFactCheckSentence, t as AiImageAccess, u as AiImageAspect, v as AiImageEvent, w as AiImageHandle, x as AiImageInstallEvent, y as AiImageInstallHandle, z as AiImageModel, B as AiImageModelFit, C as AiImagePhase, D as AiImagePreferences, E as AiImagePreferencesPatch, F as AiImageProgress, G as AiImageRequest, H as AiImageResult, I as AiImageStyle, J as AiImageUnavailableReason, K as AiImagesAPI, L as AiKnowledgeAPI, M as AiKnowledgeAction, N as AiKnowledgeCatalog, O as AiKnowledgePassage, P as AiKnowledgeState, Q as
|
|
13
|
+
export { A as AI_IMAGE_ASPECTS, a as AI_IMAGE_FIT_VERDICTS, b as AI_IMAGE_WIRE_LIMITS, c as AiChatCompletion, d as AiChatEvent, e as AiChatEvidence, f as AiChatHandle, g as AiChatKnowledge, h as AiChatKnowledgeSource, i as AiChatMessage, j as AiChatProgress, k as AiChatPurpose, l as AiChatRequest, m as AiConnectionStep, n as AiEnsureWorkspaceHandle, o as AiError, p as AiErrorCode, q as AiFactCheck, r as AiFactCheckRequest, s as AiFactCheckSentence, t as AiImageAccess, u as AiImageAspect, v as AiImageEvent, w as AiImageHandle, x as AiImageInstallEvent, y as AiImageInstallHandle, z as AiImageModel, B as AiImageModelFit, C as AiImagePhase, D as AiImagePreferences, E as AiImagePreferencesPatch, F as AiImageProgress, G as AiImageRequest, H as AiImageResult, I as AiImageStyle, J as AiImageUnavailableReason, K as AiImagesAPI, L as AiKnowledgeAPI, M as AiKnowledgeAction, N as AiKnowledgeCatalog, O as AiKnowledgePassage, P as AiKnowledgeState, Q as AiModelDocbench, R as AiModelDownloadInfo, S as AiModelFit, T as AiModelInfo, U as AiModelInstallEvent, V as AiModelInstallHandle, W as AiPreferences, X as AiPreferencesPatch, Y as AiProgress, Z as AiProviderInfo, _ as AiResponseFormat, $ as AiResult, a0 as AiReviewMode, a1 as AiSearchHit, a2 as AiSearchQuery, a3 as AiSearchResult, a4 as AiSpeechAudio, a5 as AiStatus, a6 as AiSynthesizeRequest, a7 as AiTranscribeRequest, a8 as AiTranscript, a9 as AiUnavailableReason, aa as DocBlocksHostAPI, ab as DocBlocksHostAiAPI, ac as DocBlocksHostClipboardAPI, ad as DocBlocksHostExportAPI, ae as DocBlocksHostExternalAPI, af as DocBlocksHostFfmpegAPI, ag as DocBlocksHostFsAPI, ah as DocBlocksHostGitAPI, ai as DocBlocksHostLifecycleAPI, aj as DocBlocksHostMenuAPI, ak as DocBlocksHostShellAPI, al as DocBlocksHostSpeechAPI, am as DocBlocksHostUpdaterAPI, an as DocBlocksHostWorkspacesAPI, ao as ElectronWorkspaceInfo, ap as ExternalBinaryCommitResult, aq as GitBranchInfo, ar as GitCapabilities, as as GitCloneHandle, at as GitCloneProgress, au as GitError, av as GitErrorCode, aw as GitFileAtRevision, ax as GitFileChange, ay as GitFileStatusCode, az as GitLogEntry, aA as GitLogOptions, aB as GitRemoteInfo, aC as GitRepoDetection, aD as GitResult, aE as GitRevision, aF as GitStatus, aG as HOST_PLATFORMS, aH as HOST_SURFACE_KINDS, aI as HostCapabilities, aJ as HostCloseReason, aK as HostEnvironment, aL as HostExportTargetGrant, aM as HostPinnedDocument, aN as HostPlatform, aO as HostPrepareCloseRequest, aP as HostPrepareCloseResult, aQ as HostSurfaceKind, aR as MenuCommand, aS as NO_HOST_CAPABILITIES, aT as OpenRequest, aU as SpeechAudioChunk, aV as SpeechCatalog, aW as SpeechError, aX as SpeechErrorCode, aY as SpeechInstallEvent, aZ as SpeechInstallHandle, a_ as SpeechModelInfo, a$ as SpeechModelKind, b0 as SpeechPreferences, b1 as SpeechPreferencesPatch, b2 as SpeechProgress, b3 as SpeechReadiness, b4 as SpeechReadinessState, b5 as SpeechResult, b6 as SpeechSegment, b7 as SpeechStatus, b8 as SpeechSynthesisHandle, b9 as SpeechSynthesisSummary, ba as SpeechSynthesizeEvent, bb as SpeechSynthesizeRequest, bc as SpeechTranscribeRequest, bd as SpeechTranscript, be as SpeechVoiceInfo, bf as SpeechWord, bg as SpeechWordTiming, bh as UpdateCheckResult, bi as UpdateInstallResult, bj as UpdaterStatus, bk as deriveHostCapabilities, bl as isAiImageAspect, bm as isAiImageModelId, bn as knowledgeChatEvent, bo as knowledgeSources, bp as parseAiImageAccess, bq as parseAiImageEvent, br as parseAiImageInstallEvent, bs as parseAiImageModel, bt as parseAiImageModelList, bu as parseAiImagePreferences, bv as parseAiImagePreferencesPatch, bw as parseAiImageRequest, bx as parseAiImageResult, by as parseAiImageStyle, bz as parseAiImageStyleList, bA as parseAiKnowledgeAction, bB as parseAiKnowledgeState, bC as parseHostEnvironment } from './capabilities-rfOUYj1Y.js';
|
|
14
14
|
export { D as DocBlocksHostFsV2API, E as ELECTRON_FILE_SYSTEM_V2_CAPABILITIES, F as FILE_SYSTEM_TRANSFER_LIMITS, H as HostFileSystemReadTransfer, a as HostFileSystemV2OpenRequest, b as HostFileSystemV2Result, c as HostFileSystemV2WatchMessage } from './filesystem-v2-CYPHqoIw.js';
|
|
15
15
|
import '@bendyline/squisq/markdown';
|
|
16
16
|
import '@bendyline/squisq/storage';
|
package/dist/index.js
CHANGED
|
@@ -70,8 +70,8 @@ import "./chunk-3GSMJ4MQ.js";
|
|
|
70
70
|
import {
|
|
71
71
|
ElectronFileSystemProvider,
|
|
72
72
|
ElectronFileSystemProviderV2
|
|
73
|
-
} from "./chunk-
|
|
74
|
-
import "./chunk-
|
|
73
|
+
} from "./chunk-XC7766WT.js";
|
|
74
|
+
import "./chunk-WIC3ASFS.js";
|
|
75
75
|
import {
|
|
76
76
|
AI_IMAGE_ASPECTS,
|
|
77
77
|
AI_IMAGE_FIT_VERDICTS,
|
|
@@ -83,6 +83,7 @@ import {
|
|
|
83
83
|
HOST_SURFACE_KINDS,
|
|
84
84
|
NO_HOST_CAPABILITIES,
|
|
85
85
|
SPEECH_WIRE_LIMITS,
|
|
86
|
+
buildChatCompletionBody,
|
|
86
87
|
deriveHostCapabilities,
|
|
87
88
|
getDocBlocksHost,
|
|
88
89
|
getHostCapabilities,
|
|
@@ -92,6 +93,7 @@ import {
|
|
|
92
93
|
isAiImageAspect,
|
|
93
94
|
isAiImageModelId,
|
|
94
95
|
isElectronHost,
|
|
96
|
+
isLocalEngineModel,
|
|
95
97
|
isSpeechModelId,
|
|
96
98
|
knowledgeChatEvent,
|
|
97
99
|
knowledgeSources,
|
|
@@ -116,6 +118,7 @@ import {
|
|
|
116
118
|
parseAiImageStyleList,
|
|
117
119
|
parseAiKnowledgeAction,
|
|
118
120
|
parseAiKnowledgeState,
|
|
121
|
+
parseAiModelDocbench,
|
|
119
122
|
parseAiModelDownloadInfo,
|
|
120
123
|
parseAiModelDownloadInfoList,
|
|
121
124
|
parseAiModelInfo,
|
|
@@ -144,8 +147,11 @@ import {
|
|
|
144
147
|
parseSpeechSynthesizeRequest,
|
|
145
148
|
parseSpeechTranscribeRequest,
|
|
146
149
|
parseSpeechTranscript,
|
|
147
|
-
parseSpeechVoiceInfo
|
|
148
|
-
|
|
150
|
+
parseSpeechVoiceInfo,
|
|
151
|
+
providerModelDocbench,
|
|
152
|
+
providerModelRanking,
|
|
153
|
+
sortModelDownloads
|
|
154
|
+
} from "./chunk-OXEMTJRJ.js";
|
|
149
155
|
import "./chunk-245W57QP.js";
|
|
150
156
|
import {
|
|
151
157
|
EXPORT_TRANSFER_LIMITS,
|
|
@@ -252,6 +258,7 @@ export {
|
|
|
252
258
|
SQUISQ_RUNTIME_DIRECTORY_NAME,
|
|
253
259
|
SUPPORT_EMAIL_ADDRESS,
|
|
254
260
|
WORKSPACE_ROOT,
|
|
261
|
+
buildChatCompletionBody,
|
|
255
262
|
createDbkWorkspaceSnapshot,
|
|
256
263
|
createFileMediaProvider,
|
|
257
264
|
createFileSystemDocumentTarget,
|
|
@@ -290,6 +297,7 @@ export {
|
|
|
290
297
|
isFileSystemMoveStateError,
|
|
291
298
|
isFileSystemPartialMoveError,
|
|
292
299
|
isIgnoredWorkspaceEntryName,
|
|
300
|
+
isLocalEngineModel,
|
|
293
301
|
isMarkdownFileName,
|
|
294
302
|
isNativeFileSystemSupported,
|
|
295
303
|
isQuotaExceededError,
|
|
@@ -325,6 +333,7 @@ export {
|
|
|
325
333
|
parseAiImageStyleList,
|
|
326
334
|
parseAiKnowledgeAction,
|
|
327
335
|
parseAiKnowledgeState,
|
|
336
|
+
parseAiModelDocbench,
|
|
328
337
|
parseAiModelDownloadInfo,
|
|
329
338
|
parseAiModelDownloadInfoList,
|
|
330
339
|
parseAiModelInfo,
|
|
@@ -363,6 +372,8 @@ export {
|
|
|
363
372
|
parseSpeechVoiceInfo,
|
|
364
373
|
parseSupportMailtoUrl,
|
|
365
374
|
parseWorkspacePath,
|
|
375
|
+
providerModelDocbench,
|
|
376
|
+
providerModelRanking,
|
|
366
377
|
reconcileElectronWorkspaceDescriptors,
|
|
367
378
|
registerTransientWorkspace,
|
|
368
379
|
removeDirectoryHandle,
|
|
@@ -374,6 +385,7 @@ export {
|
|
|
374
385
|
rewriteCompanionReferences,
|
|
375
386
|
saveWorkspace,
|
|
376
387
|
serializeFsError,
|
|
388
|
+
sortModelDownloads,
|
|
377
389
|
storeDirectoryHandle,
|
|
378
390
|
suggestWikiArticles,
|
|
379
391
|
touchWorkspace,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { d as FileSystemProvider } from './types-BIaQ_gYW.js';
|
|
2
|
-
import {
|
|
2
|
+
import { ao as ElectronWorkspaceInfo, aK as HostEnvironment } from './capabilities-rfOUYj1Y.js';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* Origin of a transient workspace — records where its contents came from and
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
export { D as DEFAULT_WORKSPACE_ID, E as ElectronWorkspaceReconciliation, T as TransientOrigin, W as WorkspaceDescriptor, e as ensureDefaultWorkspace, g as getTransientWorkspace, a as getWorkspace, l as listWorkspaces, p as parsePersistedWorkspaceList, r as reconcileElectronWorkspaceDescriptors, b as registerTransientWorkspace, c as removeWorkspace, s as saveWorkspace, t as touchWorkspace, u as unregisterTransientWorkspace } from '../reconcile-electron-
|
|
1
|
+
export { D as DEFAULT_WORKSPACE_ID, E as ElectronWorkspaceReconciliation, T as TransientOrigin, W as WorkspaceDescriptor, e as ensureDefaultWorkspace, g as getTransientWorkspace, a as getWorkspace, l as listWorkspaces, p as parsePersistedWorkspaceList, r as reconcileElectronWorkspaceDescriptors, b as registerTransientWorkspace, c as removeWorkspace, s as saveWorkspace, t as touchWorkspace, u as unregisterTransientWorkspace } from '../reconcile-electron-DtP-HC39.js';
|
|
2
2
|
import { ContentContainer } from '@bendyline/squisq/storage';
|
|
3
3
|
import { o as FileSystemProviderV2 } from '../v2-pBdrFAlW.js';
|
|
4
4
|
import { a as WorkspacePath } from '../workspace-path-CWVrcuPL.js';
|
|
5
5
|
import '../types-BIaQ_gYW.js';
|
|
6
|
-
import '../capabilities-
|
|
6
|
+
import '../capabilities-rfOUYj1Y.js';
|
|
7
7
|
import '../filesystem-v2-CYPHqoIw.js';
|
|
8
8
|
|
|
9
9
|
declare const WORKSPACE_BACKUP_MANIFEST = "docblocks-backup.json";
|