microsoft / microsoft/semantic-kernel
.Net: [MEVD] Throw for non-nullable embedding-generated vector properties without a setter
Open
@roji is already working on this.
Since Apr 25, 2025.
.NET
Build
msft.ext.vectordata
- Dominant language
- C#
- Stars
- 28.6k
- Forks
- 4.8k
- Avg merge
- 14h 13m
- Merged PRs (30d)
- 18
Description
In https://github.com/microsoft/semantic-kernel/issues/10492, we're adding the ability to map arbitrary properties to a data store vector property, via an IEmbeddingGenerator:
[VectorStoreRecordVector(Dimensions: 3)]
public string Description { get; set; }
Such properties aren't read back from the database (embeddings can't be converted back to their source input) - we through if Include Vectors is set to true.
To tighten things a bit, we could validate that such properties are nullable. However, these properties can also be getter-only, as follows:
[VectorStoreRecordData]
public string Description { get; set; }
[VectorStoreRecordVector(Dimensions: 3)]
public string DescriptionEmbedding => Description;
So we should do this only when there's a setter.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.