@autorag/librarian 2.11.0 → 2.13.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/NOTICE +6 -0
- package/README.md +14 -6
- package/dist/agent/agent.d.ts +136 -33
- package/dist/agent/answer-citations.d.ts +34 -2
- package/dist/agent/answer-guidelines.d.ts +20 -3
- package/dist/agent/ask-user.d.ts +8 -0
- package/dist/agent/automation-tool.d.ts +45 -0
- package/dist/agent/citation-links.d.ts +23 -0
- package/dist/agent/citation-numbers.d.ts +68 -0
- package/dist/agent/citation-relevance.d.ts +37 -0
- package/dist/agent/conversation-queries.d.ts +31 -0
- package/dist/agent/convert-tool.d.ts +28 -0
- package/dist/agent/current-date.d.ts +10 -0
- package/dist/agent/datasource-skill.d.ts +2 -2
- package/dist/agent/environment-prompt.d.ts +20 -0
- package/dist/agent/evidence-ledger.d.ts +4 -2
- package/dist/agent/evidence-persistence.d.ts +17 -11
- package/dist/agent/index.d.ts +1 -0
- package/dist/agent/intent-tracing.d.ts +33 -0
- package/dist/agent/location-claims.d.ts +14 -0
- package/dist/agent/packaged-skill.d.ts +19 -0
- package/dist/agent/permission-gate.d.ts +78 -0
- package/dist/agent/permission-judgment.d.ts +72 -0
- package/dist/agent/permission-paths.d.ts +23 -0
- package/dist/agent/query-routing.d.ts +78 -27
- package/dist/agent/results.d.ts +10 -2
- package/dist/agent/search-documents.d.ts +6 -1
- package/dist/agent/self-config.d.ts +6 -4
- package/dist/agent/skill-invocation.d.ts +17 -0
- package/dist/agent/user-requests.d.ts +52 -0
- package/dist/automation/config.d.ts +48 -0
- package/dist/automation/daemon.d.ts +31 -0
- package/dist/automation/dispatch.d.ts +13 -0
- package/dist/automation/run-agent.d.ts +22 -0
- package/dist/automation/run.d.ts +32 -0
- package/dist/automation/service.d.ts +61 -0
- package/dist/cli/commands/automate.d.ts +2 -0
- package/dist/cli/commands/evidence.d.ts +2 -0
- package/dist/cli/config.d.ts +21 -0
- package/dist/cli/index.d.ts +1 -1
- package/dist/cli/index.js +19531 -14871
- package/dist/cli/open-target.d.ts +9 -0
- package/dist/cli/setup.d.ts +14 -0
- package/dist/convert/cli.d.ts +77 -0
- package/dist/convert/index.d.ts +4 -0
- package/dist/convert/installer.d.ts +84 -0
- package/dist/convert/matrix.d.ts +27 -0
- package/dist/convert/relate.d.ts +30 -0
- package/dist/core.js +32479 -28141
- package/dist/datasource/connector-timeouts.d.ts +6 -2
- package/dist/datasource/crawler-skill.d.ts +1 -0
- package/dist/datasource/crawler-types.d.ts +1 -1
- package/dist/datasource/index.d.ts +1 -1
- package/dist/datasource/sidecar/methods.d.ts +8 -1
- package/dist/datasource/skills/clawgallery/skill.d.ts +4 -0
- package/dist/datasource/skills/discrawl/skill.d.ts +5 -0
- package/dist/datasource/skills/factory.d.ts +5 -1
- package/dist/datasource/skills/lazykatok/index.d.ts +1 -1
- package/dist/datasource/skills/lazykatok/methods.d.ts +5 -5
- package/dist/datasource/skills/lazykatok/skill.d.ts +1 -0
- package/dist/datasource/skills/lazykatok/types.d.ts +2 -2
- package/dist/datasource/skills/mailcrawl/skill.d.ts +1 -0
- package/dist/datasource/skills/mailcrawl/types.d.ts +1 -1
- package/dist/dupey/cli.d.ts +18 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +32558 -28145
- package/dist/mcp/index.js +32651 -28263
- package/dist/memory/memory.d.ts +4 -1
- package/dist/minsync/installer.d.ts +1 -1
- package/dist/mirror/atomic-write.d.ts +16 -1
- package/dist/mirror/sync.d.ts +2 -0
- package/dist/profiles/agent-factory.d.ts +60 -0
- package/dist/profiles/automation-profiles.d.ts +25 -0
- package/dist/profiles/loop-guard.d.ts +23 -0
- package/dist/profiles/retrieval-tools.d.ts +24 -0
- package/dist/profiles/session-model.d.ts +69 -0
- package/dist/profiles.d.ts +13 -0
- package/dist/profiles.js +35246 -0
- package/dist/retrieval/chunk-location.d.ts +28 -0
- package/dist/retrieval/fallback.d.ts +24 -0
- package/dist/retrieval/index.d.ts +1 -0
- package/dist/retrieval/rerank.d.ts +6 -0
- package/dist/retrieval/types.d.ts +16 -0
- package/internal-skills/organize/SKILL.md +43 -0
- package/package.json +9 -2
- package/skills/autorag/SKILL.md +89 -7
- package/skills/autorag-setup/SKILL.md +10 -4
|
@@ -9,8 +9,12 @@
|
|
|
9
9
|
* of making progress. Interactive reads (`search`, `doctor`, chunk lookups) keep
|
|
10
10
|
* the short default.
|
|
11
11
|
*/
|
|
12
|
-
/**
|
|
13
|
-
|
|
12
|
+
/**
|
|
13
|
+
* Non-interactive budget for a connector `sync`/`index` step (one hour). A no-op mailcrawl `sync` of a
|
|
14
|
+
* 1,000-message INBOX measured 16 to 27 minutes because mailcrawl re-reads every message on each run
|
|
15
|
+
* (NomaDamas/mailcrawl#48), so 30 minutes did not hold even when nothing had changed.
|
|
16
|
+
*/
|
|
17
|
+
export declare const DEFAULT_CONNECTOR_SYNC_TIMEOUT_MS = 3600000;
|
|
14
18
|
/**
|
|
15
19
|
* Operator-facing hint appended to a sync/index diagnostic when the connector
|
|
16
20
|
* timeout killed the step. It names the override and explains why the next
|
|
@@ -58,6 +58,7 @@ export declare class CrawlerDatasourceSkill implements DatasourceSkill {
|
|
|
58
58
|
private syncSidecar;
|
|
59
59
|
/** Release the sidecar's database handles. Safe to call repeatedly; later use reopens them. */
|
|
60
60
|
close(): void;
|
|
61
|
+
/** One method: the sidecar's hybrid search (or BM25 without an embedder), with the CLI as the last fallback. */
|
|
61
62
|
retrievalMethods(): readonly RetrievalMethod[];
|
|
62
63
|
private cliMethod;
|
|
63
64
|
describeSources(): readonly SourceDescription[];
|
|
@@ -45,7 +45,7 @@ export interface CrawlerCliOptions {
|
|
|
45
45
|
*/
|
|
46
46
|
readonly timeoutMs?: number;
|
|
47
47
|
/**
|
|
48
|
-
* Spawn timeout for `sync` in milliseconds. Default
|
|
48
|
+
* Spawn timeout for `sync` in milliseconds. Default 3_600_000 (1 hour): a first
|
|
49
49
|
* full import over a real archive can take many minutes, and a timed-out sync
|
|
50
50
|
* restarts from scratch on the next refresh.
|
|
51
51
|
*/
|
|
@@ -13,7 +13,7 @@ export { GitHubConnector, type GitHubConnectorOptions, GitHubSkill, type GitHubS
|
|
|
13
13
|
export { HISTER_SKILL_TYPE, HisterClient, type HisterClientOptions, HisterSkill, type HisterSkillOptions, } from "./skills/hister/index.js";
|
|
14
14
|
export { LarkClient, type LarkClientOptions, LarkSkill, type LarkSkillOptions } from "./skills/lark/index.js";
|
|
15
15
|
export type { LazykatokFailureReason, LazykatokHit, LazykatokOptions, LazykatokSearchMode, LazykatokSearchOptions, LazykatokSearchResult, LazykatokSkillClient, LazykatokSkillOptions, } from "./skills/lazykatok/index.js";
|
|
16
|
-
export { LazykatokBm25Method, LazykatokClient,
|
|
16
|
+
export { LazykatokBm25Method, LazykatokClient, LazykatokHybridMethod, LazykatokSkill, } from "./skills/lazykatok/index.js";
|
|
17
17
|
export { MailExportConnector, type MailExportConnectorOptions, MailExportSkill, type MailExportSkillOptions, } from "./skills/mail-export/index.js";
|
|
18
18
|
export { MAILCRAWL_MODES, MailcrawlClient, type MailcrawlFailure, type MailcrawlFailureReason, type MailcrawlIndexInfo, MailcrawlMethod, type MailcrawlOptions, type MailcrawlSearchHit, type MailcrawlSearchMode, type MailcrawlSearchResult, MailcrawlSkill, type MailcrawlSyncInfo, type MailcrawlSyncResult, } from "./skills/mailcrawl/index.js";
|
|
19
19
|
export { NotcrawlClient, type NotcrawlOptions, NotionSkill, type NotionSkillOptions, } from "./skills/notion/index.js";
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
import type { RetrievalMethod, RetrievalMethodDescriptor, RetrievalOptions, RetrievalResult } from "../../retrieval/types.js";
|
|
7
7
|
import type { CrawlerDescriptor } from "./descriptors.js";
|
|
8
8
|
import type { CrawlerSidecar } from "./index.js";
|
|
9
|
-
export type SidecarMode = "bm25" | "
|
|
9
|
+
export type SidecarMode = "bm25" | "hybrid";
|
|
10
10
|
export interface SidecarMethodOptions {
|
|
11
11
|
readonly sidecar: CrawlerSidecar;
|
|
12
12
|
readonly descriptor: CrawlerDescriptor;
|
|
@@ -25,3 +25,10 @@ export declare class SidecarRetrievalMethod implements RetrievalMethod {
|
|
|
25
25
|
retrieve(query: string, options: RetrievalOptions): Promise<RetrievalResult[]>;
|
|
26
26
|
private toResult;
|
|
27
27
|
}
|
|
28
|
+
/**
|
|
29
|
+
* The one method a sidecar-backed crawler registers. The sidecar's hybrid search leads when semantic
|
|
30
|
+
* search is enabled and its BM25 search leads otherwise. When the leader throws, the sidecar's own BM25
|
|
31
|
+
* answers next and the crawler's CLI search last, so the datasource still searches when the embedder or
|
|
32
|
+
* the sidecar index is down. A leader that answers with no hits is final.
|
|
33
|
+
*/
|
|
34
|
+
export declare function sidecarFirstMethod(options: Omit<SidecarMethodOptions, "mode">, cli: RetrievalMethod): RetrievalMethod;
|
|
@@ -29,6 +29,10 @@ export declare class ClawGallerySkill implements DatasourceSkill {
|
|
|
29
29
|
describe(): DatasourceSkillDescriptor;
|
|
30
30
|
polling(): PollingMetadata;
|
|
31
31
|
index(options?: DatasourceIndexOptions): Promise<DatasourceIndexResult>;
|
|
32
|
+
/**
|
|
33
|
+
* Hybrid RRF-fuses every channel the index has, so it runs alone and keyword search stands in only
|
|
34
|
+
* when hybrid fails. A mode the operator pinned explicitly runs by itself with no fallback.
|
|
35
|
+
*/
|
|
32
36
|
retrievalMethods(): readonly RetrievalMethod[];
|
|
33
37
|
describeSources(): readonly SourceDescription[];
|
|
34
38
|
skillManifest(): DatasourceSkillManifest;
|
|
@@ -48,6 +48,11 @@ export declare class DiscrawlSkill implements DatasourceSkill {
|
|
|
48
48
|
describe(): DatasourceSkillDescriptor;
|
|
49
49
|
polling(): PollingMetadata;
|
|
50
50
|
index(options?: DatasourceIndexOptions): Promise<DatasourceIndexResult>;
|
|
51
|
+
/**
|
|
52
|
+
* One method per query. Hybrid is the default and already degrades to FTS inside the single
|
|
53
|
+
* `discrawl search` call when embeddings are unavailable, so FTS and semantic are not registered
|
|
54
|
+
* beside it; an operator who pins `defaultMode` to `fts` or `semantic` gets exactly that mode.
|
|
55
|
+
*/
|
|
51
56
|
retrievalMethods(): readonly RetrievalMethod[];
|
|
52
57
|
describeSources(): readonly SourceDescription[];
|
|
53
58
|
skillManifest(): DatasourceSkillManifest;
|
|
@@ -50,7 +50,11 @@ export interface DatasourceEmbeddingOptions {
|
|
|
50
50
|
/** MinSync binary, embedder and chunking shared with the local-file index; vault indexes run on it too. */
|
|
51
51
|
readonly minSync?: ObsidianMinSyncOptions;
|
|
52
52
|
}
|
|
53
|
-
/**
|
|
53
|
+
/** Whether the skill's backend exists on `platform`. Names with no platform restriction are always supported. */
|
|
54
|
+
export declare function datasourceSkillSupported(name: string, platform?: NodeJS.Platform): boolean;
|
|
55
|
+
/** Skill names this factory can build on `platform`. */
|
|
56
|
+
export declare function builtinDatasourceSkillNames(platform?: NodeJS.Platform): readonly string[];
|
|
57
|
+
/** Skill names this factory can build on the running platform. */
|
|
54
58
|
export declare const BUILTIN_DATASOURCE_SKILL_NAMES: readonly string[];
|
|
55
59
|
/**
|
|
56
60
|
* Build datasource skills from the trusted config section. `false` or
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
* the form `/kakao/<instance-id>/chunks/<chunk-id>`.
|
|
7
7
|
*/
|
|
8
8
|
export { LazykatokClient } from "./client.js";
|
|
9
|
-
export { LazykatokBm25Method, type LazykatokMethodOptions, type LazykatokSearchClient,
|
|
9
|
+
export { LazykatokBm25Method, LazykatokHybridMethod, type LazykatokMethodOptions, type LazykatokSearchClient, } from "./methods.js";
|
|
10
10
|
export { LazykatokSkill, type LazykatokSkillClient, type LazykatokSkillOptions } from "./skill.js";
|
|
11
11
|
export type { LazykatokChunkResult, LazykatokDoctorResult, LazykatokFailureReason, LazykatokHit, LazykatokIndexResult, LazykatokOptions, LazykatokSearchMode, LazykatokSearchOptions, LazykatokSearchResult, LazykatokSyncResult, } from "./types.js";
|
|
12
12
|
export { DEFAULT_LAZYKATOK_INDEX_TIMEOUT_MS, DEFAULT_LAZYKATOK_OPTIONS } from "./types.js";
|
|
@@ -27,12 +27,12 @@ export declare class LazykatokBm25Method implements RetrievalMethod {
|
|
|
27
27
|
retrieve(query: string, options: RetrievalOptions): Promise<RetrievalResult[]>;
|
|
28
28
|
}
|
|
29
29
|
/**
|
|
30
|
-
*
|
|
31
|
-
*
|
|
32
|
-
* controlled at the datasource/tag level.
|
|
33
|
-
*
|
|
30
|
+
* Hybrid retrieval over a KakaoTalk datasource via the external `lazykatok` CLI in hybrid mode
|
|
31
|
+
* (BM25 and semantic rankings fused by reciprocal rank fusion inside the CLI). Lazykatok does not
|
|
32
|
+
* expose source scopes; access is controlled at the datasource/tag level. Client failures reach the
|
|
33
|
+
* caller verbatim so the pipeline can fall back to {@link LazykatokBm25Method}.
|
|
34
34
|
*/
|
|
35
|
-
export declare class
|
|
35
|
+
export declare class LazykatokHybridMethod implements RetrievalMethod {
|
|
36
36
|
private readonly client;
|
|
37
37
|
private readonly instanceId;
|
|
38
38
|
private readonly tags;
|
|
@@ -38,6 +38,7 @@ export declare class LazykatokSkill implements DatasourceSkill {
|
|
|
38
38
|
index(options?: DatasourceIndexOptions): Promise<DatasourceIndexResult>;
|
|
39
39
|
/** Release the sidecar's database handles. Safe to call repeatedly; later use reopens them. */
|
|
40
40
|
close(): void;
|
|
41
|
+
/** One method: sidecar hybrid when a sidecar is configured, else the CLI's hybrid; BM25 is the fallback either way. */
|
|
41
42
|
retrievalMethods(): readonly RetrievalMethod[];
|
|
42
43
|
private syncSidecar;
|
|
43
44
|
describeSources(): readonly SourceDescription[];
|
|
@@ -23,7 +23,7 @@ export interface LazykatokOptions {
|
|
|
23
23
|
*/
|
|
24
24
|
readonly timeoutMs?: number;
|
|
25
25
|
/**
|
|
26
|
-
* Spawn timeout for `sync`/`index` in milliseconds. Default
|
|
26
|
+
* Spawn timeout for `sync`/`index` in milliseconds. Default 3_600_000 (1 hour):
|
|
27
27
|
* the first semantic index over a large archive was measured at ~11 minutes, and
|
|
28
28
|
* a timed-out build restarts from scratch on the next refresh.
|
|
29
29
|
*/
|
|
@@ -59,7 +59,7 @@ export declare const DEFAULT_LAZYKATOK_TIMEOUT_MS = 60000;
|
|
|
59
59
|
* the 60-second interactive default: a first semantic index over a large archive
|
|
60
60
|
* was measured at ~11 minutes.
|
|
61
61
|
*/
|
|
62
|
-
export declare const DEFAULT_LAZYKATOK_INDEX_TIMEOUT_MS =
|
|
62
|
+
export declare const DEFAULT_LAZYKATOK_INDEX_TIMEOUT_MS = 3600000;
|
|
63
63
|
/** The live macOS adapter `sync` names by default on darwin. */
|
|
64
64
|
export declare const DEFAULT_LAZYKATOK_SOURCE = "macos";
|
|
65
65
|
export declare const DEFAULT_LAZYKATOK_MAX_BUFFER_BYTES: number;
|
|
@@ -27,6 +27,7 @@ export declare class MailcrawlSkill implements DatasourceSkill {
|
|
|
27
27
|
describe(): DatasourceSkillDescriptor;
|
|
28
28
|
polling(): PollingMetadata;
|
|
29
29
|
index(options?: DatasourceIndexOptions): Promise<DatasourceIndexResult>;
|
|
30
|
+
/** Hybrid search first; BM25 only when mailcrawl cannot run hybrid (for example, no usable semantic index). */
|
|
30
31
|
retrievalMethods(): readonly RetrievalMethod[];
|
|
31
32
|
describeSources(): readonly SourceDescription[];
|
|
32
33
|
skillManifest(): DatasourceSkillManifest;
|
|
@@ -19,7 +19,7 @@ export interface MailcrawlOptions {
|
|
|
19
19
|
* `indexTimeoutMs`, because a 0.2.0 native index run is not interactive.
|
|
20
20
|
*/
|
|
21
21
|
readonly timeoutMs?: number;
|
|
22
|
-
/** Non-interactive budget for `sync`/`index`; defaults to
|
|
22
|
+
/** Non-interactive budget for `sync`/`index`; defaults to one hour. */
|
|
23
23
|
readonly indexTimeoutMs?: number;
|
|
24
24
|
readonly maxBufferBytes?: number;
|
|
25
25
|
readonly env?: Readonly<Record<string, string | undefined>>;
|
package/dist/dupey/cli.d.ts
CHANGED
|
@@ -38,3 +38,21 @@ export declare class DupeyCliError extends Error {
|
|
|
38
38
|
constructor(message: string);
|
|
39
39
|
}
|
|
40
40
|
export declare function scanWithDupey(dir: string, options?: DupeyCliOptions): Promise<DupeyScanResult>;
|
|
41
|
+
export type DupeyRelation = "exact" | "near" | "contains" | "different";
|
|
42
|
+
export type DupeyCompareResult = {
|
|
43
|
+
readonly relation: DupeyRelation;
|
|
44
|
+
readonly nearScore: number;
|
|
45
|
+
readonly jaccard: number;
|
|
46
|
+
readonly containmentAInB?: number;
|
|
47
|
+
readonly containmentBInA?: number;
|
|
48
|
+
}
|
|
49
|
+
/** dupey cannot extract text from one of the files (for example HTML or an image), so no family can form. */
|
|
50
|
+
| {
|
|
51
|
+
readonly relation: "unsupported";
|
|
52
|
+
};
|
|
53
|
+
/**
|
|
54
|
+
* Would `dupey scan` put these two files in one family? Classifies with the
|
|
55
|
+
* same default thresholds the scan uses, so the answer matches what a later
|
|
56
|
+
* scan of a directory holding both will report.
|
|
57
|
+
*/
|
|
58
|
+
export declare function compareWithDupey(a: string, b: string, options?: DupeyCliOptions): Promise<DupeyCompareResult>;
|
package/dist/index.d.ts
CHANGED
|
@@ -2,6 +2,7 @@ export { AutoRAGAgent, type AutoRAGAgentOptions, type AutoRAGRefreshComponentSta
|
|
|
2
2
|
export { type AutoRAGResultsDetails, reportSchema, type SearchDocumentDiagnostic, type SearchDocumentDiagnosticCode, type SearchDocumentDiagnosticSeverity, type SearchDocumentsResponse, type SearchDocumentsStreamEvent, type SearchDocumentWarning, } from "./agent/index.js";
|
|
3
3
|
export { buildSystemPrompt, type SystemPromptConfig } from "./agent/system-prompt.js";
|
|
4
4
|
export * from "./cloud/index.js";
|
|
5
|
+
export * from "./convert/index.js";
|
|
5
6
|
export { AutoRAGLite, type AutoRAGLiteOptions, buildAgentOptions, type CliConfig, createAutoRAGLite, type ResolveConfigInput, resolveConfig, resolveConfigReadOnly, writeConfigObject, writeDefaultConfig, } from "./core.js";
|
|
6
7
|
export * from "./datasource/index.js";
|
|
7
8
|
export * from "./dupey/index.js";
|