From 991f297965ed28f1246e800de491c2fa650f902e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rodrigo=20Liberoff=20V=C3=A1zquez?= Date: Fri, 19 Jan 2024 13:09:05 +0100 Subject: [PATCH 1/2] - Signature of `UpsertMemoryAsync` method has changed in `IMemoryManager` interface. - Signature of `BatchUpsertMemoriesAsync` method has changed in `IMemoryManager` interface. - Dependency with `Kernel` has been replace with dependency to `ITextEmbeddingGenerationService` in `MemoryManager` class. Also, added dependency with `ILogger`. --- CHANGELOG.md | 4 +++- Directory.Build.props | 2 +- .../IMemoryManager.cs | 5 ++-- .../IServiceCollectionExtensions.cs | 4 ++-- .../MemoryManager.cs | 23 ++++++++++--------- 5 files changed, 21 insertions(+), 17 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 8c2cbef..c266e32 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -21,13 +21,15 @@ Previous classification is not required if changes are simple or all belong to t ### Braking Changes - Replace dependency with `IMemoryStore` for `IMemoryManager` in abstract class `MemoryStoreHandlerBase`. This affects internal types like the `EphemeralMemoryStoreHandler`. - Removed visibility modifiers in `IMemoryManager` interface. +- Signature of `UpsertMemoryAsync` method has changed in `IMemoryManager` interface. +- Signature of `BatchUpsertMemoriesAsync` method has changed in `IMemoryManager` interface. +- Dependency with `Kernel` has been replace with dependency to `ITextEmbeddingGenerationService` in `MemoryManager` class. Also, added dependency with `ILogger`. ### Major change - Method `GetDocumentConnector` in `DocumentContentExtractorBase` is now `public` instead of `protected`. - New `MemoryManager` property of type `IMemoryManager` in `IMemoryStoreHandler` interface to get read-only access to the underlaying memory manager. - New `MemoryStore` property of type `IMemoryStore` in `IMemoryManager` interface to get read-only access to the underlaying memory store. - Removed unnecessary `Guards` when adding a Memory Manager and the Ephemeral Memory Store Handler. The exceptions will be thrown by the DI engine itself. -- Modified dependency injection lifetime for `MemoryManager` and `EphemeralMemoryStoreHandler` services. ### Minor Changes - Properties `CollectionNamePostfix` and `CollectionNamePrefix` from `MemoryStoreHandlerBase` are now `virtual` instead of `abstract`. diff --git a/Directory.Build.props b/Directory.Build.props index af3ba29..dc174fb 100644 --- a/Directory.Build.props +++ b/Directory.Build.props @@ -17,7 +17,7 @@ 8.1.2 - preview-6 + preview-7