@tangle-network/agent-knowledge 6.0.0 → 6.1.1
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/CHANGELOG.md +17 -0
- package/README.md +1 -1
- package/dist/benchmarks/index.d.ts +2 -53
- package/dist/benchmarks/index.js +2 -49
- package/dist/benchmarks-CmW6iORW.js +2718 -0
- package/dist/benchmarks-CmW6iORW.js.map +1 -0
- package/dist/cli.d.ts +1 -1
- package/dist/cli.js +180 -274
- package/dist/cli.js.map +1 -1
- package/dist/ids-DRqPZ42_.js +15 -0
- package/dist/ids-DRqPZ42_.js.map +1 -0
- package/dist/index-CGBctbit.d.ts +857 -0
- package/dist/index-CGBctbit.d.ts.map +1 -0
- package/dist/index-CIW3G4s_.d.ts +680 -0
- package/dist/index-CIW3G4s_.d.ts.map +1 -0
- package/dist/index.d.ts +1671 -1868
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +5836 -6528
- package/dist/index.js.map +1 -1
- package/dist/inspect-D5iarJc2.js +1864 -0
- package/dist/inspect-D5iarJc2.js.map +1 -0
- package/dist/memory/index.d.ts +3 -8
- package/dist/memory/index.js +3 -81
- package/dist/memory-C6KPRhoU.js +4494 -0
- package/dist/memory-C6KPRhoU.js.map +1 -0
- package/dist/search-CP0QtBJZ.js +113 -0
- package/dist/search-CP0QtBJZ.js.map +1 -0
- package/dist/sources/index.d.ts +212 -205
- package/dist/sources/index.d.ts.map +1 -0
- package/dist/sources/index.js +614 -33
- package/dist/sources/index.js.map +1 -1
- package/dist/types-DcCCzreS.d.ts +175 -0
- package/dist/types-DcCCzreS.d.ts.map +1 -0
- package/dist/viz/index.d.ts +23 -22
- package/dist/viz/index.d.ts.map +1 -0
- package/dist/viz/index.js +134 -10
- package/dist/viz/index.js.map +1 -1
- package/package.json +22 -11
- package/dist/benchmarks/index.js.map +0 -1
- package/dist/chunk-46YPZHAX.js +0 -5443
- package/dist/chunk-46YPZHAX.js.map +0 -1
- package/dist/chunk-4PNXQ2NT.js +0 -147
- package/dist/chunk-4PNXQ2NT.js.map +0 -1
- package/dist/chunk-AKYJG2MR.js +0 -2183
- package/dist/chunk-AKYJG2MR.js.map +0 -1
- package/dist/chunk-DQ3PDMDP.js +0 -115
- package/dist/chunk-DQ3PDMDP.js.map +0 -1
- package/dist/chunk-MYFM6LKH.js +0 -551
- package/dist/chunk-MYFM6LKH.js.map +0 -1
- package/dist/chunk-PVCSESAF.js +0 -3153
- package/dist/chunk-PVCSESAF.js.map +0 -1
- package/dist/chunk-YMKHCTS2.js +0 -19
- package/dist/chunk-YMKHCTS2.js.map +0 -1
- package/dist/index-C--N5wQV.d.ts +0 -796
- package/dist/memory/index.js.map +0 -1
- package/dist/types-6x0OpfW6.d.ts +0 -173
- package/dist/types-BY-xLVw-.d.ts +0 -622
package/dist/memory/index.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
|
package/dist/types-6x0OpfW6.d.ts
DELETED
|
@@ -1,173 +0,0 @@
|
|
|
1
|
-
type KnowledgeId = string;
|
|
2
|
-
interface SourceAnchor {
|
|
3
|
-
id: string;
|
|
4
|
-
sourceId: string;
|
|
5
|
-
label?: string;
|
|
6
|
-
page?: number;
|
|
7
|
-
lineStart?: number;
|
|
8
|
-
lineEnd?: number;
|
|
9
|
-
charStart?: number;
|
|
10
|
-
charEnd?: number;
|
|
11
|
-
timestampMs?: number;
|
|
12
|
-
metadata?: Record<string, unknown>;
|
|
13
|
-
}
|
|
14
|
-
interface SourceRecord {
|
|
15
|
-
id: KnowledgeId;
|
|
16
|
-
uri: string;
|
|
17
|
-
title?: string;
|
|
18
|
-
mediaType?: string;
|
|
19
|
-
contentHash: string;
|
|
20
|
-
text?: string;
|
|
21
|
-
anchors?: SourceAnchor[];
|
|
22
|
-
/** ISO timestamp after which consumers should treat this source as stale. */
|
|
23
|
-
validUntil?: string;
|
|
24
|
-
/** ISO timestamp for the last successful source freshness verification. */
|
|
25
|
-
lastVerifiedAt?: string;
|
|
26
|
-
metadata?: Record<string, unknown>;
|
|
27
|
-
createdAt: string;
|
|
28
|
-
}
|
|
29
|
-
interface SourceRegistry {
|
|
30
|
-
generatedAt: string;
|
|
31
|
-
sources: SourceRecord[];
|
|
32
|
-
}
|
|
33
|
-
interface ClaimRef {
|
|
34
|
-
sourceId: string;
|
|
35
|
-
anchorId?: string;
|
|
36
|
-
quote?: string;
|
|
37
|
-
}
|
|
38
|
-
interface KnowledgeClaim {
|
|
39
|
-
id: KnowledgeId;
|
|
40
|
-
text: string;
|
|
41
|
-
refs: ClaimRef[];
|
|
42
|
-
confidence?: number;
|
|
43
|
-
status?: 'draft' | 'active' | 'superseded' | 'rejected';
|
|
44
|
-
metadata?: Record<string, unknown>;
|
|
45
|
-
}
|
|
46
|
-
interface KnowledgeRelation {
|
|
47
|
-
sourceId: KnowledgeId;
|
|
48
|
-
targetId: KnowledgeId;
|
|
49
|
-
predicate: string;
|
|
50
|
-
weight?: number;
|
|
51
|
-
metadata?: Record<string, unknown>;
|
|
52
|
-
}
|
|
53
|
-
interface KnowledgeUnit {
|
|
54
|
-
id: KnowledgeId;
|
|
55
|
-
title: string;
|
|
56
|
-
text: string;
|
|
57
|
-
claims?: KnowledgeClaim[];
|
|
58
|
-
relations?: KnowledgeRelation[];
|
|
59
|
-
sourceIds?: string[];
|
|
60
|
-
tags?: string[];
|
|
61
|
-
metadata?: Record<string, unknown>;
|
|
62
|
-
updatedAt?: string;
|
|
63
|
-
}
|
|
64
|
-
interface KnowledgePage {
|
|
65
|
-
id: KnowledgeId;
|
|
66
|
-
path: string;
|
|
67
|
-
title: string;
|
|
68
|
-
text: string;
|
|
69
|
-
frontmatter: Record<string, unknown>;
|
|
70
|
-
sourceIds: string[];
|
|
71
|
-
tags: string[];
|
|
72
|
-
outLinks: string[];
|
|
73
|
-
}
|
|
74
|
-
interface KnowledgeGraphNode {
|
|
75
|
-
id: KnowledgeId;
|
|
76
|
-
title: string;
|
|
77
|
-
path: string;
|
|
78
|
-
tags: string[];
|
|
79
|
-
sourceIds: string[];
|
|
80
|
-
outDegree: number;
|
|
81
|
-
inDegree: number;
|
|
82
|
-
}
|
|
83
|
-
interface KnowledgeGraphEdge {
|
|
84
|
-
source: KnowledgeId;
|
|
85
|
-
target: KnowledgeId;
|
|
86
|
-
weight: number;
|
|
87
|
-
reasons: string[];
|
|
88
|
-
}
|
|
89
|
-
interface KnowledgeGraph {
|
|
90
|
-
nodes: KnowledgeGraphNode[];
|
|
91
|
-
edges: KnowledgeGraphEdge[];
|
|
92
|
-
}
|
|
93
|
-
interface KnowledgeIndex {
|
|
94
|
-
root: string;
|
|
95
|
-
generatedAt: string;
|
|
96
|
-
sources: SourceRecord[];
|
|
97
|
-
pages: KnowledgePage[];
|
|
98
|
-
graph: KnowledgeGraph;
|
|
99
|
-
}
|
|
100
|
-
interface KnowledgeSearchResult {
|
|
101
|
-
page: KnowledgePage;
|
|
102
|
-
/**
|
|
103
|
-
* Raw reciprocal rank fusion score. Mathematically meaningful for ordering
|
|
104
|
-
* but not on a [0, 1] confidence scale — typical absolute values are in the
|
|
105
|
-
* 0.01–0.05 range. Equal to `rrfScore`; preserved as `score` for backward
|
|
106
|
-
* compatibility with consumers built against earlier releases.
|
|
107
|
-
*/
|
|
108
|
-
score: number;
|
|
109
|
-
/** Alias of `score` — the raw RRF value. Use this when intent matters. */
|
|
110
|
-
rrfScore: number;
|
|
111
|
-
/**
|
|
112
|
-
* Score linearly normalized to [0, 1] relative to the top hit *in this
|
|
113
|
-
* result set*. The top hit is always 1 (when present); subsequent hits are
|
|
114
|
-
* `score / topScore`. Designed to match human intuition for "how confident
|
|
115
|
-
* is this match" — safe to compare against fixed thresholds. Note: this is
|
|
116
|
-
* a within-set ranking, not a cross-query absolute confidence.
|
|
117
|
-
*/
|
|
118
|
-
normalizedScore: number;
|
|
119
|
-
rank: number;
|
|
120
|
-
snippet: string;
|
|
121
|
-
reasons: string[];
|
|
122
|
-
}
|
|
123
|
-
interface KnowledgeLintFinding {
|
|
124
|
-
type: 'broken-link' | 'orphan' | 'no-outlinks' | 'uncited-claim' | 'missing-source' | 'duplicate-title' | 'duplicate-page-id' | 'duplicate-source-hash' | 'missing-frontmatter';
|
|
125
|
-
severity: 'info' | 'warning' | 'error';
|
|
126
|
-
page?: string;
|
|
127
|
-
message: string;
|
|
128
|
-
metadata?: Record<string, unknown>;
|
|
129
|
-
}
|
|
130
|
-
interface KnowledgePolicy {
|
|
131
|
-
id: string;
|
|
132
|
-
description?: string;
|
|
133
|
-
requiredCitationRate?: number;
|
|
134
|
-
allowedPathPrefixes?: string[];
|
|
135
|
-
metadata?: Record<string, unknown>;
|
|
136
|
-
}
|
|
137
|
-
interface KnowledgeBaseCandidate {
|
|
138
|
-
id: KnowledgeId;
|
|
139
|
-
units: KnowledgeUnit[];
|
|
140
|
-
retrievalPolicy?: string;
|
|
141
|
-
synthesisPolicy?: string;
|
|
142
|
-
questionPolicy?: string;
|
|
143
|
-
updatePolicy?: string;
|
|
144
|
-
metadata?: Record<string, unknown>;
|
|
145
|
-
}
|
|
146
|
-
interface KnowledgeWriteBlock {
|
|
147
|
-
path: string;
|
|
148
|
-
content: string;
|
|
149
|
-
}
|
|
150
|
-
interface KnowledgeWriteParseResult {
|
|
151
|
-
blocks: KnowledgeWriteBlock[];
|
|
152
|
-
warnings: string[];
|
|
153
|
-
}
|
|
154
|
-
type KnowledgeEventType = 'source.added' | 'proposal.applied' | 'index.built' | 'lint.run' | 'research.iteration' | 'optimization.run' | 'release.promoted' | 'release.rejected';
|
|
155
|
-
interface KnowledgeEvent {
|
|
156
|
-
id: string;
|
|
157
|
-
type: KnowledgeEventType;
|
|
158
|
-
createdAt: string;
|
|
159
|
-
actor?: string;
|
|
160
|
-
target?: string;
|
|
161
|
-
metadata?: Record<string, unknown>;
|
|
162
|
-
}
|
|
163
|
-
interface KnowledgeRelease {
|
|
164
|
-
id: string;
|
|
165
|
-
candidateId: string;
|
|
166
|
-
createdAt: string;
|
|
167
|
-
promoted: boolean;
|
|
168
|
-
scorecard?: unknown;
|
|
169
|
-
runRecordIds?: string[];
|
|
170
|
-
metadata?: Record<string, unknown>;
|
|
171
|
-
}
|
|
172
|
-
|
|
173
|
-
export type { ClaimRef as C, KnowledgeGraphEdge as K, SourceRecord as S, KnowledgeGraphNode as a, KnowledgeGraph as b, KnowledgeIndex as c, KnowledgeSearchResult as d, SourceRegistry as e, KnowledgeEvent as f, KnowledgeLintFinding as g, KnowledgeEventType as h, KnowledgePage as i, KnowledgeWriteBlock as j, KnowledgeClaim as k, KnowledgeRelease as l, KnowledgeWriteParseResult as m, KnowledgeBaseCandidate as n, KnowledgeId as o, KnowledgePolicy as p, KnowledgeRelation as q, KnowledgeUnit as r, SourceAnchor as s };
|