@utaba/deep-memory 0.6.1 → 0.8.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/dist/index.d.cts CHANGED
@@ -1,14 +1,14 @@
1
- import { G as GovernanceConfig, M as MemoryVocabulary, x as ResolvedVocabulary, C as CreateEntityInput, U as UpdateEntityInput, y as CreateRelationshipInput, z as EntityTypeDefinition, A as VocabularyProposal, F as VocabularyProposalResult, H as ProvenanceContext, J as Provenance, E as Entity, D as DetailLevel, a as EntitySummary, b as EntityBrief, K as FindEntitiesQuery, e as PaginatedResult, L as ReembedResult, N as Relationship, P as PropertyFilter, R as RelationshipSummary, O as GraphResult, Q as ExploreOptions, T as Neighborhood, W as PathOptions, X as PathResult, Y as ConceptSearchOptions, Z as ScoredEntity, _ as TimelineOptions, $ as TimelineResult, i as RepositoryStats, a0 as RepositoryConfig, c as StoredRepository, d as RepositoryFilter, a1 as RepositorySummary, g as RepositoryUpdate, a2 as ExportOptions, a3 as ExportArchive, a4 as ImportOptions, a5 as ImportResult, a6 as ExportStreamItem, a7 as ImportStreamHeader, I as ImportChunk, k as StoredEntity, S as StorageRepositoryConfig, f as StoredRepositorySummary, h as DeleteProgressCallback, j as PaginationOptions, V as VocabularyChangeRecord, l as StoredEntityUpdate, m as StorageFindQuery, n as StoredRelationship, o as RelationshipQueryOptions, p as StorageExploreOptions, q as StorageNeighborhood, r as StoragePathOptions, s as StoragePathResult, t as StorageTimelineOptions, u as StorageTimelineResult, v as ExportChunk, B as BulkImportOptions, w as BulkImportResult, a8 as SearchOptions, a9 as SearchHit } from './portability-B-8J4nQQ.cjs';
2
- export { aa as EnrichedRelationship, ab as EntityMap, ac as EntityTypeInput, ad as ExportLegalMetadata, ae as ExportManifest, af as ExportPipelineMetadata, ag as GetEntitiesOptions, ah as GetEntityOptions, ai as GovernanceMode, aj as ImportWarning, ak as NeighborhoodCenter, al as NeighborhoodGroup, am as NeighborhoodLayer, an as Path, ao as PropertySchema, ap as PropertyType, aq as ProvenanceFilter, ar as RelationshipDirection, as as RelationshipTypeDefinition, at as RelationshipTypeInput, au as RepositoryMetadata, av as StorageNeighborhoodGroup, aw as StorageNeighborhoodLayer, ax as StoragePath, ay as StorageTimelineEvent, az as TimelineEntityRef, aA as TimelineEvent, aB as TimelineRelationshipDetail, aC as VocabularyInput } from './portability-B-8J4nQQ.cjs';
1
+ import { G as GovernanceConfig, M as MemoryVocabulary, x as ResolvedVocabulary, C as CreateEntityInput, y as ValidationResult, U as UpdateEntityInput, z as CreateRelationshipInput, A as EntityTypeDefinition, F as VocabularyProposal, H as VocabularyProposalResult, J as ProvenanceContext, K as Provenance, E as Entity, D as DetailLevel, a as EntitySummary, b as EntityBrief, L as FindEntitiesQuery, e as PaginatedResult, N as DeleteEntitiesResult, O as ReembedResult, Q as Relationship, T as RemoveRelationshipsResult, P as PropertyFilter, R as RelationshipSummary, W as GraphResult, X as ExploreOptions, Y as Neighborhood, Z as PathOptions, _ as PathResult, $ as ConceptSearchOptions, a0 as ScoredEntity, a1 as TimelineOptions, a2 as TimelineResult, i as RepositoryStats, a3 as ValidateEntitiesOptions, a4 as EntityValidationPage, a5 as ValidateRelationshipsOptions, a6 as RelationshipValidationPage, a7 as RepositoryConfig, c as StoredRepository, d as RepositoryFilter, a8 as RepositorySummary, g as RepositoryUpdate, a9 as ExportOptions, aa as ExportArchive, ab as ImportOptions, ac as ImportResult, ad as ExportStreamItem, ae as ImportStreamHeader, I as ImportChunk, k as StoredEntity, S as StorageRepositoryConfig, f as StoredRepositorySummary, h as DeleteProgressCallback, j as PaginationOptions, V as VocabularyChangeRecord, l as StoredEntityUpdate, m as StorageFindQuery, n as StoredRelationship, o as RelationshipQueryOptions, p as StorageExploreOptions, q as StorageNeighborhood, r as StoragePathOptions, s as StoragePathResult, t as StorageTimelineOptions, u as StorageTimelineResult, v as ExportChunk, B as BulkImportOptions, w as BulkImportResult, af as SearchOptions, ag as SearchHit } from './portability-dhIuWJbJ.cjs';
2
+ export { ah as EnrichedRelationship, ai as EntityMap, aj as EntityTypeInput, ak as EntityValidationIssue, al as ExportLegalMetadata, am as ExportManifest, an as ExportPipelineMetadata, ao as GetEntitiesOptions, ap as GetEntityOptions, aq as GovernanceMode, ar as ImportWarning, as as NeighborhoodCenter, at as NeighborhoodGroup, au as NeighborhoodLayer, av as Path, aw as PropertySchema, ax as PropertyType, ay as ProvenanceFilter, az as RelationshipDirection, aA as RelationshipTypeDefinition, aB as RelationshipTypeInput, aC as RelationshipValidationIssue, aD as RepositoryMetadata, aE as StorageNeighborhoodGroup, aF as StorageNeighborhoodLayer, aG as StoragePath, aH as StorageTimelineEvent, aI as TimelineEntityRef, aJ as TimelineEvent, aK as TimelineRelationshipDetail, aL as VocabularyInput } from './portability-dhIuWJbJ.cjs';
3
3
  import { DeepMemoryEventType, EventHandler, Unsubscribe, DeepMemoryEvent, HookResult, EventPayload } from './types/index.cjs';
