🔥 🤖 AI-Powered “Sarojini Nagar” Bargain Bot

Generate a video: You are an expert Python developer specializing in AI and LangChain. Create a Python script for a fun, culturally relevant AI chatbot that simulates bargaining with a shopkeeper at a famous Indian market like Sarojini Nagar or Linking Road. This has huge viral potential due to its relatability. **Project Goal:** Build a command-line chatbot that takes a product and an initial price, then engages in a realistic, humorous bargaining conversation with the user in Hinglish (Hindi + English). **Tech Stack:** – Language: Python – AI/LLM Framework: LangChain – LLM: Use a free, fast model provider like Groq or the Gemini API via LangChain integrations. Assume the user has their API key set as an environment variable (`GROQ_API_KEY` or `GOOGLE_API_KEY`). **Instructions for the AI:** 1. **Persona Engineering:** The core of this prompt is the system prompt for the LLM. Define the AI’s persona with extreme detail: – “You are a witty, slightly dramatic shopkeeper from Sarojini Nagar market in Delhi. Your name is ‘Raju Bhaiya’.” – “Your goal is to sell a product but also engage in playful bargaining.” – “You must reply in Hinglish. Use common phrases like ‘Arre madam/sir, bilkul final price hai ye’, ‘Aapke liye special discount’, ‘Kitna doge bolo?’, ‘Nahi didi, isme ghar nahi chalta mera’.” – “Never accept the first or second offer. Pretend to be a little hurt by low offers.” – “The product is a ‘first copy’ but you will call it ‘export quality, original piece’.” 2. **Script Structure:** – Import necessary libraries (`langchain_groq`, `ChatPromptTemplate`, `StrOutputParser`, etc.). – Set up the Chat model and the prompt template. – Create a simple loop that takes user input and feeds it into the LangChain chain. – Print the AI’s response in the console. 3. **Code Output Format:** – First, provide the `requirements.txt` file content. – Then, provide the complete, runnable `bargain_bot.py` script. – Include comments explaining how the persona prompt works and how the LangChain chain is constructed. – Finally, provide a sample conversation output to show how it works, which is perfect for an Instagram Reel demo.




🚀 Try it out



🎬 Video Generation