@nexusm/sdk 1.3.2 → 2.0.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.mts +89 -97
- package/dist/index.d.ts +89 -97
- package/dist/index.js.map +1 -1
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -656,122 +656,88 @@ interface ContextRequest {
|
|
|
656
656
|
as_of?: string;
|
|
657
657
|
}
|
|
658
658
|
/**
|
|
659
|
-
* A
|
|
660
|
-
*
|
|
659
|
+
* A user profile memory element (`ContextRetrieveResponse.profile[]`).
|
|
660
|
+
* Mirrors backend `ProfileMemory`.
|
|
661
661
|
*/
|
|
662
|
-
interface
|
|
663
|
-
/**
|
|
664
|
-
|
|
662
|
+
interface ProfileMemory {
|
|
663
|
+
/** Memory identifier */
|
|
664
|
+
memory_id: string;
|
|
665
665
|
/** Memory content text */
|
|
666
666
|
content: string;
|
|
667
|
-
/**
|
|
668
|
-
memory_type:
|
|
667
|
+
/** Memory type */
|
|
668
|
+
memory_type: string;
|
|
669
|
+
/** Optional category */
|
|
670
|
+
category?: string | null;
|
|
669
671
|
/** Relevance score from similarity search */
|
|
670
|
-
|
|
671
|
-
/**
|
|
672
|
-
|
|
672
|
+
similarity_score?: number | null;
|
|
673
|
+
/** Arbitrary metadata */
|
|
674
|
+
metadata?: Record<string, unknown>;
|
|
673
675
|
}
|
|
674
676
|
/**
|
|
675
|
-
*
|
|
676
|
-
*
|
|
677
|
+
* A conversation message element (`ContextRetrieveResponse.history[]`).
|
|
678
|
+
* Mirrors backend `ConversationMessage`.
|
|
677
679
|
*/
|
|
678
|
-
interface
|
|
679
|
-
/**
|
|
680
|
-
|
|
681
|
-
/** Total number of memories the user has */
|
|
682
|
-
total_count: number;
|
|
683
|
-
}
|
|
684
|
-
/** A single message within conversation history. */
|
|
685
|
-
interface ContextMessage {
|
|
680
|
+
interface ConversationMessage {
|
|
681
|
+
/** Message identifier */
|
|
682
|
+
message_id: string;
|
|
686
683
|
/** Message role */
|
|
687
684
|
role: 'user' | 'assistant' | 'system' | 'tool';
|
|
688
685
|
/** Message content text */
|
|
689
686
|
content: string;
|
|
690
|
-
/**
|
|
687
|
+
/** Creation timestamp (ISO 8601) */
|
|
691
688
|
created_at: string;
|
|
689
|
+
/** Arbitrary metadata */
|
|
690
|
+
metadata?: Record<string, unknown>;
|
|
692
691
|
}
|
|
693
692
|
/**
|
|
694
|
-
*
|
|
695
|
-
*
|
|
696
|
-
*/
|
|
697
|
-
interface ContextHistory {
|
|
698
|
-
/** List of recent messages */
|
|
699
|
-
messages: ContextMessage[];
|
|
700
|
-
/** Auto-generated conversation summary (if available) */
|
|
701
|
-
summary?: string;
|
|
702
|
-
/** Session identifier */
|
|
703
|
-
session_id?: string;
|
|
704
|
-
}
|
|
705
|
-
/** Entity ownership type in the knowledge graph */
|
|
706
|
-
type OwnerType = 'agent' | 'user';
|
|
707
|
-
/**
|
|
708
|
-
* A knowledge entity within the graph context.
|
|
709
|
-
* Sourced from Fast GraphRAG.
|
|
693
|
+
* A knowledge graph entity element (`ContextRetrieveResponse.graph[]`).
|
|
694
|
+
* Mirrors backend `ContextGraphEntity`.
|
|
710
695
|
*/
|
|
711
|
-
interface
|
|
712
|
-
/**
|
|
713
|
-
|
|
696
|
+
interface ContextGraphEntity {
|
|
697
|
+
/** Entity identifier */
|
|
698
|
+
entity_id: string;
|
|
714
699
|
/** Entity display name */
|
|
715
700
|
name: string;
|
|
716
|
-
/** Entity type classification
|
|
717
|
-
|
|
701
|
+
/** Entity type classification */
|
|
702
|
+
type: string;
|
|
718
703
|
/** Entity description */
|
|
719
|
-
description?: string;
|
|
720
|
-
/**
|
|
721
|
-
|
|
722
|
-
/**
|
|
723
|
-
|
|
724
|
-
}
|
|
725
|
-
/** A relationship between two entities in the knowledge graph. */
|
|
726
|
-
interface ContextRelation {
|
|
727
|
-
/** Source entity name */
|
|
728
|
-
source: string;
|
|
729
|
-
/** Relationship type label */
|
|
730
|
-
relation: string;
|
|
731
|
-
/** Target entity name */
|
|
732
|
-
target: string;
|
|
733
|
-
/** Relationship weight/strength */
|
|
734
|
-
weight?: number;
|
|
735
|
-
}
|
|
736
|
-
/**
|
|
737
|
-
* Knowledge graph section of the context response.
|
|
738
|
-
* Sourced from Fast GraphRAG.
|
|
739
|
-
*/
|
|
740
|
-
interface ContextGraph {
|
|
741
|
-
/** List of relevant entities */
|
|
742
|
-
entities: ContextEntity[];
|
|
743
|
-
/** List of relationships between entities */
|
|
744
|
-
relations: ContextRelation[];
|
|
745
|
-
}
|
|
746
|
-
/**
|
|
747
|
-
* Retrieval performance metadata.
|
|
748
|
-
* Provides timing information for each retrieval layer.
|
|
749
|
-
*/
|
|
750
|
-
interface ContextMeta {
|
|
751
|
-
/** Total retrieval time in milliseconds */
|
|
752
|
-
took_ms: number;
|
|
753
|
-
/** Memory retrieval time in milliseconds */
|
|
754
|
-
memory_took_ms?: number;
|
|
755
|
-
/** History retrieval time in milliseconds */
|
|
756
|
-
history_took_ms?: number;
|
|
757
|
-
/** Graph retrieval time in milliseconds */
|
|
758
|
-
graph_took_ms?: number;
|
|
759
|
-
/** Original query text */
|
|
760
|
-
query?: string;
|
|
704
|
+
description?: string | null;
|
|
705
|
+
/** Relationships (free-form objects) */
|
|
706
|
+
relationships?: Array<Record<string, unknown>>;
|
|
707
|
+
/** Relevance score for unified ranking */
|
|
708
|
+
relevance_score?: number;
|
|
761
709
|
}
|
|
762
710
|
/**
|
|
763
711
|
* Aggregated context response from the retrieve endpoint.
|
|
764
|
-
*
|
|
712
|
+
*
|
|
713
|
+
* **v2.0.0 BREAKING (contract reconciliation, ADR-003):** canonical = backend
|
|
714
|
+
* flat-array shape. `profile`/`history`/`graph` are now flat arrays (not nested
|
|
715
|
+
* `{memories,...}` containers); `meta` is removed (use `total_latency_ms`);
|
|
716
|
+
* top-level diagnostic/identity fields are surfaced directly.
|
|
765
717
|
*/
|
|
766
718
|
interface ContextRetrieveResponse {
|
|
767
|
-
/**
|
|
768
|
-
|
|
769
|
-
/**
|
|
770
|
-
|
|
771
|
-
/**
|
|
772
|
-
|
|
773
|
-
/**
|
|
774
|
-
|
|
719
|
+
/** Unique retrieval ID for feedback association (PUT /feedback/{retrieve_id}, 7d window) */
|
|
720
|
+
retrieve_id?: string | null;
|
|
721
|
+
/** User profile memories (flat array) */
|
|
722
|
+
profile?: ProfileMemory[] | null;
|
|
723
|
+
/** Conversation history (flat array) */
|
|
724
|
+
history?: ConversationMessage[] | null;
|
|
725
|
+
/** Knowledge graph entities (flat array) */
|
|
726
|
+
graph?: ContextGraphEntity[] | null;
|
|
727
|
+
/** AI-synthesized user profile (free-form key-value) */
|
|
728
|
+
ai_profile?: Record<string, unknown> | null;
|
|
729
|
+
/** Retrieval completion timestamp (ISO 8601) */
|
|
730
|
+
retrieved_at: string;
|
|
731
|
+
/** Total retrieval time in milliseconds */
|
|
732
|
+
total_latency_ms: number;
|
|
733
|
+
/** Partial-failure errors (sub-service name -> message) */
|
|
734
|
+
errors?: Record<string, string> | null;
|
|
735
|
+
/** A/B experiment group assignment (US-030) */
|
|
736
|
+
experiment_group?: 'control' | 'treatment' | 'override_vector' | 'override_rerank' | 'error' | null;
|
|
737
|
+
/** Count of memories removed by US-035 temporal validity filter (diagnostic; 0 = none filtered) */
|
|
738
|
+
temporal_filtered_count?: number | null;
|
|
739
|
+
/** Echoes the request `as_of` anchor (null for current-time retrieval) */
|
|
740
|
+
as_of?: string | null;
|
|
775
741
|
}
|
|
776
742
|
|
|
777
743
|
/**
|
|
@@ -914,16 +880,42 @@ interface MemorySearch {
|
|
|
914
880
|
*/
|
|
915
881
|
threshold?: number;
|
|
916
882
|
}
|
|
883
|
+
/**
|
|
884
|
+
* A single semantic-search result element (`MemorySearchResult.results[]`).
|
|
885
|
+
* Mirrors backend `SearchResult` (flat — not a nested `Memory` object).
|
|
886
|
+
*
|
|
887
|
+
* @since 2.0.0
|
|
888
|
+
*/
|
|
889
|
+
interface SearchResult {
|
|
890
|
+
/** Memory identifier */
|
|
891
|
+
memory_id: string;
|
|
892
|
+
/** Memory content text */
|
|
893
|
+
content: string;
|
|
894
|
+
/** Memory type */
|
|
895
|
+
memory_type: string;
|
|
896
|
+
/** Similarity score (0..1) */
|
|
897
|
+
similarity: number;
|
|
898
|
+
/** Arbitrary metadata */
|
|
899
|
+
metadata?: Record<string, unknown>;
|
|
900
|
+
}
|
|
917
901
|
/**
|
|
918
902
|
* Response from a semantic memory search operation.
|
|
903
|
+
*
|
|
904
|
+
* **v2.0.0 BREAKING (contract reconciliation, ADR-003):** canonical = backend
|
|
905
|
+
* `MemorySearchResponse`. `results` is now a flat `SearchResult[]` (not
|
|
906
|
+
* `Memory[]`); `took_ms` renamed `search_time_ms`; `total_found` added.
|
|
907
|
+
* (Backend response_model is named `MemorySearchResponse`; this SDK type keeps
|
|
908
|
+
* the name `MemorySearchResult` — shapes are identical.)
|
|
919
909
|
*/
|
|
920
910
|
interface MemorySearchResult {
|
|
921
|
-
/**
|
|
922
|
-
results:
|
|
911
|
+
/** Matching results (flat) */
|
|
912
|
+
results: SearchResult[];
|
|
923
913
|
/** Original search query */
|
|
924
914
|
query: string;
|
|
915
|
+
/** Total number of matches found */
|
|
916
|
+
total_found: number;
|
|
925
917
|
/** Search execution time in milliseconds */
|
|
926
|
-
|
|
918
|
+
search_time_ms: number;
|
|
927
919
|
}
|
|
928
920
|
/**
|
|
929
921
|
* Paginated list of memories.
|
|
@@ -2569,4 +2561,4 @@ declare const apiKeyCreateSchema: z.ZodObject<{
|
|
|
2569
2561
|
expires_days?: number | undefined;
|
|
2570
2562
|
}>;
|
|
2571
2563
|
|
|
2572
|
-
export { type Activity, type ActivityProcessingStatus, ActivityService, type ActivityStats, type ActivityStatusResponse, type ActivityStreamRequest, type ActivityStreamResponse, type ActivityType, ApiError, type ApiErrorDetail, type ApiKey, type ApiKeyCreate, type ApiKeyCreated, type ApiKeyScope, type ApiResponse, AuthenticationError, type CacheConfig, type CompoundId, ConfigurationError, type ContextDepth, type ContextDepthPreset, type
|
|
2564
|
+
export { type Activity, type ActivityProcessingStatus, ActivityService, type ActivityStats, type ActivityStatusResponse, type ActivityStreamRequest, type ActivityStreamResponse, type ActivityType, ApiError, type ApiErrorDetail, type ApiKey, type ApiKeyCreate, type ApiKeyCreated, type ApiKeyScope, type ApiResponse, AuthenticationError, type CacheConfig, type CompoundId, ConfigurationError, type ContextDepth, type ContextDepthPreset, type ContextGraphEntity, type ContextLayer, type ContextRequest, type ContextRetrieveResponse, ContextService, type Conversation, type ConversationCreate, type ConversationDetail, type ConversationList, type ConversationListParams, type ConversationMessage, ConversationService, type ConversationStatus, type ConversationSummary, DEFAULT_CONFIG, DEPTH_PRESETS, type EntityCreate, type EntityListParams, type EntityListResponse, type ErrorReportRequest, type ErrorReportResponse, ErrorService, type ErrorSeverity, type ErrorType, type ExtractionRequest, type ExtractionResult, type FeedbackItemRequest, type FeedbackListItem, type FeedbackListParams, type FeedbackListResponse, type FeedbackResponse, FeedbackService, type FeedbackSubmitRequest, type GraphPath, type GraphPathEntity, type GraphPathRelationship, type GraphQueryRequest, type GraphQueryResponse, type HealthResponse, type HealthStatus, InputValidationError, type JournalEntry, type JournalResponse, type KnowledgeEntity, type KnowledgeRelationship, KnowledgeService, type Memory, type MemoryCreate, type MemoryJournalParams, type MemoryList, type MemoryListParams, type MemorySearch, type MemorySearchResult, MemoryService, type MemoryType, type MemoryUpdate, type Message, type MessageCreate, type MessageList, type MessageListParams, type MessageRole, NetworkError, NexusClient, type NexusConfig, NexusError, NotFoundError, type OfflineConfig, OfflineQueue, type PaginatedResponse, type Pagination, type ProfileMemory, type QueuedRequest, RateLimitError, type RequestOptions, type ResolvedCacheConfig, type ResolvedConfig, type ResolvedRetryConfig, type RetryConfig, type SearchResult, type ServiceStatus, type SortOrder, type Tenant, type TenantQuotas, TenantService, type TenantTier, type TenantUsage, TimeoutError, type UsageStats, ValidationError, apiKeyCreateSchema, contextRequestSchema, conversationCreateSchema, entityCreateSchema, extractionRequestSchema, graphQueryRequestSchema, memoryCreateSchema, memorySearchSchema, memoryUpdateSchema, messageCreateSchema, resolveConfig };
|
package/dist/index.d.ts
CHANGED
|
@@ -656,122 +656,88 @@ interface ContextRequest {
|
|
|
656
656
|
as_of?: string;
|
|
657
657
|
}
|
|
658
658
|
/**
|
|
659
|
-
* A
|
|
660
|
-
*
|
|
659
|
+
* A user profile memory element (`ContextRetrieveResponse.profile[]`).
|
|
660
|
+
* Mirrors backend `ProfileMemory`.
|
|
661
661
|
*/
|
|
662
|
-
interface
|
|
663
|
-
/**
|
|
664
|
-
|
|
662
|
+
interface ProfileMemory {
|
|
663
|
+
/** Memory identifier */
|
|
664
|
+
memory_id: string;
|
|
665
665
|
/** Memory content text */
|
|
666
666
|
content: string;
|
|
667
|
-
/**
|
|
668
|
-
memory_type:
|
|
667
|
+
/** Memory type */
|
|
668
|
+
memory_type: string;
|
|
669
|
+
/** Optional category */
|
|
670
|
+
category?: string | null;
|
|
669
671
|
/** Relevance score from similarity search */
|
|
670
|
-
|
|
671
|
-
/**
|
|
672
|
-
|
|
672
|
+
similarity_score?: number | null;
|
|
673
|
+
/** Arbitrary metadata */
|
|
674
|
+
metadata?: Record<string, unknown>;
|
|
673
675
|
}
|
|
674
676
|
/**
|
|
675
|
-
*
|
|
676
|
-
*
|
|
677
|
+
* A conversation message element (`ContextRetrieveResponse.history[]`).
|
|
678
|
+
* Mirrors backend `ConversationMessage`.
|
|
677
679
|
*/
|
|
678
|
-
interface
|
|
679
|
-
/**
|
|
680
|
-
|
|
681
|
-
/** Total number of memories the user has */
|
|
682
|
-
total_count: number;
|
|
683
|
-
}
|
|
684
|
-
/** A single message within conversation history. */
|
|
685
|
-
interface ContextMessage {
|
|
680
|
+
interface ConversationMessage {
|
|
681
|
+
/** Message identifier */
|
|
682
|
+
message_id: string;
|
|
686
683
|
/** Message role */
|
|
687
684
|
role: 'user' | 'assistant' | 'system' | 'tool';
|
|
688
685
|
/** Message content text */
|
|
689
686
|
content: string;
|
|
690
|
-
/**
|
|
687
|
+
/** Creation timestamp (ISO 8601) */
|
|
691
688
|
created_at: string;
|
|
689
|
+
/** Arbitrary metadata */
|
|
690
|
+
metadata?: Record<string, unknown>;
|
|
692
691
|
}
|
|
693
692
|
/**
|
|
694
|
-
*
|
|
695
|
-
*
|
|
696
|
-
*/
|
|
697
|
-
interface ContextHistory {
|
|
698
|
-
/** List of recent messages */
|
|
699
|
-
messages: ContextMessage[];
|
|
700
|
-
/** Auto-generated conversation summary (if available) */
|
|
701
|
-
summary?: string;
|
|
702
|
-
/** Session identifier */
|
|
703
|
-
session_id?: string;
|
|
704
|
-
}
|
|
705
|
-
/** Entity ownership type in the knowledge graph */
|
|
706
|
-
type OwnerType = 'agent' | 'user';
|
|
707
|
-
/**
|
|
708
|
-
* A knowledge entity within the graph context.
|
|
709
|
-
* Sourced from Fast GraphRAG.
|
|
693
|
+
* A knowledge graph entity element (`ContextRetrieveResponse.graph[]`).
|
|
694
|
+
* Mirrors backend `ContextGraphEntity`.
|
|
710
695
|
*/
|
|
711
|
-
interface
|
|
712
|
-
/**
|
|
713
|
-
|
|
696
|
+
interface ContextGraphEntity {
|
|
697
|
+
/** Entity identifier */
|
|
698
|
+
entity_id: string;
|
|
714
699
|
/** Entity display name */
|
|
715
700
|
name: string;
|
|
716
|
-
/** Entity type classification
|
|
717
|
-
|
|
701
|
+
/** Entity type classification */
|
|
702
|
+
type: string;
|
|
718
703
|
/** Entity description */
|
|
719
|
-
description?: string;
|
|
720
|
-
/**
|
|
721
|
-
|
|
722
|
-
/**
|
|
723
|
-
|
|
724
|
-
}
|
|
725
|
-
/** A relationship between two entities in the knowledge graph. */
|
|
726
|
-
interface ContextRelation {
|
|
727
|
-
/** Source entity name */
|
|
728
|
-
source: string;
|
|
729
|
-
/** Relationship type label */
|
|
730
|
-
relation: string;
|
|
731
|
-
/** Target entity name */
|
|
732
|
-
target: string;
|
|
733
|
-
/** Relationship weight/strength */
|
|
734
|
-
weight?: number;
|
|
735
|
-
}
|
|
736
|
-
/**
|
|
737
|
-
* Knowledge graph section of the context response.
|
|
738
|
-
* Sourced from Fast GraphRAG.
|
|
739
|
-
*/
|
|
740
|
-
interface ContextGraph {
|
|
741
|
-
/** List of relevant entities */
|
|
742
|
-
entities: ContextEntity[];
|
|
743
|
-
/** List of relationships between entities */
|
|
744
|
-
relations: ContextRelation[];
|
|
745
|
-
}
|
|
746
|
-
/**
|
|
747
|
-
* Retrieval performance metadata.
|
|
748
|
-
* Provides timing information for each retrieval layer.
|
|
749
|
-
*/
|
|
750
|
-
interface ContextMeta {
|
|
751
|
-
/** Total retrieval time in milliseconds */
|
|
752
|
-
took_ms: number;
|
|
753
|
-
/** Memory retrieval time in milliseconds */
|
|
754
|
-
memory_took_ms?: number;
|
|
755
|
-
/** History retrieval time in milliseconds */
|
|
756
|
-
history_took_ms?: number;
|
|
757
|
-
/** Graph retrieval time in milliseconds */
|
|
758
|
-
graph_took_ms?: number;
|
|
759
|
-
/** Original query text */
|
|
760
|
-
query?: string;
|
|
704
|
+
description?: string | null;
|
|
705
|
+
/** Relationships (free-form objects) */
|
|
706
|
+
relationships?: Array<Record<string, unknown>>;
|
|
707
|
+
/** Relevance score for unified ranking */
|
|
708
|
+
relevance_score?: number;
|
|
761
709
|
}
|
|
762
710
|
/**
|
|
763
711
|
* Aggregated context response from the retrieve endpoint.
|
|
764
|
-
*
|
|
712
|
+
*
|
|
713
|
+
* **v2.0.0 BREAKING (contract reconciliation, ADR-003):** canonical = backend
|
|
714
|
+
* flat-array shape. `profile`/`history`/`graph` are now flat arrays (not nested
|
|
715
|
+
* `{memories,...}` containers); `meta` is removed (use `total_latency_ms`);
|
|
716
|
+
* top-level diagnostic/identity fields are surfaced directly.
|
|
765
717
|
*/
|
|
766
718
|
interface ContextRetrieveResponse {
|
|
767
|
-
/**
|
|
768
|
-
|
|
769
|
-
/**
|
|
770
|
-
|
|
771
|
-
/**
|
|
772
|
-
|
|
773
|
-
/**
|
|
774
|
-
|
|
719
|
+
/** Unique retrieval ID for feedback association (PUT /feedback/{retrieve_id}, 7d window) */
|
|
720
|
+
retrieve_id?: string | null;
|
|
721
|
+
/** User profile memories (flat array) */
|
|
722
|
+
profile?: ProfileMemory[] | null;
|
|
723
|
+
/** Conversation history (flat array) */
|
|
724
|
+
history?: ConversationMessage[] | null;
|
|
725
|
+
/** Knowledge graph entities (flat array) */
|
|
726
|
+
graph?: ContextGraphEntity[] | null;
|
|
727
|
+
/** AI-synthesized user profile (free-form key-value) */
|
|
728
|
+
ai_profile?: Record<string, unknown> | null;
|
|
729
|
+
/** Retrieval completion timestamp (ISO 8601) */
|
|
730
|
+
retrieved_at: string;
|
|
731
|
+
/** Total retrieval time in milliseconds */
|
|
732
|
+
total_latency_ms: number;
|
|
733
|
+
/** Partial-failure errors (sub-service name -> message) */
|
|
734
|
+
errors?: Record<string, string> | null;
|
|
735
|
+
/** A/B experiment group assignment (US-030) */
|
|
736
|
+
experiment_group?: 'control' | 'treatment' | 'override_vector' | 'override_rerank' | 'error' | null;
|
|
737
|
+
/** Count of memories removed by US-035 temporal validity filter (diagnostic; 0 = none filtered) */
|
|
738
|
+
temporal_filtered_count?: number | null;
|
|
739
|
+
/** Echoes the request `as_of` anchor (null for current-time retrieval) */
|
|
740
|
+
as_of?: string | null;
|
|
775
741
|
}
|
|
776
742
|
|
|
777
743
|
/**
|
|
@@ -914,16 +880,42 @@ interface MemorySearch {
|
|
|
914
880
|
*/
|
|
915
881
|
threshold?: number;
|
|
916
882
|
}
|
|
883
|
+
/**
|
|
884
|
+
* A single semantic-search result element (`MemorySearchResult.results[]`).
|
|
885
|
+
* Mirrors backend `SearchResult` (flat — not a nested `Memory` object).
|
|
886
|
+
*
|
|
887
|
+
* @since 2.0.0
|
|
888
|
+
*/
|
|
889
|
+
interface SearchResult {
|
|
890
|
+
/** Memory identifier */
|
|
891
|
+
memory_id: string;
|
|
892
|
+
/** Memory content text */
|
|
893
|
+
content: string;
|
|
894
|
+
/** Memory type */
|
|
895
|
+
memory_type: string;
|
|
896
|
+
/** Similarity score (0..1) */
|
|
897
|
+
similarity: number;
|
|
898
|
+
/** Arbitrary metadata */
|
|
899
|
+
metadata?: Record<string, unknown>;
|
|
900
|
+
}
|
|
917
901
|
/**
|
|
918
902
|
* Response from a semantic memory search operation.
|
|
903
|
+
*
|
|
904
|
+
* **v2.0.0 BREAKING (contract reconciliation, ADR-003):** canonical = backend
|
|
905
|
+
* `MemorySearchResponse`. `results` is now a flat `SearchResult[]` (not
|
|
906
|
+
* `Memory[]`); `took_ms` renamed `search_time_ms`; `total_found` added.
|
|
907
|
+
* (Backend response_model is named `MemorySearchResponse`; this SDK type keeps
|
|
908
|
+
* the name `MemorySearchResult` — shapes are identical.)
|
|
919
909
|
*/
|
|
920
910
|
interface MemorySearchResult {
|
|
921
|
-
/**
|
|
922
|
-
results:
|
|
911
|
+
/** Matching results (flat) */
|
|
912
|
+
results: SearchResult[];
|
|
923
913
|
/** Original search query */
|
|
924
914
|
query: string;
|
|
915
|
+
/** Total number of matches found */
|
|
916
|
+
total_found: number;
|
|
925
917
|
/** Search execution time in milliseconds */
|
|
926
|
-
|
|
918
|
+
search_time_ms: number;
|
|
927
919
|
}
|
|
928
920
|
/**
|
|
929
921
|
* Paginated list of memories.
|
|
@@ -2569,4 +2561,4 @@ declare const apiKeyCreateSchema: z.ZodObject<{
|
|
|
2569
2561
|
expires_days?: number | undefined;
|
|
2570
2562
|
}>;
|
|
2571
2563
|
|
|
2572
|
-
export { type Activity, type ActivityProcessingStatus, ActivityService, type ActivityStats, type ActivityStatusResponse, type ActivityStreamRequest, type ActivityStreamResponse, type ActivityType, ApiError, type ApiErrorDetail, type ApiKey, type ApiKeyCreate, type ApiKeyCreated, type ApiKeyScope, type ApiResponse, AuthenticationError, type CacheConfig, type CompoundId, ConfigurationError, type ContextDepth, type ContextDepthPreset, type
|
|
2564
|
+
export { type Activity, type ActivityProcessingStatus, ActivityService, type ActivityStats, type ActivityStatusResponse, type ActivityStreamRequest, type ActivityStreamResponse, type ActivityType, ApiError, type ApiErrorDetail, type ApiKey, type ApiKeyCreate, type ApiKeyCreated, type ApiKeyScope, type ApiResponse, AuthenticationError, type CacheConfig, type CompoundId, ConfigurationError, type ContextDepth, type ContextDepthPreset, type ContextGraphEntity, type ContextLayer, type ContextRequest, type ContextRetrieveResponse, ContextService, type Conversation, type ConversationCreate, type ConversationDetail, type ConversationList, type ConversationListParams, type ConversationMessage, ConversationService, type ConversationStatus, type ConversationSummary, DEFAULT_CONFIG, DEPTH_PRESETS, type EntityCreate, type EntityListParams, type EntityListResponse, type ErrorReportRequest, type ErrorReportResponse, ErrorService, type ErrorSeverity, type ErrorType, type ExtractionRequest, type ExtractionResult, type FeedbackItemRequest, type FeedbackListItem, type FeedbackListParams, type FeedbackListResponse, type FeedbackResponse, FeedbackService, type FeedbackSubmitRequest, type GraphPath, type GraphPathEntity, type GraphPathRelationship, type GraphQueryRequest, type GraphQueryResponse, type HealthResponse, type HealthStatus, InputValidationError, type JournalEntry, type JournalResponse, type KnowledgeEntity, type KnowledgeRelationship, KnowledgeService, type Memory, type MemoryCreate, type MemoryJournalParams, type MemoryList, type MemoryListParams, type MemorySearch, type MemorySearchResult, MemoryService, type MemoryType, type MemoryUpdate, type Message, type MessageCreate, type MessageList, type MessageListParams, type MessageRole, NetworkError, NexusClient, type NexusConfig, NexusError, NotFoundError, type OfflineConfig, OfflineQueue, type PaginatedResponse, type Pagination, type ProfileMemory, type QueuedRequest, RateLimitError, type RequestOptions, type ResolvedCacheConfig, type ResolvedConfig, type ResolvedRetryConfig, type RetryConfig, type SearchResult, type ServiceStatus, type SortOrder, type Tenant, type TenantQuotas, TenantService, type TenantTier, type TenantUsage, TimeoutError, type UsageStats, ValidationError, apiKeyCreateSchema, contextRequestSchema, conversationCreateSchema, entityCreateSchema, extractionRequestSchema, graphQueryRequestSchema, memoryCreateSchema, memorySearchSchema, memoryUpdateSchema, messageCreateSchema, resolveConfig };
|