Contributing to AgentForge
Thank you for your interest in contributing to AgentForge! This guide will help you get started.
Code of Conduct
We are committed to providing a welcoming and inclusive environment. Please be respectful and constructive in all interactions.
How Can I Contribute?
Reporting Bugs
Before creating a bug report, please check existing issues to avoid duplicates.
When filing a bug report, include:
- Clear, descriptive title
- Steps to reproduce the issue
- Expected vs actual behavior
- Code samples or test cases
- Environment details (Node version, OS, package versions)
- Error messages and stack traces
Suggesting Features
We welcome feature suggestions! Please:
- Check if the feature has already been suggested
- Provide a clear use case
- Explain why this feature would be useful
- Consider implementation details
Improving Documentation
Documentation improvements are always welcome:
- Fix typos or unclear explanations
- Add examples or tutorials
- Improve API documentation
- Translate documentation
Contributing Code
Fork the repository
Clone your fork
bashgit clone https://github.com/YOUR_USERNAME/agentforge.git cd agentforgeInstall dependencies
bashpnpm installCreate a branch
bashgit checkout -b feature/your-feature-nameMake your changes
- Write clean, readable code
- Follow the existing code style
- Add tests for new features
- Update documentation as needed
Run tests
bashpnpm test pnpm typecheck pnpm lintCommit your changes
bashgit add . git commit -m "feat: add your feature description"We follow Conventional Commits:
feat:- New featuresfix:- Bug fixesdocs:- Documentation changestest:- Test changesrefactor:- Code refactoringchore:- Maintenance tasks
Push to your fork
bashgit push origin feature/your-feature-nameCreate a Pull Request
- Provide a clear description of the changes
- Reference any related issues
- Ensure all CI checks pass
Development Setup
Prerequisites
- Node.js >= 18.0.0
- pnpm >= 8.0.0
Project Structure
agentforge/
├── packages/
│ ├── core/ # Core abstractions
│ ├── patterns/ # Agent patterns
│ ├── cli/ # CLI tool
│ ├── testing/ # Testing utilities
│ └── tools/ # Built-in tools
├── docs-site/ # Documentation site
└── examples/ # Example projectsRunning Tests
bash
# Run all tests
pnpm test
# Run tests in watch mode
pnpm test:watch
# Run tests with coverage
pnpm test:coverage
# Run tests with UI
pnpm test:uiBuilding
bash
# Build all packages
pnpm build
# Build specific package
cd packages/core
pnpm buildDocumentation
bash
# Start docs dev server
cd docs-site
pnpm dev
# Build docs
pnpm build
# Preview built docs
pnpm previewStyle Guide
TypeScript
- Use TypeScript for all code
- Provide proper type annotations
- Avoid
anytypes - Use Zod for runtime validation
Code Style
- Follow the ESLint configuration
- Use Prettier for formatting
- Write descriptive variable and function names
- Add JSDoc comments for public APIs
Testing
- Write tests for all new features
- Aim for high test coverage
- Use descriptive test names
- Test edge cases and error conditions
Pull Request Process
- Update documentation for any user-facing changes
- Add tests for new functionality
- Ensure all tests pass and linting is clean
- Update the changelog if applicable
- Request review from maintainers
- Address feedback promptly and professionally
Questions?
- GitHub Discussions
- Discord Server
- Email: contribute@agentforge.dev
License
By contributing, you agree that your contributions will be licensed under the MIT License.
Thank you for contributing to AgentForge! 🎉