MemoryRecord.FromMetadata Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Create a memory record from a memory record's metadata.
public static Microsoft.SemanticKernel.Memory.MemoryRecord FromMetadata (Microsoft.SemanticKernel.Memory.MemoryRecordMetadata metadata, ReadOnlyMemory<float> embedding, string? key = default, DateTimeOffset? timestamp = default);
static member FromMetadata : Microsoft.SemanticKernel.Memory.MemoryRecordMetadata * ReadOnlyMemory<single> * string * Nullable<DateTimeOffset> -> Microsoft.SemanticKernel.Memory.MemoryRecord
Public Shared Function FromMetadata (metadata As MemoryRecordMetadata, embedding As ReadOnlyMemory(Of Single), Optional key As String = Nothing, Optional timestamp As Nullable(Of DateTimeOffset) = Nothing) As MemoryRecord
Parameters
- metadata
- MemoryRecordMetadata
Metadata associated with a memory.
- embedding
- ReadOnlyMemory<Single>
Optional embedding associated with a memory record.
- key
- String
Optional existing database key.
- timestamp
- Nullable<DateTimeOffset>
optional timestamp.
Returns
Memory record