Skip to content

Latest commit

 

History

History
90 lines (68 loc) · 1.89 KB

File metadata and controls

90 lines (68 loc) · 1.89 KB

Contributing to nxdo

Thank you for your interest in contributing to nxdo!

Development Setup

  1. Clone the repository:
git clone https://github.com/semcod/nxdo.git
cd nxdo
  1. Create a virtual environment:
python -m venv .venv
source .venv/bin/activate  # On Windows: .venv\Scripts\activate
  1. Install the package in development mode:
pip install -e ".[dev]"

Running Tests

Run all tests:

PYTHONPATH=src python -m pytest tests/ -v

Run a specific test file:

PYTHONPATH=src python -m pytest tests/test_models.py -v

Code Quality

Run type checking:

mypy src/nxdo

Run linting:

ruff check src/nxdo tests/

Auto-fix linting issues:

ruff check --fix src/nxdo tests/

Project Structure

  • src/nxdo/ - Main package source code
    • cli.py - Command-line interface
    • config.py - Configuration management
    • git_reader.py - Git history analysis
    • llm_client.py - LLM client (legacy compatibility)
    • models.py - Pydantic data models
    • output.py - Rich-based rendering
    • planner.py - Main orchestrator
    • project_analyzer.py - Project snapshot analysis
    • providers/ - LLM provider implementations
  • tests/ - Test suite

Making Changes

  1. Create a branch for your changes:
git checkout -b feature/your-feature-name
  1. Make your changes and add tests
  2. Run tests and linting to ensure everything passes
  3. Commit your changes with a clear message
  4. Push and create a pull request

Adding New LLM Providers

To add a new LLM provider:

  1. Create a new file in src/nxdo/providers/
  2. Implement the LLMProvider interface from providers/base.py
  3. Add appropriate tests in tests/test_providers.py
  4. Export the provider in src/nxdo/providers/__init__.py

License

By contributing, you agree that your contributions will be licensed under the Apache License 2.0.