Orchestrating Streamlit apps using API

Hi Team,
We are using Streamlit for LLM usecases, right now the streamlit app asks a bunch of questions to a user, and then uses the inputs to generate prompts and then runs prompts and returns output.
Streamlit has made it really easy for iteration of the concept, and running apps.

However the key challenge right now is on how to integrate Streamlit with other proceses. Having some form of an api to fill some parts of the streamlit app, and also orchestrate it in some cases, without replicating the whole logic, packages of streamlit into another service would help.

Hi @Vamshi_Krishna,

Thanks for your feedback!

Do you find yourself re-using a lot of the elements and could you share which ones specifically you would like some abstraction to?

I would also recommend creating utility functions for elements that you can re-use for specific parts of your app.

One approach to integrating Streamlit with other processes is to develop a RESTful API that interacts with the Streamlit app, allowing for data exchange and orchestration. This enables other services to interact with specific parts of the Streamlit app without duplicating its logic or packages. Moreover, utilizing webhooks or messaging queues can facilitate seamless communication between Streamlit and external processes, enhancing flexibility and scalability.

Hi @Vamshi_Krishna

I have seen others explore the use of FastAPI with Streamlit. Here are some tutorial blogs that can give you some ideas:

Hope this helps!

1 Like

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.