Relative Content

Tag Archive for pythonsql-serverdataframeobjectlangchain

Passing Complex Objects Through Routes and Functions in Langchain Flask App

I am building a chatbot application that connects to an SQL server, grabs custom data tables, turns them into pandas dataframes, and then uses them with a Langchain agent. Upon the page loading/sign in, the user’s email is used to determine the access level of sensitive information that is pulled from different SQL tables in the same database. These tables are stored in dataframes and passed to a pandas Langchain agent along with my llm. Whenever the user asks a question, it invokes the agent who will then respond. On my backend, I also check for if the user wants some form of visualization and create it using plotly, the dataframes, and custom code that I get the agent to create.