Repository navigation
Replies: 3 comments 1 reply
|
I got a Requestinterceptor to work by creating a custom Unfortunatly i did not come up with a nice mechanism to dynamically set tags but kinda works for now. |
|
@Pyrokahd Your inquiry is very important, i think we need to plan metadata support. Is it specific to OpenAI, what about other providers? Thank you |
|
@Pyrokahd - thank you very much for the analysis. Appears as one more area of "native" support: thinking, structured output, tools metadata. LLMOptions "extensions" is the proper mechanism for "native" support. Could you please research other LLM providers besides OpenAI? Also, there is tight integration with Spring AI, and architecturally we would like to be less coupled with low-level APIs such as Spring AI and ensure LangChain4J (as an example) can be used instead; see LLMMessageSender examples in the embabel experimental repo. Thanks again! |
Uh oh!
There was an error while loading. Please reload this page.
Hi i have a question regarding metadata.
It seems to be common to send metadata with llm calls and SDKs like OpenAI have their "extra_body" field.
E.g.
response = client.chat.completions.create( model="gpt-4", messages=[{"role": "user", "content": "Hello"}], extra_body={ "metadata": { "tags": ["engineering"] } } )Is there a way to send metadata in embabel as well?
In my case i need to be able to define Tags and send them with my LLM calls in order to correctly track calls via a liteLLM instance which is my custom Openai url.
I tried through Spring ClientHttpRequestInterceptor but they are never called note sure if im doing it wrong.
I also found the
LlmMessageSenderin the docs but since my provider is supported by SpringAi i shouldn`t need it.Spring AI also supports metadata in its chat client https://docs.spring.io/spring-ai/reference/api/chatclient.html#_message_metadata (not sure how exactly embable uses spring ai)
But adding metadata shouldn`t be that complicated imo. Granted Embabel is still in an early development stage.
All reactions