AnyCode accepts focused bug fixes, documentation improvements, tests, and discussed enhancements. A contribution is ready to merge when its behavior, tests, documentation, compatibility impact, and changelog entry agree.
- Search existing issues and pull requests before opening a duplicate.
- Bug fixes may start with a pull request when the problem and expected behavior are clear.
- Discuss new features, public API changes, persisted-format changes, large dependencies, and cross-cutting architecture changes in an issue before implementation.
- Report vulnerabilities through the private process in SECURITY.md, not a public issue.
Maintainers may close an unsolicited feature pull request when the project has not agreed to its contract or long-term maintenance cost.
AnyCode requires Python 3.12 or newer and uses uv for dependency management.
git clone https://github.com/Quantlix/anycode.git
cd anycode
uv sync --locked --group devCreate a short-lived branch from the current main branch:
git fetch origin
git switch --create fix/short-description origin/mainUse feat/, fix/, docs/, refactor/, test/, or chore/ followed by a short lowercase description. Keep one coherent outcome per branch.
Follow the repository conventions in AGENTS.md:
- Keep agent execution, provider calls, and tools async.
- Keep Pydantic models frozen and create replacements instead of mutating them.
- Import public APIs from the package root in examples and user documentation.
- Preserve provider, tool, and storage protocol boundaries.
- Add tests for behavior changes and regressions.
- Update docstrings, guides, examples, and reference pages in the same pull request as user-visible behavior.
- Add a user-facing entry under
[Unreleased]in CHANGELOG.md for notable changes.
Commit subjects use Conventional Commit prefixes such as feat:, fix:, docs:, test:, refactor:, or chore:.
The following are public contracts:
- Names exported through
anycode.__all__. - Documented function signatures, defaults, exceptions, and result semantics.
- CLI commands and documented output intended for automation.
- Declarative YAML and TOML configuration.
- Checkpoints, durable run records, transcripts, and turn checkpoints.
Read the compatibility and versioning policy before changing one of these surfaces. A breaking change needs prior design agreement, the correct version increment, migration and rollback notes, compatibility tests, documentation, and a prominent changelog entry.
Run a focused test while iterating, then run the complete local gate before marking the pull request ready:
uv run python scripts/check_versions.py
uv run python -m ruff check .
uv run python -m ruff format --check src/
uv run python -m pyright
uv run python -m pytest
uv run python -m mkdocs build --strictThe default pytest configuration excludes service-backed integration tests. To run the same Redis and ChromaDB suite used in CI:
docker compose up -d --wait redis chromadb
uv run python -m pytest tests/integration -m integration --strict-markers --tb=short
docker compose downPackaging, dependency, CLI, and release changes also require:
uv run python -m build --no-isolation
uv run python -m twine check --strict dist/*CI runs the complete non-integration suite on Python 3.12 and 3.13 across Linux, Windows, and macOS. It separately tests every optional extra, service integrations, documentation, and installed wheel behavior.
Documentation source lives in site_docs/ and builds with MkDocs Material. Preview it with:
uv run python -m mkdocs serveEvery page must be registered in mkdocs.yml, use one clear H1, and describe current behavior. Keep site_docs/llms.txt current when an important page is added, renamed, or moved. The documentation contributor guide covers page types, frontmatter, API reference generation, and versioned deployment.
Complete the pull request template with:
- The problem and observable outcome.
- Compatibility and version impact.
- Tests and exact validation commands.
- Documentation and changelog impact.
- Migration, rollback, persistence, or security considerations.
Use a draft pull request for work in progress. Mark it ready only when the change is scoped, tested, documented, and free of unrelated edits. Maintainers normally squash-merge approved pull requests after required checks pass and review conversations are resolved.
Review may request changes to behavior, tests, API shape, documentation, or scope. Keep discussion technical and respectful, assume good intent, and focus on the effect of the change. Maintainer decisions follow MAINTAINERS.md.