Contributing Guide

How to contribute to eval_752.

Getting Started

  1. Fork the repository
  2. Clone your fork
  3. Install pre-commit hooks:
    uvx pre-commit install
    uvx pre-commit install --hook-type commit-msg

Development Workflow

  1. Create feature branch: git checkout -b feat/my-feature
  2. Make changes
  3. Write tests
  4. Run quality checks: ./check.py
  5. Commit with conventional commits
  6. Push and create PR

Commit Convention

feat(scope): add new feature

Detailed description of changes.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>

Types: feat, fix, docs, test, refactor, chore, perf

Quality Gates

All PRs must:

  • Pass linting (ruff, eslint)
  • Pass type checking (mypy, tsc)
  • Pass tests (95% backend coverage)
  • Include tests for new features
  • Update documentation

Localization Checklist

If your change touches user-facing copy:

  • Add or update keys in locales/en/frontend.json or locales/en/backend.json
  • Mirror the same key structure in every supported locale
  • Verify browser-follow mode and manual language override in Settings
  • Avoid inline fallback English in components, hooks, and API routes

See Internationalization for the full workflow.

Code Review

PRs are reviewed for:

  • Correctness
  • Test coverage
  • Documentation
  • Performance
  • Security

For setup details, see Development Guide.

Documentation Development (Rspress v2)

We publish docs with Rspress v2 from the docs/ directory. English content lives under docs/en/, Simplified Chinese content under docs/zh/, and shared static assets under docs/public/.

Setup and Local Preview

cd docs
pnpm install
pnpm dev

Build and Verify

cd docs
pnpm build

Analytics

  • The docs site initializes posthog-js from docs/theme/index.tsx, not from ad-hoc inline page scripts.
  • Local preview hosts (localhost, 127.0.0.1, ::1, 0.0.0.0) are excluded so pnpm dev and local preview traffic do not pollute production docs analytics.
  • Current docs analytics scope is intentionally narrow: SPA pageviews plus link/button autocapture. Session replay and surveys stay disabled unless a later plan explicitly widens scope.

Linking and Assets

  • Use relative links inside the locale tree. Example: ../operations/configuration.md.
  • For files outside docs/ (such as specs/), link to the GitHub blob URL.
  • Place shared images under docs/public/, typically docs/public/screenshots/<locale>/.
  • Prefer Markdown, MDX components, and built-in Rspress capabilities over ad-hoc embedded scripts.
  • Brand assets (logo, icon) live under docs/public/brand/.
  • Locale navigation lives in docs/en/_nav.json and docs/zh/_nav.json; section ordering lives in _meta.json.

Redirects

Legacy route redirects are implemented as lightweight redirect pages inside the docs content tree.

CI

The deploy-docs workflow installs docs dependencies with pnpm in docs/ and publishes the Rspress build output.