@swarmvaultai/engine 0.1.22 → 0.1.23

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -53,6 +53,7 @@ type PageManager = "system" | "human";
53
53
  type ApprovalEntryStatus = "pending" | "accepted" | "rejected";
54
54
  type ApprovalChangeType = "create" | "update" | "delete" | "promote";
55
55
  type SourceKind = "markdown" | "text" | "pdf" | "image" | "html" | "binary" | "code";
56
+ type SourceCaptureType = "arxiv" | "doi" | "tweet" | "article" | "url";
56
57
  type CodeLanguage = "javascript" | "jsx" | "typescript" | "tsx" | "python" | "go" | "rust" | "java" | "csharp" | "c" | "cpp" | "php" | "ruby" | "powershell";
57
58
  type CodeSymbolKind = "function" | "class" | "interface" | "type_alias" | "enum" | "variable" | "struct" | "trait";
58
59
  type OrchestrationRole = "research" | "audit" | "context" | "safety";
@@ -163,6 +164,11 @@ interface VaultConfig {
163
164
  agents: AgentType[];
164
165
  schedules?: Record<string, ScheduleJobConfig>;
165
166
  orchestration?: OrchestrationConfig;
167
+ benchmark?: {
168
+ enabled?: boolean;
169
+ questions?: string[];
170
+ maxQuestions?: number;
171
+ };
166
172
  webSearch?: {
167
173
  providers: Record<string, WebSearchProviderConfig>;
168
174
  tasks: {
@@ -265,6 +271,7 @@ interface SourceManifest {
265
271
  title: string;
266
272
  originType: "file" | "url";
267
273
  sourceKind: SourceKind;
274
+ sourceType?: SourceCaptureType;
268
275
  language?: CodeLanguage;
269
276
  originalPath?: string;
270
277
  repoRelativePath?: string;
@@ -400,6 +407,7 @@ interface GraphPage {
400
407
  path: string;
401
408
  title: string;
402
409
  kind: PageKind;
410
+ sourceType?: SourceCaptureType;
403
411
  sourceIds: string[];
404
412
  projectIds: string[];
405
413
  nodeIds: string[];
@@ -554,6 +562,7 @@ interface SearchResult {
554
562
  kind?: PageKind;
555
563
  status?: PageStatus;
556
564
  projectIds: string[];
565
+ sourceType?: SourceCaptureType;
557
566
  }
558
567
  interface QueryOptions {
559
568
  question: string;
@@ -771,7 +780,7 @@ interface AddOptions extends IngestOptions {
771
780
  contributor?: string;
772
781
  }
773
782
  interface AddResult {
774
- captureType: "arxiv" | "tweet" | "url";
783
+ captureType: SourceCaptureType;
775
784
  manifest: SourceManifest;
776
785
  normalizedUrl: string;
777
786
  title: string;
@@ -782,10 +791,20 @@ interface BenchmarkQuestionResult {
782
791
  queryTokens: number;
783
792
  reduction: number;
784
793
  visitedNodeIds: string[];
794
+ visitedEdgeIds: string[];
785
795
  pageIds: string[];
786
796
  }
797
+ interface BenchmarkSummary {
798
+ questionCount: number;
799
+ uniqueVisitedNodes: number;
800
+ finalContextTokens: number;
801
+ naiveCorpusTokens: number;
802
+ avgReduction: number;
803
+ reductionRatio: number;
804
+ }
787
805
  interface BenchmarkArtifact {
788
806
  generatedAt: string;
807
+ graphHash: string;
789
808
  corpusWords: number;
790
809
  corpusTokens: number;
791
810
  nodes: number;
@@ -794,9 +813,77 @@ interface BenchmarkArtifact {
794
813
  reductionRatio: number;
795
814
  sampleQuestions: string[];
796
815
  perQuestion: BenchmarkQuestionResult[];
816
+ questionResults: BenchmarkQuestionResult[];
817
+ summary: BenchmarkSummary;
797
818
  }
798
819
  interface BenchmarkOptions {
799
820
  questions?: string[];
821
+ maxQuestions?: number;
822
+ }
823
+ interface GraphReportArtifact {
824
+ generatedAt: string;
825
+ graphHash: string;
826
+ overview: {
827
+ nodes: number;
828
+ edges: number;
829
+ pages: number;
830
+ communities: number;
831
+ };
832
+ benchmark?: {
833
+ generatedAt: string;
834
+ stale: boolean;
835
+ summary: BenchmarkSummary;
836
+ questionCount: number;
837
+ };
838
+ godNodes: Array<{
839
+ nodeId: string;
840
+ label: string;
841
+ pageId?: string;
842
+ degree?: number;
843
+ bridgeScore?: number;
844
+ }>;
845
+ bridgeNodes: Array<{
846
+ nodeId: string;
847
+ label: string;
848
+ pageId?: string;
849
+ degree?: number;
850
+ bridgeScore?: number;
851
+ }>;
852
+ thinCommunities: Array<{
853
+ id: string;
854
+ label: string;
855
+ nodeCount: number;
856
+ pageId?: string;
857
+ path?: string;
858
+ title?: string;
859
+ }>;
860
+ surprisingConnections: Array<{
861
+ id: string;
862
+ sourceNodeId: string;
863
+ sourceLabel: string;
864
+ targetNodeId: string;
865
+ targetLabel: string;
866
+ relation: string;
867
+ evidenceClass: EvidenceClass;
868
+ confidence: number;
869
+ pathNodeIds: string[];
870
+ pathEdgeIds: string[];
871
+ pathSummary: string;
872
+ explanation: string;
873
+ }>;
874
+ suggestedQuestions: string[];
875
+ communityPages: Array<{
876
+ id: string;
877
+ path: string;
878
+ title: string;
879
+ }>;
880
+ recentResearchSources: Array<{
881
+ pageId: string;
882
+ path: string;
883
+ title: string;
884
+ sourceType: SourceCaptureType;
885
+ updatedAt: string;
886
+ }>;
800
887
  }
801
888
  interface ScheduledCompileTask {
802
889
  type: "compile";
@@ -1025,4 +1112,4 @@ declare function getWatchStatus(rootDir: string): Promise<WatchStatusResult>;
1025
1112
  declare function createWebSearchAdapter(id: string, config: WebSearchProviderConfig, rootDir: string): Promise<WebSearchAdapter>;
1026
1113
  declare function getWebSearchAdapterForTask(rootDir: string, task: "deepLintProvider"): Promise<WebSearchAdapter>;
1027
1114
 
1028
- export { type AddOptions, type AddResult, type AgentType, type AnalyzedTerm, type ApprovalChangeType, type ApprovalDetail, type ApprovalEntry, type ApprovalEntryDetail, type ApprovalEntryStatus, type ApprovalManifest, type ApprovalSummary, type BenchmarkArtifact, type BenchmarkOptions, type BenchmarkQuestionResult, type CandidateRecord, type ChartDatum, type ChartSpec, type ClaimStatus, type CodeAnalysis, type CodeDiagnostic, type CodeImport, type CodeIndexArtifact, type CodeIndexEntry, type CodeLanguage, type CodeSymbol, type CodeSymbolKind, type CommandRoleExecutorConfig, type CompileOptions, type CompileResult, type CompileState, type DirectoryIngestResult, type DirectoryIngestSkip, type EvidenceClass, type ExploreOptions, type ExploreResult, type ExploreStepResult, type ExtractionClaim, type ExtractionKind, type ExtractionTerm, type Freshness, type GenerationAttachment, type GenerationRequest, type GenerationResponse, type GitHookStatus, type GraphArtifact, type GraphEdge, type GraphExplainNeighbor, type GraphExplainResult, type GraphExportFormat, type GraphExportResult, type GraphNode, type GraphPage, type GraphPathResult, type GraphQueryMatch, type GraphQueryResult, type ImageGenerationRequest, type ImageGenerationResponse, type ImageVisionExtraction, type InboxImportResult, type InboxImportSkip, type IngestOptions, type InitOptions, type InstallAgentOptions, type LintFinding, type LintOptions, type OrchestrationConfig, type OrchestrationFinding, type OrchestrationProposal, type OrchestrationRole, type OrchestrationRoleConfig, type OrchestrationRoleResult, type OutputAsset, type OutputAssetRole, type OutputFormat, type OutputOrigin, type PageKind, type PageManager, type PageStatus, type PendingSemanticRefreshEntry, type Polarity, type ProviderAdapter, type ProviderCapability, type ProviderConfig, type ProviderRoleExecutorConfig, type ProviderType, type QueryOptions, type QueryResult, type RepoSyncResult, type ResolvedPaths, type ReviewActionResult, type RoleExecutorConfig, type SceneElement, type SceneSpec, type ScheduleController, type ScheduleJobConfig, type ScheduleStateRecord, type ScheduleTriggerConfig, type ScheduledCompileTask, type ScheduledExploreTask, type ScheduledLintTask, type ScheduledQueryTask, type ScheduledRunResult, type ScheduledTaskConfig, type SearchResult, type SourceAnalysis, type SourceAttachment, type SourceClaim, type SourceExtractionArtifact, type SourceKind, type SourceManifest, type SourceRationale, type VaultConfig, type WatchController, type WatchOptions, type WatchRepoSyncResult, type WatchRunRecord, type WatchStatusResult, type WebSearchAdapter, type WebSearchProviderConfig, type WebSearchProviderType, type WebSearchResult, acceptApproval, addInput, agentTypeSchema, archiveCandidate, assertProviderCapability, benchmarkVault, bootstrapDemo, compileVault, createMcpServer, createProvider, createWebSearchAdapter, defaultVaultConfig, defaultVaultSchema, explainGraphVault, exploreVault, exportGraphFormat, exportGraphHtml, getGitHookStatus, getProviderForTask, getWatchStatus, getWebSearchAdapterForTask, getWorkspaceInfo, importInbox, ingestDirectory, ingestInput, initVault, initWorkspace, installAgent, installConfiguredAgents, installGitHooks, lintVault, listApprovals, listCandidates, listGodNodes, listManifests, listPages, listSchedules, listTrackedRepoRoots, loadVaultConfig, loadVaultSchema, loadVaultSchemas, pathGraphVault, promoteCandidate, providerCapabilitySchema, providerTypeSchema, queryGraphVault, queryVault, readApproval, readExtractedText, readPage, rejectApproval, resolvePaths, runSchedule, runWatchCycle, searchVault, serveSchedules, startGraphServer, startMcpServer, syncTrackedRepos, syncTrackedReposForWatch, uninstallGitHooks, watchVault, webSearchProviderTypeSchema };
1115
+ export { type AddOptions, type AddResult, type AgentType, type AnalyzedTerm, type ApprovalChangeType, type ApprovalDetail, type ApprovalEntry, type ApprovalEntryDetail, type ApprovalEntryStatus, type ApprovalManifest, type ApprovalSummary, type BenchmarkArtifact, type BenchmarkOptions, type BenchmarkQuestionResult, type BenchmarkSummary, type CandidateRecord, type ChartDatum, type ChartSpec, type ClaimStatus, type CodeAnalysis, type CodeDiagnostic, type CodeImport, type CodeIndexArtifact, type CodeIndexEntry, type CodeLanguage, type CodeSymbol, type CodeSymbolKind, type CommandRoleExecutorConfig, type CompileOptions, type CompileResult, type CompileState, type DirectoryIngestResult, type DirectoryIngestSkip, type EvidenceClass, type ExploreOptions, type ExploreResult, type ExploreStepResult, type ExtractionClaim, type ExtractionKind, type ExtractionTerm, type Freshness, type GenerationAttachment, type GenerationRequest, type GenerationResponse, type GitHookStatus, type GraphArtifact, type GraphEdge, type GraphExplainNeighbor, type GraphExplainResult, type GraphExportFormat, type GraphExportResult, type GraphNode, type GraphPage, type GraphPathResult, type GraphQueryMatch, type GraphQueryResult, type GraphReportArtifact, type ImageGenerationRequest, type ImageGenerationResponse, type ImageVisionExtraction, type InboxImportResult, type InboxImportSkip, type IngestOptions, type InitOptions, type InstallAgentOptions, type LintFinding, type LintOptions, type OrchestrationConfig, type OrchestrationFinding, type OrchestrationProposal, type OrchestrationRole, type OrchestrationRoleConfig, type OrchestrationRoleResult, type OutputAsset, type OutputAssetRole, type OutputFormat, type OutputOrigin, type PageKind, type PageManager, type PageStatus, type PendingSemanticRefreshEntry, type Polarity, type ProviderAdapter, type ProviderCapability, type ProviderConfig, type ProviderRoleExecutorConfig, type ProviderType, type QueryOptions, type QueryResult, type RepoSyncResult, type ResolvedPaths, type ReviewActionResult, type RoleExecutorConfig, type SceneElement, type SceneSpec, type ScheduleController, type ScheduleJobConfig, type ScheduleStateRecord, type ScheduleTriggerConfig, type ScheduledCompileTask, type ScheduledExploreTask, type ScheduledLintTask, type ScheduledQueryTask, type ScheduledRunResult, type ScheduledTaskConfig, type SearchResult, type SourceAnalysis, type SourceAttachment, type SourceCaptureType, type SourceClaim, type SourceExtractionArtifact, type SourceKind, type SourceManifest, type SourceRationale, type VaultConfig, type WatchController, type WatchOptions, type WatchRepoSyncResult, type WatchRunRecord, type WatchStatusResult, type WebSearchAdapter, type WebSearchProviderConfig, type WebSearchProviderType, type WebSearchResult, acceptApproval, addInput, agentTypeSchema, archiveCandidate, assertProviderCapability, benchmarkVault, bootstrapDemo, compileVault, createMcpServer, createProvider, createWebSearchAdapter, defaultVaultConfig, defaultVaultSchema, explainGraphVault, exploreVault, exportGraphFormat, exportGraphHtml, getGitHookStatus, getProviderForTask, getWatchStatus, getWebSearchAdapterForTask, getWorkspaceInfo, importInbox, ingestDirectory, ingestInput, initVault, initWorkspace, installAgent, installConfiguredAgents, installGitHooks, lintVault, listApprovals, listCandidates, listGodNodes, listManifests, listPages, listSchedules, listTrackedRepoRoots, loadVaultConfig, loadVaultSchema, loadVaultSchemas, pathGraphVault, promoteCandidate, providerCapabilitySchema, providerTypeSchema, queryGraphVault, queryVault, readApproval, readExtractedText, readPage, rejectApproval, resolvePaths, runSchedule, runWatchCycle, searchVault, serveSchedules, startGraphServer, startMcpServer, syncTrackedRepos, syncTrackedReposForWatch, uninstallGitHooks, watchVault, webSearchProviderTypeSchema };