An innovative solution for automating teaching assistant tasks using the Piazza API, LangChain, FAISS, and OpenAI. This bot helps teaching assistants manage and respond to student questions efficiently through an intuitive web interface.
- Automated Response Generation: Uses OpenAI and LangChain to generate contextually relevant responses to student questions
- Piazza Integration: Seamlessly integrates with Piazza's platform for managing course Q&A
- Smart Search: Utilizes FAISS for efficient similarity search and retrieval of relevant information
- Modern Web Interface: Built with Streamlit for a clean, responsive user experience
- Secure Authentication: Implements user authentication to protect sensitive course data
- Python 3.9 or higher
- Poetry (Python package manager)
- OpenAI API key
- Piazza account credentials
-
Clone the repository:
git clone https://github.com/gr8monk3ys/TAlker.git cd TAlker
-
Set up environment variables:
cp .env.example .env
Edit
.env
and add your credentials:OPENAI_API_KEY=your_openai_api_key PIAZZA_EMAIL=your_piazza_email PIAZZA_PASSWORD=your_piazza_password PIAZZA_COURSE_ID=your_course_id
-
Install dependencies using Poetry:
make setup
-
Start the application:
make run
-
For development with auto-reload:
make dev
-
Access the web interface at
http://localhost:8501
-
Format code:
make format
-
Run linting:
make lint
-
Run tests:
make test
TAlker/
├── src/
│ ├── dashboard/ # Web interface components
│ │ ├── Home.py # Main Streamlit application
│ │ └── llm.py # LangChain integration
│ └── piazza_bot/ # Core bot functionality
│ ├── bot.py # Piazza API integration
│ ├── profile.py # User profile management
│ └── responses.py # Response generation
├── data/ # Data storage
├── tests/ # Test suite
├── pyproject.toml # Poetry dependencies
└── Makefile # Development commands
make setup
: Install Poetry and project dependenciesmake run
: Start the Streamlit applicationmake dev
: Start the application in development modemake lint
: Run Pylint for code quality checksmake format
: Format code using Blackmake test
: Run the test suitemake clean
: Clean up cache and temporary files
- Fork the repository
- Create your feature branch (
git checkout -b feature/AmazingFeature
) - Format and lint your code (
make format && make lint
) - Commit your changes (
git commit -m 'Add some AmazingFeature'
) - Push to the branch (
git push origin feature/AmazingFeature
) - Open a Pull Request
This project is licensed under the GNU License - see the LICENSE file for details.