@tangle-network/agent-knowledge 6.1.10 → 6.2.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/AGENTS.md +9 -0
- package/CHANGELOG.md +19 -0
- package/README.md +1 -1
- package/dist/benchmarks/index.d.ts +1 -1
- package/dist/cli.js +1 -1
- package/dist/{index-CIW3G4s_.d.ts → index-3z3lFJnE.d.ts} +2 -2
- package/dist/{index-CIW3G4s_.d.ts.map → index-3z3lFJnE.d.ts.map} +1 -1
- package/dist/{index-CGBctbit.d.ts → index-DHebFLgU.d.ts} +3 -3
- package/dist/{index-CGBctbit.d.ts.map → index-DHebFLgU.d.ts.map} +1 -1
- package/dist/index.d.ts +351 -43
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +235 -190
- package/dist/index.js.map +1 -1
- package/dist/{inspect-DAXpFyrs.js → inspect-LUMkas6A.js} +681 -12
- package/dist/inspect-LUMkas6A.js.map +1 -0
- package/dist/memory/index.d.ts +2 -2
- package/dist/types-Cd57BPRt.d.ts +291 -0
- package/dist/{types-DcCCzreS.d.ts.map → types-Cd57BPRt.d.ts.map} +1 -1
- package/dist/viz/index.d.ts +1 -1
- package/docs/architecture.md +30 -0
- package/package.json +2 -2
- package/dist/inspect-DAXpFyrs.js.map +0 -1
- package/dist/types-DcCCzreS.d.ts +0 -175
package/dist/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { $ as RetrievalConfig, A as KnowledgeBenchmarkResponder, At as AgentMemoryScope, B as KnowledgeMemoryEvent, Bt as RetrievalHoldoutSessionState, C as KnowledgeBenchmarkArtifact, Ct as createInMemoryBenchmarkAdapter, D as KnowledgeBenchmarkEvaluation, Dt as AgentMemoryContext, E as KnowledgeBenchmarkDistribution, Et as AgentMemoryBranchIsolation, F as KnowledgeBenchmarkSplit, Ft as RetrievalHoldoutCallContext, G as MemoryAdapterBenchmarkCandidate, H as KnowledgeRetrievalBenchmarkCase, I as KnowledgeBenchmarkTaskKind, It as RetrievalHoldoutConfig, J as RunKnowledgeBenchmarkSuiteResult, K as MemoryAdapterBenchmarkRankingRow, L as KnowledgeClaimMatcher, Lt as RetrievalHoldoutEligibleItem, M as KnowledgeBenchmarkSliceSummary, Mt as AgentMemoryWriteInput, N as KnowledgeBenchmarkSource, Nt as AgentMemoryWriteResult, O as KnowledgeBenchmarkFamily, Ot as AgentMemoryHit, P as KnowledgeBenchmarkSpec, Pt as RetrievalHoldoutBypassReason, Q as PartitionRetrievalScenariosOptions, R as KnowledgeMemoryBenchmarkCase, Rt as RetrievalHoldoutEvent, S as KnowledgeAnswerBenchmarkTaskKind, St as acquireAgentMemoryRunLease, T as KnowledgeBenchmarkCaseBase, Tt as AgentMemoryAdapter, U as KnowledgeRetrievalBenchmarkQrel, V as KnowledgeMemoryFactMatcher, W as KnowledgeRetrievalBenchmarkQuery, X as RunMemoryAdapterBenchmarkResult, Y as RunMemoryAdapterBenchmarkOptions, Z as BuildRetrievalEvalDispatchOptions, _ as buildIndustryRagBenchmarkSmokeCases, _t as scoreRetrievalArtifact, a as runKnowledgeBenchmarkSuite, at as RetrievalGoldTarget, b as BuildRetrievalBenchmarkCasesFromQrelsOptions, bt as AgentMemoryRunLease, c as buildRetrievalBenchmarkCasesFromQrels, ct as RetrievalRecallJudgeOptions, d as summarizeKnowledgeBenchmarkCampaign, dt as RetrievedSourceSpan, et as RetrievalEvalArtifact, f as runMemoryAdapterBenchmark, ft as buildRetrievalEvalDispatch, g as buildIndustryMemoryBenchmarkSmokeCases, gt as retrievalRecallJudge, h as buildFirstPartyMemoryLifecycleBenchmarkCases, ht as retrievalConfigSurface, i as renderKnowledgeBenchmarkReportMarkdown, it as RetrievalEvalScenario, j as KnowledgeBenchmarkScenario, jt as AgentMemorySearchOptions, k as KnowledgeBenchmarkReport, kt as AgentMemoryKind, l as parseKnowledgeBenchmarkJsonl, lt as RetrievalScenarioPartitions, m as INDUSTRY_RAG_BENCHMARKS, mt as retrievalConfigFromSurface, n as buildKnowledgeBenchmarkScenarios, nt as RetrievalEvalRetrieverInput, o as scoreKnowledgeBenchmarkArtifact, ot as RetrievalMetricSummary, p as INDUSTRY_MEMORY_BENCHMARKS, pt as partitionRetrievalScenarios, q as RunKnowledgeBenchmarkSuiteOptions, r as knowledgeBenchmarkJudge, rt as RetrievalEvalRetrieverResult, s as scoreMemoryBenchmarkArtifact, st as RetrievalMetricWeights, t as isKnowledgeMemoryBenchmarkCase, tt as RetrievalEvalRetriever, u as parseKnowledgeBenchmarkQrels, ut as RetrievedKnowledgeHit, v as respondToIndustryMemoryBenchmarkSmokeCase, vt as AgentMemoryAcquireRunLease, w as KnowledgeBenchmarkCase, wt as createNoopMemoryBenchmarkAdapter, x as KnowledgeAnswerBenchmarkCase, xt as OwnedAgentMemoryRunLease, y as respondToIndustryRagBenchmarkSmokeCase, yt as AgentMemoryControllerMode, z as KnowledgeMemoryBenchmarkTaskKind, zt as RetrievalHoldoutResult } from "./index-
|
|
3
|
-
import { $ as buildAgentMemorySequenceScenarios, A as AgentMemoryFinalPair, At as defaultGetMemoryContext, B as applySessionStickyRetrievalHoldout, C as runBoundedMemoryLifecycle, Ct as AgentMemoryJournalEntry, D as AgentMemoryActivationDriver, Dt as ForkAgentMemoryBranchSnapshotOptions, E as AgentMemoryActivation, Et as CreateAgentMemoryBranchOptions, F as RunAgentMemoryImprovementResult, Ft as SerializedCandidateCodec, G as toOffPolicyTrajectory, H as emitRetrievalHoldoutBypass, I as RetrievalHoldoutOffPolicyOptions, It as jsonCandidateCodec, J as GraphitiToolNames, K as GraphitiMcpClientLike, L as RetrievalHoldoutOffPolicyResult, Lt as jsonObjectCandidateCodec, M as AgentMemoryPromotionDecision, Mt as RunSerializedKnowledgeOptimizationOptions, N as MemoryConfigScenario, Nt as RunSerializedKnowledgeOptimizationResult, O as AgentMemoryDimensionComparison, Ot as createAgentMemoryBranch, P as RunAgentMemoryImprovementOptions, Pt as SerializedCandidate, Q as agentMemorySequenceJudge, R as RetrievalHoldoutSessionSummary, Rt as runSerializedKnowledgeOptimization, S as resolveMemoryCleanupTimeoutMs, St as AgentMemoryBranchSnapshot, T as runAgentMemoryImprovement, Tt as AgentMemoryVisibility, U as resetRetrievalHoldoutRegistry, V as deterministicRng, W as retrievalHoldoutConfigHash, X as graphitiMemoryAdapterIdentity, Y as createGraphitiMemoryAdapter, Z as runAgentMemoryExperiment, _ as AgentMemoryLifecycleTimeoutError, _t as BuildAgentMemorySequencesFromBenchmarkCasesOptions, a as AgentMemoryScopeSchema, at as AgentMemoryExecutionPaidCallInput, b as createMemoryExecutionPool, bt as AgentMemoryBranch, c as createNeo4jAgentMemoryAdapter, ct as AgentMemoryExperimentCandidate, d as Mem0HostedMemoryAdapterOptions, dt as AgentMemorySequence, et as buildAgentMemorySequencesFromBenchmarkCases, f as Mem0MemoryAdapterOptions, ft as AgentMemorySequenceArtifact, g as mem0MemoryAdapterIdentity, gt as AgentMemorySequenceStep, h as createMem0MemoryAdapter, ht as AgentMemorySequenceScenario, i as AgentMemoryKindSchema, it as AgentMemoryExecutionCostReceipt, j as AgentMemoryImprovementRunLease, jt as renderMemoryContext, k as AgentMemoryFinalEvaluation, kt as forkAgentMemoryBranchSnapshot, l as Mem0ClientMode, lt as AgentMemoryExperimentRankingRow, m as Mem0OssMemoryAdapterOptions, mt as AgentMemorySequenceProbeResult, n as memoryWriteResultToSourceRecord, nt as AgentMemoryExecutionContext, o as AgentMemoryWriteInputSchema, ot as AgentMemoryExecutionPaidCallResult, p as Mem0OssClient, pt as AgentMemorySequenceProbe, q as GraphitiMemoryAdapterOptions, r as AgentMemoryHitSchema, rt as AgentMemoryExecutionCostMeter, s as Neo4jAgentMemoryAdapterOptions, st as AgentMemoryExecutionStep, t as memoryHitToSourceRecord, tt as AgentMemoryAttemptEvent, u as Mem0HostedClient, ut as AgentMemoryExperimentRunLease, v as AgentMemoryLifecycleUnsafeError, vt as RunAgentMemoryExperimentOptions, w as sleepForMemoryRecovery, wt as AgentMemorySharingPolicy, x as memoryRecoveryDelayMs, xt as AgentMemoryBranchLifetime, y as DEFAULT_MEMORY_CLEANUP_TIMEOUT_MS, yt as RunAgentMemoryExperimentResult, z as applyRetrievalHoldout, zt as scenarioContentFingerprint } from "./index-
|
|
1
|
+
import { C as ResearchClaimEvidence, D as SourceRecord, E as SourceAnchor, O as SourceRegistry, S as KnowledgeWriteParseResult, T as ResearchClaimRecord, _ as KnowledgeRelation, a as KnowledgeBaseCandidate, b as KnowledgeUnit, c as KnowledgeEventType, d as KnowledgeGraphNode, f as KnowledgeId, g as KnowledgePolicy, h as KnowledgePage, i as KNOWLEDGE_EVENT_TYPES, k as TrackedClaim, l as KnowledgeGraph, m as KnowledgeLintFinding, n as DeepQuestion, o as KnowledgeClaim, p as KnowledgeIndex, r as DeepQuestionKind, s as KnowledgeEvent, t as ClaimRef, u as KnowledgeGraphEdge, v as KnowledgeRelease, w as ResearchClaimLedger, x as KnowledgeWriteBlock, y as KnowledgeSearchResult } from "./types-Cd57BPRt.js";
|
|
2
|
+
import { $ as RetrievalConfig, A as KnowledgeBenchmarkResponder, At as AgentMemoryScope, B as KnowledgeMemoryEvent, Bt as RetrievalHoldoutSessionState, C as KnowledgeBenchmarkArtifact, Ct as createInMemoryBenchmarkAdapter, D as KnowledgeBenchmarkEvaluation, Dt as AgentMemoryContext, E as KnowledgeBenchmarkDistribution, Et as AgentMemoryBranchIsolation, F as KnowledgeBenchmarkSplit, Ft as RetrievalHoldoutCallContext, G as MemoryAdapterBenchmarkCandidate, H as KnowledgeRetrievalBenchmarkCase, I as KnowledgeBenchmarkTaskKind, It as RetrievalHoldoutConfig, J as RunKnowledgeBenchmarkSuiteResult, K as MemoryAdapterBenchmarkRankingRow, L as KnowledgeClaimMatcher, Lt as RetrievalHoldoutEligibleItem, M as KnowledgeBenchmarkSliceSummary, Mt as AgentMemoryWriteInput, N as KnowledgeBenchmarkSource, Nt as AgentMemoryWriteResult, O as KnowledgeBenchmarkFamily, Ot as AgentMemoryHit, P as KnowledgeBenchmarkSpec, Pt as RetrievalHoldoutBypassReason, Q as PartitionRetrievalScenariosOptions, R as KnowledgeMemoryBenchmarkCase, Rt as RetrievalHoldoutEvent, S as KnowledgeAnswerBenchmarkTaskKind, St as acquireAgentMemoryRunLease, T as KnowledgeBenchmarkCaseBase, Tt as AgentMemoryAdapter, U as KnowledgeRetrievalBenchmarkQrel, V as KnowledgeMemoryFactMatcher, W as KnowledgeRetrievalBenchmarkQuery, X as RunMemoryAdapterBenchmarkResult, Y as RunMemoryAdapterBenchmarkOptions, Z as BuildRetrievalEvalDispatchOptions, _ as buildIndustryRagBenchmarkSmokeCases, _t as scoreRetrievalArtifact, a as runKnowledgeBenchmarkSuite, at as RetrievalGoldTarget, b as BuildRetrievalBenchmarkCasesFromQrelsOptions, bt as AgentMemoryRunLease, c as buildRetrievalBenchmarkCasesFromQrels, ct as RetrievalRecallJudgeOptions, d as summarizeKnowledgeBenchmarkCampaign, dt as RetrievedSourceSpan, et as RetrievalEvalArtifact, f as runMemoryAdapterBenchmark, ft as buildRetrievalEvalDispatch, g as buildIndustryMemoryBenchmarkSmokeCases, gt as retrievalRecallJudge, h as buildFirstPartyMemoryLifecycleBenchmarkCases, ht as retrievalConfigSurface, i as renderKnowledgeBenchmarkReportMarkdown, it as RetrievalEvalScenario, j as KnowledgeBenchmarkScenario, jt as AgentMemorySearchOptions, k as KnowledgeBenchmarkReport, kt as AgentMemoryKind, l as parseKnowledgeBenchmarkJsonl, lt as RetrievalScenarioPartitions, m as INDUSTRY_RAG_BENCHMARKS, mt as retrievalConfigFromSurface, n as buildKnowledgeBenchmarkScenarios, nt as RetrievalEvalRetrieverInput, o as scoreKnowledgeBenchmarkArtifact, ot as RetrievalMetricSummary, p as INDUSTRY_MEMORY_BENCHMARKS, pt as partitionRetrievalScenarios, q as RunKnowledgeBenchmarkSuiteOptions, r as knowledgeBenchmarkJudge, rt as RetrievalEvalRetrieverResult, s as scoreMemoryBenchmarkArtifact, st as RetrievalMetricWeights, t as isKnowledgeMemoryBenchmarkCase, tt as RetrievalEvalRetriever, u as parseKnowledgeBenchmarkQrels, ut as RetrievedKnowledgeHit, v as respondToIndustryMemoryBenchmarkSmokeCase, vt as AgentMemoryAcquireRunLease, w as KnowledgeBenchmarkCase, wt as createNoopMemoryBenchmarkAdapter, x as KnowledgeAnswerBenchmarkCase, xt as OwnedAgentMemoryRunLease, y as respondToIndustryRagBenchmarkSmokeCase, yt as AgentMemoryControllerMode, z as KnowledgeMemoryBenchmarkTaskKind, zt as RetrievalHoldoutResult } from "./index-3z3lFJnE.js";
|
|
3
|
+
import { $ as buildAgentMemorySequenceScenarios, A as AgentMemoryFinalPair, At as defaultGetMemoryContext, B as applySessionStickyRetrievalHoldout, C as runBoundedMemoryLifecycle, Ct as AgentMemoryJournalEntry, D as AgentMemoryActivationDriver, Dt as ForkAgentMemoryBranchSnapshotOptions, E as AgentMemoryActivation, Et as CreateAgentMemoryBranchOptions, F as RunAgentMemoryImprovementResult, Ft as SerializedCandidateCodec, G as toOffPolicyTrajectory, H as emitRetrievalHoldoutBypass, I as RetrievalHoldoutOffPolicyOptions, It as jsonCandidateCodec, J as GraphitiToolNames, K as GraphitiMcpClientLike, L as RetrievalHoldoutOffPolicyResult, Lt as jsonObjectCandidateCodec, M as AgentMemoryPromotionDecision, Mt as RunSerializedKnowledgeOptimizationOptions, N as MemoryConfigScenario, Nt as RunSerializedKnowledgeOptimizationResult, O as AgentMemoryDimensionComparison, Ot as createAgentMemoryBranch, P as RunAgentMemoryImprovementOptions, Pt as SerializedCandidate, Q as agentMemorySequenceJudge, R as RetrievalHoldoutSessionSummary, Rt as runSerializedKnowledgeOptimization, S as resolveMemoryCleanupTimeoutMs, St as AgentMemoryBranchSnapshot, T as runAgentMemoryImprovement, Tt as AgentMemoryVisibility, U as resetRetrievalHoldoutRegistry, V as deterministicRng, W as retrievalHoldoutConfigHash, X as graphitiMemoryAdapterIdentity, Y as createGraphitiMemoryAdapter, Z as runAgentMemoryExperiment, _ as AgentMemoryLifecycleTimeoutError, _t as BuildAgentMemorySequencesFromBenchmarkCasesOptions, a as AgentMemoryScopeSchema, at as AgentMemoryExecutionPaidCallInput, b as createMemoryExecutionPool, bt as AgentMemoryBranch, c as createNeo4jAgentMemoryAdapter, ct as AgentMemoryExperimentCandidate, d as Mem0HostedMemoryAdapterOptions, dt as AgentMemorySequence, et as buildAgentMemorySequencesFromBenchmarkCases, f as Mem0MemoryAdapterOptions, ft as AgentMemorySequenceArtifact, g as mem0MemoryAdapterIdentity, gt as AgentMemorySequenceStep, h as createMem0MemoryAdapter, ht as AgentMemorySequenceScenario, i as AgentMemoryKindSchema, it as AgentMemoryExecutionCostReceipt, j as AgentMemoryImprovementRunLease, jt as renderMemoryContext, k as AgentMemoryFinalEvaluation, kt as forkAgentMemoryBranchSnapshot, l as Mem0ClientMode, lt as AgentMemoryExperimentRankingRow, m as Mem0OssMemoryAdapterOptions, mt as AgentMemorySequenceProbeResult, n as memoryWriteResultToSourceRecord, nt as AgentMemoryExecutionContext, o as AgentMemoryWriteInputSchema, ot as AgentMemoryExecutionPaidCallResult, p as Mem0OssClient, pt as AgentMemorySequenceProbe, q as GraphitiMemoryAdapterOptions, r as AgentMemoryHitSchema, rt as AgentMemoryExecutionCostMeter, s as Neo4jAgentMemoryAdapterOptions, st as AgentMemoryExecutionStep, t as memoryHitToSourceRecord, tt as AgentMemoryAttemptEvent, u as Mem0HostedClient, ut as AgentMemoryExperimentRunLease, v as AgentMemoryLifecycleUnsafeError, vt as RunAgentMemoryExperimentOptions, w as sleepForMemoryRecovery, wt as AgentMemorySharingPolicy, x as memoryRecoveryDelayMs, xt as AgentMemoryBranchLifetime, y as DEFAULT_MEMORY_CLEANUP_TIMEOUT_MS, yt as RunAgentMemoryExperimentResult, z as applyRetrievalHoldout, zt as scenarioContentFingerprint } from "./index-DHebFLgU.js";
|
|
4
4
|
import { CornellLiiSelector, CornellLiiSourceOptions, FetchOpts, FragmentProvenance, IRS_DIMENSION_HINTS, IrsPublicationsSourceOptions, KnowledgeFragment, KnowledgeSource, MAX_RESPONSE_BYTES, MIN_REQUEST_GAP_MS, POLITE_USER_AGENT, PoliteFetchOptions, PoliteFetchResult, StateSosEntity, StateSosSourceConfig, __resetHttpThrottle, createCornellLiiSource, createIrsPublicationsSource, createStateSosSource, extractLinks, firstMatch, htmlToText, innerHtmlById, looksLikeBlockPage, politeFetch } from "./sources/index.js";
|
|
5
5
|
import { AgentCandidateJsonValue, AgentCandidateKnowledgeRef, AgentImprovementActivation, AgentImprovementActivationResult } from "@tangle-network/agent-interface";
|
|
6
6
|
import { AnalystFinding, AnalystSeverity, ControlEvalResult, ControlRuntimeConfig, DataAcquisitionPlan, DatasetScenario, GateDecision, KnowledgeAcquisitionMode, KnowledgeBundle, KnowledgeFreshness, KnowledgeImportance, KnowledgeReadinessReport, KnowledgeRequirement, KnowledgeRequirementCategory, KnowledgeSensitivity, ReleaseConfidenceScorecard, ReleaseTraceEvidence, RunRecord, UserQuestion } from "@tangle-network/agent-eval";
|
|
@@ -238,11 +238,21 @@ interface DriverResearchContext {
|
|
|
238
238
|
* open. Only invoked when `driverResearches` is true.
|
|
239
239
|
* - `foldGaps` — turn the remaining gaps into a steer string for the worker's
|
|
240
240
|
* next prompt. Defaults to a compact bulleted list when omitted.
|
|
241
|
+
* - `checkpoint` — write whatever state the driver accumulated to durable
|
|
242
|
+
* storage. Called at the end of every round, after `foldGaps`, so state that
|
|
243
|
+
* a synchronous hook produced is on disk before the next round can crash.
|
|
244
|
+
* - `prepareFold` — durably announce the next synchronous fold before it runs,
|
|
245
|
+
* so a crash between question generation and `checkpoint` can be recovered.
|
|
246
|
+
* - `commitSources` — confirm source records are durable after verification;
|
|
247
|
+
* drivers with pending evidence must not count it before this callback.
|
|
241
248
|
*/
|
|
242
249
|
interface ResearchDriver {
|
|
243
250
|
verifySource(source: ResearchSourceProposal, ctx: SourceVerificationContext): Promise<SourceVerdict> | SourceVerdict;
|
|
244
251
|
research?(ctx: DriverResearchContext): Promise<ResearchContribution> | ResearchContribution;
|
|
245
252
|
foldGaps?(gaps: KnowledgeGap[]): string;
|
|
253
|
+
prepareFold?(): Promise<void> | void;
|
|
254
|
+
commitSources?(sourceUris: readonly string[]): Promise<void> | void;
|
|
255
|
+
checkpoint?(): Promise<void> | void;
|
|
246
256
|
}
|
|
247
257
|
type SourceVerdict = {
|
|
248
258
|
accept: true;
|
|
@@ -1612,6 +1622,105 @@ interface WorkerClaimDecorationOptions {
|
|
|
1612
1622
|
*/
|
|
1613
1623
|
declare function createClaimDecorator(options?: WorkerClaimDecorationOptions): (source: ResearchSourceProposal, goal: string) => Promise<ResearchSourceProposal>;
|
|
1614
1624
|
//#endregion
|
|
1625
|
+
//#region src/claim-ledger.d.ts
|
|
1626
|
+
/**
|
|
1627
|
+
* Claim identity = sha256 of the normalized claim text, so the same assertion
|
|
1628
|
+
* discovered independently by two workers is ONE claim with two supporting
|
|
1629
|
+
* sources rather than two claims with one each — which is the difference
|
|
1630
|
+
* between corroborated and unsupported.
|
|
1631
|
+
*/
|
|
1632
|
+
declare function claimId(text: string): string;
|
|
1633
|
+
/** Stable identity for one extracted claim/source/contradiction observation. */
|
|
1634
|
+
declare function claimEvidenceId(claim: Pick<ResearchClaimEvidence, 'claimId' | 'sourceUri' | 'contradictsClaimId'>): string;
|
|
1635
|
+
/** Case-, whitespace-, and stylistic-punctuation-insensitive claim identity form. */
|
|
1636
|
+
declare function normalizeClaimText(text: string): string;
|
|
1637
|
+
/**
|
|
1638
|
+
* The canonical host a source uri counts as, which is what makes two sources
|
|
1639
|
+
* INDEPENDENT: corroboration is "distinct hosts", so this function is the rule
|
|
1640
|
+
* that decides whether a claim is confirmed or merely repeated. Exported so a
|
|
1641
|
+
* consumer building a `ResearchClaimRecord` cannot answer it a different way — a
|
|
1642
|
+
* consumer that counted raw uris would report two pages of one site as
|
|
1643
|
+
* independent confirmation.
|
|
1644
|
+
*/
|
|
1645
|
+
declare function claimSourceHost(uri: string): string;
|
|
1646
|
+
/** Stable identity for one deep question. */
|
|
1647
|
+
declare function deepQuestionId(kind: DeepQuestion['kind'], text: string): string;
|
|
1648
|
+
/**
|
|
1649
|
+
* Refuse a claim record whose identity or source count disagrees with its evidence.
|
|
1650
|
+
*
|
|
1651
|
+
* `supportingHosts` is used as the independent-source count, so accepting hosts
|
|
1652
|
+
* that cannot be derived from `supportingUris` would let a malformed record
|
|
1653
|
+
* manufacture corroboration. Canonical ordering also makes equal records have
|
|
1654
|
+
* equal bytes regardless of which process assembled them.
|
|
1655
|
+
*/
|
|
1656
|
+
declare function assertTrackedClaimIntegrity(claim: ResearchClaimRecord): void;
|
|
1657
|
+
/** Refuse a deep question whose stable identity or set fields are malformed. */
|
|
1658
|
+
declare function assertDeepQuestionIntegrity(question: DeepQuestion): void;
|
|
1659
|
+
/** Refuse an extracted observation whose identity or content is malformed. */
|
|
1660
|
+
declare function assertResearchClaimEvidenceIntegrity(evidence: ResearchClaimEvidence): void;
|
|
1661
|
+
/** Refuse a ledger that is not one canonical, internally consistent record. */
|
|
1662
|
+
declare function assertResearchClaimLedgerIntegrity(ledger: ResearchClaimLedger): void;
|
|
1663
|
+
/** A ledger with nothing in it yet. */
|
|
1664
|
+
declare function emptyClaimLedger(id: string, goal?: string): ResearchClaimLedger;
|
|
1665
|
+
/**
|
|
1666
|
+
* Turn only evidence backed by a confirmed source registration into support.
|
|
1667
|
+
*
|
|
1668
|
+
* This is a monotone closure: it never removes claims or evidence, and running
|
|
1669
|
+
* it twice is a no-op. Keeping it in the ledger algebra means a source-confirming
|
|
1670
|
+
* writer and an evidence-producing writer can arrive in either order.
|
|
1671
|
+
*/
|
|
1672
|
+
declare function materializeRegisteredClaimEvidence(ledger: ResearchClaimLedger): ResearchClaimLedger;
|
|
1673
|
+
/**
|
|
1674
|
+
* Raised when two ledgers that accumulated evidence for DIFFERENT goals are
|
|
1675
|
+
* combined. Merging them would pool two questions' evidence into one
|
|
1676
|
+
* corroboration count, which reports a claim as independently confirmed when
|
|
1677
|
+
* nobody confirmed it — strictly worse than losing the ledger, so this refuses.
|
|
1678
|
+
*/
|
|
1679
|
+
declare class ClaimLedgerGoalConflictError extends Error {
|
|
1680
|
+
readonly ledgerId: string;
|
|
1681
|
+
readonly existingGoal: string;
|
|
1682
|
+
readonly incomingGoal: string;
|
|
1683
|
+
constructor(ledgerId: string, existingGoal: string, incomingGoal: string);
|
|
1684
|
+
}
|
|
1685
|
+
/**
|
|
1686
|
+
* Combine two records of the same claim.
|
|
1687
|
+
*
|
|
1688
|
+
* Union on every support collection, because a claim asserted by hosts {a} in
|
|
1689
|
+
* one writer and {b} in another is asserted by two independent hosts and the
|
|
1690
|
+
* whole completion oracle turns on that count. `contested` is OR — one writer
|
|
1691
|
+
* seeing a contradiction is enough for the claim to be contested, and no later
|
|
1692
|
+
* writer that simply did not see it may clear the flag.
|
|
1693
|
+
*/
|
|
1694
|
+
declare function mergeTrackedClaims(base: ResearchClaimRecord, incoming: ResearchClaimRecord): ResearchClaimRecord;
|
|
1695
|
+
/**
|
|
1696
|
+
* Combine two ledgers for the same run.
|
|
1697
|
+
*
|
|
1698
|
+
* `addressed` on a question is OR for the same reason `contested` is: a writer
|
|
1699
|
+
* that answered a question has answered it, and a writer that never saw the
|
|
1700
|
+
* answer must not reopen it. Everything else is a union or an extreme, so this
|
|
1701
|
+
* is associative and idempotent — merge order cannot change the result and a
|
|
1702
|
+
* replayed merge is a no-op.
|
|
1703
|
+
*/
|
|
1704
|
+
declare function mergeClaimLedgers(base: ResearchClaimLedger, incoming: ResearchClaimLedger): ResearchClaimLedger;
|
|
1705
|
+
/**
|
|
1706
|
+
* Make every contradiction edge symmetric and mark both ends contested.
|
|
1707
|
+
*
|
|
1708
|
+
* A contradiction is a property of a PAIR, and a writer only ever sees one side
|
|
1709
|
+
* of it: the worker that found the refuting source records "X contradicts Y" and
|
|
1710
|
+
* knows nothing about Y's record. Left one-sided, Y reads as an uncontested
|
|
1711
|
+
* claim, and the completion oracle would settle a question two sources disagree
|
|
1712
|
+
* about. `createResearchDrivingDriver` does this pairwise as it records; this is
|
|
1713
|
+
* the same rule stated over a whole ledger, for writers that assemble one from
|
|
1714
|
+
* events rather than from a live loop.
|
|
1715
|
+
*
|
|
1716
|
+
* Idempotent and monotone like every other rule here: edges only appear and
|
|
1717
|
+
* `contested` only latches on, so applying it twice changes nothing. An edge
|
|
1718
|
+
* pointing at a claim this ledger does not hold is KEPT — the other side may
|
|
1719
|
+
* arrive from another writer later, and discarding evidence of disagreement
|
|
1720
|
+
* because the counterpart has not shown up yet is the failure this prevents.
|
|
1721
|
+
*/
|
|
1722
|
+
declare function linkClaimContradictions(ledger: ResearchClaimLedger): ResearchClaimLedger;
|
|
1723
|
+
//#endregion
|
|
1615
1724
|
//#region src/collection-research-driver.d.ts
|
|
1616
1725
|
/**
|
|
1617
1726
|
* Build the single-agent collection driver. Accepts every source; never gates,
|
|
@@ -1687,6 +1796,39 @@ interface RunDiscoveryLoopOptions {
|
|
|
1687
1796
|
declare function runDiscoveryLoop(options: RunDiscoveryLoopOptions): Promise<DiscoveryLoopResult>;
|
|
1688
1797
|
declare function createLocalDiscoveryDispatcher(worker: KnowledgeDiscoveryWorker): KnowledgeDiscoveryDispatcher;
|
|
1689
1798
|
//#endregion
|
|
1799
|
+
//#region src/durable-fs.d.ts
|
|
1800
|
+
interface RegularFileSnapshot {
|
|
1801
|
+
bytes: Buffer;
|
|
1802
|
+
mode: number;
|
|
1803
|
+
}
|
|
1804
|
+
declare function writeFileDurable(path: string, data: string | Buffer, options?: {
|
|
1805
|
+
encoding?: BufferEncoding;
|
|
1806
|
+
mode?: number;
|
|
1807
|
+
}): Promise<void>;
|
|
1808
|
+
declare function writeJsonDurable(path: string, value: unknown): Promise<void>;
|
|
1809
|
+
declare function writeFileDurableWithinRoot(root: string, relativePath: string, data: string | Buffer, options?: {
|
|
1810
|
+
encoding?: BufferEncoding;
|
|
1811
|
+
mode?: number;
|
|
1812
|
+
}): Promise<void>;
|
|
1813
|
+
declare function writeJsonDurableWithinRoot(root: string, relativePath: string, value: unknown): Promise<void>;
|
|
1814
|
+
declare function renameDurable(source: string, target: string): Promise<void>;
|
|
1815
|
+
declare function removeDurable(path: string): Promise<void>;
|
|
1816
|
+
declare function syncDirectory(path: string): Promise<void>;
|
|
1817
|
+
/**
|
|
1818
|
+
* Keeps the target's parent directory open while the operation runs. On Linux,
|
|
1819
|
+
* `/proc/self/fd` anchors every lookup to that directory even if an ancestor is
|
|
1820
|
+
* renamed concurrently.
|
|
1821
|
+
*/
|
|
1822
|
+
declare function withSafeDescendant<T>(root: string, relativePath: string, use: (path: string) => Promise<T> | T): Promise<T>;
|
|
1823
|
+
declare function withSafeDirectory<T>(root: string, relativePath: string, create: boolean, use: (path: string) => Promise<T> | T): Promise<T>;
|
|
1824
|
+
declare function readRegularFileNoFollow(path: string): Promise<RegularFileSnapshot>;
|
|
1825
|
+
declare function readRegularFileWithinRoot(root: string, relativePath: string): Promise<RegularFileSnapshot>;
|
|
1826
|
+
declare function listRegularFilesWithinRoot(root: string, relativeDirectory: string): Promise<Array<RegularFileSnapshot & {
|
|
1827
|
+
path: string;
|
|
1828
|
+
}>>;
|
|
1829
|
+
declare function isMissingFile(error: unknown): boolean;
|
|
1830
|
+
declare function isKernelAnchoredPath(path: string): boolean;
|
|
1831
|
+
//#endregion
|
|
1690
1832
|
//#region src/events.d.ts
|
|
1691
1833
|
interface KnowledgeEventQuery {
|
|
1692
1834
|
type?: KnowledgeEventType;
|
|
@@ -1859,6 +2001,15 @@ declare function stableId(prefix: string, content: string): string;
|
|
|
1859
2001
|
//#endregion
|
|
1860
2002
|
//#region src/indexer.d.ts
|
|
1861
2003
|
declare function buildKnowledgeIndex(root: string): Promise<KnowledgeIndex>;
|
|
2004
|
+
/**
|
|
2005
|
+
* Build the index from the knowledge tree and store it.
|
|
2006
|
+
*
|
|
2007
|
+
* The write goes through `FileSystemKbStore` rather than straight to disk: this
|
|
2008
|
+
* function and the store used to write two different index files in two
|
|
2009
|
+
* different places, so a knowledge base could hold two disagreeing indexes and
|
|
2010
|
+
* a store-based reader saw none of the indexer's work. One writer now, and it
|
|
2011
|
+
* validates through `KnowledgeIndexSchema` on the way out.
|
|
2012
|
+
*/
|
|
1862
2013
|
declare function writeKnowledgeIndex(root: string): Promise<KnowledgeIndex>;
|
|
1863
2014
|
//#endregion
|
|
1864
2015
|
//#region src/inspect.d.ts
|
|
@@ -2119,6 +2270,22 @@ interface ThesisRunResult {
|
|
|
2119
2270
|
declare function runInvestmentThesisTask(input: ThesisTaskInput, options: ThesisRunOptions): Promise<ThesisRunResult>;
|
|
2120
2271
|
//#endregion
|
|
2121
2272
|
//#region src/kb-store.d.ts
|
|
2273
|
+
/**
|
|
2274
|
+
* Where a filesystem knowledge base keeps its machine-written records, relative
|
|
2275
|
+
* to the knowledge-base root.
|
|
2276
|
+
*
|
|
2277
|
+
* This is the ONE location. `FileSystemKbStore` used to write `<dir>/index.json`
|
|
2278
|
+
* while `writeKnowledgeIndex` wrote `<root>/.agent-knowledge/index.json` — two
|
|
2279
|
+
* index writers, two files, and only the second one reachable, so a store that
|
|
2280
|
+
* had just been written to reported an empty knowledge base. Both now go through
|
|
2281
|
+
* `FileSystemKbStore`, anchored on the knowledge-base root, which is also the
|
|
2282
|
+
* directory `withKnowledgeMutation` locks: one file, one lock domain.
|
|
2283
|
+
*/
|
|
2284
|
+
declare const KB_STORE_DIR = ".agent-knowledge";
|
|
2285
|
+
declare const KB_INDEX_PATH = ".agent-knowledge/index.json";
|
|
2286
|
+
declare const KB_EVENTS_PATH = ".agent-knowledge/events.json";
|
|
2287
|
+
declare const KB_CLAIM_LEDGER_DIR = ".agent-knowledge/claim-ledgers";
|
|
2288
|
+
declare function assertClaimLedgerId(id: string): string;
|
|
2122
2289
|
interface KbStore {
|
|
2123
2290
|
putSource(source: SourceRecord): Promise<void>;
|
|
2124
2291
|
getSource(id: string): Promise<SourceRecord | null>;
|
|
@@ -2131,10 +2298,38 @@ interface KbStore {
|
|
|
2131
2298
|
putEvent(event: KnowledgeEvent): Promise<void>;
|
|
2132
2299
|
listEvents(query?: KnowledgeEventQuery): Promise<KnowledgeEvent[]>;
|
|
2133
2300
|
}
|
|
2134
|
-
|
|
2301
|
+
/** Optional durable capability for stores that retain per-run research belief. */
|
|
2302
|
+
interface ClaimLedgerStore {
|
|
2303
|
+
/**
|
|
2304
|
+
* Persist one research run's claim ledger — the corroboration counts,
|
|
2305
|
+
* contradiction edges, and open deep questions that make up its belief state.
|
|
2306
|
+
* Addressed by `ledger.id` so two runs against one knowledge base cannot
|
|
2307
|
+
* overwrite each other.
|
|
2308
|
+
*/
|
|
2309
|
+
putClaimLedger(ledger: ResearchClaimLedger): Promise<void>;
|
|
2310
|
+
getClaimLedger(id: string): Promise<ResearchClaimLedger | null>;
|
|
2311
|
+
listClaimLedgers(): Promise<ResearchClaimLedger[]>;
|
|
2312
|
+
/**
|
|
2313
|
+
* Read one ledger, hand it to `merge`, and write what comes back — with the
|
|
2314
|
+
* store's exclusive lock held across all three steps.
|
|
2315
|
+
*
|
|
2316
|
+
* This is the call a concurrent writer must use, and `putClaimLedger` is the
|
|
2317
|
+
* one it must not. `putClaimLedger` writes the whole record, so two writers
|
|
2318
|
+
* accumulating into one ledger each write a record built from what they read
|
|
2319
|
+
* before the other wrote, and the later write erases the earlier writer's
|
|
2320
|
+
* claims. Persisting a ledger that loses half its evidence is not compounding
|
|
2321
|
+
* knowledge; it is losing it more slowly.
|
|
2322
|
+
*
|
|
2323
|
+
* `merge` is SYNCHRONOUS on purpose: it runs inside the critical section, and
|
|
2324
|
+
* an `await` in there is a lock held across arbitrary I/O.
|
|
2325
|
+
*/
|
|
2326
|
+
mergeClaimLedger(id: string, merge: (current: ResearchClaimLedger | null) => ResearchClaimLedger): Promise<ResearchClaimLedger>;
|
|
2327
|
+
}
|
|
2328
|
+
declare class MemoryKbStore implements KbStore, ClaimLedgerStore {
|
|
2135
2329
|
private readonly sources;
|
|
2136
2330
|
private readonly pages;
|
|
2137
2331
|
private readonly events;
|
|
2332
|
+
private readonly claimLedgers;
|
|
2138
2333
|
private index;
|
|
2139
2334
|
putSource(source: SourceRecord): Promise<void>;
|
|
2140
2335
|
getSource(id: string): Promise<SourceRecord | null>;
|
|
@@ -2146,10 +2341,35 @@ declare class MemoryKbStore implements KbStore {
|
|
|
2146
2341
|
getIndex(): Promise<KnowledgeIndex | null>;
|
|
2147
2342
|
putEvent(event: KnowledgeEvent): Promise<void>;
|
|
2148
2343
|
listEvents(query?: KnowledgeEventQuery): Promise<KnowledgeEvent[]>;
|
|
2344
|
+
putClaimLedger(ledger: ResearchClaimLedger): Promise<void>;
|
|
2345
|
+
getClaimLedger(id: string): Promise<ResearchClaimLedger | null>;
|
|
2346
|
+
listClaimLedgers(): Promise<ResearchClaimLedger[]>;
|
|
2347
|
+
mergeClaimLedger(id: string, merge: (current: ResearchClaimLedger | null) => ResearchClaimLedger): Promise<ResearchClaimLedger>;
|
|
2149
2348
|
}
|
|
2150
|
-
|
|
2151
|
-
|
|
2152
|
-
|
|
2349
|
+
/**
|
|
2350
|
+
* The durable record store for one knowledge base.
|
|
2351
|
+
*
|
|
2352
|
+
* The object constructor is anchored on the knowledge-base root and keeps its
|
|
2353
|
+
* records under `<root>/.agent-knowledge/`, which is the layout used by
|
|
2354
|
+
* `writeKnowledgeIndex`. The string constructor preserves the published direct
|
|
2355
|
+
* record-directory layout (`<directory>/index.json`).
|
|
2356
|
+
*/
|
|
2357
|
+
interface FileSystemKbStoreOptions {
|
|
2358
|
+
/** Knowledge-base root; records are stored under `<root>/.agent-knowledge/`. */
|
|
2359
|
+
root: string;
|
|
2360
|
+
}
|
|
2361
|
+
declare class FileSystemKbStore implements KbStore, ClaimLedgerStore {
|
|
2362
|
+
private readonly root;
|
|
2363
|
+
private readonly indexPath;
|
|
2364
|
+
private readonly eventsPath;
|
|
2365
|
+
private readonly claimLedgerDir;
|
|
2366
|
+
/**
|
|
2367
|
+
* A string retains the published direct-directory contract.
|
|
2368
|
+
* The object form explicitly selects a knowledge-base root and the canonical
|
|
2369
|
+
* `.agent-knowledge/` layout. A string naming that exact canonical directory
|
|
2370
|
+
* keeps its file paths but shares the root form's lock domain.
|
|
2371
|
+
*/
|
|
2372
|
+
constructor(input: string | FileSystemKbStoreOptions);
|
|
2153
2373
|
putSource(source: SourceRecord): Promise<void>;
|
|
2154
2374
|
getSource(id: string): Promise<SourceRecord | null>;
|
|
2155
2375
|
listSources(): Promise<SourceRecord[]>;
|
|
@@ -2160,9 +2380,14 @@ declare class FileSystemKbStore implements KbStore {
|
|
|
2160
2380
|
getIndex(): Promise<KnowledgeIndex | null>;
|
|
2161
2381
|
putEvent(event: KnowledgeEvent): Promise<void>;
|
|
2162
2382
|
listEvents(query?: KnowledgeEventQuery): Promise<KnowledgeEvent[]>;
|
|
2383
|
+
putClaimLedger(ledger: ResearchClaimLedger): Promise<void>;
|
|
2384
|
+
getClaimLedger(id: string): Promise<ResearchClaimLedger | null>;
|
|
2385
|
+
listClaimLedgers(): Promise<ResearchClaimLedger[]>;
|
|
2386
|
+
mergeClaimLedger(id: string, merge: (current: ResearchClaimLedger | null) => ResearchClaimLedger): Promise<ResearchClaimLedger>;
|
|
2163
2387
|
private updateIndex;
|
|
2164
2388
|
private readIndex;
|
|
2165
2389
|
private readEvents;
|
|
2390
|
+
private claimLedgerPath;
|
|
2166
2391
|
}
|
|
2167
2392
|
//#endregion
|
|
2168
2393
|
//#region src/lint.d.ts
|
|
@@ -2354,43 +2579,9 @@ interface KnowledgeReleaseInput {
|
|
|
2354
2579
|
declare function knowledgeReleaseReport(input: KnowledgeReleaseInput): KnowledgeReleaseReport;
|
|
2355
2580
|
//#endregion
|
|
2356
2581
|
//#region src/research-driving-driver.d.ts
|
|
2357
|
-
/** The four deep sub-question kinds the driver generates to drive depth. */
|
|
2358
|
-
type DeepQuestionKind = 'comparative' | 'mechanism' | 'gap' | 'contradiction';
|
|
2359
|
-
/** A deep sub-question the driver folds into the worker's next prompt. */
|
|
2360
|
-
interface DeepQuestion {
|
|
2361
|
-
kind: DeepQuestionKind;
|
|
2362
|
-
text: string;
|
|
2363
|
-
/** sha256-derived stable id, so "addressed" can be tracked across rounds. */
|
|
2364
|
-
id: string;
|
|
2365
|
-
/** Claim id(s) this question interrogates (for contradiction/mechanism kinds). */
|
|
2366
|
-
claimIds: string[];
|
|
2367
|
-
/** True once a later round's evidence addressed it (see `markAddressed`). */
|
|
2368
|
-
addressed: boolean;
|
|
2369
|
-
/** The round this question was raised in. */
|
|
2370
|
-
raisedRound: number;
|
|
2371
|
-
}
|
|
2372
|
-
/** One tracked claim plus the independent sources that assert it. */
|
|
2373
|
-
interface TrackedClaim {
|
|
2374
|
-
id: string;
|
|
2375
|
-
/** The claim text as first extracted (kept for prompts/audit). */
|
|
2376
|
-
text: string;
|
|
2377
|
-
/** Canonical hosts of the INDEPENDENT sources that assert this claim. */
|
|
2378
|
-
supportingHosts: Set<string>;
|
|
2379
|
-
/** Source URIs that assert this claim (provenance; may share a host). */
|
|
2380
|
-
supportingUris: string[];
|
|
2381
|
-
/** Claim ids this claim was found to CONTRADICT (and vice versa). */
|
|
2382
|
-
contradicts: Set<string>;
|
|
2383
|
-
/**
|
|
2384
|
-
* CONTESTED = a contradiction the loop surfaced but could not resolve to a
|
|
2385
|
-
* single supported claim. A contested claim counts as "settled enough to be
|
|
2386
|
-
* done" (we report the disagreement) even with < 2 independent sources.
|
|
2387
|
-
*/
|
|
2388
|
-
contested: boolean;
|
|
2389
|
-
firstSeenRound: number;
|
|
2390
|
-
}
|
|
2391
2582
|
/** The driver's accumulated research state — the completion oracle reads this. */
|
|
2392
2583
|
interface ResearchDrivingState {
|
|
2393
|
-
/** Every claim
|
|
2584
|
+
/** Every extracted claim backed by a registered source, by id. */
|
|
2394
2585
|
claims: TrackedClaim[];
|
|
2395
2586
|
/** Every deep sub-question raised, by id. */
|
|
2396
2587
|
questions: DeepQuestion[];
|
|
@@ -2427,6 +2618,20 @@ interface ResearchDrivingDriverOptions {
|
|
|
2427
2618
|
/** Observe each round's generated steer (for instrumentation / the script). */
|
|
2428
2619
|
onSteer?: (steer: ResearchDrivingSteer) => void;
|
|
2429
2620
|
}
|
|
2621
|
+
/**
|
|
2622
|
+
* Options for the durable driver: the same driver plus a store to keep its
|
|
2623
|
+
* belief state in.
|
|
2624
|
+
*/
|
|
2625
|
+
interface PersistentResearchDrivingDriverOptions extends ResearchDrivingDriverOptions {
|
|
2626
|
+
/** Where the claim ledger is read from and written to. */
|
|
2627
|
+
store: ClaimLedgerStore;
|
|
2628
|
+
/**
|
|
2629
|
+
* Names this run's ledger. Stable across resumes (that is what makes a resume
|
|
2630
|
+
* a resume) and distinct per run against one knowledge base. Must be a single
|
|
2631
|
+
* safe path segment — see `assertClaimLedgerId`.
|
|
2632
|
+
*/
|
|
2633
|
+
ledgerId: string;
|
|
2634
|
+
}
|
|
2430
2635
|
/** What the driver folded into one round's worker prompt, surfaced for audit. */
|
|
2431
2636
|
interface ResearchDrivingSteer {
|
|
2432
2637
|
round: number;
|
|
@@ -2459,8 +2664,42 @@ interface ResearchDrivingDriver extends ResearchDriver {
|
|
|
2459
2664
|
* to assert the driver produced deeper questions / invalidation challenges.
|
|
2460
2665
|
*/
|
|
2461
2666
|
lastSteer(): ResearchDrivingSteer | undefined;
|
|
2667
|
+
/**
|
|
2668
|
+
* Write the current belief state to the store. `verifySource` already persists
|
|
2669
|
+
* each pending observation; this exists for the state `foldGaps` produces —
|
|
2670
|
+
* the deep questions — which is raised by a synchronous hook and would
|
|
2671
|
+
* otherwise be lost if the process died before the next source arrived.
|
|
2672
|
+
*
|
|
2673
|
+
* `runVerifiedResearchLoop` calls this at the end of every round. A driver
|
|
2674
|
+
* built without a store has nothing to write and resolves immediately.
|
|
2675
|
+
*/
|
|
2676
|
+
checkpoint(): Promise<void>;
|
|
2677
|
+
/** Durably announce the next synchronous fold before it begins. */
|
|
2678
|
+
prepareFold(): Promise<void>;
|
|
2679
|
+
/**
|
|
2680
|
+
* Confirm that source registration completed for these exact original URIs.
|
|
2681
|
+
* Pending extracted evidence cannot affect claims or completion before this.
|
|
2682
|
+
*/
|
|
2683
|
+
commitSources(sourceUris: readonly string[]): Promise<void>;
|
|
2684
|
+
/** The ledger record as it would be written right now. */
|
|
2685
|
+
toLedger(): ResearchClaimLedger;
|
|
2462
2686
|
}
|
|
2687
|
+
/**
|
|
2688
|
+
* The in-memory driver. Its belief state lives for exactly as long as the
|
|
2689
|
+
* process does — use `createPersistentResearchDrivingDriver` when the run must
|
|
2690
|
+
* survive a crash or resume.
|
|
2691
|
+
*/
|
|
2463
2692
|
declare function createResearchDrivingDriver(options?: ResearchDrivingDriverOptions): ResearchDrivingDriver;
|
|
2693
|
+
/**
|
|
2694
|
+
* The durable driver: same behaviour, plus its claim ledger is read from the
|
|
2695
|
+
* store at construction and written back after every claim and every round.
|
|
2696
|
+
*
|
|
2697
|
+
* Construction is asynchronous because loading is I/O, and loading has to happen
|
|
2698
|
+
* before the caller can read `researchState()` or `isComplete()` — a driver that
|
|
2699
|
+
* loaded lazily would answer "nothing researched, not complete" for a run that
|
|
2700
|
+
* had already corroborated everything.
|
|
2701
|
+
*/
|
|
2702
|
+
declare function createPersistentResearchDrivingDriver(options: PersistentResearchDrivingDriverOptions): Promise<ResearchDrivingDriver>;
|
|
2464
2703
|
//#endregion
|
|
2465
2704
|
//#region src/schemas.d.ts
|
|
2466
2705
|
declare const SourceAnchorSchema: z.ZodObject<{
|
|
@@ -2588,6 +2827,7 @@ declare const KnowledgeEventSchema: z.ZodObject<{
|
|
|
2588
2827
|
"proposal.applied": "proposal.applied";
|
|
2589
2828
|
"release.promoted": "release.promoted";
|
|
2590
2829
|
"release.rejected": "release.rejected";
|
|
2830
|
+
"research.iteration": "research.iteration";
|
|
2591
2831
|
"source.added": "source.added";
|
|
2592
2832
|
}>;
|
|
2593
2833
|
createdAt: z.ZodString;
|
|
@@ -2595,6 +2835,74 @@ declare const KnowledgeEventSchema: z.ZodObject<{
|
|
|
2595
2835
|
target: z.ZodOptional<z.ZodString>;
|
|
2596
2836
|
metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
2597
2837
|
}, z.core.$strip>;
|
|
2838
|
+
declare const DeepQuestionSchema: z.ZodObject<{
|
|
2839
|
+
kind: z.ZodEnum<{
|
|
2840
|
+
comparative: "comparative";
|
|
2841
|
+
contradiction: "contradiction";
|
|
2842
|
+
gap: "gap";
|
|
2843
|
+
mechanism: "mechanism";
|
|
2844
|
+
}>;
|
|
2845
|
+
text: z.ZodString;
|
|
2846
|
+
id: z.ZodString;
|
|
2847
|
+
claimIds: z.ZodArray<z.ZodString>;
|
|
2848
|
+
addressed: z.ZodBoolean;
|
|
2849
|
+
raisedRound: z.ZodNumber;
|
|
2850
|
+
}, z.core.$strict>;
|
|
2851
|
+
declare const ResearchClaimRecordSchema: z.ZodObject<{
|
|
2852
|
+
id: z.ZodString;
|
|
2853
|
+
text: z.ZodString;
|
|
2854
|
+
supportingHosts: z.ZodArray<z.ZodString>;
|
|
2855
|
+
supportingUris: z.ZodArray<z.ZodString>;
|
|
2856
|
+
contradicts: z.ZodArray<z.ZodString>;
|
|
2857
|
+
contested: z.ZodBoolean;
|
|
2858
|
+
firstSeenRound: z.ZodNumber;
|
|
2859
|
+
}, z.core.$strict>;
|
|
2860
|
+
declare const ResearchClaimEvidenceSchema: z.ZodObject<{
|
|
2861
|
+
id: z.ZodString;
|
|
2862
|
+
claimId: z.ZodString;
|
|
2863
|
+
text: z.ZodString;
|
|
2864
|
+
sourceUri: z.ZodString;
|
|
2865
|
+
contradictsClaimId: z.ZodOptional<z.ZodString>;
|
|
2866
|
+
firstSeenRound: z.ZodNumber;
|
|
2867
|
+
}, z.core.$strict>;
|
|
2868
|
+
declare const ResearchClaimLedgerSchema: z.ZodObject<{
|
|
2869
|
+
id: z.ZodString;
|
|
2870
|
+
goal: z.ZodOptional<z.ZodString>;
|
|
2871
|
+
updatedAt: z.ZodISODateTime;
|
|
2872
|
+
rounds: z.ZodNumber;
|
|
2873
|
+
preparedRounds: z.ZodOptional<z.ZodNumber>;
|
|
2874
|
+
claimEvidence: z.ZodArray<z.ZodObject<{
|
|
2875
|
+
id: z.ZodString;
|
|
2876
|
+
claimId: z.ZodString;
|
|
2877
|
+
text: z.ZodString;
|
|
2878
|
+
sourceUri: z.ZodString;
|
|
2879
|
+
contradictsClaimId: z.ZodOptional<z.ZodString>;
|
|
2880
|
+
firstSeenRound: z.ZodNumber;
|
|
2881
|
+
}, z.core.$strict>>;
|
|
2882
|
+
registeredSourceUris: z.ZodArray<z.ZodString>;
|
|
2883
|
+
claims: z.ZodArray<z.ZodObject<{
|
|
2884
|
+
id: z.ZodString;
|
|
2885
|
+
text: z.ZodString;
|
|
2886
|
+
supportingHosts: z.ZodArray<z.ZodString>;
|
|
2887
|
+
supportingUris: z.ZodArray<z.ZodString>;
|
|
2888
|
+
contradicts: z.ZodArray<z.ZodString>;
|
|
2889
|
+
contested: z.ZodBoolean;
|
|
2890
|
+
firstSeenRound: z.ZodNumber;
|
|
2891
|
+
}, z.core.$strict>>;
|
|
2892
|
+
questions: z.ZodArray<z.ZodObject<{
|
|
2893
|
+
kind: z.ZodEnum<{
|
|
2894
|
+
comparative: "comparative";
|
|
2895
|
+
contradiction: "contradiction";
|
|
2896
|
+
gap: "gap";
|
|
2897
|
+
mechanism: "mechanism";
|
|
2898
|
+
}>;
|
|
2899
|
+
text: z.ZodString;
|
|
2900
|
+
id: z.ZodString;
|
|
2901
|
+
claimIds: z.ZodArray<z.ZodString>;
|
|
2902
|
+
addressed: z.ZodBoolean;
|
|
2903
|
+
raisedRound: z.ZodNumber;
|
|
2904
|
+
}, z.core.$strict>>;
|
|
2905
|
+
}, z.core.$strict>;
|
|
2598
2906
|
declare const KnowledgeBaseCandidateSchema: z.ZodObject<{
|
|
2599
2907
|
id: z.ZodString;
|
|
2600
2908
|
units: z.ZodArray<z.ZodObject<{
|
|
@@ -2683,5 +2991,5 @@ declare function normalizeLinkTarget(target: string): string;
|
|
|
2683
2991
|
declare function isSafeKnowledgePath(path: string, allowedPrefixes?: string[]): boolean;
|
|
2684
2992
|
declare function parseKnowledgeWriteBlocks(text: string, allowedPrefixes?: string[]): KnowledgeWriteParseResult;
|
|
2685
2993
|
//#endregion
|
|
2686
|
-
export { AdaptiveDecision, AdaptiveDriverOptions, AdaptiveResearchDriver, AdaptiveStats, AddSourceOptions, AddSourceTextInput, AgentMemoryAcquireRunLease, type AgentMemoryActivation, type AgentMemoryActivationDriver, AgentMemoryAdapter, type AgentMemoryAttemptEvent, AgentMemoryBranch, AgentMemoryBranchIsolation, AgentMemoryBranchLifetime, AgentMemoryBranchSnapshot, AgentMemoryContext, AgentMemoryControllerMode, type AgentMemoryDimensionComparison, type AgentMemoryExecutionContext, type AgentMemoryExecutionCostMeter, type AgentMemoryExecutionCostReceipt, type AgentMemoryExecutionPaidCallInput, type AgentMemoryExecutionPaidCallResult, type AgentMemoryExecutionStep, type AgentMemoryExperimentCandidate, type AgentMemoryExperimentRankingRow, type AgentMemoryExperimentRunLease, type AgentMemoryFinalEvaluation, type AgentMemoryFinalPair, AgentMemoryHit, AgentMemoryHitSchema, type AgentMemoryImprovementRunLease, AgentMemoryJournalEntry, AgentMemoryKind, AgentMemoryKindSchema, AgentMemoryLifecycleTimeoutError, AgentMemoryLifecycleUnsafeError, type AgentMemoryPromotionDecision, AgentMemoryRunLease, AgentMemoryScope, AgentMemoryScopeSchema, AgentMemorySearchOptions, type AgentMemorySequence, type AgentMemorySequenceArtifact, type AgentMemorySequenceProbe, type AgentMemorySequenceProbeResult, type AgentMemorySequenceScenario, type AgentMemorySequenceStep, AgentMemorySharingPolicy, AgentMemoryVisibility, AgentMemoryWriteInput, AgentMemoryWriteInputSchema, AgentMemoryWriteResult, ApplyWriteBlocksResult, type BuildAgentMemorySequencesFromBenchmarkCasesOptions, BuildEvalKnowledgeBundleOptions, type BuildRetrievalBenchmarkCasesFromQrelsOptions, BuildRetrievalEvalDispatchOptions, ChunkingOptions, ClaimGroundingDriverOptions, ClaimRef, CompanyEvalCase, CornellLiiSelector, CornellLiiSourceOptions, CreateAgentMemoryBranchOptions, D1Adapter, DEFAULT_MEMORY_CLEANUP_TIMEOUT_MS, DedupReason, DeepQuestion, DeepQuestionKind, DefineReadinessSpecInput, DetectChangesOptions, DetectChangesResult, DiscoveryLoopResult, DiscoveryLoopRound, DiscoveryLoopStopReason, DiscoveryResult, DiscoveryTask, DriverResearchContext, EvalKnowledgeBundleBuildResult, EvaluateKnowledgeBaseReadinessOptions, ExpectedGroup, type ExternalRagEvalScore, FactResult, FetchOpts, FileSystemFreshnessStoreOptions, FileSystemKbStore, FileSystemSearchOptions, FileSystemSearchProvider, FileSystemSearchProviderOptions, ForkAgentMemoryBranchSnapshotOptions, FragmentProvenance, FreshnessKey, FreshnessMark, FreshnessRecord, FreshnessTtl, GraphitiMcpClientLike, GraphitiMemoryAdapterOptions, GraphitiToolNames, GroundClaimOptions, GroundingResult, INDUSTRY_MEMORY_BENCHMARKS, INDUSTRY_RAG_BENCHMARKS, IRS_DIMENSION_HINTS, IrsPublicationsSourceOptions, KbStore, type KnowledgeAnswerBenchmarkCase, type KnowledgeAnswerBenchmarkTaskKind, KnowledgeBaseCandidate, KnowledgeBaseCandidateSchema, type KnowledgeBaseQualityOptions, type KnowledgeBaseQualityReport, KnowledgeBaseReadinessEvaluation, type KnowledgeBenchmarkArtifact, type KnowledgeBenchmarkCase, type KnowledgeBenchmarkCaseBase, type KnowledgeBenchmarkDistribution, type KnowledgeBenchmarkEvaluation, type KnowledgeBenchmarkFamily, type KnowledgeBenchmarkReport, type KnowledgeBenchmarkResponder, type KnowledgeBenchmarkScenario, type KnowledgeBenchmarkSliceSummary, type KnowledgeBenchmarkSource, type KnowledgeBenchmarkSpec, type KnowledgeBenchmarkSplit, type KnowledgeBenchmarkTaskKind, KnowledgeChange, KnowledgeChangeKind, KnowledgeChunk, KnowledgeClaim, type KnowledgeClaimMatcher, KnowledgeControlLoopAction, KnowledgeControlLoopActionResult, KnowledgeControlLoopAdapter, KnowledgeControlLoopAdapterOptions, KnowledgeControlLoopState, KnowledgeDiscoveryDispatcher, KnowledgeDiscoveryWorker, KnowledgeEvent, KnowledgeEventQuery, KnowledgeEventSchema, KnowledgeEventType, KnowledgeExplanation, KnowledgeFragment, KnowledgeFreshnessStore, KnowledgeGap, KnowledgeGraph, KnowledgeGraphEdge, KnowledgeGraphEdgeSchema, KnowledgeGraphNode, KnowledgeGraphNodeSchema, KnowledgeId, type KnowledgeImprovementActivationPersistence, type KnowledgeImprovementCandidateRecord, type KnowledgeImprovementCandidateRef, KnowledgeImprovementCandidateRefSchema, type KnowledgeImprovementEvaluationInput, type KnowledgeImprovementEvaluator, type KnowledgeImprovementEvent, type KnowledgeImprovementEvidence, KnowledgeImprovementEvidenceSchema, type KnowledgeImprovementMetric, type KnowledgeImprovementMetricProvenance, type KnowledgeImprovementMutationReceipt, type KnowledgeImprovementMutationResult, type KnowledgeImprovementOptions, type KnowledgeImprovementRagOptimizationOptions, type KnowledgeImprovementRagOptimizationRunInput, type KnowledgeImprovementResult, type KnowledgeImprovementRetrievalOptions, type KnowledgeImprovementRunState, KnowledgeImprovementRunStateSchema, type KnowledgeImprovementStatus, type KnowledgeImprovementTarget, type KnowledgeImprovementUpdate, type KnowledgeImprovementUpdateInput, KnowledgeIndex, KnowledgeIndexSchema, KnowledgeInspection, KnowledgeLayout, KnowledgeLintFinding, type KnowledgeMemoryBenchmarkCase, type KnowledgeMemoryBenchmarkTaskKind, type KnowledgeMemoryEvent, type KnowledgeMemoryFactMatcher, KnowledgePage, KnowledgePageSchema, KnowledgePolicy, type KnowledgePolicyDispatch, KnowledgeProposal, KnowledgeProposalParseError, KnowledgeReadinessSpec, KnowledgeRelation, KnowledgeRelease, KnowledgeReleaseInput, KnowledgeReleaseReport, KnowledgeResearchLoopContext, KnowledgeResearchLoopDecision, KnowledgeResearchLoopResult, KnowledgeResearchLoopStep, type KnowledgeRetrievalBenchmarkCase, type KnowledgeRetrievalBenchmarkQrel, type KnowledgeRetrievalBenchmarkQuery, KnowledgeSearchResult, KnowledgeSource, KnowledgeUnit, KnowledgeWriteBlock, KnowledgeWriteParseResult, type LoadKnowledgeImprovementActivationResultOptions, MAX_RESPONSE_BYTES, MIN_REQUEST_GAP_MS, MaterialFact, MaterialFactLens, MaterialFactsResult, Mem0ClientMode, Mem0HostedClient, Mem0HostedMemoryAdapterOptions, Mem0MemoryAdapterOptions, Mem0OssClient, Mem0OssMemoryAdapterOptions, type MemoryAdapterBenchmarkCandidate, type MemoryAdapterBenchmarkRankingRow, type MemoryConfigScenario, MemoryKbStore, Neo4jAgentMemoryAdapterOptions, type OptimizeKnowledgeBasePolicyOptions, type OptimizeKnowledgeBasePolicyResult, OwnedAgentMemoryRunLease, POLITE_USER_AGENT, ParsedFrontmatter, PartitionRetrievalScenariosOptions, type PendingKnowledgeMutation, PoliteFetchOptions, PoliteFetchResult, type PromoteKnowledgeCandidateOptions, ProposeFromFindingsResult, READINESS_SPEC_DEFAULTS, type RagAnswerEvalArtifact, type RagAnswerEvalCase, type RagAnswerEvalScenario, type RagAnswerMetricSummary, type RagAnswerQualityHookOptions, RagAnswerQualityInput, type RagAnswerQualityJudgeOptions, RagAnswerQualityResult, type RagCalibrationOptions, type RagCalibrationResult, RagDiagnosisInput, type RagEvalCitation, type RagEvalClaim, type RagEvalContext, type RagEvalMetricKey, type RagEvalProvider, type RagEvalSlice, RagGapFinding, RagGapKind, RagGapSeverity, RagKnowledgeAcquisitionInput, RagKnowledgeImprovementPhase, RagKnowledgeImprovementPhaseResult, RagKnowledgeImprovementPhaseStatus, RagKnowledgeResearchOptions, RagKnowledgeUpdateInput, RagKnowledgeUpdateResult, RagOptimizationConfig, RagOptimizationSelection, RagPhaseInputBase, RagPromotionInput, RagPromotionResult, type RagRequiredContext, type RecoverPendingKnowledgeMutationOptions, RejectedSource, ResearchContribution, ResearchDriver, ResearchDrivingDriver, ResearchDrivingDriverOptions, ResearchDrivingState, ResearchDrivingSteer, ResearchSourceProposal, ResearchWorker, type ResolvedKnowledgeImprovementCandidate, type ResolvedKnowledgeImprovementComparison, type ResolvedKnowledgeImprovementComparisonSnapshot, type RestoreKnowledgeCandidateBaselineOptions, RetrievalConfig, RetrievalEvalArtifact, RetrievalEvalRetriever, RetrievalEvalRetrieverInput, RetrievalEvalRetrieverResult, RetrievalEvalScenario, RetrievalGoldTarget, RetrievalHoldoutBypassReason, RetrievalHoldoutCallContext, RetrievalHoldoutConfig, RetrievalHoldoutEligibleItem, RetrievalHoldoutEvent, RetrievalHoldoutOffPolicyOptions, RetrievalHoldoutOffPolicyResult, RetrievalHoldoutResult, RetrievalHoldoutSessionState, RetrievalHoldoutSessionSummary, RetrievalMetricSummary, RetrievalMetricWeights, RetrievalOptimizationSelection, RetrievalRecallJudgeOptions, RetrievalScenarioPartitions, RetrievedKnowledgeHit, RetrievedSourceSpan, RouterClient, RouterError, RouterUsage, type RunAgentMemoryExperimentOptions, type RunAgentMemoryExperimentResult, type RunAgentMemoryImprovementOptions, type RunAgentMemoryImprovementResult, RunDiscoveryLoopOptions, type RunKnowledgeBenchmarkSuiteOptions, type RunKnowledgeBenchmarkSuiteResult, RunKnowledgeResearchLoopOptions, type RunMemoryAdapterBenchmarkOptions, type RunMemoryAdapterBenchmarkResult, RunRagKnowledgeImprovementLoopOptions, RunRagKnowledgeImprovementLoopResult, RunRagOptimizationOptions, RunRagOptimizationResult, RunRetrievalImprovementLoopOptions, RunRetrievalImprovementLoopResult, RunSerializedKnowledgeOptimizationOptions, RunSerializedKnowledgeOptimizationResult, SCAFFOLD_PAGE_BASENAMES, SerializedCandidate, SerializedCandidateCodec, SourceAdapter, SourceAdapterInput, SourceAdapterOutput, SourceAnchor, SourceAnchorSchema, SourceFreshnessInspection, SourceRecord, SourceRecordSchema, SourceRegistry, SourceVerdict, SourceVerificationContext, StateSosEntity, StateSosSourceConfig, TangleRouterOptions, ThesisRunOptions, ThesisRunResult, ThesisTaskInput, TrackedClaim, TriageClass, type UseKnowledgeImprovementCandidateOptions, ValidateKnowledgeOptions, ValidateKnowledgeResult, VerifiedResearchLoopOptions, VerifiedResearchLoopResult, VerifiedResearchRound, VerifyingDriverOptions, WIKILINK_REGEX, WebResearchWorkerOptions, WebSearchHit, WorkerClaimDecorationOptions, WorkerResearchContext, __resetHttpThrottle, acquireAgentMemoryRunLease, addSourcePath, addSourceText, agentMemorySequenceJudge, applyKnowledgeWriteBlocks, applyKnowledgeWriteBlocksFile, applyRetrievalHoldout, applySessionStickyRetrievalHoldout, buildAgentMemorySequenceScenarios, buildAgentMemorySequencesFromBenchmarkCases, buildEvalKnowledgeBundle, buildFirstPartyMemoryLifecycleBenchmarkCases, buildIndustryMemoryBenchmarkSmokeCases, buildIndustryRagBenchmarkSmokeCases, buildKnowledgeBenchmarkScenarios, buildKnowledgeGraph, buildKnowledgeIndex, buildRetrievalBenchmarkCasesFromQrels, buildRetrievalEvalDispatch, calibrateRagAnswerJudge, canonicalizeUrl, chunkMarkdown, citedClaimKey, citedClaimOf, contentKey, createAdaptiveResearchDriver, createAgentMemoryBranch, createClaimDecorator, createClaimGroundingVerifier, createCollectionResearchDriver, createCornellLiiSource, createD1FreshnessStoreStub, createFileSystemFreshnessStore, createFileSystemSearchProvider, createGraphitiMemoryAdapter, createInMemoryBenchmarkAdapter, createIrsPublicationsSource, createKnowledgeControlLoopAdapter, createKnowledgeEvent, createLocalDiscoveryDispatcher, createMem0MemoryAdapter, createMemoryExecutionPool, createNeo4jAgentMemoryAdapter, createNoopMemoryBenchmarkAdapter, createRagAnswerQualityHook, createResearchDrivingDriver, createStateSosSource, createTangleRouterClient, createVerifyingResearchDriver, createWebResearchWorker, defaultGetMemoryContext, defineReadinessSpec, detectChanges, deterministicRng, diagnoseRagAnswerFailure, emitRetrievalHoldoutBypass, evaluateKnowledgeBaseReadiness, explainKnowledgeTarget, extractLinks, extractWikilinks, firstMatch, forkAgentMemoryBranchSnapshot, formatFrontmatter, fromAgentCandidateKnowledgeRef, gradeCompanyAgainstText, gradeFactAgainstText, graphitiMemoryAdapterIdentity, groundClaimInText, hashKnowledgeBase, htmlToText, improveKnowledgeBase, initKnowledgeBase, innerHtmlById, inspectKnowledgeIndex, inspectPendingKnowledgeMutation, investmentThesisSet, isKnowledgeMemoryBenchmarkCase, isSafeKnowledgePath, isScaffoldPath, jsonCandidateCodec, jsonObjectCandidateCodec, kbIndexToText, knowledgeBenchmarkJudge, knowledgeImprovementCandidateRef, knowledgeImprovementRunDir, knowledgeImprovementRunId, knowledgeReleaseReport, layoutFor, lensDistribution, lintKnowledgeIndex, loadKnowledgeImprovementActivationResult, loadKnowledgeImprovementEvents, loadKnowledgeImprovementState, loadKnowledgePages, loadSourceRegistry, looksLikeBlockPage, materialFactsSurfaced, materialFactsSurfacedInText, mediaTypeFor, mem0MemoryAdapterIdentity, memoryHitToSourceRecord, memoryRecoveryDelayMs, memoryWriteResultToSourceRecord, normalizeExternalRagScores, normalizeLinkTarget, optimizeKnowledgeBasePolicy, parseFrontmatter, parseKnowledgeBenchmarkJsonl, parseKnowledgeBenchmarkQrels, parseKnowledgeWriteBlocks, partitionRetrievalScenarios, politeFetch, promoteKnowledgeCandidate, proposeFromFinding, proposeFromFindings, ragAnswerQualityJudge, reciprocalRankFusion, recoverPendingKnowledgeMutation, renderKnowledgeBenchmarkReportMarkdown, renderMemoryContext, resetRetrievalHoldoutRegistry, resolveMemoryCleanupTimeoutMs, respondToIndustryMemoryBenchmarkSmokeCase, respondToIndustryRagBenchmarkSmokeCase, restoreKnowledgeCandidateBaseline, retrievalConfigFromSurface, retrievalConfigSurface, retrievalHoldoutConfigHash, retrievalRecallJudge, runAgentMemoryExperiment, runAgentMemoryImprovement, runBoundedMemoryLifecycle, runDiscoveryLoop, runInvestmentThesisTask, runKnowledgeBenchmarkSuite, runKnowledgeResearchLoop, runMemoryAdapterBenchmark, runRagKnowledgeImprovementLoop, runRagOptimization, runRetrievalImprovementLoop, runSerializedKnowledgeOptimization, runVerifiedResearchLoop, scenarioContentFingerprint, scoreKnowledgeBaseIndex, scoreKnowledgeBenchmarkArtifact, scoreMemoryBenchmarkArtifact, scoreRagAnswerArtifact, scoreRetrievalArtifact, searchKnowledge, sha256, sleepForMemoryRecovery, slugify, sourceMatchesGaps, sourceRegistryPath, stableId, stripFrontmatter, summarizeKnowledgeBenchmarkCampaign, textSourceAdapter, thesisReadinessSpecs, toAgentCandidateKnowledgeRef, toDeepEvalTestCases, toOffPolicyTrajectory, toRagCheckerRecords, toRagasEvaluationRows, toTruLensRecords, tokenizeQuery, totalMaterialFacts, triageSource, validateKnowledgeIndex, withCitedClaim, withKnowledgeImprovementCandidate, withKnowledgeImprovementComparison, writeJson, writeKnowledgeIndex, writeSourceRegistry };
|
|
2994
|
+
export { AdaptiveDecision, AdaptiveDriverOptions, AdaptiveResearchDriver, AdaptiveStats, AddSourceOptions, AddSourceTextInput, AgentMemoryAcquireRunLease, type AgentMemoryActivation, type AgentMemoryActivationDriver, AgentMemoryAdapter, type AgentMemoryAttemptEvent, AgentMemoryBranch, AgentMemoryBranchIsolation, AgentMemoryBranchLifetime, AgentMemoryBranchSnapshot, AgentMemoryContext, AgentMemoryControllerMode, type AgentMemoryDimensionComparison, type AgentMemoryExecutionContext, type AgentMemoryExecutionCostMeter, type AgentMemoryExecutionCostReceipt, type AgentMemoryExecutionPaidCallInput, type AgentMemoryExecutionPaidCallResult, type AgentMemoryExecutionStep, type AgentMemoryExperimentCandidate, type AgentMemoryExperimentRankingRow, type AgentMemoryExperimentRunLease, type AgentMemoryFinalEvaluation, type AgentMemoryFinalPair, AgentMemoryHit, AgentMemoryHitSchema, type AgentMemoryImprovementRunLease, AgentMemoryJournalEntry, AgentMemoryKind, AgentMemoryKindSchema, AgentMemoryLifecycleTimeoutError, AgentMemoryLifecycleUnsafeError, type AgentMemoryPromotionDecision, AgentMemoryRunLease, AgentMemoryScope, AgentMemoryScopeSchema, AgentMemorySearchOptions, type AgentMemorySequence, type AgentMemorySequenceArtifact, type AgentMemorySequenceProbe, type AgentMemorySequenceProbeResult, type AgentMemorySequenceScenario, type AgentMemorySequenceStep, AgentMemorySharingPolicy, AgentMemoryVisibility, AgentMemoryWriteInput, AgentMemoryWriteInputSchema, AgentMemoryWriteResult, ApplyWriteBlocksResult, type BuildAgentMemorySequencesFromBenchmarkCasesOptions, BuildEvalKnowledgeBundleOptions, type BuildRetrievalBenchmarkCasesFromQrelsOptions, BuildRetrievalEvalDispatchOptions, ChunkingOptions, ClaimGroundingDriverOptions, ClaimLedgerGoalConflictError, ClaimLedgerStore, ClaimRef, CompanyEvalCase, CornellLiiSelector, CornellLiiSourceOptions, CreateAgentMemoryBranchOptions, D1Adapter, DEFAULT_MEMORY_CLEANUP_TIMEOUT_MS, DedupReason, DeepQuestion, DeepQuestionKind, DeepQuestionSchema, DefineReadinessSpecInput, DetectChangesOptions, DetectChangesResult, DiscoveryLoopResult, DiscoveryLoopRound, DiscoveryLoopStopReason, DiscoveryResult, DiscoveryTask, DriverResearchContext, EvalKnowledgeBundleBuildResult, EvaluateKnowledgeBaseReadinessOptions, ExpectedGroup, type ExternalRagEvalScore, FactResult, FetchOpts, FileSystemFreshnessStoreOptions, FileSystemKbStore, FileSystemKbStoreOptions, FileSystemSearchOptions, FileSystemSearchProvider, FileSystemSearchProviderOptions, ForkAgentMemoryBranchSnapshotOptions, FragmentProvenance, FreshnessKey, FreshnessMark, FreshnessRecord, FreshnessTtl, GraphitiMcpClientLike, GraphitiMemoryAdapterOptions, GraphitiToolNames, GroundClaimOptions, GroundingResult, INDUSTRY_MEMORY_BENCHMARKS, INDUSTRY_RAG_BENCHMARKS, IRS_DIMENSION_HINTS, IrsPublicationsSourceOptions, KB_CLAIM_LEDGER_DIR, KB_EVENTS_PATH, KB_INDEX_PATH, KB_STORE_DIR, KNOWLEDGE_EVENT_TYPES, KbStore, type KnowledgeAnswerBenchmarkCase, type KnowledgeAnswerBenchmarkTaskKind, KnowledgeBaseCandidate, KnowledgeBaseCandidateSchema, type KnowledgeBaseQualityOptions, type KnowledgeBaseQualityReport, KnowledgeBaseReadinessEvaluation, type KnowledgeBenchmarkArtifact, type KnowledgeBenchmarkCase, type KnowledgeBenchmarkCaseBase, type KnowledgeBenchmarkDistribution, type KnowledgeBenchmarkEvaluation, type KnowledgeBenchmarkFamily, type KnowledgeBenchmarkReport, type KnowledgeBenchmarkResponder, type KnowledgeBenchmarkScenario, type KnowledgeBenchmarkSliceSummary, type KnowledgeBenchmarkSource, type KnowledgeBenchmarkSpec, type KnowledgeBenchmarkSplit, type KnowledgeBenchmarkTaskKind, KnowledgeChange, KnowledgeChangeKind, KnowledgeChunk, KnowledgeClaim, type KnowledgeClaimMatcher, KnowledgeControlLoopAction, KnowledgeControlLoopActionResult, KnowledgeControlLoopAdapter, KnowledgeControlLoopAdapterOptions, KnowledgeControlLoopState, KnowledgeDiscoveryDispatcher, KnowledgeDiscoveryWorker, KnowledgeEvent, KnowledgeEventQuery, KnowledgeEventSchema, KnowledgeEventType, KnowledgeExplanation, KnowledgeFragment, KnowledgeFreshnessStore, KnowledgeGap, KnowledgeGraph, KnowledgeGraphEdge, KnowledgeGraphEdgeSchema, KnowledgeGraphNode, KnowledgeGraphNodeSchema, KnowledgeId, type KnowledgeImprovementActivationPersistence, type KnowledgeImprovementCandidateRecord, type KnowledgeImprovementCandidateRef, KnowledgeImprovementCandidateRefSchema, type KnowledgeImprovementEvaluationInput, type KnowledgeImprovementEvaluator, type KnowledgeImprovementEvent, type KnowledgeImprovementEvidence, KnowledgeImprovementEvidenceSchema, type KnowledgeImprovementMetric, type KnowledgeImprovementMetricProvenance, type KnowledgeImprovementMutationReceipt, type KnowledgeImprovementMutationResult, type KnowledgeImprovementOptions, type KnowledgeImprovementRagOptimizationOptions, type KnowledgeImprovementRagOptimizationRunInput, type KnowledgeImprovementResult, type KnowledgeImprovementRetrievalOptions, type KnowledgeImprovementRunState, KnowledgeImprovementRunStateSchema, type KnowledgeImprovementStatus, type KnowledgeImprovementTarget, type KnowledgeImprovementUpdate, type KnowledgeImprovementUpdateInput, KnowledgeIndex, KnowledgeIndexSchema, KnowledgeInspection, KnowledgeLayout, KnowledgeLintFinding, type KnowledgeMemoryBenchmarkCase, type KnowledgeMemoryBenchmarkTaskKind, type KnowledgeMemoryEvent, type KnowledgeMemoryFactMatcher, KnowledgePage, KnowledgePageSchema, KnowledgePolicy, type KnowledgePolicyDispatch, KnowledgeProposal, KnowledgeProposalParseError, KnowledgeReadinessSpec, KnowledgeRelation, KnowledgeRelease, KnowledgeReleaseInput, KnowledgeReleaseReport, KnowledgeResearchLoopContext, KnowledgeResearchLoopDecision, KnowledgeResearchLoopResult, KnowledgeResearchLoopStep, type KnowledgeRetrievalBenchmarkCase, type KnowledgeRetrievalBenchmarkQrel, type KnowledgeRetrievalBenchmarkQuery, KnowledgeSearchResult, KnowledgeSource, KnowledgeUnit, KnowledgeWriteBlock, KnowledgeWriteParseResult, type LoadKnowledgeImprovementActivationResultOptions, MAX_RESPONSE_BYTES, MIN_REQUEST_GAP_MS, MaterialFact, MaterialFactLens, MaterialFactsResult, Mem0ClientMode, Mem0HostedClient, Mem0HostedMemoryAdapterOptions, Mem0MemoryAdapterOptions, Mem0OssClient, Mem0OssMemoryAdapterOptions, type MemoryAdapterBenchmarkCandidate, type MemoryAdapterBenchmarkRankingRow, type MemoryConfigScenario, MemoryKbStore, Neo4jAgentMemoryAdapterOptions, type OptimizeKnowledgeBasePolicyOptions, type OptimizeKnowledgeBasePolicyResult, OwnedAgentMemoryRunLease, POLITE_USER_AGENT, ParsedFrontmatter, PartitionRetrievalScenariosOptions, type PendingKnowledgeMutation, PersistentResearchDrivingDriverOptions, PoliteFetchOptions, PoliteFetchResult, type PromoteKnowledgeCandidateOptions, ProposeFromFindingsResult, READINESS_SPEC_DEFAULTS, type RagAnswerEvalArtifact, type RagAnswerEvalCase, type RagAnswerEvalScenario, type RagAnswerMetricSummary, type RagAnswerQualityHookOptions, RagAnswerQualityInput, type RagAnswerQualityJudgeOptions, RagAnswerQualityResult, type RagCalibrationOptions, type RagCalibrationResult, RagDiagnosisInput, type RagEvalCitation, type RagEvalClaim, type RagEvalContext, type RagEvalMetricKey, type RagEvalProvider, type RagEvalSlice, RagGapFinding, RagGapKind, RagGapSeverity, RagKnowledgeAcquisitionInput, RagKnowledgeImprovementPhase, RagKnowledgeImprovementPhaseResult, RagKnowledgeImprovementPhaseStatus, RagKnowledgeResearchOptions, RagKnowledgeUpdateInput, RagKnowledgeUpdateResult, RagOptimizationConfig, RagOptimizationSelection, RagPhaseInputBase, RagPromotionInput, RagPromotionResult, type RagRequiredContext, type RecoverPendingKnowledgeMutationOptions, RegularFileSnapshot, RejectedSource, ResearchClaimEvidence, ResearchClaimEvidenceSchema, ResearchClaimLedger, ResearchClaimLedgerSchema, ResearchClaimRecord, ResearchClaimRecordSchema, ResearchContribution, ResearchDriver, ResearchDrivingDriver, ResearchDrivingDriverOptions, ResearchDrivingState, ResearchDrivingSteer, ResearchSourceProposal, ResearchWorker, type ResolvedKnowledgeImprovementCandidate, type ResolvedKnowledgeImprovementComparison, type ResolvedKnowledgeImprovementComparisonSnapshot, type RestoreKnowledgeCandidateBaselineOptions, RetrievalConfig, RetrievalEvalArtifact, RetrievalEvalRetriever, RetrievalEvalRetrieverInput, RetrievalEvalRetrieverResult, RetrievalEvalScenario, RetrievalGoldTarget, RetrievalHoldoutBypassReason, RetrievalHoldoutCallContext, RetrievalHoldoutConfig, RetrievalHoldoutEligibleItem, RetrievalHoldoutEvent, RetrievalHoldoutOffPolicyOptions, RetrievalHoldoutOffPolicyResult, RetrievalHoldoutResult, RetrievalHoldoutSessionState, RetrievalHoldoutSessionSummary, RetrievalMetricSummary, RetrievalMetricWeights, RetrievalOptimizationSelection, RetrievalRecallJudgeOptions, RetrievalScenarioPartitions, RetrievedKnowledgeHit, RetrievedSourceSpan, RouterClient, RouterError, RouterUsage, type RunAgentMemoryExperimentOptions, type RunAgentMemoryExperimentResult, type RunAgentMemoryImprovementOptions, type RunAgentMemoryImprovementResult, RunDiscoveryLoopOptions, type RunKnowledgeBenchmarkSuiteOptions, type RunKnowledgeBenchmarkSuiteResult, RunKnowledgeResearchLoopOptions, type RunMemoryAdapterBenchmarkOptions, type RunMemoryAdapterBenchmarkResult, RunRagKnowledgeImprovementLoopOptions, RunRagKnowledgeImprovementLoopResult, RunRagOptimizationOptions, RunRagOptimizationResult, RunRetrievalImprovementLoopOptions, RunRetrievalImprovementLoopResult, RunSerializedKnowledgeOptimizationOptions, RunSerializedKnowledgeOptimizationResult, SCAFFOLD_PAGE_BASENAMES, SerializedCandidate, SerializedCandidateCodec, SourceAdapter, SourceAdapterInput, SourceAdapterOutput, SourceAnchor, SourceAnchorSchema, SourceFreshnessInspection, SourceRecord, SourceRecordSchema, SourceRegistry, SourceVerdict, SourceVerificationContext, StateSosEntity, StateSosSourceConfig, TangleRouterOptions, ThesisRunOptions, ThesisRunResult, ThesisTaskInput, TrackedClaim, TriageClass, type UseKnowledgeImprovementCandidateOptions, ValidateKnowledgeOptions, ValidateKnowledgeResult, VerifiedResearchLoopOptions, VerifiedResearchLoopResult, VerifiedResearchRound, VerifyingDriverOptions, WIKILINK_REGEX, WebResearchWorkerOptions, WebSearchHit, WorkerClaimDecorationOptions, WorkerResearchContext, __resetHttpThrottle, acquireAgentMemoryRunLease, addSourcePath, addSourceText, agentMemorySequenceJudge, applyKnowledgeWriteBlocks, applyKnowledgeWriteBlocksFile, applyRetrievalHoldout, applySessionStickyRetrievalHoldout, assertClaimLedgerId, assertDeepQuestionIntegrity, assertResearchClaimEvidenceIntegrity, assertResearchClaimLedgerIntegrity, assertTrackedClaimIntegrity, buildAgentMemorySequenceScenarios, buildAgentMemorySequencesFromBenchmarkCases, buildEvalKnowledgeBundle, buildFirstPartyMemoryLifecycleBenchmarkCases, buildIndustryMemoryBenchmarkSmokeCases, buildIndustryRagBenchmarkSmokeCases, buildKnowledgeBenchmarkScenarios, buildKnowledgeGraph, buildKnowledgeIndex, buildRetrievalBenchmarkCasesFromQrels, buildRetrievalEvalDispatch, calibrateRagAnswerJudge, canonicalizeUrl, chunkMarkdown, citedClaimKey, citedClaimOf, claimEvidenceId, claimId, claimSourceHost, contentKey, createAdaptiveResearchDriver, createAgentMemoryBranch, createClaimDecorator, createClaimGroundingVerifier, createCollectionResearchDriver, createCornellLiiSource, createD1FreshnessStoreStub, createFileSystemFreshnessStore, createFileSystemSearchProvider, createGraphitiMemoryAdapter, createInMemoryBenchmarkAdapter, createIrsPublicationsSource, createKnowledgeControlLoopAdapter, createKnowledgeEvent, createLocalDiscoveryDispatcher, createMem0MemoryAdapter, createMemoryExecutionPool, createNeo4jAgentMemoryAdapter, createNoopMemoryBenchmarkAdapter, createPersistentResearchDrivingDriver, createRagAnswerQualityHook, createResearchDrivingDriver, createStateSosSource, createTangleRouterClient, createVerifyingResearchDriver, createWebResearchWorker, deepQuestionId, defaultGetMemoryContext, defineReadinessSpec, detectChanges, deterministicRng, diagnoseRagAnswerFailure, emitRetrievalHoldoutBypass, emptyClaimLedger, evaluateKnowledgeBaseReadiness, explainKnowledgeTarget, extractLinks, extractWikilinks, firstMatch, forkAgentMemoryBranchSnapshot, formatFrontmatter, fromAgentCandidateKnowledgeRef, gradeCompanyAgainstText, gradeFactAgainstText, graphitiMemoryAdapterIdentity, groundClaimInText, hashKnowledgeBase, htmlToText, improveKnowledgeBase, initKnowledgeBase, innerHtmlById, inspectKnowledgeIndex, inspectPendingKnowledgeMutation, investmentThesisSet, isKernelAnchoredPath, isKnowledgeMemoryBenchmarkCase, isMissingFile, isSafeKnowledgePath, isScaffoldPath, jsonCandidateCodec, jsonObjectCandidateCodec, kbIndexToText, knowledgeBenchmarkJudge, knowledgeImprovementCandidateRef, knowledgeImprovementRunDir, knowledgeImprovementRunId, knowledgeReleaseReport, layoutFor, lensDistribution, linkClaimContradictions, lintKnowledgeIndex, listRegularFilesWithinRoot, loadKnowledgeImprovementActivationResult, loadKnowledgeImprovementEvents, loadKnowledgeImprovementState, loadKnowledgePages, loadSourceRegistry, looksLikeBlockPage, materialFactsSurfaced, materialFactsSurfacedInText, materializeRegisteredClaimEvidence, mediaTypeFor, mem0MemoryAdapterIdentity, memoryHitToSourceRecord, memoryRecoveryDelayMs, memoryWriteResultToSourceRecord, mergeClaimLedgers, mergeTrackedClaims, normalizeClaimText, normalizeExternalRagScores, normalizeLinkTarget, optimizeKnowledgeBasePolicy, parseFrontmatter, parseKnowledgeBenchmarkJsonl, parseKnowledgeBenchmarkQrels, parseKnowledgeWriteBlocks, partitionRetrievalScenarios, politeFetch, promoteKnowledgeCandidate, proposeFromFinding, proposeFromFindings, ragAnswerQualityJudge, readRegularFileNoFollow, readRegularFileWithinRoot, reciprocalRankFusion, recoverPendingKnowledgeMutation, removeDurable, renameDurable, renderKnowledgeBenchmarkReportMarkdown, renderMemoryContext, resetRetrievalHoldoutRegistry, resolveMemoryCleanupTimeoutMs, respondToIndustryMemoryBenchmarkSmokeCase, respondToIndustryRagBenchmarkSmokeCase, restoreKnowledgeCandidateBaseline, retrievalConfigFromSurface, retrievalConfigSurface, retrievalHoldoutConfigHash, retrievalRecallJudge, runAgentMemoryExperiment, runAgentMemoryImprovement, runBoundedMemoryLifecycle, runDiscoveryLoop, runInvestmentThesisTask, runKnowledgeBenchmarkSuite, runKnowledgeResearchLoop, runMemoryAdapterBenchmark, runRagKnowledgeImprovementLoop, runRagOptimization, runRetrievalImprovementLoop, runSerializedKnowledgeOptimization, runVerifiedResearchLoop, scenarioContentFingerprint, scoreKnowledgeBaseIndex, scoreKnowledgeBenchmarkArtifact, scoreMemoryBenchmarkArtifact, scoreRagAnswerArtifact, scoreRetrievalArtifact, searchKnowledge, sha256, sleepForMemoryRecovery, slugify, sourceMatchesGaps, sourceRegistryPath, stableId, stripFrontmatter, summarizeKnowledgeBenchmarkCampaign, syncDirectory, textSourceAdapter, thesisReadinessSpecs, toAgentCandidateKnowledgeRef, toDeepEvalTestCases, toOffPolicyTrajectory, toRagCheckerRecords, toRagasEvaluationRows, toTruLensRecords, tokenizeQuery, totalMaterialFacts, triageSource, validateKnowledgeIndex, withCitedClaim, withKnowledgeImprovementCandidate, withKnowledgeImprovementComparison, withSafeDescendant, withSafeDirectory, writeFileDurable, writeFileDurableWithinRoot, writeJson, writeJsonDurable, writeJsonDurableWithinRoot, writeKnowledgeIndex, writeSourceRegistry };
|
|
2687
2995
|
//# sourceMappingURL=index.d.ts.map
|