Thank you for your interest in contributing to ATLAS! We value all contributions, whether it's code, documentation, bug reports, feature requests, or community support.
- Fix bugs: Address issues in existing code
- Add features: Implement new capabilities or trainers
- Improve documentation: Enhance clarity, fix typos, add examples
- Report issues: Help us identify bugs and areas for improvement
- Answer questions: Support the community in discussions
- Fork and clone the repository:
git clone git@github.com:<your-username>/ATLAS.git
cd ATLAS
git remote add upstream https://github.com/Arc-Computer/ATLAS.git- Create a development environment:
conda create -n atlas-dev python=3.11
conda activate atlas-dev
pip install -e .[dev]- Install pre-commit hooks:
pre-commit install- Sync with upstream:
git checkout main
git fetch upstream
git merge upstream/main- Create a feature branch:
git checkout -b feature/your-feature-name- Make your changes and ensure tests pass:
pytest tests/
make lint # Run code quality checks- Commit with descriptive messages:
git add .
git commit -m "feat: add new teacher training algorithm"- Push and create a pull request:
git push -u origin feature/your-feature-nameInclude the following information:
- Python version
- PyTorch version
- ATLAS version (
pip show atlas) - CUDA version and GPU model
- Minimal reproducible code example
- Full error traceback
Run atlas env to automatically collect environment information.
Describe:
- Motivation: Problem or use case driving the request
- Proposed solution: Detailed description with examples
- Alternatives considered: Other approaches you've evaluated
- Related work: Links to papers or implementations
We use ruff for code formatting and linting:
make format # Auto-format code
make lint # Check code qualityAll public functions must include:
def train_teacher(
model: nn.Module,
config: TrainerConfig,
dataset: Dataset,
) -> nn.Module:
"""
Train a teacher model using GRPO.
Args:
model (`nn.Module`):
Base model to train.
config (`TrainerConfig`):
Training configuration.
dataset (`Dataset`):
Training dataset.
Returns:
`nn.Module`: Trained teacher model.
Raises:
ValueError: If config parameters are invalid.
RuntimeError: If training fails.
Examples:
```python
>>> model = AutoModelForCausalLM.from_pretrained("llama-3.1-8b")
>>> config = TrainerConfig(learning_rate=1e-5)
>>> trained = train_teacher(model, config, dataset)
```
"""Add tests for new features:
def test_new_feature():
"""Test description."""
# Arrange
model = create_test_model()
# Act
result = new_feature(model)
# Assert
assert result.shape == expected_shape
assert torch.allclose(result, expected_output)Run tests with coverage:
pytest tests/ --cov=atlas_core --cov-report=htmlBefore submitting:
- Code follows style guidelines (
make lintpasses) - Tests added/updated and passing
- Documentation updated if needed
- Commit messages follow conventional format
- PR title summarizes the contribution
- Linked to relevant issue (fixes #123)
When adding a new training algorithm:
-
Open an issue first with:
- Paper link and summary
- Implementation complexity
- Performance benchmarks
- Use cases
-
Follow the trainer template:
- Inherit from
BaseTrainer - Implement required methods
- Add configuration class
- Include comprehensive tests
- Inherit from
-
Document thoroughly:
- Add to trainer documentation
- Include usage examples
- Provide benchmark results
- Be respectful and inclusive
- Welcome newcomers and help them get started
- Focus on constructive feedback
- Respect differing viewpoints
- GitHub Discussions: For questions and ideas
- GitHub Issues: For bugs and feature requests
We aim to:
- Triage new issues within 48 hours
- Review PRs within 1 week
- Merge approved PRs within 2 weeks
Contributors are recognized in:
- Release notes
- Contributors file
- Annual community report
By contributing, you agree that your contributions will be licensed under the Apache 2.0 License.
Feel free to ask in:
Thank you for contributing to ATLAS! 🚀