Thank you for contributing to QuantMind! This guide covers environment
setup and the contribution process. The canonical development workflow
(commit format, PR format, component development) lives in the
quantmind-dev skill — .claude/skills/quantmind-dev/SKILL.md /
.agents/skills/quantmind-dev/SKILL.md — and the repository-wide rules
live in AGENTS.md / CLAUDE.md. If you develop with a coding agent, it
will pick these up automatically.
-
Fork and clone the repository
-
Set up environment:
uv venv && source .venv/bin/activate uv pip install -e ".[dev]"
-
Install pre-commit hooks:
./scripts/pre-commit-setup.sh
scripts/verify.sh is the single source of truth for "is this branch
shippable". CI runs the exact same script, so a green local run means a
green PR:
bash scripts/verify.shIt runs five fast-fail steps: ruff format --check, ruff check,
basedpyright, lint-imports, pytest --cov (with a branch-coverage
floor configured in pyproject.toml).
Hooks: the pre-commit stage runs formatting/lint and file hygiene
checks; the pre-push stage runs the full scripts/verify.sh. If a hook
fails, fix the issue — don't bypass with --no-verify.
# Run all pre-commit hooks manually
pre-commit run --all-files
# Run targeted tests while iterating
pytest tests/<module>/- Architecture: QuantMind is a domain library on top of the OpenAI
Agents SDK — functions over classes,
Protocolover ABC, no CLI, no agent-runtime rebuilding. SeeAGENTS.md/CLAUDE.mdfor the stable constraints and the module map. - Style: Google-style docstrings, English comments, 80-char lines (enforced by ruff).
- Types: Pydantic models at boundaries, frozen dataclasses internally;
comprehensive type hints (
basedpyrightruns in standard mode). - Dependency boundaries: enforced by
import-linter(pyproject.toml); don't work around a failing contract. - Tests: required under
tests/<module>/(mirror the module structure),unittest.TestCase, mock external services, cover success and failure paths. - Examples: one focused example under
examples/<module>/for each new feature.
- Create a feature branch from
master. - Follow Conventional Commits:
type(scope): description, in English. - Verify before submitting:
bash scripts/verify.shmust be green. - Submit the PR using the template — English body, reference the related issue, and state the verification you performed.
- Keep PRs small and focused (Google eng practices).
For significant changes (new modules, new dependencies, API redesigns), open an issue to discuss first.
- Check existing issues
- Review architecture patterns in existing code
- See
AGENTS.md/CLAUDE.mdfor repository-wide rules
Thank you for contributing! 🚀