postgres-chatbot — Gemini Agents | Neura Market
    Neura MarketNeura Market/Gemini
    ChatGPTChatGPTClaudeClaudeGeminiGeminiCursorCursorGrokGrokPerplexityPerplexityDeepSeekDeepSeek
    CoPilotCoPilotStable DiffusionStable DiffusionMidjourneyMidjourney
    View All Directories
    OverviewRulesPromptsMCPsAgentsBlogVideosGuidesCoursesCommunityGemsExtensionsTrendingGenerate
    GeminiAgentspostgres-chatbot
    Back to Agents
    postgres-chatbot

    postgres-chatbot

    BlueBash May 21, 2024
    22 copies 0 downloads

    This Streamlit application allows users to interact with their PostgreSQL database using natural language queries. Users can type questions in natural language, which the app translates into SQL queries executed against the database. The results are then displayed in the chat interface. Powered by Google Generative AI and LangChain's SQL agent tool

    Agent Definition
    # README.md
    
    ## Project Title: Postgres Chatbot with Streamlit
    
    
    ### Introduction
    
    This project aims to develop a chatbot that can interact with a PostgreSQL database and answer queries in natural language. The chatbot will be able to handle queries related to an `Orders` table, which includes columns such as `order_id`, `customer_email`, `tracking_number`, `shipping_service`, `tracking_URL`, `order_created_at`, and `order_shipped_at`.
    
    The chatbot will be designed to understand and respond to layman language questions, such as:
    1. "Give me the status of order number 12222."
    2. "What is the order ID of tracking number?"
    3. "How many orders are shipped?"
    
    A user interface will be created using Streamlit where users can input their PostgreSQL credentials and ask questions.
    
    ### Setup Instructions
    
    Follow these steps to set up the project on your local machine:
    
    
    **1. Clone the Repository**
    Begin by cloning the repository to your local machine:
    ```
    https://github.com/langchain-tech/postgres-chatbot.git
    cd postgres-chatbot
    ```
    
    **2. Install Dependencies with Poetry**
    It is recommended to use poetry to manage dependencies. Install the necessary packages and create a virtual environment:
    
    ```
    poetry install
    ```
    
    **3. Activate the virtual environment:**
    after installation the necessary packages activate the virtual env:
    ```
    poetry shell
    ```
    
    
    **4. Set Up Environment Variables**
    Create a .env file in the root directory of your project and add the required environment variables. For example:
    ```
    GOOGLE_API_KEY=your_gemini_api_key
    ```
    
    
    **5. Start the Application**
    
    Run the application using Streamlit:
    ```
    streamlit run app.py
    ```
    
    
    ## How to use 
    ![My test image](assets/img1.gif)
    ### Notes
    
    - Questions will not be limited to one table, so it should be done to ask from database
    - As long as entry is added into database, we should be able to answer questions for that new record
    

    Tags

    chatbotgeminigemini-apilangchainpostgresqlretrieval-augmented-generationstreamlit

    Comments

    More Agents

    View all
    research

    NotebookLM

    Google's AI-powered research notebook that ingests your documents and becomes an expert on your content. Generates audio overviews, study guides, FAQs, and interactive discussions from uploaded sources.

    G
    Google
    browser

    Project Mariner (Browser Agent)

    Google DeepMind's experimental AI agent that can navigate websites, fill forms, and complete multi-step browser tasks autonomously. Uses Gemini's multimodal understanding to interact with web interfaces.

    G
    Google DeepMind
    multimodal

    Project Astra (Multimodal Agent)

    Google DeepMind's universal AI assistant prototype that can see, hear, and respond in real-time through your device camera and microphone. Demonstrates the future of multimodal AI interaction.

    G
    Google DeepMind
    enterprise

    Gemini Enterprise Agent Platform

    Google Cloud's enterprise platform for building, deploying, and managing AI agents powered by Gemini. Supports multi-agent orchestration, tool integration, and enterprise governance.

    G
    Google Cloud
    research

    Gemini Deep Research Agent

    Gemini's agentic research capability that autonomously browses the web, synthesizes information from dozens of sources, and produces comprehensive research reports on any topic.

    G
    Google
    canvas

    Gemini Canvas Agent

    Interactive coding and content creation agent that generates, previews, and iterates on code, documents, and interactive applications in a side panel. Supports HTML/CSS/JS, Python, and more.

    G
    Google

    Stay up to date

    Get the latest Gemini prompts, rules, and resources delivered to your inbox weekly.

    Neura Market LogoNeura Market

    Discover the best AI prompts, plugins, and resources for Gemini and more.

    Content Types

    • Rules
    • Prompts
    • MCPs
    • Agents
    • Guides

    Platforms

    • ChatGPT Directory
    • Claude Directory
    • Gemini Directory
    • Cursor Directory
    • Grok Directory
    • Perplexity Directory
    • DeepSeek Directory
    • CoPilot Directory
    • Stable Diffusion Directory
    • Midjourney Directory
    • All Directories

    Resources

    • Blog
    • Documentation
    • Help Center
    • Marketplace

    Legal

    • Privacy Policy
    • Terms of Service

    © 2026 Neura Market. All rights reserved.

    |

    Not affiliated with any AI platform vendors.