4
- import { T as TraversalSpec, a as TraversalResult } from './traversal-Llalk03r.cjs';
5
- export { Q as QueryMetadata, b as TraversalAggregation, c as TraversalPath, d as TraversalProjection, e as TraversalRelationship, f as TraversalReturnMode, g as TraversalStart, h as TraversalStep } from './traversal-Llalk03r.cjs';
6
- import { S as StorageProvider, E as EnsureSchemaResult } from './StorageProvider-CBhwqavV.cjs';
7
- import { EmbeddingProvider, SearchProvider, GraphTraversalProvider, LockProvider, SearchableEntity } from './providers/index.cjs';
4
+ import { T as TraversalSpec, a as TraversalResult } from './traversal-Bmv4we_g.cjs';
5
+ export { Q as QueryMetadata, b as TraversalAggregation, c as TraversalPath, d as TraversalProjection, e as TraversalRelationship, f as TraversalReturnMode, g as TraversalStart, h as TraversalStep } from './traversal-Bmv4we_g.cjs';
6
+ import { S as StorageProvider, E as EnsureSchemaResult } from './StorageProvider-DmKddrEg.cjs';
7
+ import { EmbeddingProvider, SearchProvider, EmbeddingProviderFactory, GraphTraversalProvider, LockProvider, SearchableEntity } from './providers/index.cjs';
8
8
  export { GraphTraversalCapabilities, LockHandle, LockOptions } from './providers/index.cjs';
9
9
 
10
10
  /** Error codes for all Deep Memory errors */
11
- type DeepMemoryErrorCode = 'INVALID_INPUT' | 'ENTITY_NOT_FOUND' | 'ENTITY_ALREADY_EXISTS' | 'RELATIONSHIP_NOT_FOUND' | 'RELATIONSHIP_ALREADY_EXISTS' | 'REPOSITORY_NOT_FOUND' | 'REPOSITORY_ALREADY_EXISTS' | 'VOCABULARY_VALIDATION_FAILED' | 'RELATIONSHIP_CONSTRAINT_FAILED' | 'GOVERNANCE_DENIED' | 'OPERATION_CANCELLED' | 'EMBEDDING_PROVIDER_REQUIRED' | 'IMPORT_ERROR' | 'EXPORT_ERROR' | 'PROVIDER_ERROR' | 'GRAPH_TRAVERSAL_PROVIDER_REQUIRED' | 'TRAVERSAL_VALIDATION_FAILED' | 'TRAVERSAL_VOCABULARY_ERROR' | 'TRAVERSAL_TIMEOUT';
11
+ type DeepMemoryErrorCode = 'INVALID_INPUT' | 'ENTITY_NOT_FOUND' | 'ENTITY_ALREADY_EXISTS' | 'RELATIONSHIP_NOT_FOUND' | 'RELATIONSHIP_ALREADY_EXISTS' | 'REPOSITORY_NOT_FOUND' | 'REPOSITORY_ALREADY_EXISTS' | 'VOCABULARY_VALIDATION_FAILED' | 'RELATIONSHIP_CONSTRAINT_FAILED' | 'SELF_REFERENTIAL_RELATIONSHIP' | 'GOVERNANCE_DENIED' | 'OPERATION_CANCELLED' | 'EMBEDDING_PROVIDER_REQUIRED' | 'IMPORT_ERROR' | 'EXPORT_ERROR' | 'PROVIDER_ERROR' | 'GRAPH_TRAVERSAL_PROVIDER_REQUIRED' | 'TRAVERSAL_VALIDATION_FAILED' | 'TRAVERSAL_VOCABULARY_ERROR' | 'TRAVERSAL_TIMEOUT';
12
12
  /** Base error class for all Deep Memory errors */
