Token Consumption for Embedding API #6592
-
In semantic kernel implementation of the GetEmbeddingAsync Method, though the api returns the usage information, that is not bubbled up . Is there any reason why it is not? Also is there any plans to bubble it up to the call chain and make available to the caller? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
@jmurkothintel Thanks for your question. We have ADR for new embedding design, which takes that into account and allows to return metadata as well. We will need to prioritize this item. |
Beta Was this translation helpful? Give feedback.
@jmurkothintel Thanks for your question.
Current embeddings API doesn't allow to include metadata, since it returns multiple
ReadOnlyMemory
objects only:semantic-kernel/dotnet/src/SemanticKernel.Abstractions/AI/Embeddings/IEmbeddingGenerationService.cs
Line 28 in bebe127
We have ADR for new embedding design, which takes that into account and allows to return metadata as well. We will need to prioritize this item.