Agrosphere is an AI-powered conversational assistant designed to support agricultural knowledge dissemination. It leverages modern language models, embedding techniques, and a local vector database to answer user queries based on agricultural documents.
- Conversational AI chatbot trained on agricultural documents
- Uses Google Generative AI and Groq APIs
- Embedding storage with Chroma vector database
- Streamlit-based UI for quick interaction
- Environment-friendly design with smooth background
agrosphere/
├── agribot.py # Main chatbot application
├── embedding.py # Script to create document embeddings
├── background.jpg # UI background image
├── .env # Environment variables (API keys etc.)
├── my\_chroma\_store/ # Chroma vector database
├── Agriculture/inr.pdf # Sample input document
├── venv/ # Python virtual environment
Python 3.8 or later and the following Python libraries:
streamlit
python-dotenv
langchain
langchain-community
langchain-google-genai
langchain-groq
You can install these using:
pip install -r requirements.txtYou can create
requirements.txtwith:streamlit python-dotenv langchain langchain-community langchain-google-genai langchain-groq
-
Clone the Repository
git clone https://github.com/your-username/agrosphere.git cd agrosphere -
Create and Activate Virtual Environment (optional)
python -m venv venv source venv/bin/activate # On Windows: venv\Scripts\activate
-
Install Dependencies
pip install -r requirements.txt
-
Set Environment Variables
Create a
.envfile in the project directory with:GOOGLE_API_KEY=your_google_api_key GROQ_API_KEY=your_groq_api_key -
Run the Chatbot
streamlit run agribot.py
To embed new documents, update or add files in the Agriculture folder and re-run:
python embedding.pyThis regenerates the vector database using Chroma.
Made with ❤️ for smart farming by Anusha Singh.