13
13
  declare class DeepMemoryError extends Error {
14
14
  readonly code: DeepMemoryErrorCode;
@@ -71,6 +71,12 @@ declare class RelationshipConstraintError extends DeepMemoryError {
71
71
  readonly targetType?: string;
72
72
  constructor(relationshipType: string, message: string, sourceType?: string, targetType?: string);
73
73
  }
74
+ /** Relationship source and target entity are the same — self-references are not permitted */
75
+ declare class SelfReferentialRelationshipError extends DeepMemoryError {
76
+ readonly entityId: string;
77
+ readonly relationshipType: string;
78
+ constructor(entityId: string, relationshipType: string);
79
+ }
74
80
  /** Governance rules denied the operation */
75
81
  declare class GovernanceDeniedError extends DeepMemoryError {
76
82
  readonly governanceMode: string;
@@ -118,18 +124,6 @@ declare class TraversalTimeoutError extends DeepMemoryError {
118
124
  constructor(timeoutMs: number);
119
125
  }
120
126
 
121
- /** A single validation error with optional suggestion */
122
- interface ValidationError {
123
- field: string;
124
- message: string;
125
- suggestion?: string;
126
- }
127
- /** Result of a validation check */
128
- interface ValidationResult {
129
- valid: boolean;
130
- errors: ValidationError[];
131
- }
132
-
133
127
  interface VocabularyEngineConfig {
134
128
  repositoryId: string;
135
129
  storageProvider: StorageProvider;
@@ -172,6 +166,8 @@ declare class VocabularyEngine {
172
166
  proposeExtension(proposal: VocabularyProposal, proposedBy: string): Promise<VocabularyProposalResult>;
173
167
  /** Cascade-delete all data for a deleted vocabulary type */
174
168
  private cascadeDeleteData;
169
+ /** Validate all property schemas in a proposal — returns a rejected result on the first invalid schema, or undefined if all pass */
170
+ private validateProposalPropertySchemas;
175
171
  private getExistingTypesForProposal;
176
172
  private getProposedTypeName;
177
173
  private getProposedDescription;
@@ -230,7 +226,13 @@ interface MemoryRepositoryConfig {
230
226
  repositoryId: string;
231
227
  storage: StorageProvider;
232
228
  search?: SearchProvider;
229
+ /** Embedding provider configured for this repository's model + dimensions */
233
230
  embedding?: EmbeddingProvider;
231
+ /**
232
+ * Factory for producing embedding providers with different model/dimensions.
233
+ * Required only if reembedAll will be called with a new model or dimensions.
234
+ */
235
+ embeddingFactory?: EmbeddingProviderFactory;
234
236
  graphTraversal?: GraphTraversalProvider;
235
237
  vocabularyEngine: VocabularyEngine;
236
238
  provenanceTracker: ProvenanceTracker;
@@ -247,6 +249,8 @@ declare class MemoryRepository {
247
249
  private readonly relationshipManager;
248
250
  private readonly graphTraversal;
249
251
  private readonly searchOrchestrator;
252
+ private readonly embeddingFactory?;
253
+ private embedding?;
250
254
  constructor(config: MemoryRepositoryConfig);
251
255
  getVocabulary(): Promise<ResolvedVocabulary>;
252
256
  proposeVocabularyChange(proposal: VocabularyProposal): Promise<VocabularyProposalResult>;
@@ -258,15 +262,22 @@ declare class MemoryRepository {
258
262
  getBySlug(slug: string, detailLevel?: DetailLevel): Promise<Entity | EntitySummary | EntityBrief | null>;
259
263
  getEntities(entityIds: string[], detailLevel?: 'brief' | 'summary'): Promise<Map<string, EntitySummary | EntityBrief>>;
260
264
  findEntities(query: FindEntitiesQuery): Promise<PaginatedResult<Entity | EntitySummary | EntityBrief>>;
261
- deleteEntity(entityId: string): Promise<void>;
265
+ deleteEntities(ids: string[]): Promise<DeleteEntitiesResult>;
262
266
  /** Re-embed specific entities using the current EmbeddingProvider */
263
267
  reembedEntities(entityIds: string[]): Promise<ReembedResult>;
264
268
  /**
265
- * Re-embed all entities in the repository using the current EmbeddingProvider.
269
+ * Re-embed all entities in the repository. If `model` or `dimensions` is provided,
270
+ * the repository's embedding configuration is updated to the new values before
271
+ * re-embedding, so all subsequent entity writes use the new model/dimensionality.
272
+ *
266
273
  * Processes in batches with optional rate limiting. Emits reembed:* events for progress tracking.
267
274
  * Updates repository metadata with the new model ID and dimensions on completion.
268
275
  */
269
276
  reembedAll(options?: {
277
+ /** New embedding model to switch to. Requires an embeddingFactory on DeepMemory. */
278
+ model?: string;
279
+ /** New embedding dimensionality to switch to. Requires an embeddingFactory on DeepMemory. */
280
+ dimensions?: number;
270
281
  batchSize?: number;
271
282
  /** Max retries per batch on embedding failure (default 3) */
272
283
  maxRetries?: number;
@@ -276,7 +287,7 @@ declare class MemoryRepository {
276
287
  delayBetweenBatchesMs?: number;
277
288
  }): Promise<ReembedResult>;
278
289
  createRelationships(inputs: CreateRelationshipInput[]): Promise<Relationship[]>;
279
- removeRelationship(relationshipId: string): Promise<void>;
290
+ removeRelationships(ids: string[]): Promise<RemoveRelationshipsResult>;
280
291
  getRelationships(entityId: string, options?: {
281
292
  relationshipTypes?: string[];
282
293
  direction?: 'outbound' | 'inbound' | 'both';
@@ -299,6 +310,19 @@ declare class MemoryRepository {
299
310
  searchByConcept(query: string, options?: ConceptSearchOptions): Promise<PaginatedResult<ScoredEntity>>;
300
311
  getTimeline(entityId: string, options?: TimelineOptions): Promise<TimelineResult>;
301
312
  getStats(): Promise<RepositoryStats>;
313
+ /**
314
+ * Audit a window of entities against the current vocabulary. Returns a single
315
+ * page; callers loop until `done` is true. Paging is over scanned entities,
316
+ * not issues. Does not mutate anything.
317
+ */
318
+ validateEntities(options?: ValidateEntitiesOptions): Promise<EntityValidationPage>;
319
+ /**
320
+ * Audit a window of relationships against the current vocabulary. Returns a
321
+ * single page; callers loop until `done` is true. The full entity set is
322
+ * loaded once per call to resolve orphan and type-mismatch checks, then
323
+ * offset/take is applied to the relationship stream. Does not mutate anything.
324
+ */
325
+ validateRelationships(options?: ValidateRelationshipsOptions): Promise<RelationshipValidationPage>;
302
326
  /** Delete all entities and relationships in this repository, preserving the repository and vocabulary */
303
327
  deleteAllContents(): Promise<{
304
328
  deletedEntities: number;
@@ -323,8 +347,17 @@ interface DeepMemoryConfig {
323
347
  storage: StorageProvider;
324
348
  /** Optional: search provider for full-text search */
325
349
  search?: SearchProvider;
326
- /** Optional: embedding provider for semantic search */
327
- embedding?: EmbeddingProvider;
350
+ /**
351
+ * Optional: factory that produces an EmbeddingProvider configured for a specific
352
+ * model + dimensionality. Called once per repository open/create using the repo's
353
+ * stored embedding metadata, so different repositories can use different models
354
+ * and embedding dimensions without any per-mutation lookups.
355
+ */
356
+ embeddingFactory?: EmbeddingProviderFactory;
357
+ /** Default embedding model for new repositories that don't specify one in metadata */
358
+ defaultEmbeddingModel?: string;
359
+ /** Default embedding dimensions for new repositories that don't specify one in metadata */
360
+ defaultEmbeddingDimensions?: number;
328
361
  /** Optional: lock provider for distributed locking */
329
362
  lock?: LockProvider;
330
363
  /** Optional: graph traversal provider for native multi-hop queries */
@@ -335,7 +368,9 @@ interface DeepMemoryConfig {
335
368
  declare class DeepMemory {
336
369
  private readonly storage;
337
370
  private readonly search?;
338
- private readonly embedding?;
371
+ private readonly embeddingFactory?;
372
+ private readonly defaultEmbeddingModel?;
373
+ private readonly defaultEmbeddingDimensions?;
339
374
  /** Reserved for future distributed locking support */
340
375
  readonly lock?: LockProvider;
341
376
  private readonly graphTraversalProvider?;
@@ -343,6 +378,11 @@ declare class DeepMemory {
343
378
  private readonly globalEventBus;
344
379
  private initialized;
345
380
  constructor(config: DeepMemoryConfig);
381
+ /**
382
+ * Build an embedding provider for a repository given its stored model + dimensions.
383
+ * Returns undefined when no factory is configured or when model/dimensions are missing.
384
+ */
385
+ private buildEmbeddingForRepository;
346
386
  /** Initialize the storage provider and optional providers (call once before use) */
347
387
  private ensureInitialized;
348
388
  /** Create or migrate the storage schema. Call once at deployment / startup, not per-request. */
@@ -388,6 +428,15 @@ declare class DeepMemory {
388
428
  dispose(): Promise<void>;
389
429
  }
390
430
 
431
+ declare class RepositoryValidator {
432
+ private readonly repositoryId;
433
+ private readonly storage;
434
+ private readonly vocabularyEngine;
435
+ constructor(repositoryId: string, storage: StorageProvider, vocabularyEngine: VocabularyEngine);
436
+ validateEntities(options?: ValidateEntitiesOptions): Promise<EntityValidationPage>;
437
+ validateRelationships(options?: ValidateRelationshipsOptions): Promise<RelationshipValidationPage>;
438
+ }
439
+
391
440
  /**
392
441
  * Evaluate whether a set of properties matches all given filters.
393
442
  * All filters are AND'd — every filter must match for the result to be true.
@@ -454,7 +503,15 @@ declare class InMemoryStorageProvider implements StorageProvider {
454
503
  createRelationship(repositoryId: string, relationship: StoredRelationship): Promise<StoredRelationship>;
455
504
  getRelationship(repositoryId: string, relationshipId: string): Promise<StoredRelationship | null>;
456
505
  getEntityRelationships(repositoryId: string, entityId: string, options?: RelationshipQueryOptions): Promise<PaginatedResult<StoredRelationship>>;
506
+ deleteEntities(repositoryId: string, ids: string[]): Promise<{
507
+ deleted: string[];
508
+ notFound: string[];
509
+ }>;
457
510
  deleteRelationship(repositoryId: string, relationshipId: string): Promise<void>;
511
+ deleteRelationships(repositoryId: string, ids: string[]): Promise<{
512
+ deleted: string[];
513
+ notFound: string[];
514
+ }>;
458
515
  deleteRelationshipsByType(repositoryId: string, relationshipType: string): Promise<{
459
516
  deletedRelationships: number;
460
517
  }>;
@@ -481,4 +538,4 @@ declare class NoOpEmbeddingProvider implements EmbeddingProvider {
481
538
  modelId(): string;
482
539
  }
483
540
 
484
- export { BulkImportOptions, BulkImportResult, type CompiledQuery, ConceptSearchOptions, CreateEntityInput, CreateRelationshipInput, CypherCompiler, DeepMemory, type DeepMemoryConfig, DeepMemoryError, type DeepMemoryErrorCode, DeepMemoryEvent, DeepMemoryEventType, DeleteProgressCallback, DetailLevel, DuplicateEntityError, DuplicateRelationshipError, DuplicateRepositoryError, EmbeddingProvider, EmbeddingProviderRequiredError, EnsureSchemaResult, Entity, EntityBrief, EntityNotFoundError, EntitySummary, EntityTypeDefinition, EventHandler, EventPayload, ExploreOptions, ExportArchive, ExportChunk, ExportError, ExportOptions, ExportStreamItem, FindEntitiesQuery, GovernanceConfig, GovernanceDeniedError, GraphResult, GraphTraversalProvider, GraphTraversalProviderRequiredError, GremlinCompiler, HookResult, ImportChunk, ImportError, ImportOptions, ImportResult, ImportStreamHeader, InMemorySearchProvider, InMemoryStorageProvider, InvalidInputError, LockProvider, MemoryRepository, MemoryVocabulary, Neighborhood, NoOpEmbeddingProvider, OperationCancelledError, PaginatedResult, PaginationOptions, PathOptions, PathResult, PropertyFilter, Provenance, ProvenanceContext, ProviderError, ReembedResult, Relationship, RelationshipConstraintError, RelationshipNotFoundError, RelationshipQueryOptions, RelationshipSummary, RepositoryConfig, RepositoryFilter, RepositoryNotFoundError, RepositoryStats, RepositorySummary, RepositoryUpdate, ResolvedVocabulary, ScoredEntity, SearchHit, SearchOptions, SearchProvider, SearchableEntity, StorageExploreOptions, StorageFindQuery, StorageNeighborhood, StoragePathOptions, StoragePathResult, StorageProvider, StorageRepositoryConfig, StorageTimelineOptions, StorageTimelineResult, StoredEntity, StoredEntityUpdate, StoredRelationship, StoredRepository, StoredRepositorySummary, TimelineOptions, TimelineResult, type TraversalCompiler, TraversalResult, TraversalSpec, TraversalTimeoutError, TraversalValidationError, TraversalVocabularyError, Unsubscribe, UpdateEntityInput, VocabularyChangeRecord, VocabularyProposal, VocabularyProposalResult, VocabularyValidationError, generateId, isValidUuid, matchesPropertyFilters, projectEntity };
541
+ export { BulkImportOptions, BulkImportResult, type CompiledQuery, ConceptSearchOptions, CreateEntityInput, CreateRelationshipInput, CypherCompiler, DeepMemory, type DeepMemoryConfig, DeepMemoryError, type DeepMemoryErrorCode, DeepMemoryEvent, DeepMemoryEventType, DeleteEntitiesResult, DeleteProgressCallback, DetailLevel, DuplicateEntityError, DuplicateRelationshipError, DuplicateRepositoryError, EmbeddingProvider, EmbeddingProviderFactory, EmbeddingProviderRequiredError, EnsureSchemaResult, Entity, EntityBrief, EntityNotFoundError, EntitySummary, EntityTypeDefinition, EntityValidationPage, EventHandler, EventPayload, ExploreOptions, ExportArchive, ExportChunk, ExportError, ExportOptions, ExportStreamItem, FindEntitiesQuery, GovernanceConfig, GovernanceDeniedError, GraphResult, GraphTraversalProvider, GraphTraversalProviderRequiredError, GremlinCompiler, HookResult, ImportChunk, ImportError, ImportOptions, ImportResult, ImportStreamHeader, InMemorySearchProvider, InMemoryStorageProvider, InvalidInputError, LockProvider, MemoryRepository, MemoryVocabulary, Neighborhood, NoOpEmbeddingProvider, OperationCancelledError, PaginatedResult, PaginationOptions, PathOptions, PathResult, PropertyFilter, Provenance, ProvenanceContext, ProviderError, ReembedResult, Relationship, RelationshipConstraintError, RelationshipNotFoundError, RelationshipQueryOptions, RelationshipSummary, RelationshipValidationPage, RemoveRelationshipsResult, RepositoryConfig, RepositoryFilter, RepositoryNotFoundError, RepositoryStats, RepositorySummary, RepositoryUpdate, RepositoryValidator, ResolvedVocabulary, ScoredEntity, SearchHit, SearchOptions, SearchProvider, SearchableEntity, SelfReferentialRelationshipError, StorageExploreOptions, StorageFindQuery, StorageNeighborhood, StoragePathOptions, StoragePathResult, StorageProvider, StorageRepositoryConfig, StorageTimelineOptions, StorageTimelineResult, StoredEntity, StoredEntityUpdate, StoredRelationship, StoredRepository, StoredRepositorySummary, TimelineOptions, TimelineResult, type TraversalCompiler, TraversalResult, TraversalSpec, TraversalTimeoutError, TraversalValidationError, TraversalVocabularyError, Unsubscribe, UpdateEntityInput, ValidateEntitiesOptions, ValidateRelationshipsOptions, VocabularyChangeRecord, VocabularyProposal, VocabularyProposalResult, VocabularyValidationError, generateId, isValidUuid, matchesPropertyFilters, projectEntity };
package/dist/index.d.ts CHANGED
@@ -1,14 +1,14 @@
1
- import { G as GovernanceConfig, M as MemoryVocabulary, x as ResolvedVocabulary, C as CreateEntityInput, U as UpdateEntityInput, y as CreateRelationshipInput, z as EntityTypeDefinition, A as VocabularyProposal, F as VocabularyProposalResult, H as ProvenanceContext, J as Provenance, E as Entity, D as DetailLevel, a as EntitySummary, b as EntityBrief, K as FindEntitiesQuery, e as PaginatedResult, L as ReembedResult, N as Relationship, P as PropertyFilter, R as RelationshipSummary, O as GraphResult, Q as ExploreOptions, T as Neighborhood, W as PathOptions, X as PathResult, Y as ConceptSearchOptions, Z as ScoredEntity, _ as TimelineOptions, $ as TimelineResult, i as RepositoryStats, a0 as RepositoryConfig, c as StoredRepository, d as RepositoryFilter, a1 as RepositorySummary, g as RepositoryUpdate, a2 as ExportOptions, a3 as ExportArchive, a4 as ImportOptions, a5 as ImportResult, a6 as ExportStreamItem, a7 as ImportStreamHeader, I as ImportChunk, k as StoredEntity, S as StorageRepositoryConfig, f as StoredRepositorySummary, h as DeleteProgressCallback, j as PaginationOptions, V as VocabularyChangeRecord, l as StoredEntityUpdate, m as StorageFindQuery, n as StoredRelationship, o as RelationshipQueryOptions, p as StorageExploreOptions, q as StorageNeighborhood, r as StoragePathOptions, s as StoragePathResult, t as StorageTimelineOptions, u as StorageTimelineResult, v as ExportChunk, B as BulkImportOptions, w as BulkImportResult, a8 as SearchOptions, a9 as SearchHit } from './portability-B-8J4nQQ.js';
2
- export { aa as EnrichedRelationship, ab as EntityMap, ac as EntityTypeInput, ad as ExportLegalMetadata, ae as ExportManifest, af as ExportPipelineMetadata, ag as GetEntitiesOptions, ah as GetEntityOptions, ai as GovernanceMode, aj as ImportWarning, ak as NeighborhoodCenter, al as NeighborhoodGroup, am as NeighborhoodLayer, an as Path, ao as PropertySchema, ap as PropertyType, aq as ProvenanceFilter, ar as RelationshipDirection, as as RelationshipTypeDefinition, at as RelationshipTypeInput, au as RepositoryMetadata, av as StorageNeighborhoodGroup, aw as StorageNeighborhoodLayer, ax as StoragePath, ay as StorageTimelineEvent, az as TimelineEntityRef, aA as TimelineEvent, aB as TimelineRelationshipDetail, aC as VocabularyInput } from './portability-B-8J4nQQ.js';
1
+ import { G as GovernanceConfig, M as MemoryVocabulary, x as ResolvedVocabulary, C as CreateEntityInput, y as ValidationResult, U as UpdateEntityInput, z as CreateRelationshipInput, A as EntityTypeDefinition, F as VocabularyProposal, H as VocabularyProposalResult, J as ProvenanceContext, K as Provenance, E as Entity, D as DetailLevel, a as EntitySummary, b as EntityBrief, L as FindEntitiesQuery, e as PaginatedResult, N as DeleteEntitiesResult, O as ReembedResult, Q as Relationship, T as RemoveRelationshipsResult, P as PropertyFilter, R as RelationshipSummary, W as GraphResult, X as ExploreOptions, Y as Neighborhood, Z as PathOptions, _ as PathResult, $ as ConceptSearchOptions, a0 as ScoredEntity, a1 as TimelineOptions, a2 as TimelineResult, i as RepositoryStats, a3 as ValidateEntitiesOptions, a4 as EntityValidationPage, a5 as ValidateRelationshipsOptions, a6 as RelationshipValidationPage, a7 as RepositoryConfig, c as StoredRepository, d as RepositoryFilter, a8 as RepositorySummary, g as RepositoryUpdate, a9 as ExportOptions, aa as ExportArchive, ab as ImportOptions, ac as ImportResult, ad as ExportStreamItem, ae as ImportStreamHeader, I as ImportChunk, k as StoredEntity, S as StorageRepositoryConfig, f as StoredRepositorySummary, h as DeleteProgressCallback, j as PaginationOptions, V as VocabularyChangeRecord, l as StoredEntityUpdate, m as StorageFindQuery, n as StoredRelationship, o as RelationshipQueryOptions, p as StorageExploreOptions, q as StorageNeighborhood, r as StoragePathOptions, s as StoragePathResult, t as StorageTimelineOptions, u as StorageTimelineResult, v as ExportChunk, B as BulkImportOptions, w as BulkImportResult, af as SearchOptions, ag as SearchHit } from './portability-dhIuWJbJ.js';
2
+ export { ah as EnrichedRelationship, ai as EntityMap, aj as EntityTypeInput, ak as EntityValidationIssue, al as ExportLegalMetadata, am as ExportManifest, an as ExportPipelineMetadata, ao as GetEntitiesOptions, ap as GetEntityOptions, aq as GovernanceMode, ar as ImportWarning, as as NeighborhoodCenter, at as NeighborhoodGroup, au as NeighborhoodLayer, av as Path, aw as PropertySchema, ax as PropertyType, ay as ProvenanceFilter, az as RelationshipDirection, aA as RelationshipTypeDefinition, aB as RelationshipTypeInput, aC as RelationshipValidationIssue, aD as RepositoryMetadata, aE as StorageNeighborhoodGroup, aF as StorageNeighborhoodLayer, aG as StoragePath, aH as StorageTimelineEvent, aI as TimelineEntityRef, aJ as TimelineEvent, aK as TimelineRelationshipDetail, aL as VocabularyInput } from './portability-dhIuWJbJ.js';
3
3
  import { DeepMemoryEventType, EventHandler, Unsubscribe, DeepMemoryEvent, HookResult, EventPayload } from './types/index.js';
4
- import { T as TraversalSpec, a as TraversalResult } from './traversal-BdmDLMxV.js';
5
- export { Q as QueryMetadata, b as TraversalAggregation, c as TraversalPath, d as TraversalProjection, e as TraversalRelationship, f as TraversalReturnMode, g as TraversalStart, h as TraversalStep } from './traversal-BdmDLMxV.js';
6
- import { S as StorageProvider, E as EnsureSchemaResult } from './StorageProvider-ynfpc5wz.js';
7
- import { EmbeddingProvider, SearchProvider, GraphTraversalProvider, LockProvider, SearchableEntity } from './providers/index.js';
4
+ import { T as TraversalSpec, a as TraversalResult } from './traversal-D8SGKq0z.js';
5
+ export { Q as QueryMetadata, b as TraversalAggregation, c as TraversalPath, d as TraversalProjection, e as TraversalRelationship, f as TraversalReturnMode, g as TraversalStart, h as TraversalStep } from './traversal-D8SGKq0z.js';
6
+ import { S as StorageProvider, E as EnsureSchemaResult } from './StorageProvider-CRenWERy.js';
7
+ import { EmbeddingProvider, SearchProvider, EmbeddingProviderFactory, GraphTraversalProvider, LockProvider, SearchableEntity } from './providers/index.js';
8
8
  export { GraphTraversalCapabilities, LockHandle, LockOptions } from './providers/index.js';
9
9
 
10
10
  /** Error codes for all Deep Memory errors */
11
- type DeepMemoryErrorCode = 'INVALID_INPUT' | 'ENTITY_NOT_FOUND' | 'ENTITY_ALREADY_EXISTS' | 'RELATIONSHIP_NOT_FOUND' | 'RELATIONSHIP_ALREADY_EXISTS' | 'REPOSITORY_NOT_FOUND' | 'REPOSITORY_ALREADY_EXISTS' | 'VOCABULARY_VALIDATION_FAILED' | 'RELATIONSHIP_CONSTRAINT_FAILED' | 'GOVERNANCE_DENIED' | 'OPERATION_CANCELLED' | 'EMBEDDING_PROVIDER_REQUIRED' | 'IMPORT_ERROR' | 'EXPORT_ERROR' | 'PROVIDER_ERROR' | 'GRAPH_TRAVERSAL_PROVIDER_REQUIRED' | 'TRAVERSAL_VALIDATION_FAILED' | 'TRAVERSAL_VOCABULARY_ERROR' | 'TRAVERSAL_TIMEOUT';
11
+ type DeepMemoryErrorCode = 'INVALID_INPUT' | 'ENTITY_NOT_FOUND' | 'ENTITY_ALREADY_EXISTS' | 'RELATIONSHIP_NOT_FOUND' | 'RELATIONSHIP_ALREADY_EXISTS' | 'REPOSITORY_NOT_FOUND' | 'REPOSITORY_ALREADY_EXISTS' | 'VOCABULARY_VALIDATION_FAILED' | 'RELATIONSHIP_CONSTRAINT_FAILED' | 'SELF_REFERENTIAL_RELATIONSHIP' | 'GOVERNANCE_DENIED' | 'OPERATION_CANCELLED' | 'EMBEDDING_PROVIDER_REQUIRED' | 'IMPORT_ERROR' | 'EXPORT_ERROR' | 'PROVIDER_ERROR' | 'GRAPH_TRAVERSAL_PROVIDER_REQUIRED' | 'TRAVERSAL_VALIDATION_FAILED' | 'TRAVERSAL_VOCABULARY_ERROR' | 'TRAVERSAL_TIMEOUT';
12
12
  /** Base error class for all Deep Memory errors */
13
13
  declare class DeepMemoryError extends Error {
14
14
  readonly code: DeepMemoryErrorCode;
@@ -71,6 +71,12 @@ declare class RelationshipConstraintError extends DeepMemoryError {
71
71
  readonly targetType?: string;
72
72
  constructor(relationshipType: string, message: string, sourceType?: string, targetType?: string);
73
73
  }
74
+ /** Relationship source and target entity are the same — self-references are not permitted */
75
+ declare class SelfReferentialRelationshipError extends DeepMemoryError {
76
+ readonly entityId: string;
77
+ readonly relationshipType: string;
78
+ constructor(entityId: string, relationshipType: string);
79
+ }
74
80
  /** Governance rules denied the operation */
75
81
  declare class GovernanceDeniedError extends DeepMemoryError {
76
82
  readonly governanceMode: string;
@@ -118,18 +124,6 @@ declare class TraversalTimeoutError extends DeepMemoryError {
118
124
  constructor(timeoutMs: number);
119
125
  }
120
126
 
121
- /** A single validation error with optional suggestion */
122
- interface ValidationError {
123
- field: string;
124
- message: string;
125
- suggestion?: string;
126
- }
127
- /** Result of a validation check */
128
- interface ValidationResult {
129
- valid: boolean;
130
- errors: ValidationError[];
131
- }
132
-
133
127
  interface VocabularyEngineConfig {
134
128
  repositoryId: string;
135
129
  storageProvider: StorageProvider;
@@ -172,6 +166,8 @@ declare class VocabularyEngine {
172
166
  proposeExtension(proposal: VocabularyProposal, proposedBy: string): Promise<VocabularyProposalResult>;
173
167
  /** Cascade-delete all data for a deleted vocabulary type */
174
168
  private cascadeDeleteData;
169
+ /** Validate all property schemas in a proposal — returns a rejected result on the first invalid schema, or undefined if all pass */
170
+ private validateProposalPropertySchemas;
175
171
  private getExistingTypesForProposal;
176
172
  private getProposedTypeName;
177
173
  private getProposedDescription;
@@ -230,7 +226,13 @@ interface MemoryRepositoryConfig {
230
226
  repositoryId: string;
231
227
  storage: StorageProvider;
232
228
  search?: SearchProvider;
229
+ /** Embedding provider configured for this repository's model + dimensions */
233
230
  embedding?: EmbeddingProvider;
231
+ /**
232
+ * Factory for producing embedding providers with different model/dimensions.
233
+ * Required only if reembedAll will be called with a new model or dimensions.
234
+ */
235
+ embeddingFactory?: EmbeddingProviderFactory;
234
236
  graphTraversal?: GraphTraversalProvider;
235
237
  vocabularyEngine: VocabularyEngine;
236
238
  provenanceTracker: ProvenanceTracker;
@@ -247,6 +249,8 @@ declare class MemoryRepository {
247
249
  private readonly relationshipManager;
248
250
  private readonly graphTraversal;
249
251
  private readonly searchOrchestrator;
252
+ private readonly embeddingFactory?;
253
+ private embedding?;
250
254
  constructor(config: MemoryRepositoryConfig);
251
255
  getVocabulary(): Promise<ResolvedVocabulary>;
252
256
  proposeVocabularyChange(proposal: VocabularyProposal): Promise<VocabularyProposalResult>;
@@ -258,15 +262,22 @@ declare class MemoryRepository {
258
262
  getBySlug(slug: string, detailLevel?: DetailLevel): Promise<Entity | EntitySummary | EntityBrief | null>;
259
263
  getEntities(entityIds: string[], detailLevel?: 'brief' | 'summary'): Promise<Map<string, EntitySummary | EntityBrief>>;
260
264
  findEntities(query: FindEntitiesQuery): Promise<PaginatedResult<Entity | EntitySummary | EntityBrief>>;
261
- deleteEntity(entityId: string): Promise<void>;
265
+ deleteEntities(ids: string[]): Promise<DeleteEntitiesResult>;
262
266
  /** Re-embed specific entities using the current EmbeddingProvider */
263
267
  reembedEntities(entityIds: string[]): Promise<ReembedResult>;
264
268
  /**
265
- * Re-embed all entities in the repository using the current EmbeddingProvider.
269
+ * Re-embed all entities in the repository. If `model` or `dimensions` is provided,
270
+ * the repository's embedding configuration is updated to the new values before
271
+ * re-embedding, so all subsequent entity writes use the new model/dimensionality.
272
+ *
266
273
  * Processes in batches with optional rate limiting. Emits reembed:* events for progress tracking.
267
274
  * Updates repository metadata with the new model ID and dimensions on completion.
268
275
  */
269
276
  reembedAll(options?: {
277
+ /** New embedding model to switch to. Requires an embeddingFactory on DeepMemory. */
278
+ model?: string;
279
+ /** New embedding dimensionality to switch to. Requires an embeddingFactory on DeepMemory. */
280
+ dimensions?: number;
270
281
  batchSize?: number;
271
282
  /** Max retries per batch on embedding failure (default 3) */
272
283
  maxRetries?: number;
@@ -276,7 +287,7 @@ declare class MemoryRepository {
276
287
  delayBetweenBatchesMs?: number;
277
288
  }): Promise<ReembedResult>;
278
289
  createRelationships(inputs: CreateRelationshipInput[]): Promise<Relationship[]>;
279
- removeRelationship(relationshipId: string): Promise<void>;
290
+ removeRelationships(ids: string[]): Promise<RemoveRelationshipsResult>;
280
291
  getRelationships(entityId: string, options?: {
281
292
  relationshipTypes?: string[];
282
293
  direction?: 'outbound' | 'inbound' | 'both';
@@ -299,6 +310,19 @@ declare class MemoryRepository {
299
310
  searchByConcept(query: string, options?: ConceptSearchOptions): Promise<PaginatedResult<ScoredEntity>>;
300
311
  getTimeline(entityId: string, options?: TimelineOptions): Promise<TimelineResult>;
301
312
  getStats(): Promise<RepositoryStats>;
313
+ /**
314
+ * Audit a window of entities against the current vocabulary. Returns a single
315
+ * page; callers loop until `done` is true. Paging is over scanned entities,
316
+ * not issues. Does not mutate anything.
317
+ */
318
+ validateEntities(options?: ValidateEntitiesOptions): Promise<EntityValidationPage>;
319
+ /**
320
+ * Audit a window of relationships against the current vocabulary. Returns a
321
+ * single page; callers loop until `done` is true. The full entity set is
322
+ * loaded once per call to resolve orphan and type-mismatch checks, then
323
+ * offset/take is applied to the relationship stream. Does not mutate anything.
324
+ */
325
+ validateRelationships(options?: ValidateRelationshipsOptions): Promise<RelationshipValidationPage>;
302
326
  /** Delete all entities and relationships in this repository, preserving the repository and vocabulary */
303
327
  deleteAllContents(): Promise<{
304
328
  deletedEntities: number;
@@ -323,8 +347,17 @@ interface DeepMemoryConfig {
323
347
  storage: StorageProvider;
324
348
  /** Optional: search provider for full-text search */
325
349
  search?: SearchProvider;
326
- /** Optional: embedding provider for semantic search */
327
- embedding?: EmbeddingProvider;
350
+ /**
351
+ * Optional: factory that produces an EmbeddingProvider configured for a specific
352
+ * model + dimensionality. Called once per repository open/create using the repo's
353
+ * stored embedding metadata, so different repositories can use different models
354
+ * and embedding dimensions without any per-mutation lookups.
355
+ */
356
+ embeddingFactory?: EmbeddingProviderFactory;
357
+ /** Default embedding model for new repositories that don't specify one in metadata */
358
+ defaultEmbeddingModel?: string;
359
+ /** Default embedding dimensions for new repositories that don't specify one in metadata */
360
+ defaultEmbeddingDimensions?: number;
328
361
  /** Optional: lock provider for distributed locking */
329
362
  lock?: LockProvider;
330
363
  /** Optional: graph traversal provider for native multi-hop queries */
@@ -335,7 +368,9 @@ interface DeepMemoryConfig {
335
368
  declare class DeepMemory {
336
369
  private readonly storage;
337
370
  private readonly search?;
338
- private readonly embedding?;
371
+ private readonly embeddingFactory?;
372
+ private readonly defaultEmbeddingModel?;
373
+ private readonly defaultEmbeddingDimensions?;
339
374
  /** Reserved for future distributed locking support */
340
375
  readonly lock?: LockProvider;
341
376
  private readonly graphTraversalProvider?;
@@ -343,6 +378,11 @@ declare class DeepMemory {
343
378
  private readonly globalEventBus;
344
379
  private initialized;
345
380
  constructor(config: DeepMemoryConfig);
381
+ /**
382
+ * Build an embedding provider for a repository given its stored model + dimensions.
383
+ * Returns undefined when no factory is configured or when model/dimensions are missing.
384
+ */
385
+ private buildEmbeddingForRepository;
346
386
  /** Initialize the storage provider and optional providers (call once before use) */
347
387
  private ensureInitialized;
348
388
  /** Create or migrate the storage schema. Call once at deployment / startup, not per-request. */
@@ -388,6 +428,15 @@ declare class DeepMemory {
388
428
  dispose(): Promise<void>;
389
429
  }
390
430
 
431
+ declare class RepositoryValidator {
432
+ private readonly repositoryId;
433
+ private readonly storage;
434
+ private readonly vocabularyEngine;
435
+ constructor(repositoryId: string, storage: StorageProvider, vocabularyEngine: VocabularyEngine);
436
+ validateEntities(options?: ValidateEntitiesOptions): Promise<EntityValidationPage>;
437
+ validateRelationships(options?: ValidateRelationshipsOptions): Promise<RelationshipValidationPage>;
438
+ }
439
+
391
440
  /**
392
441
  * Evaluate whether a set of properties matches all given filters.
393
442
  * All filters are AND'd — every filter must match for the result to be true.
@@ -454,7 +503,15 @@ declare class InMemoryStorageProvider implements StorageProvider {
454
503
  createRelationship(repositoryId: string, relationship: StoredRelationship): Promise<StoredRelationship>;
455
504
  getRelationship(repositoryId: string, relationshipId: string): Promise<StoredRelationship | null>;
456
505
  getEntityRelationships(repositoryId: string, entityId: string, options?: RelationshipQueryOptions): Promise<PaginatedResult<StoredRelationship>>;
506
+ deleteEntities(repositoryId: string, ids: string[]): Promise<{
507
+ deleted: string[];
508
+ notFound: string[];
509
+ }>;
457
510
  deleteRelationship(repositoryId: string, relationshipId: string): Promise<void>;
511
+ deleteRelationships(repositoryId: string, ids: string[]): Promise<{
512
+ deleted: string[];
513
+ notFound: string[];
514
+ }>;
458
515
  deleteRelationshipsByType(repositoryId: string, relationshipType: string): Promise<{
459
516
  deletedRelationships: number;
460
517
  }>;
@@ -481,4 +538,4 @@ declare class NoOpEmbeddingProvider implements EmbeddingProvider {
481
538
  modelId(): string;
482
539
  }
483
540
 
484
- export { BulkImportOptions, BulkImportResult, type CompiledQuery, ConceptSearchOptions, CreateEntityInput, CreateRelationshipInput, CypherCompiler, DeepMemory, type DeepMemoryConfig, DeepMemoryError, type DeepMemoryErrorCode, DeepMemoryEvent, DeepMemoryEventType, DeleteProgressCallback, DetailLevel, DuplicateEntityError, DuplicateRelationshipError, DuplicateRepositoryError, EmbeddingProvider, EmbeddingProviderRequiredError, EnsureSchemaResult, Entity, EntityBrief, EntityNotFoundError, EntitySummary, EntityTypeDefinition, EventHandler, EventPayload, ExploreOptions, ExportArchive, ExportChunk, ExportError, ExportOptions, ExportStreamItem, FindEntitiesQuery, GovernanceConfig, GovernanceDeniedError, GraphResult, GraphTraversalProvider, GraphTraversalProviderRequiredError, GremlinCompiler, HookResult, ImportChunk, ImportError, ImportOptions, ImportResult, ImportStreamHeader, InMemorySearchProvider, InMemoryStorageProvider, InvalidInputError, LockProvider, MemoryRepository, MemoryVocabulary, Neighborhood, NoOpEmbeddingProvider, OperationCancelledError, PaginatedResult, PaginationOptions, PathOptions, PathResult, PropertyFilter, Provenance, ProvenanceContext, ProviderError, ReembedResult, Relationship, RelationshipConstraintError, RelationshipNotFoundError, RelationshipQueryOptions, RelationshipSummary, RepositoryConfig, RepositoryFilter, RepositoryNotFoundError, RepositoryStats, RepositorySummary, RepositoryUpdate, ResolvedVocabulary, ScoredEntity, SearchHit, SearchOptions, SearchProvider, SearchableEntity, StorageExploreOptions, StorageFindQuery, StorageNeighborhood, StoragePathOptions, StoragePathResult, StorageProvider, StorageRepositoryConfig, StorageTimelineOptions, StorageTimelineResult, StoredEntity, StoredEntityUpdate, StoredRelationship, StoredRepository, StoredRepositorySummary, TimelineOptions, TimelineResult, type TraversalCompiler, TraversalResult, TraversalSpec, TraversalTimeoutError, TraversalValidationError, TraversalVocabularyError, Unsubscribe, UpdateEntityInput, VocabularyChangeRecord, VocabularyProposal, VocabularyProposalResult, VocabularyValidationError, generateId, isValidUuid, matchesPropertyFilters, projectEntity };
541
+ export { BulkImportOptions, BulkImportResult, type CompiledQuery, ConceptSearchOptions, CreateEntityInput, CreateRelationshipInput, CypherCompiler, DeepMemory, type DeepMemoryConfig, DeepMemoryError, type DeepMemoryErrorCode, DeepMemoryEvent, DeepMemoryEventType, DeleteEntitiesResult, DeleteProgressCallback, DetailLevel, DuplicateEntityError, DuplicateRelationshipError, DuplicateRepositoryError, EmbeddingProvider, EmbeddingProviderFactory, EmbeddingProviderRequiredError, EnsureSchemaResult, Entity, EntityBrief, EntityNotFoundError, EntitySummary, EntityTypeDefinition, EntityValidationPage, EventHandler, EventPayload, ExploreOptions, ExportArchive, ExportChunk, ExportError, ExportOptions, ExportStreamItem, FindEntitiesQuery, GovernanceConfig, GovernanceDeniedError, GraphResult, GraphTraversalProvider, GraphTraversalProviderRequiredError, GremlinCompiler, HookResult, ImportChunk, ImportError, ImportOptions, ImportResult, ImportStreamHeader, InMemorySearchProvider, InMemoryStorageProvider, InvalidInputError, LockProvider, MemoryRepository, MemoryVocabulary, Neighborhood, NoOpEmbeddingProvider, OperationCancelledError, PaginatedResult, PaginationOptions, PathOptions, PathResult, PropertyFilter, Provenance, ProvenanceContext, ProviderError, ReembedResult, Relationship, RelationshipConstraintError, RelationshipNotFoundError, RelationshipQueryOptions, RelationshipSummary, RelationshipValidationPage, RemoveRelationshipsResult, RepositoryConfig, RepositoryFilter, RepositoryNotFoundError, RepositoryStats, RepositorySummary, RepositoryUpdate, RepositoryValidator, ResolvedVocabulary, ScoredEntity, SearchHit, SearchOptions, SearchProvider, SearchableEntity, SelfReferentialRelationshipError, StorageExploreOptions, StorageFindQuery, StorageNeighborhood, StoragePathOptions, StoragePathResult, StorageProvider, StorageRepositoryConfig, StorageTimelineOptions, StorageTimelineResult, StoredEntity, StoredEntityUpdate, StoredRelationship, StoredRepository, StoredRepositorySummary, TimelineOptions, TimelineResult, type TraversalCompiler, TraversalResult, TraversalSpec, TraversalTimeoutError, TraversalValidationError, TraversalVocabularyError, Unsubscribe, UpdateEntityInput, ValidateEntitiesOptions, ValidateRelationshipsOptions, VocabularyChangeRecord, VocabularyProposal, VocabularyProposalResult, VocabularyValidationError, generateId, isValidUuid, matchesPropertyFilters, projectEntity };