Get hands-on experience with 20+ free Google Cloud products and $300 in free credit for new customers.

ABAP SDK - multi-turn conversation?

I have installed the sdk and it looks great. I can send a simple request and get a response but I have seen no option to do a multi-turn conversation. Did I overlook this option? I assume just appending the user messages and model responses into the user message has some disadvantages over having user and assistant messages.

Solved Solved
0 4 301
1 ACCEPTED SOLUTION

@wommel ....Thanks for your question....the current SDK in it's shape and form primarily focusses on invoking Gemini for SAP enterprises use cases....which in ABAP application programming world is not usually multi turn and you would invoke Gemini with a business prompt to derive a grounded response (RAG)....

I would like to know your use case further to see how to assist you better with multiturn conversation based implementation....

PS: I am part of the product team which engineered the ABAP SDK....and hence would like to learn about your use case to assist you better....

View solution in original post

4 REPLIES 4

Hi @wommel,

Welcome to Google Cloud Community!

The ABAP SDK documentation focuses primarily on the technical details of interacting with LLMs, such as sending requests and processing responses. It doesn't offer built-in features or instructions for managing multi-turn conversations. Instead, building conversational flows within the SDK requires you to leverage your existing ABAP expertise alongside prompt engineering techniques.

Here are relevant documentation that may help you:

Additionally, check these resources SAP Help Portal and SAP Community for any documentation related to ABAP development, database access, and HTTP client classes (ex: cl_http_client). Furthermore, refer to the documentation for the LLM service you’re using (ex: OpenAI, Azure OpenAI) to learn about their specific recommendations for crafting effective conversational prompts.


Was this helpful? If so, please accept this answer as “Solution”. If you need additional assistance, reply here within 2 business days and I’ll be happy to help.

@wommel ....Thanks for your question....the current SDK in it's shape and form primarily focusses on invoking Gemini for SAP enterprises use cases....which in ABAP application programming world is not usually multi turn and you would invoke Gemini with a business prompt to derive a grounded response (RAG)....

I would like to know your use case further to see how to assist you better with multiturn conversation based implementation....

PS: I am part of the product team which engineered the ABAP SDK....and hence would like to learn about your use case to assist you better....

@devesh-sapcloud thanks a lot for your reply. Yeah I understand now better why it is the way it is. I currently don't have a specific multi-turn use case in mind. I am writing a multi-provider llm client and I was wondering if this sdk means less effort than to implement the API directly especially since the API looked quite overwhelming at first 😉

I can think of multi-turn use cases but probably less common as part of business processes, more as development support or eventually with agents. Possible that all those could be worked around by somehow combining prompts and results of previous steps. As all of this is still in early stages I unfortunately cannot give you a really compelling use case currently. 

Hello @wommel ....we just released V1.10 version of the ABAP SDK....with this version you get the opportunity to add conversation history during Gemini invocation....please take a look.

Also here is our sample GenAI solution based on this feature (for reference) on how to build SAP ABAP based Conversation Agents....please take a look and let us know if you have any questions.