Inspiration We wanted to create an intuitive and easy-to-use chatbot interface that leverages real-time web data to provide relevant and dynamic answers. Instead of relying solely on static knowledge, this chatbot intelligently fetches top URLs related to a user’s query, processes the information, and responds with actionable insights — all accessible through a simple web app. The goal was to bridge conversational AI with live web search for smarter, more context-aware answers.

What it does This Flask app lets users input any natural language question via a clean web interface. Behind the scenes, it:

Searches the web for top relevant URLs based on the user’s query.

Feeds those URLs into a chatbot engine designed to process and summarize web content.

Returns a concise, helpful response generated from the live web data.

Displays the interaction seamlessly in the browser, enabling easy, real-time Q&A.

How we built it Backend: Used Flask for a lightweight web server to handle HTTP requests and render HTML templates.

Search: Created a custom search_top_k_urls function to fetch and rank relevant URLs for the query.

Chatbot: Built a website_chatbot function that integrates the search results to generate meaningful answers.

Frontend: Designed a responsive HTML/CSS interface with Jinja templating for dynamic content display.

Leveraged Python’s modularity to separate concerns (search, chatbot logic, web app) into different files for maintainability.

Challenges we ran into Handling diverse queries: Building a search function that returns highly relevant URLs regardless of the question complexity was tricky.

Response latency: Processing multiple URLs through the chatbot could slow down response time, so we balanced comprehensiveness with speed.

User experience: Designing an interface that was both minimal and informative, including loading states and clear response areas.

Error handling: Managing cases when no relevant URLs were found or the chatbot failed to generate an answer gracefully.

Accomplishments that we're proud of Successfully combined live web search with chatbot generation for dynamic, context-aware answers.

Delivered a clean, intuitive UI that works across devices with instant feedback.

Modular codebase that can be extended with different search engines or chatbot backends.

Enabled a fully functional demo in under X days/weeks (customize based on your timeline).

What we learned The importance of decoupling search and chatbot logic to keep the system flexible.

How to integrate Flask with external APIs and custom Python modules efficiently.

User experience design nuances for chatbot applications, especially managing asynchronous operations.

Effective debugging of HTTP errors and form submission issues in Flask apps.

What's next for Dynamic Chatbot Builder Implement real-time chat experience with message history and streaming responses.

Optimize URL ranking and filtering for faster and more accurate results.

Add support for multi-language queries and responses.

Integrate advanced NLP models or APIs for richer chatbot conversations.

Deploy as a scalable web service with authentication and user management.

Explore voice input/output to enable hands-free interactions.

Built With

Share this project:

Updates