Contributing¶
Thank you for your interest in contributing to ResearchPad. This guide covers the development setup, build process, and pull request workflow.
Development Setup¶
Prerequisites¶
- Python >= 3.10
- Node.js >= 18
- npm >= 9
Clone and Install¶
This runs pip install -e ".[dev,docs]", which installs the package in editable mode along with development and documentation dependencies.
Start Development Servers¶
This starts both the frontend dev server (with hot reload) and the backend server concurrently.
Project Structure¶
researchpad/
src/
frontend/ # React + Tailwind UI
server/ # Node.js API server
researchpad/
cli/ # Python CLI (init, runserver, version)
server/ # Bundled server (generated by build)
templates/ # Cursor command templates
tests/ # Python test suite
docs/ # Documentation (mkdocs)
Building¶
This builds both the frontend and server into production bundles at researchpad/server/. The build process:
- Runs
npm ci && npm run buildinsrc/frontend/ - Runs
npm ci && node build.mjsinsrc/server/
Running Tests¶
This runs the Python test suite with pytest:
Serving Docs Locally¶
This starts a local mkdocs development server at http://localhost:8000 with live reload.
Pull Request Process¶
- Fork the repository and create a feature branch from
main. - Make your changes. Keep commits focused and write clear commit messages.
- Add tests for any new functionality.
- Run the test suite to confirm nothing is broken:
make test - Open a pull request against
mainwith a clear description of what changed and why.
Code style
The project uses Ruff for Python linting and formatting. The configuration lives in pyproject.toml with a line length of 100 and a target version of Python 3.10.
Reporting Issues¶
Open an issue on GitHub with:
- A clear title and description
- Steps to reproduce (if applicable)
- Expected vs. actual behavior
- Your Python version, Node.js version, and operating system