Contributing to Quiver¶
Want to help make Quiver even better? We'd love your contributions! This guide will help you get started with the development process. 🚀
Getting Started¶
Prerequisites¶
Before you begin, make sure you have:
- Go 1.18 or later
- Git
- A C compiler (for DuckDB integration)
- Your favorite code editor
Setting Up the Development Environment¶
- Fork the repository on GitHub
- Clone your fork:
- Add the upstream repository:
- Install dependencies:
Development Workflow¶
Creating a Branch¶
Create a new branch for your feature or bugfix:
Use a descriptive name that reflects what you're working on.
Making Changes¶
- Make your changes to the codebase
- Write or update tests for your changes
- Run the tests to make sure everything passes:
- Run the benchmarks to ensure performance is maintained:
Coding Standards¶
We follow standard Go coding conventions:
- Use
gofmt
to format your code - Follow the Go Code Review Comments
- Write clear, concise comments
- Add documentation for public functions
Commit Messages¶
Write clear, concise commit messages that explain your changes:
feat: Add support for custom distance functions
This commit adds the ability for users to define and use custom
distance functions for vector similarity calculations.
We follow the Conventional Commits format:
feat:
for new featuresfix:
for bug fixesdocs:
for documentation changestest:
for changes to testsperf:
for performance improvementsrefactor:
for code refactoringchore:
for changes to the build process or auxiliary tools
Submitting a Pull Request¶
- Push your branch to your fork:
- Go to the Quiver repository and create a new pull request
- Provide a clear description of your changes
- Link any related issues
Testing¶
Running Tests¶
Run the full test suite:
Run tests with verbose output:
Run a specific test:
Running Benchmarks¶
Run all benchmarks:
Run a specific benchmark:
Compare benchmark results before and after your changes:
# Before changes
go test -bench=. -benchmem ./... > before.txt
# After changes
go test -bench=. -benchmem ./... > after.txt
# Compare
benchstat before.txt after.txt
Documentation¶
Updating Documentation¶
If you're adding new features or changing existing ones, please update the documentation:
- Update the relevant markdown files in the
docs/
directory - Update code comments, especially for exported functions
- Add examples if appropriate
Building the Documentation¶
Build the documentation site:
Preview the documentation locally:
Then open http://localhost:8000 in your browser.
Getting Help¶
If you need help or have questions:
- Open an issue on GitHub
- Join our community discussions
- Reach out to the maintainers
Code of Conduct¶
Please note that this project is released with a Contributor Code of Conduct. By participating in this project you agree to abide by its terms.
License¶
By contributing to Quiver, you agree that your contributions will be licensed under the project's MIT License.
Thank You¶
Your contributions make Quiver better for everyone. We appreciate your time and effort! 🙏