How don2604/accenture_hack works
Main components
• Backend API Server: Centered around the “backend/main.py” file; it defines the REST API endpoints (e.g., /weather, /sustainability, /market_trends, /carbon_footprint, /water_usage).
• AI Agent Layer: Under the “backend/agents” directory, include distinct agents for weather, sustainability, water usage, carbon footprint, and market trends. Also include the DecisionAgent that formats insights.
• Utility Modules: Under “backend/modules”, key subcomponents such as auth_handler, memory_handler, query_extract_run, response_handler, ticket_handler, and weather_fetcher should be depicted as supporting tools used by the primary agents.
• Database/Persistent Memory: Represent the “backend/db” directory containing SQLite databases and initialization scripts. This component supports persistent memory and previous insights.
• Data Sources: Include the “backend/data” directory (CSV datasets) as external input for initial advisory data.
• CI/CD: Optionally add the GitHub Actions workflows from the “.github/workflows” directory to note the automated build/deployment process.
• External Services: Represent external integrations like DuckDuckGo web search (as mentioned in the README) and LangChain/LLMs (e.g., LLaMA3-70B, Qwen 2.5 via Groq API).
Relationships and data flow
• Within the Backend, show request routing from main.py into specific AI agents. Then illustrate how these agents may call utility modules (for memory handling, query extraction, etc.) as well as interact with the SQLite databases.
Architectural patterns and principles
• Modular design: The separation of domain-specific agents (each handling a distinct agricultural advisory domain) emphasizes a plug-and-play, scalable architecture.
• RESTful API: The backend exposes clearly defined endpoints.
• Data persistence & memory: The integration of SQLite databases shows state persistence for smarter future responses.
• Integration of AI: The sophisticated usage of LangChain for handling language models and AI agent-driven decision making.
Relevant technologies
• Backend: Python, Flask, SQLite, LangChain, and custom module logic.
• Frontend: Flutter (with sub-folders for Android, iOS, web, Linux, macOS, Windows).
• Others: GitHub Actions for continuous integration, external web scraping (DuckDuckGo).