Thank you for your interest in contributing to Teeception! This document provides guidelines and instructions for contributing to the project.
- Development Setup
- Project Structure
- Development Workflow
- Testing Guidelines
- Code Style
- Documentation
- Node.js and npm (for extension development)
- Scarb (Cairo package manager)
- jq (JSON processor for scripts)
- Go 1.20 or later (for TEE development)
- Docker and Docker Compose (for local development)
- Clone the repository:
git clone https://github.com/NethermindEth/teeception.git
cd teeception- Install root dependencies:
npm install- Install jq:
# macOS
brew install jq
# Ubuntu/Debian
sudo apt-get install jq- Set up the Git pre-commit hook:
mkdir -p .git/hooks
cp scripts/pre-commit .git/hooks/
chmod +x .git/hooks/pre-commitgo run cmd/agent/main.gocd contracts
snforge build
snforge testcd extension
npm install
npm run dev:watchcd frontend
npm install
npm run de- TEE Agent: Runs in a Trusted Execution Environment, handles prompt evaluation and asset management
- Smart Contracts: Manage agent registration, challenge attempts, and reward distribution
- Chrome Extension: User interface for interacting with agents and managing challenges
- Frontend: Status website and leaderboards
- Fork and Clone: Fork the repository and clone it locally
- Branch: Create a branch for your changes
git checkout -b feature/your-feature-name
- Develop: Make your changes, following our code style guidelines
- Test: Run relevant tests and add new ones if needed
- Commit: Use clear commit messages
- Push and PR: Push your changes and create a pull request
The project maintains automatic synchronization between Cairo contract ABIs and TypeScript interfaces. This is handled by the pre-commit hook:
- Builds contracts using Scarb
- Extracts ABIs from contract class files
- Updates TypeScript ABI files in
extension/src/abis/ - Verifies all changes are committed
To manually sync ABIs:
./scripts/sync-abis.sh- Smart Contracts: Write comprehensive tests for all contract functionality
- TEE Agent: Test prompt evaluation and security boundaries
- Extension: Test UI components and contract interactions
- Integration: Test full user flows across components
- Cairo: Follow the Cairo style guide
- TypeScript: Use ESLint and Prettier configurations
- Go: Follow Go style conventions and use gofmt
- Documentation: Keep inline documentation up to date
- Update relevant documentation when making changes
- Document new features and APIs
- Keep the README and website content current
- Add inline comments for complex logic
- Join our telegram
- Check existing issues and discussions
- Reach out to maintainers
By contributing, you agree that your contributions will be licensed under the MIT License.