cyt-indexer-sdk 0.2.7 → 0.3.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 +3 -1
- package/cyt-indexer-sdk.darwin-x64.node +0 -0
- package/cyt-indexer-sdk.linux-arm64-gnu.node +0 -0
- package/cyt-indexer-sdk.linux-x64-gnu.node +0 -0
- package/cyt-indexer-sdk.win32-arm64-msvc.node +0 -0
- package/cyt-indexer-sdk.win32-x64-msvc.node +0 -0
- package/dist/build.d.ts +10 -1
- package/dist/build.d.ts.map +1 -1
- package/dist/build.js +25 -15
- package/dist/build.js.map +1 -1
- package/dist/catalog-io.d.ts +7 -0
- package/dist/catalog-io.d.ts.map +1 -0
- package/dist/catalog-io.js +7 -0
- package/dist/catalog-io.js.map +1 -0
- package/dist/decomposed-catalog.d.ts +4 -13
- package/dist/decomposed-catalog.d.ts.map +1 -1
- package/dist/decomposed-catalog.js +3 -60
- package/dist/decomposed-catalog.js.map +1 -1
- package/dist/documents.d.ts +7 -0
- package/dist/documents.d.ts.map +1 -0
- package/dist/documents.js +15 -0
- package/dist/documents.js.map +1 -0
- package/dist/index.d.ts +8 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +9 -2
- package/dist/index.js.map +1 -1
- package/dist/native.d.ts +77 -1
- package/dist/native.d.ts.map +1 -1
- package/dist/native.js +83 -0
- package/dist/native.js.map +1 -1
- package/dist/paths.d.ts +18 -1
- package/dist/paths.d.ts.map +1 -1
- package/dist/paths.js +26 -1
- package/dist/paths.js.map +1 -1
- package/dist/policies.d.ts +57 -0
- package/dist/policies.d.ts.map +1 -0
- package/dist/policies.js +153 -0
- package/dist/policies.js.map +1 -0
- package/dist/retrieve.d.ts +7 -5
- package/dist/retrieve.d.ts.map +1 -1
- package/dist/retrieve.js +34 -9
- package/dist/retrieve.js.map +1 -1
- package/dist/runtime-defaults.d.ts +15 -0
- package/dist/runtime-defaults.d.ts.map +1 -0
- package/dist/runtime-defaults.js +18 -0
- package/dist/runtime-defaults.js.map +1 -0
- package/dist/test/build.test.js +19 -4
- package/dist/test/build.test.js.map +1 -1
- package/dist/test/paths.test.js +8 -8
- package/dist/test/paths.test.js.map +1 -1
- package/dist/test/smoke.test.js +20 -11
- package/dist/test/smoke.test.js.map +1 -1
- package/native.cjs +136 -52
- package/native.d.ts +207 -0
- package/package.json +1 -1
- package/dist/catalog-json.d.ts +0 -7
- package/dist/catalog-json.d.ts.map +0 -1
- package/dist/catalog-json.js +0 -89
- package/dist/catalog-json.js.map +0 -1
- package/dist/decomposed-paths.d.ts +0 -7
- package/dist/decomposed-paths.d.ts.map +0 -1
- package/dist/decomposed-paths.js +0 -37
- package/dist/decomposed-paths.js.map +0 -1
- package/dist/test/catalog-json.test.d.ts +0 -2
- package/dist/test/catalog-json.test.d.ts.map +0 -1
- package/dist/test/catalog-json.test.js +0 -28
- package/dist/test/catalog-json.test.js.map +0 -1
- package/dist/test/schema-enums.test.d.ts +0 -2
- package/dist/test/schema-enums.test.d.ts.map +0 -1
- package/dist/test/schema-enums.test.js +0 -27
- package/dist/test/schema-enums.test.js.map +0 -1
package/README.md
CHANGED
|
@@ -28,7 +28,9 @@ CI stages every `cyt-indexer-sdk.*.node` into the package root and runs `npm pub
|
|
|
28
28
|
|
|
29
29
|
```typescript
|
|
30
30
|
import {
|
|
31
|
+
anthropicToolsToCatalogEntries,
|
|
32
|
+
buildCatalogFromTools,
|
|
31
33
|
buildCatalogIndex,
|
|
32
|
-
|
|
34
|
+
retrieveTools,
|
|
33
35
|
} from "cyt-indexer-sdk";
|
|
34
36
|
```
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/dist/build.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
|
+
import { collectEnums } from "./paths.js";
|
|
1
2
|
import type { JsonRecord } from "./types.js";
|
|
2
|
-
export {
|
|
3
|
+
export { collectEnums };
|
|
3
4
|
export declare function catalogToolCount(data: JsonRecord): number;
|
|
4
5
|
export declare class CatalogIndex {
|
|
5
6
|
readonly tools: JsonRecord[];
|
|
@@ -12,4 +13,12 @@ export declare class CatalogIndex {
|
|
|
12
13
|
};
|
|
13
14
|
}
|
|
14
15
|
export declare function buildCatalogIndex(tools: JsonRecord[], allEnums: unknown[]): CatalogIndex;
|
|
16
|
+
export declare function buildCatalogFromTools(tools: JsonRecord[]): CatalogIndex;
|
|
17
|
+
export declare function prepareToolEntry(serverName: string, name: string, description: string, inputSchema: JsonRecord): JsonRecord;
|
|
18
|
+
export declare function anthropicToolToCatalogEntry(tool: JsonRecord): JsonRecord | null;
|
|
19
|
+
export declare function anthropicToolsToCatalogEntries(tools: JsonRecord[]): {
|
|
20
|
+
entries: JsonRecord[];
|
|
21
|
+
enums: unknown[];
|
|
22
|
+
};
|
|
23
|
+
export declare function truncateDescription(description: string, maxTokens?: number): string;
|
|
15
24
|
//# sourceMappingURL=build.d.ts.map
|
package/dist/build.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"build.d.ts","sourceRoot":"","sources":["../src/build.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"build.d.ts","sourceRoot":"","sources":["../src/build.ts"],"names":[],"mappings":"AAUA,OAAO,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAC1C,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAE7C,OAAO,EAAE,YAAY,EAAE,CAAC;AAExB,wBAAgB,gBAAgB,CAAC,IAAI,EAAE,UAAU,GAAG,MAAM,CAEzD;AAED,qBAAa,YAAY;aAEL,KAAK,EAAE,UAAU,EAAE;aACnB,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC;gBAD7B,KAAK,EAAE,UAAU,EAAE,EACnB,KAAK,GAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAM;IAGpD,aAAa,CAAC,aAAa,CAAC,EAAE,MAAM,GAAG;QACrC,EAAE,EAAE,UAAU,EAAE,CAAC;QACjB,IAAI,EAAE,UAAU,EAAE,CAAC;QACnB,KAAK,EAAE,UAAU,EAAE,CAAC;KACrB;CAUF;AASD,wBAAgB,iBAAiB,CAC/B,KAAK,EAAE,UAAU,EAAE,EACnB,QAAQ,EAAE,OAAO,EAAE,GAClB,YAAY,CAGd;AAED,wBAAgB,qBAAqB,CAAC,KAAK,EAAE,UAAU,EAAE,GAAG,YAAY,CAGvE;AAED,wBAAgB,gBAAgB,CAC9B,UAAU,EAAE,MAAM,EAClB,IAAI,EAAE,MAAM,EACZ,WAAW,EAAE,MAAM,EACnB,WAAW,EAAE,UAAU,GACtB,UAAU,CAOZ;AAED,wBAAgB,2BAA2B,CACzC,IAAI,EAAE,UAAU,GACf,UAAU,GAAG,IAAI,CAEnB;AAED,wBAAgB,8BAA8B,CAAC,KAAK,EAAE,UAAU,EAAE,GAAG;IACnE,OAAO,EAAE,UAAU,EAAE,CAAC;IACtB,KAAK,EAAE,OAAO,EAAE,CAAC;CAClB,CAKA;AAED,wBAAgB,mBAAmB,CACjC,WAAW,EAAE,MAAM,EACnB,SAAS,SAAK,GACb,MAAM,CAER"}
|
package/dist/build.js
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
export { collectSchemaEnums as collectEnums } from "./catalog-json.js";
|
|
1
|
+
import { anthropicToolToCatalogEntryNative, anthropicToolsToCatalogEntriesNative, buildCatalogFromToolsNative, buildCatalogIndexNative, catalogIndexToCatalogDictNative, catalogToolCountNative, prepareToolEntryNative, truncateDescriptionNative, } from "./native.js";
|
|
2
|
+
import { collectEnums } from "./paths.js";
|
|
3
|
+
export { collectEnums };
|
|
5
4
|
export function catalogToolCount(data) {
|
|
6
5
|
return catalogToolCountNative(data);
|
|
7
6
|
}
|
|
@@ -12,20 +11,31 @@ export class CatalogIndex {
|
|
|
12
11
|
this.tools = tools;
|
|
13
12
|
this.files = files;
|
|
14
13
|
}
|
|
15
|
-
toCatalogDict(catalogPrefix
|
|
16
|
-
|
|
17
|
-
const jsonEntries = [];
|
|
18
|
-
for (const relPath of Object.keys(this.files).sort()) {
|
|
19
|
-
if (!relPath.startsWith(DECOMPOSED_PREFIX)) {
|
|
20
|
-
continue;
|
|
21
|
-
}
|
|
22
|
-
appendDecomposedCatalogEntry(relPath, this.files[relPath] ?? "", catalogPrefix, mdEntries, jsonEntries);
|
|
23
|
-
}
|
|
24
|
-
return { md: mdEntries, json: jsonEntries, tools: this.tools };
|
|
14
|
+
toCatalogDict(catalogPrefix) {
|
|
15
|
+
return catalogIndexToCatalogDictNative({ tools: this.tools, files: this.files }, catalogPrefix);
|
|
25
16
|
}
|
|
26
17
|
}
|
|
18
|
+
function catalogIndexFromRaw(raw) {
|
|
19
|
+
return new CatalogIndex([...raw.tools], { ...raw.files });
|
|
20
|
+
}
|
|
27
21
|
export function buildCatalogIndex(tools, allEnums) {
|
|
28
22
|
const raw = buildCatalogIndexNative(tools, allEnums);
|
|
29
|
-
return
|
|
23
|
+
return catalogIndexFromRaw(raw);
|
|
24
|
+
}
|
|
25
|
+
export function buildCatalogFromTools(tools) {
|
|
26
|
+
const raw = buildCatalogFromToolsNative(tools);
|
|
27
|
+
return catalogIndexFromRaw(raw);
|
|
28
|
+
}
|
|
29
|
+
export function prepareToolEntry(serverName, name, description, inputSchema) {
|
|
30
|
+
return prepareToolEntryNative(serverName, name, description, inputSchema);
|
|
31
|
+
}
|
|
32
|
+
export function anthropicToolToCatalogEntry(tool) {
|
|
33
|
+
return anthropicToolToCatalogEntryNative(tool);
|
|
34
|
+
}
|
|
35
|
+
export function anthropicToolsToCatalogEntries(tools) {
|
|
36
|
+
return anthropicToolsToCatalogEntriesNative(tools);
|
|
37
|
+
}
|
|
38
|
+
export function truncateDescription(description, maxTokens = 60) {
|
|
39
|
+
return truncateDescriptionNative(description, maxTokens);
|
|
30
40
|
}
|
|
31
41
|
//# sourceMappingURL=build.js.map
|
package/dist/build.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"build.js","sourceRoot":"","sources":["../src/build.ts"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"build.js","sourceRoot":"","sources":["../src/build.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,iCAAiC,EACjC,oCAAoC,EACpC,2BAA2B,EAC3B,uBAAuB,EACvB,+BAA+B,EAC/B,sBAAsB,EACtB,sBAAsB,EACtB,yBAAyB,GAC1B,MAAM,aAAa,CAAC;AACrB,OAAO,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAG1C,OAAO,EAAE,YAAY,EAAE,CAAC;AAExB,MAAM,UAAU,gBAAgB,CAAC,IAAgB;IAC/C,OAAO,sBAAsB,CAAC,IAAI,CAAC,CAAC;AACtC,CAAC;AAED,MAAM,OAAO,YAAY;IAEL;IACA;IAFlB,YACkB,KAAmB,EACnB,QAAgC,EAAE;QADlC,UAAK,GAAL,KAAK,CAAc;QACnB,UAAK,GAAL,KAAK,CAA6B;IACjD,CAAC;IAEJ,aAAa,CAAC,aAAsB;QAKlC,OAAO,+BAA+B,CACpC,EAAE,KAAK,EAAE,IAAI,CAAC,KAAK,EAAE,KAAK,EAAE,IAAI,CAAC,KAAK,EAAE,EACxC,aAAa,CAKd,CAAC;IACJ,CAAC;CACF;AAED,SAAS,mBAAmB,CAAC,GAG5B;IACC,OAAO,IAAI,YAAY,CAAC,CAAC,GAAG,GAAG,CAAC,KAAK,CAAC,EAAE,EAAE,GAAG,GAAG,CAAC,KAAK,EAAE,CAAC,CAAC;AAC5D,CAAC;AAED,MAAM,UAAU,iBAAiB,CAC/B,KAAmB,EACnB,QAAmB;IAEnB,MAAM,GAAG,GAAG,uBAAuB,CAAC,KAAK,EAAE,QAAQ,CAAC,CAAC;IACrD,OAAO,mBAAmB,CAAC,GAAG,CAAC,CAAC;AAClC,CAAC;AAED,MAAM,UAAU,qBAAqB,CAAC,KAAmB;IACvD,MAAM,GAAG,GAAG,2BAA2B,CAAC,KAAK,CAAC,CAAC;IAC/C,OAAO,mBAAmB,CAAC,GAAG,CAAC,CAAC;AAClC,CAAC;AAED,MAAM,UAAU,gBAAgB,CAC9B,UAAkB,EAClB,IAAY,EACZ,WAAmB,EACnB,WAAuB;IAEvB,OAAO,sBAAsB,CAC3B,UAAU,EACV,IAAI,EACJ,WAAW,EACX,WAAW,CACE,CAAC;AAClB,CAAC;AAED,MAAM,UAAU,2BAA2B,CACzC,IAAgB;IAEhB,OAAO,iCAAiC,CAAC,IAAI,CAAsB,CAAC;AACtE,CAAC;AAED,MAAM,UAAU,8BAA8B,CAAC,KAAmB;IAIhE,OAAO,oCAAoC,CAAC,KAAK,CAGhD,CAAC;AACJ,CAAC;AAED,MAAM,UAAU,mBAAmB,CACjC,WAAmB,EACnB,SAAS,GAAG,EAAE;IAEd,OAAO,yBAAyB,CAAC,WAAW,EAAE,SAAS,CAAC,CAAC;AAC3D,CAAC"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/** Catalog disk I/O and builder (Rust-backed). */
|
|
2
|
+
import { CatalogBuilderNative } from "./native.js";
|
|
3
|
+
import type { JsonRecord } from "./types.js";
|
|
4
|
+
export declare function writeCatalogIndex(index: JsonRecord, outputDir?: string | null, prune?: boolean | null): void;
|
|
5
|
+
export type CatalogBuilder = InstanceType<typeof CatalogBuilderNative>;
|
|
6
|
+
export { CatalogBuilderNative as CatalogBuilder };
|
|
7
|
+
//# sourceMappingURL=catalog-io.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"catalog-io.d.ts","sourceRoot":"","sources":["../src/catalog-io.ts"],"names":[],"mappings":"AAAA,kDAAkD;AAElD,OAAO,EAAE,oBAAoB,EAA2B,MAAM,aAAa,CAAC;AAC5E,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAE7C,wBAAgB,iBAAiB,CAC/B,KAAK,EAAE,UAAU,EACjB,SAAS,CAAC,EAAE,MAAM,GAAG,IAAI,EACzB,KAAK,CAAC,EAAE,OAAO,GAAG,IAAI,GACrB,IAAI,CAEN;AAED,MAAM,MAAM,cAAc,GAAG,YAAY,CAAC,OAAO,oBAAoB,CAAC,CAAC;AAEvE,OAAO,EAAE,oBAAoB,IAAI,cAAc,EAAE,CAAC"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/** Catalog disk I/O and builder (Rust-backed). */
|
|
2
|
+
import { CatalogBuilderNative, writeCatalogIndexNative } from "./native.js";
|
|
3
|
+
export function writeCatalogIndex(index, outputDir, prune) {
|
|
4
|
+
writeCatalogIndexNative(index, outputDir ?? undefined, prune ?? undefined);
|
|
5
|
+
}
|
|
6
|
+
export { CatalogBuilderNative as CatalogBuilder };
|
|
7
|
+
//# sourceMappingURL=catalog-io.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"catalog-io.js","sourceRoot":"","sources":["../src/catalog-io.ts"],"names":[],"mappings":"AAAA,kDAAkD;AAElD,OAAO,EAAE,oBAAoB,EAAE,uBAAuB,EAAE,MAAM,aAAa,CAAC;AAG5E,MAAM,UAAU,iBAAiB,CAC/B,KAAiB,EACjB,SAAyB,EACzB,KAAsB;IAEtB,uBAAuB,CAAC,KAAK,EAAE,SAAS,IAAI,SAAS,EAAE,KAAK,IAAI,SAAS,CAAC,CAAC;AAC7E,CAAC;AAID,OAAO,EAAE,oBAAoB,IAAI,cAAc,EAAE,CAAC"}
|
|
@@ -1,14 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
import
|
|
3
|
-
export
|
|
4
|
-
|
|
5
|
-
constructor(jsonFiles?: Record<string, JsonRecord>);
|
|
6
|
-
static fromCatalogIndex(index: CatalogIndex): DecomposedCatalog;
|
|
7
|
-
static fromCatalogDict(data: JsonRecord): DecomposedCatalog;
|
|
8
|
-
resolveKey(filePath: string): string | null;
|
|
9
|
-
hasJson(key: string): boolean;
|
|
10
|
-
getJson(key: string): JsonRecord | undefined;
|
|
11
|
-
toJsonFiles(): Record<string, JsonRecord>;
|
|
12
|
-
}
|
|
13
|
-
export declare function resolveDecomposedCatalog(catalog: DecomposedCatalog | CatalogIndex): DecomposedCatalog;
|
|
1
|
+
/** In-memory decomposed catalog (Rust-backed). */
|
|
2
|
+
import { DecomposedCatalogNative } from "./native.js";
|
|
3
|
+
export type DecomposedCatalog = InstanceType<typeof DecomposedCatalogNative>;
|
|
4
|
+
export declare const DecomposedCatalog: typeof import("../native.js").DecomposedCatalog;
|
|
14
5
|
//# sourceMappingURL=decomposed-catalog.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"decomposed-catalog.d.ts","sourceRoot":"","sources":["../src/decomposed-catalog.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"decomposed-catalog.d.ts","sourceRoot":"","sources":["../src/decomposed-catalog.ts"],"names":[],"mappings":"AAAA,kDAAkD;AAElD,OAAO,EAAE,uBAAuB,EAAE,MAAM,aAAa,CAAC;AAEtD,MAAM,MAAM,iBAAiB,GAAG,YAAY,CAAC,OAAO,uBAAuB,CAAC,CAAC;AAC7E,eAAO,MAAM,iBAAiB,iDAA0B,CAAC"}
|
|
@@ -1,61 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
export class DecomposedCatalog {
|
|
5
|
-
jsonFiles;
|
|
6
|
-
constructor(jsonFiles = {}) {
|
|
7
|
-
this.jsonFiles = jsonFiles;
|
|
8
|
-
}
|
|
9
|
-
static fromCatalogIndex(index) {
|
|
10
|
-
const jsonFiles = {};
|
|
11
|
-
for (const [relPath, content] of Object.entries(index.files)) {
|
|
12
|
-
const parsed = maybeDecomposedJsonFile(relPath, content);
|
|
13
|
-
if (parsed !== null) {
|
|
14
|
-
jsonFiles[relPath] = parsed;
|
|
15
|
-
}
|
|
16
|
-
}
|
|
17
|
-
return new DecomposedCatalog(jsonFiles);
|
|
18
|
-
}
|
|
19
|
-
static fromCatalogDict(data) {
|
|
20
|
-
const jsonFiles = {};
|
|
21
|
-
const entries = data.json;
|
|
22
|
-
if (Array.isArray(entries)) {
|
|
23
|
-
for (const entry of entries) {
|
|
24
|
-
const parsed = parseCatalogJsonEntry(entry);
|
|
25
|
-
if (parsed !== null) {
|
|
26
|
-
jsonFiles[parsed[0]] = parsed[1];
|
|
27
|
-
}
|
|
28
|
-
}
|
|
29
|
-
}
|
|
30
|
-
return new DecomposedCatalog(jsonFiles);
|
|
31
|
-
}
|
|
32
|
-
resolveKey(filePath) {
|
|
33
|
-
const normalized = toDecomposedKey(filePath);
|
|
34
|
-
const candidates = normalized === null ? [filePath] : [normalized, filePath];
|
|
35
|
-
for (const candidate of candidates) {
|
|
36
|
-
if (this.hasJson(candidate)) {
|
|
37
|
-
return candidate;
|
|
38
|
-
}
|
|
39
|
-
}
|
|
40
|
-
return null;
|
|
41
|
-
}
|
|
42
|
-
hasJson(key) {
|
|
43
|
-
return key in this.jsonFiles;
|
|
44
|
-
}
|
|
45
|
-
getJson(key) {
|
|
46
|
-
return this.jsonFiles[key];
|
|
47
|
-
}
|
|
48
|
-
toJsonFiles() {
|
|
49
|
-
return { ...this.jsonFiles };
|
|
50
|
-
}
|
|
51
|
-
}
|
|
52
|
-
export function resolveDecomposedCatalog(catalog) {
|
|
53
|
-
if (catalog instanceof DecomposedCatalog) {
|
|
54
|
-
return catalog;
|
|
55
|
-
}
|
|
56
|
-
if (catalog instanceof CatalogIndex) {
|
|
57
|
-
return DecomposedCatalog.fromCatalogIndex(catalog);
|
|
58
|
-
}
|
|
59
|
-
throw new TypeError("catalog must be DecomposedCatalog or CatalogIndex");
|
|
60
|
-
}
|
|
1
|
+
/** In-memory decomposed catalog (Rust-backed). */
|
|
2
|
+
import { DecomposedCatalogNative } from "./native.js";
|
|
3
|
+
export const DecomposedCatalog = DecomposedCatalogNative;
|
|
61
4
|
//# sourceMappingURL=decomposed-catalog.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"decomposed-catalog.js","sourceRoot":"","sources":["../src/decomposed-catalog.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"decomposed-catalog.js","sourceRoot":"","sources":["../src/decomposed-catalog.ts"],"names":[],"mappings":"AAAA,kDAAkD;AAElD,OAAO,EAAE,uBAAuB,EAAE,MAAM,aAAa,CAAC;AAGtD,MAAM,CAAC,MAAM,iBAAiB,GAAG,uBAAuB,CAAC"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/** Document text extraction for catalog chunks (Rust-backed). */
|
|
2
|
+
import type { JsonRecord } from "./types.js";
|
|
3
|
+
export declare function extractJsonCatalogDocument(item: JsonRecord): string | null;
|
|
4
|
+
export declare function extractMdCatalogDocument(item: JsonRecord): string | null;
|
|
5
|
+
export declare function extractDocumentText(itemContent: JsonRecord): string | null;
|
|
6
|
+
export declare function extractLevelInfo(data: JsonRecord): string[];
|
|
7
|
+
//# sourceMappingURL=documents.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"documents.d.ts","sourceRoot":"","sources":["../src/documents.ts"],"names":[],"mappings":"AAAA,iEAAiE;AAQjE,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAE7C,wBAAgB,0BAA0B,CAAC,IAAI,EAAE,UAAU,GAAG,MAAM,GAAG,IAAI,CAE1E;AAED,wBAAgB,wBAAwB,CAAC,IAAI,EAAE,UAAU,GAAG,MAAM,GAAG,IAAI,CAExE;AAED,wBAAgB,mBAAmB,CAAC,WAAW,EAAE,UAAU,GAAG,MAAM,GAAG,IAAI,CAE1E;AAED,wBAAgB,gBAAgB,CAAC,IAAI,EAAE,UAAU,GAAG,MAAM,EAAE,CAE3D"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/** Document text extraction for catalog chunks (Rust-backed). */
|
|
2
|
+
import { extractDocumentTextNative, extractJsonCatalogDocumentNative, extractLevelInfoNative, extractMdCatalogDocumentNative, } from "./native.js";
|
|
3
|
+
export function extractJsonCatalogDocument(item) {
|
|
4
|
+
return extractJsonCatalogDocumentNative(item);
|
|
5
|
+
}
|
|
6
|
+
export function extractMdCatalogDocument(item) {
|
|
7
|
+
return extractMdCatalogDocumentNative(item);
|
|
8
|
+
}
|
|
9
|
+
export function extractDocumentText(itemContent) {
|
|
10
|
+
return extractDocumentTextNative(itemContent);
|
|
11
|
+
}
|
|
12
|
+
export function extractLevelInfo(data) {
|
|
13
|
+
return extractLevelInfoNative(data);
|
|
14
|
+
}
|
|
15
|
+
//# sourceMappingURL=documents.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"documents.js","sourceRoot":"","sources":["../src/documents.ts"],"names":[],"mappings":"AAAA,iEAAiE;AAEjE,OAAO,EACL,yBAAyB,EACzB,gCAAgC,EAChC,sBAAsB,EACtB,8BAA8B,GAC/B,MAAM,aAAa,CAAC;AAGrB,MAAM,UAAU,0BAA0B,CAAC,IAAgB;IACzD,OAAO,gCAAgC,CAAC,IAAI,CAAC,CAAC;AAChD,CAAC;AAED,MAAM,UAAU,wBAAwB,CAAC,IAAgB;IACvD,OAAO,8BAA8B,CAAC,IAAI,CAAC,CAAC;AAC9C,CAAC;AAED,MAAM,UAAU,mBAAmB,CAAC,WAAuB;IACzD,OAAO,yBAAyB,CAAC,WAAW,CAAC,CAAC;AAChD,CAAC;AAED,MAAM,UAAU,gBAAgB,CAAC,IAAgB;IAC/C,OAAO,sBAAsB,CAAC,IAAI,CAAC,CAAC;AACtC,CAAC"}
|
package/dist/index.d.ts
CHANGED
|
@@ -1,3 +1,9 @@
|
|
|
1
|
-
|
|
2
|
-
export {
|
|
1
|
+
/** TypeScript SDK for cyt-indexer (Rust-backed catalog indexing). */
|
|
2
|
+
export { CatalogIndex, anthropicToolToCatalogEntry, anthropicToolsToCatalogEntries, buildCatalogFromTools, buildCatalogIndex, catalogToolCount, collectEnums, prepareToolEntry, truncateDescription, } from "./build.js";
|
|
3
|
+
export { DecomposedCatalog, loadCatalog, retrieveTools, type JsonRecord, type PolicyContextJs, type PolicyOptions, type RetrieveToolsOptions, } from "./retrieve.js";
|
|
4
|
+
export { configureRuntimeDefaults, decomposedScore, emptyOptionalFallbackK, enumScore, rerankScore, type RuntimeDefaultsConfig, } from "./runtime-defaults.js";
|
|
5
|
+
export { configurePathConstants, decomposedPrefix, getRootToolKey, jsonExt, mdExt, toDecomposedKey, toolIdFromDecomposedRel, } from "./paths.js";
|
|
6
|
+
export { CatalogBuilder, writeCatalogIndex } from "./catalog-io.js";
|
|
7
|
+
export { extractDocumentText, extractJsonCatalogDocument, extractLevelInfo, extractMdCatalogDocument, } from "./documents.js";
|
|
8
|
+
export * from "./policies.js";
|
|
3
9
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,YAAY,EACZ,iBAAiB,EACjB,gBAAgB,EAChB,YAAY,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,qEAAqE;AAErE,OAAO,EACL,YAAY,EACZ,2BAA2B,EAC3B,8BAA8B,EAC9B,qBAAqB,EACrB,iBAAiB,EACjB,gBAAgB,EAChB,YAAY,EACZ,gBAAgB,EAChB,mBAAmB,GACpB,MAAM,YAAY,CAAC;AACpB,OAAO,EACL,iBAAiB,EACjB,WAAW,EACX,aAAa,EACb,KAAK,UAAU,EACf,KAAK,eAAe,EACpB,KAAK,aAAa,EAClB,KAAK,oBAAoB,GAC1B,MAAM,eAAe,CAAC;AACvB,OAAO,EACL,wBAAwB,EACxB,eAAe,EACf,sBAAsB,EACtB,SAAS,EACT,WAAW,EACX,KAAK,qBAAqB,GAC3B,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EACL,sBAAsB,EACtB,gBAAgB,EAChB,cAAc,EACd,OAAO,EACP,KAAK,EACL,eAAe,EACf,uBAAuB,GACxB,MAAM,YAAY,CAAC;AACpB,OAAO,EAAE,cAAc,EAAE,iBAAiB,EAAE,MAAM,iBAAiB,CAAC;AACpE,OAAO,EACL,mBAAmB,EACnB,0BAA0B,EAC1B,gBAAgB,EAChB,wBAAwB,GACzB,MAAM,gBAAgB,CAAC;AAGxB,cAAc,eAAe,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -1,3 +1,10 @@
|
|
|
1
|
-
|
|
2
|
-
export {
|
|
1
|
+
/** TypeScript SDK for cyt-indexer (Rust-backed catalog indexing). */
|
|
2
|
+
export { CatalogIndex, anthropicToolToCatalogEntry, anthropicToolsToCatalogEntries, buildCatalogFromTools, buildCatalogIndex, catalogToolCount, collectEnums, prepareToolEntry, truncateDescription, } from "./build.js";
|
|
3
|
+
export { DecomposedCatalog, loadCatalog, retrieveTools, } from "./retrieve.js";
|
|
4
|
+
export { configureRuntimeDefaults, decomposedScore, emptyOptionalFallbackK, enumScore, rerankScore, } from "./runtime-defaults.js";
|
|
5
|
+
export { configurePathConstants, decomposedPrefix, getRootToolKey, jsonExt, mdExt, toDecomposedKey, toolIdFromDecomposedRel, } from "./paths.js";
|
|
6
|
+
export { CatalogBuilder, writeCatalogIndex } from "./catalog-io.js";
|
|
7
|
+
export { extractDocumentText, extractJsonCatalogDocument, extractLevelInfo, extractMdCatalogDocument, } from "./documents.js";
|
|
8
|
+
// Full policy surface (mirrors cyt_indexer.policies).
|
|
9
|
+
export * from "./policies.js";
|
|
3
10
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,YAAY,EACZ,iBAAiB,EACjB,gBAAgB,EAChB,YAAY,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,qEAAqE;AAErE,OAAO,EACL,YAAY,EACZ,2BAA2B,EAC3B,8BAA8B,EAC9B,qBAAqB,EACrB,iBAAiB,EACjB,gBAAgB,EAChB,YAAY,EACZ,gBAAgB,EAChB,mBAAmB,GACpB,MAAM,YAAY,CAAC;AACpB,OAAO,EACL,iBAAiB,EACjB,WAAW,EACX,aAAa,GAKd,MAAM,eAAe,CAAC;AACvB,OAAO,EACL,wBAAwB,EACxB,eAAe,EACf,sBAAsB,EACtB,SAAS,EACT,WAAW,GAEZ,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EACL,sBAAsB,EACtB,gBAAgB,EAChB,cAAc,EACd,OAAO,EACP,KAAK,EACL,eAAe,EACf,uBAAuB,GACxB,MAAM,YAAY,CAAC;AACpB,OAAO,EAAE,cAAc,EAAE,iBAAiB,EAAE,MAAM,iBAAiB,CAAC;AACpE,OAAO,EACL,mBAAmB,EACnB,0BAA0B,EAC1B,gBAAgB,EAChB,wBAAwB,GACzB,MAAM,gBAAgB,CAAC;AAExB,sDAAsD;AACtD,cAAc,eAAe,CAAC"}
|
package/dist/native.d.ts
CHANGED
|
@@ -1,6 +1,82 @@
|
|
|
1
1
|
export declare const buildCatalogIndexNative: typeof import("../native.d.ts").buildCatalogIndex;
|
|
2
|
+
export declare const buildCatalogFromToolsNative: typeof import("../native.d.ts").buildCatalogFromTools;
|
|
3
|
+
export declare const prepareToolEntryNative: typeof import("../native.d.ts").prepareToolEntry;
|
|
4
|
+
export declare const anthropicToolToCatalogEntryNative: typeof import("../native.d.ts").anthropicToolToCatalogEntry;
|
|
5
|
+
export declare const anthropicToolsToCatalogEntriesNative: typeof import("../native.d.ts").anthropicToolsToCatalogEntries;
|
|
6
|
+
export declare const truncateDescriptionNative: typeof import("../native.d.ts").truncateDescription;
|
|
2
7
|
export declare const catalogToolCountNative: typeof import("../native.d.ts").catalogToolCount;
|
|
8
|
+
export declare const catalogIndexToCatalogDictNative: typeof import("../native.d.ts").catalogIndexToCatalogDict;
|
|
3
9
|
export declare const loadCatalogNative: typeof import("../native.d.ts").loadCatalog;
|
|
4
10
|
export declare const retrieveCoreNative: typeof import("../native.d.ts").retrieveCore;
|
|
5
|
-
export
|
|
11
|
+
export declare const retrieveToolsNative: typeof import("../native.d.ts").retrieveTools;
|
|
12
|
+
export declare const DecomposedCatalogNative: typeof import("../native.d.ts").DecomposedCatalog;
|
|
13
|
+
export declare const configurePathConstantsNative: typeof import("../native.d.ts").configurePathConstants;
|
|
14
|
+
export declare const pathMdExtNative: typeof import("../native.d.ts").mdExt;
|
|
15
|
+
export declare const pathJsonExtNative: typeof import("../native.d.ts").jsonExt;
|
|
16
|
+
export declare const pathDecomposedPrefixNative: typeof import("../native.d.ts").decomposedPrefix;
|
|
17
|
+
export declare const toDecomposedKeyNative: typeof import("../native.d.ts").toDecomposedKey;
|
|
18
|
+
export declare const toolIdFromDecomposedRelNative: typeof import("../native.d.ts").toolIdFromDecomposedRel;
|
|
19
|
+
export declare const getRootToolKeyNative: typeof import("../native.d.ts").getRootToolKey;
|
|
20
|
+
export declare const collectEnumsNative: typeof import("../native.d.ts").collectEnums;
|
|
21
|
+
export declare const configureRuntimeDefaultsNative: typeof import("../native.d.ts").configureRuntimeDefaults;
|
|
22
|
+
export declare const decomposedScoreNative: typeof import("../native.d.ts").decomposedScore;
|
|
23
|
+
export declare const enumScoreNative: typeof import("../native.d.ts").enumScore;
|
|
24
|
+
export declare const rerankScoreNative: typeof import("../native.d.ts").rerankScore;
|
|
25
|
+
export declare const emptyOptionalFallbackKNative: typeof import("../native.d.ts").emptyOptionalFallbackK;
|
|
26
|
+
export declare const toolPoliciesNative: typeof import("../native.d.ts").toolPolicies;
|
|
27
|
+
export declare const PolicyContextNative: typeof import("../native.d.ts").PolicyContext;
|
|
28
|
+
export declare const policyContextFromValuesNative: typeof import("../native.d.ts").policyContextFromValues;
|
|
29
|
+
export declare const effectivePolicyNative: typeof import("../native.d.ts").effectivePolicy;
|
|
30
|
+
export declare const toolPassThroughNative: typeof import("../native.d.ts").toolPassThrough;
|
|
31
|
+
export declare const partitionCatalogNative: typeof import("../native.d.ts").partitionCatalog;
|
|
32
|
+
export declare const mergeCatalogNative: typeof import("../native.d.ts").mergeCatalog;
|
|
33
|
+
export declare const catalogNeedsPartitionNative: typeof import("../native.d.ts").catalogNeedsPartition;
|
|
34
|
+
export declare const catalogNeedsPrunedRecomposeNative: typeof import("../native.d.ts").catalogNeedsPrunedRecompose;
|
|
35
|
+
export declare const requestPassThroughNative: typeof import("../native.d.ts").requestPassThrough;
|
|
36
|
+
export declare const fullPassThroughNative: typeof import("../native.d.ts").fullPassThrough;
|
|
37
|
+
export declare const isDecomposedToolRootChunkNative: typeof import("../native.d.ts").isDecomposedToolRootChunk;
|
|
38
|
+
export declare const isDecomposedOptionalPropertyChunkNative: typeof import("../native.d.ts").isDecomposedOptionalPropertyChunk;
|
|
39
|
+
export declare const filterRecomposeJsonEntriesNative: typeof import("../native.d.ts").filterRecomposeJsonEntries;
|
|
40
|
+
export declare const mitigateEmptyOptionalPropertiesNative: typeof import("../native.d.ts").mitigateEmptyOptionalProperties;
|
|
41
|
+
export declare const dropRecomposedToolsWithEmptyPropertiesNative: typeof import("../native.d.ts").dropRecomposedToolsWithEmptyProperties;
|
|
42
|
+
export declare const rootToolIdFromChunkNative: typeof import("../native.d.ts").rootToolIdFromChunk;
|
|
43
|
+
export declare const isNonSystemToolIdNative: typeof import("../native.d.ts").isNonSystemToolId;
|
|
44
|
+
export declare const isSystemToolIdNative: typeof import("../native.d.ts").isSystemToolId;
|
|
45
|
+
export declare const chunkToolIdNative: typeof import("../native.d.ts").chunkToolId;
|
|
46
|
+
export declare const isSystemChunkNative: typeof import("../native.d.ts").isSystemChunk;
|
|
47
|
+
export declare const isNonSystemChunkNative: typeof import("../native.d.ts").isNonSystemChunk;
|
|
48
|
+
export declare const isSystemRootChunkNative: typeof import("../native.d.ts").isSystemRootChunk;
|
|
49
|
+
export declare const isMcpRootChunkNative: typeof import("../native.d.ts").isMcpRootChunk;
|
|
50
|
+
export declare const isSystemOptionalChunkNative: typeof import("../native.d.ts").isSystemOptionalChunk;
|
|
51
|
+
export declare const isMcpOptionalChunkNative: typeof import("../native.d.ts").isMcpOptionalChunk;
|
|
52
|
+
export declare const stashSystemToolsNative: typeof import("../native.d.ts").stashSystemTools;
|
|
53
|
+
export declare const restoreSystemToolsNative: typeof import("../native.d.ts").restoreSystemTools;
|
|
54
|
+
export declare const stashMcpToolsNative: typeof import("../native.d.ts").stashMcpTools;
|
|
55
|
+
export declare const restoreMcpToolsNative: typeof import("../native.d.ts").restoreMcpTools;
|
|
56
|
+
export declare const mergeToolsPreservingOrderNative: typeof import("../native.d.ts").mergeToolsPreservingOrder;
|
|
57
|
+
export declare const splitAnthropicToolsNative: typeof import("../native.d.ts").splitAnthropicTools;
|
|
58
|
+
export declare const entriesForPolicyNative: typeof import("../native.d.ts").entriesForPolicy;
|
|
59
|
+
export declare const toolsForCatalogNative: typeof import("../native.d.ts").toolsForCatalog;
|
|
60
|
+
export declare const systemRequiredEnumValuesNative: typeof import("../native.d.ts").systemRequiredEnumValues;
|
|
61
|
+
export declare const mcpRequiredEnumValuesNative: typeof import("../native.d.ts").mcpRequiredEnumValues;
|
|
62
|
+
export declare const requiredEnumValuesByToolNative: typeof import("../native.d.ts").requiredEnumValuesByTool;
|
|
63
|
+
export declare const optionalLeafSurvivedRerankNative: typeof import("../native.d.ts").optionalLeafSurvivedRerank;
|
|
64
|
+
export declare const needsPartitionNative: typeof import("../native.d.ts").needsPartition;
|
|
65
|
+
export declare const needsPrunedRecomposeNative: typeof import("../native.d.ts").needsPrunedRecompose;
|
|
66
|
+
export declare const systemToolsPassThroughNative: typeof import("../native.d.ts").systemToolsPassThrough;
|
|
67
|
+
export declare const mcpToolsPassThroughNative: typeof import("../native.d.ts").mcpToolsPassThrough;
|
|
68
|
+
export declare const anthropicToolIsSystemNative: typeof import("../native.d.ts").anthropicToolIsSystem;
|
|
69
|
+
export declare const anthropicToolIsMcpNative: typeof import("../native.d.ts").anthropicToolIsMcp;
|
|
70
|
+
export declare const directRootOptionalChunksForToolNative: typeof import("../native.d.ts").directRootOptionalChunksForTool;
|
|
71
|
+
export declare const rootChunkPropertiesEmptyNative: typeof import("../native.d.ts").rootChunkPropertiesEmpty;
|
|
72
|
+
export declare const toolIdHasEmptyDecomposedRootNative: typeof import("../native.d.ts").toolIdHasEmptyDecomposedRoot;
|
|
73
|
+
export declare const toolIdHadEmptyOriginalRootPropertiesNative: typeof import("../native.d.ts").toolIdHadEmptyOriginalRootProperties;
|
|
74
|
+
export declare const isDirectRootOptionalPropertyChunkNative: typeof import("../native.d.ts").isDirectRootOptionalPropertyChunk;
|
|
75
|
+
export declare const writeCatalogIndexNative: typeof import("../native.d.ts").writeCatalogIndex;
|
|
76
|
+
export declare const CatalogBuilderNative: typeof import("../native.d.ts").CatalogBuilder;
|
|
77
|
+
export declare const extractJsonCatalogDocumentNative: typeof import("../native.d.ts").extractJsonCatalogDocument;
|
|
78
|
+
export declare const extractMdCatalogDocumentNative: typeof import("../native.d.ts").extractMdCatalogDocument;
|
|
79
|
+
export declare const extractDocumentTextNative: typeof import("../native.d.ts").extractDocumentText;
|
|
80
|
+
export declare const extractLevelInfoNative: typeof import("../native.d.ts").extractLevelInfo;
|
|
81
|
+
export type { PolicyOptions, PolicyContextJs } from "../native.d.ts";
|
|
6
82
|
//# sourceMappingURL=native.d.ts.map
|
package/dist/native.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"native.d.ts","sourceRoot":"","sources":["../src/native.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"native.d.ts","sourceRoot":"","sources":["../src/native.ts"],"names":[],"mappings":"AAOA,eAAO,MAAM,uBAAuB,mDAA2B,CAAC;AAChE,eAAO,MAAM,2BAA2B,uDAA+B,CAAC;AACxE,eAAO,MAAM,sBAAsB,kDAA0B,CAAC;AAC9D,eAAO,MAAM,iCAAiC,6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AwB,CAAC;AAC1D,eAAO,MAAM,0BAA0B,sDAA8B,CAAC;AACtE,eAAO,MAAM,4BAA4B,wDAAgC,CAAC;AAC1E,eAAO,MAAM,yBAAyB,qDAA6B,CAAC;AACpE,eAAO,MAAM,2BAA2B,uDAA+B,CAAC;AACxE,eAAO,MAAM,wBAAwB,oDAA4B,CAAC;AAClE,eAAO,MAAM,qCAAqC,iEACV,CAAC;AACzC,eAAO,MAAM,8BAA8B,0DAAkC,CAAC;AAC9E,eAAO,MAAM,kCAAkC,8DACV,CAAC;AACtC,eAAO,MAAM,0CAA0C,sEACV,CAAC;AAC9C,eAAO,MAAM,uCAAuC,mEACV,CAAC;AAG3C,eAAO,MAAM,uBAAuB,mDAA2B,CAAC;AAChE,eAAO,MAAM,oBAAoB,gDAAwB,CAAC;AAG1D,eAAO,MAAM,gCAAgC,4DACV,CAAC;AACpC,eAAO,MAAM,8BAA8B,0DAAkC,CAAC;AAC9E,eAAO,MAAM,yBAAyB,qDAA6B,CAAC;AACpE,eAAO,MAAM,sBAAsB,kDAA0B,CAAC;AAE9D,YAAY,EAAE,aAAa,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAC"}
|
package/dist/native.js
CHANGED
|
@@ -1,8 +1,91 @@
|
|
|
1
1
|
import { createRequire } from "node:module";
|
|
2
2
|
const require = createRequire(import.meta.url);
|
|
3
3
|
const native = require("../native.cjs");
|
|
4
|
+
// Build / catalog
|
|
4
5
|
export const buildCatalogIndexNative = native.buildCatalogIndex;
|
|
6
|
+
export const buildCatalogFromToolsNative = native.buildCatalogFromTools;
|
|
7
|
+
export const prepareToolEntryNative = native.prepareToolEntry;
|
|
8
|
+
export const anthropicToolToCatalogEntryNative = native.anthropicToolToCatalogEntry;
|
|
9
|
+
export const anthropicToolsToCatalogEntriesNative = native.anthropicToolsToCatalogEntries;
|
|
10
|
+
export const truncateDescriptionNative = native.truncateDescription;
|
|
5
11
|
export const catalogToolCountNative = native.catalogToolCount;
|
|
12
|
+
export const catalogIndexToCatalogDictNative = native.catalogIndexToCatalogDict;
|
|
13
|
+
// Retrieve
|
|
6
14
|
export const loadCatalogNative = native.loadCatalog;
|
|
7
15
|
export const retrieveCoreNative = native.retrieveCore;
|
|
16
|
+
export const retrieveToolsNative = native.retrieveTools;
|
|
17
|
+
export const DecomposedCatalogNative = native.DecomposedCatalog;
|
|
18
|
+
// Paths
|
|
19
|
+
export const configurePathConstantsNative = native.configurePathConstants;
|
|
20
|
+
export const pathMdExtNative = native.mdExt;
|
|
21
|
+
export const pathJsonExtNative = native.jsonExt;
|
|
22
|
+
export const pathDecomposedPrefixNative = native.decomposedPrefix;
|
|
23
|
+
export const toDecomposedKeyNative = native.toDecomposedKey;
|
|
24
|
+
export const toolIdFromDecomposedRelNative = native.toolIdFromDecomposedRel;
|
|
25
|
+
export const getRootToolKeyNative = native.getRootToolKey;
|
|
26
|
+
export const collectEnumsNative = native.collectEnums;
|
|
27
|
+
// Runtime defaults
|
|
28
|
+
export const configureRuntimeDefaultsNative = native.configureRuntimeDefaults;
|
|
29
|
+
export const decomposedScoreNative = native.decomposedScore;
|
|
30
|
+
export const enumScoreNative = native.enumScore;
|
|
31
|
+
export const rerankScoreNative = native.rerankScore;
|
|
32
|
+
export const emptyOptionalFallbackKNative = native.emptyOptionalFallbackK;
|
|
33
|
+
// Policies
|
|
34
|
+
export const toolPoliciesNative = native.toolPolicies;
|
|
35
|
+
export const PolicyContextNative = native.PolicyContext;
|
|
36
|
+
export const policyContextFromValuesNative = native.policyContextFromValues;
|
|
37
|
+
export const effectivePolicyNative = native.effectivePolicy;
|
|
38
|
+
export const toolPassThroughNative = native.toolPassThrough;
|
|
39
|
+
export const partitionCatalogNative = native.partitionCatalog;
|
|
40
|
+
export const mergeCatalogNative = native.mergeCatalog;
|
|
41
|
+
export const catalogNeedsPartitionNative = native.catalogNeedsPartition;
|
|
42
|
+
export const catalogNeedsPrunedRecomposeNative = native.catalogNeedsPrunedRecompose;
|
|
43
|
+
export const requestPassThroughNative = native.requestPassThrough;
|
|
44
|
+
export const fullPassThroughNative = native.fullPassThrough;
|
|
45
|
+
export const isDecomposedToolRootChunkNative = native.isDecomposedToolRootChunk;
|
|
46
|
+
export const isDecomposedOptionalPropertyChunkNative = native.isDecomposedOptionalPropertyChunk;
|
|
47
|
+
export const filterRecomposeJsonEntriesNative = native.filterRecomposeJsonEntries;
|
|
48
|
+
export const mitigateEmptyOptionalPropertiesNative = native.mitigateEmptyOptionalProperties;
|
|
49
|
+
export const dropRecomposedToolsWithEmptyPropertiesNative = native.dropRecomposedToolsWithEmptyProperties;
|
|
50
|
+
export const rootToolIdFromChunkNative = native.rootToolIdFromChunk;
|
|
51
|
+
export const isNonSystemToolIdNative = native.isNonSystemToolId;
|
|
52
|
+
export const isSystemToolIdNative = native.isSystemToolId;
|
|
53
|
+
export const chunkToolIdNative = native.chunkToolId;
|
|
54
|
+
export const isSystemChunkNative = native.isSystemChunk;
|
|
55
|
+
export const isNonSystemChunkNative = native.isNonSystemChunk;
|
|
56
|
+
export const isSystemRootChunkNative = native.isSystemRootChunk;
|
|
57
|
+
export const isMcpRootChunkNative = native.isMcpRootChunk;
|
|
58
|
+
export const isSystemOptionalChunkNative = native.isSystemOptionalChunk;
|
|
59
|
+
export const isMcpOptionalChunkNative = native.isMcpOptionalChunk;
|
|
60
|
+
export const stashSystemToolsNative = native.stashSystemTools;
|
|
61
|
+
export const restoreSystemToolsNative = native.restoreSystemTools;
|
|
62
|
+
export const stashMcpToolsNative = native.stashMcpTools;
|
|
63
|
+
export const restoreMcpToolsNative = native.restoreMcpTools;
|
|
64
|
+
export const mergeToolsPreservingOrderNative = native.mergeToolsPreservingOrder;
|
|
65
|
+
export const splitAnthropicToolsNative = native.splitAnthropicTools;
|
|
66
|
+
export const entriesForPolicyNative = native.entriesForPolicy;
|
|
67
|
+
export const toolsForCatalogNative = native.toolsForCatalog;
|
|
68
|
+
export const systemRequiredEnumValuesNative = native.systemRequiredEnumValues;
|
|
69
|
+
export const mcpRequiredEnumValuesNative = native.mcpRequiredEnumValues;
|
|
70
|
+
export const requiredEnumValuesByToolNative = native.requiredEnumValuesByTool;
|
|
71
|
+
export const optionalLeafSurvivedRerankNative = native.optionalLeafSurvivedRerank;
|
|
72
|
+
export const needsPartitionNative = native.needsPartition;
|
|
73
|
+
export const needsPrunedRecomposeNative = native.needsPrunedRecompose;
|
|
74
|
+
export const systemToolsPassThroughNative = native.systemToolsPassThrough;
|
|
75
|
+
export const mcpToolsPassThroughNative = native.mcpToolsPassThrough;
|
|
76
|
+
export const anthropicToolIsSystemNative = native.anthropicToolIsSystem;
|
|
77
|
+
export const anthropicToolIsMcpNative = native.anthropicToolIsMcp;
|
|
78
|
+
export const directRootOptionalChunksForToolNative = native.directRootOptionalChunksForTool;
|
|
79
|
+
export const rootChunkPropertiesEmptyNative = native.rootChunkPropertiesEmpty;
|
|
80
|
+
export const toolIdHasEmptyDecomposedRootNative = native.toolIdHasEmptyDecomposedRoot;
|
|
81
|
+
export const toolIdHadEmptyOriginalRootPropertiesNative = native.toolIdHadEmptyOriginalRootProperties;
|
|
82
|
+
export const isDirectRootOptionalPropertyChunkNative = native.isDirectRootOptionalPropertyChunk;
|
|
83
|
+
// Catalog I/O
|
|
84
|
+
export const writeCatalogIndexNative = native.writeCatalogIndex;
|
|
85
|
+
export const CatalogBuilderNative = native.CatalogBuilder;
|
|
86
|
+
// Documents
|
|
87
|
+
export const extractJsonCatalogDocumentNative = native.extractJsonCatalogDocument;
|
|
88
|
+
export const extractMdCatalogDocumentNative = native.extractMdCatalogDocument;
|
|
89
|
+
export const extractDocumentTextNative = native.extractDocumentText;
|
|
90
|
+
export const extractLevelInfoNative = native.extractLevelInfo;
|
|
8
91
|
//# sourceMappingURL=native.js.map
|
package/dist/native.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"native.js","sourceRoot":"","sources":["../src/native.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AA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AAM,4BAA4B,GAAG,MAAM,CAAC,sBAAsB,CAAC;AAC1E,MAAM,CAAC,MAAM,yBAAyB,GAAG,MAAM,CAAC,mBAAmB,CAAC;AACpE,MAAM,CAAC,MAAM,2BAA2B,GAAG,MAAM,CAAC,qBAAqB,CAAC;AACxE,MAAM,CAAC,MAAM,wBAAwB,GAAG,MAAM,CAAC,kBAAkB,CAAC;AAClE,MAAM,CAAC,MAAM,qCAAqC,GAChD,MAAM,CAAC,+BAA+B,CAAC;AACzC,MAAM,CAAC,MAAM,8BAA8B,GAAG,MAAM,CAAC,wBAAwB,CAAC;AAC9E,MAAM,CAAC,MAAM,kCAAkC,GAC7C,MAAM,CAAC,4BAA4B,CAAC;AACtC,MAAM,CAAC,MAAM,0CAA0C,GACrD,MAAM,CAAC,oCAAoC,CAAC;AAC9C,MAAM,CAAC,MAAM,uCAAuC,GAClD,MAAM,CAAC,iCAAiC,CAAC;AAE3C,cAAc;AACd,MAAM,CAAC,MAAM,uBAAuB,GAAG,MAAM,CAAC,iBAAiB,CAAC;AAChE,MAAM,CAAC,MAAM,oBAAoB,GAAG,MAAM,CAAC,cAAc,CAAC;AAE1D,YAAY;AACZ,MAAM,CAAC,MAAM,gCAAgC,GAC3C,MAAM,CAAC,0BAA0B,CAAC;AACpC,MAAM,CAAC,MAAM,8BAA8B,GAAG,MAAM,CAAC,wBAAwB,CAAC;AAC9E,MAAM,CAAC,MAAM,yBAAyB,GAAG,MAAM,CAAC,mBAAmB,CAAC;AACpE,MAAM,CAAC,MAAM,sBAAsB,GAAG,MAAM,CAAC,gBAAgB,CAAC"}
|
package/dist/paths.d.ts
CHANGED
|
@@ -1,2 +1,19 @@
|
|
|
1
|
-
|
|
1
|
+
/** Push host app overrides into native PathConfig (Rust defaults when not called). */
|
|
2
|
+
export declare function configurePathConstants(opts: {
|
|
3
|
+
mdExt: string;
|
|
4
|
+
jsonExt: string;
|
|
5
|
+
decomposedPrefix: string;
|
|
6
|
+
decomposedRoot: string;
|
|
7
|
+
catalogPrefix: string;
|
|
8
|
+
builderMemoryOnly: boolean;
|
|
9
|
+
defaultCatalogDir: string;
|
|
10
|
+
writeCatalogPrune: boolean;
|
|
11
|
+
}): void;
|
|
12
|
+
export declare function mdExt(): string;
|
|
13
|
+
export declare function jsonExt(): string;
|
|
14
|
+
export declare function decomposedPrefix(): string;
|
|
15
|
+
export declare function toDecomposedKey(filePath: string): string | null;
|
|
16
|
+
export declare function toolIdFromDecomposedRel(relPath: string): string;
|
|
17
|
+
export declare function getRootToolKey(filePath: string): string | null;
|
|
18
|
+
export declare function collectEnums(schema: unknown): unknown[];
|
|
2
19
|
//# sourceMappingURL=paths.d.ts.map
|
package/dist/paths.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"paths.d.ts","sourceRoot":"","sources":["../src/paths.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"paths.d.ts","sourceRoot":"","sources":["../src/paths.ts"],"names":[],"mappings":"AAYA,sFAAsF;AACtF,wBAAgB,sBAAsB,CAAC,IAAI,EAAE;IAC3C,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,CAAC;IAChB,gBAAgB,EAAE,MAAM,CAAC;IACzB,cAAc,EAAE,MAAM,CAAC;IACvB,aAAa,EAAE,MAAM,CAAC;IACtB,iBAAiB,EAAE,OAAO,CAAC;IAC3B,iBAAiB,EAAE,MAAM,CAAC;IAC1B,iBAAiB,EAAE,OAAO,CAAC;CAC5B,GAAG,IAAI,CAWP;AAED,wBAAgB,KAAK,IAAI,MAAM,CAE9B;AAED,wBAAgB,OAAO,IAAI,MAAM,CAEhC;AAED,wBAAgB,gBAAgB,IAAI,MAAM,CAEzC;AAED,wBAAgB,eAAe,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI,CAE/D;AAED,wBAAgB,uBAAuB,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,CAE/D;AAED,wBAAgB,cAAc,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI,CAE9D;AAED,wBAAgB,YAAY,CAAC,MAAM,EAAE,OAAO,GAAG,OAAO,EAAE,CAEvD"}
|
package/dist/paths.js
CHANGED
|
@@ -1,2 +1,27 @@
|
|
|
1
|
-
|
|
1
|
+
import { collectEnumsNative, configurePathConstantsNative, getRootToolKeyNative, pathDecomposedPrefixNative, pathJsonExtNative, pathMdExtNative, toDecomposedKeyNative, toolIdFromDecomposedRelNative, } from "./native.js";
|
|
2
|
+
/** Push host app overrides into native PathConfig (Rust defaults when not called). */
|
|
3
|
+
export function configurePathConstants(opts) {
|
|
4
|
+
configurePathConstantsNative(opts.mdExt, opts.jsonExt, opts.decomposedPrefix, opts.decomposedRoot, opts.catalogPrefix, opts.builderMemoryOnly, opts.defaultCatalogDir, opts.writeCatalogPrune);
|
|
5
|
+
}
|
|
6
|
+
export function mdExt() {
|
|
7
|
+
return pathMdExtNative();
|
|
8
|
+
}
|
|
9
|
+
export function jsonExt() {
|
|
10
|
+
return pathJsonExtNative();
|
|
11
|
+
}
|
|
12
|
+
export function decomposedPrefix() {
|
|
13
|
+
return pathDecomposedPrefixNative();
|
|
14
|
+
}
|
|
15
|
+
export function toDecomposedKey(filePath) {
|
|
16
|
+
return toDecomposedKeyNative(filePath);
|
|
17
|
+
}
|
|
18
|
+
export function toolIdFromDecomposedRel(relPath) {
|
|
19
|
+
return toolIdFromDecomposedRelNative(relPath);
|
|
20
|
+
}
|
|
21
|
+
export function getRootToolKey(filePath) {
|
|
22
|
+
return getRootToolKeyNative(filePath);
|
|
23
|
+
}
|
|
24
|
+
export function collectEnums(schema) {
|
|
25
|
+
return collectEnumsNative(schema);
|
|
26
|
+
}
|
|
2
27
|
//# sourceMappingURL=paths.js.map
|
package/dist/paths.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"paths.js","sourceRoot":"","sources":["../src/paths.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,iBAAiB,EACjB,cAAc,
|
|
1
|
+
{"version":3,"file":"paths.js","sourceRoot":"","sources":["../src/paths.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,kBAAkB,EAClB,4BAA4B,EAC5B,oBAAoB,EACpB,0BAA0B,EAC1B,iBAAiB,EACjB,eAAe,EACf,qBAAqB,EACrB,6BAA6B,GAC9B,MAAM,aAAa,CAAC;AAGrB,sFAAsF;AACtF,MAAM,UAAU,sBAAsB,CAAC,IAStC;IACC,4BAA4B,CAC1B,IAAI,CAAC,KAAK,EACV,IAAI,CAAC,OAAO,EACZ,IAAI,CAAC,gBAAgB,EACrB,IAAI,CAAC,cAAc,EACnB,IAAI,CAAC,aAAa,EAClB,IAAI,CAAC,iBAAiB,EACtB,IAAI,CAAC,iBAAiB,EACtB,IAAI,CAAC,iBAAiB,CACvB,CAAC;AACJ,CAAC;AAED,MAAM,UAAU,KAAK;IACnB,OAAO,eAAe,EAAE,CAAC;AAC3B,CAAC;AAED,MAAM,UAAU,OAAO;IACrB,OAAO,iBAAiB,EAAE,CAAC;AAC7B,CAAC;AAED,MAAM,UAAU,gBAAgB;IAC9B,OAAO,0BAA0B,EAAE,CAAC;AACtC,CAAC;AAED,MAAM,UAAU,eAAe,CAAC,QAAgB;IAC9C,OAAO,qBAAqB,CAAC,QAAQ,CAAC,CAAC;AACzC,CAAC;AAED,MAAM,UAAU,uBAAuB,CAAC,OAAe;IACrD,OAAO,6BAA6B,CAAC,OAAO,CAAC,CAAC;AAChD,CAAC;AAED,MAAM,UAAU,cAAc,CAAC,QAAgB;IAC7C,OAAO,oBAAoB,CAAC,QAAQ,CAAC,CAAC;AACxC,CAAC;AAED,MAAM,UAAU,YAAY,CAAC,MAAe;IAC1C,OAAO,kBAAkB,CAAC,MAAoB,CAAC,CAAC;AAClD,CAAC"}
|