The community member is looking for a way to get a message object from Portkey without having to use the Langchain package. The comments indicate that Portkey does not provide a standardized message format, and the community members explain that this is a conscious decision to follow the OpenAI schema rather than creating their own abstraction. The community members suggest that the user would need to parse the JSON data and read the role key to determine the conversation role.
Hey guys π Is there any imports to get a message object from portkey? Langchain has AIMessage, HumanMessage etc and id prefer not to download the langchain package so I was wondering if you guys use some standardized message format without resorting to json
@Vrushank | Portkey not something I can't live without necessarily, I just have to convert and revert in my llm class, but it makes sense for me to use it as it declutters my code
since portkey is a unified platform for LLMs it seems logical to me that the key data structures are also unified. I dont think it should give you an error if you try to invoke with a list of langchain messages for example.
How come the decision was to keep it that way? Does it simplify the api call?