Welcome 👋 to the Kotaemon project! We're thrilled that you're interested in contributing. Whether you're fixing bugs, adding new features, or improving documentation, your efforts are highly appreciated. This guide aims to help you get started with contributing to Kotaemon.
Please review our code of conduct, which is in effect at all times. We expect everyone who contributes to this project to honor it.
-
Fork the repository: Click on the Fork button on the repository's page to create a copy of Kotaemon under your GitHub account.
-
Clone your code: Clone your forked repository to your local machine.
-
Create new branch: Create a new branch in your forked repo with a descriptive name that reflects your changes.
git checkout -b descriptive-name-for-your-changes
- Setup the development environment: If you are working on the code, make sure to install the necessary dependencies for development
pip install -e "libs/kotaemon[dev]
-
Make your changes: Ensure your code follows the project's coding style and passes all test cases.
- Check the coding style
pre-commit run --all-files
- Run the tests
pytest libs/kotaemon/tests/
-
Commit your changes: Once you are done with your changes, add and commit them with clear messages.
git add your_changes.py
git commit -m "clear message described your changes."
git push -u origin descriptive-name-for-your-changes
-
Create a pull request: When you are satisfied with your changes, submit a pull request from your forked repository to Kotaemon repository. In the pull request, provide a clear description of your changes and any related issues. For the title of the pull request, please refer to our commit messages convention.
-
Wait for reviews: Wait for the maintainers to review your pull request. If everything is okay, your changes will be merged into the Kotaemon project.
All pull requests must pass the GitHub Actions Continuous Integration (CI) tests before they can be merged. These tests include coding-style checks, PR title validation, unit tests, etc. to ensure that your changes meet the project's quality standards. Please review and fix any CI failures that arise.
Before creating an issues, search through existing issues to ensure you are not opening a duplicate. If you are reporting a bug or issue, please provide a reproducible example to help us quickly identify the problem.
We use Angular convention for commit messages to maintain consistency and clarity in our project history. Please take a moment to familiarize yourself with this convention before making your first commit.
For the sake of simplicity, we use squashing merge with pull requests. Therefore, if you contribute via a pull request, just make sure your PR's title, instead of the whole commits, follows this convention.
Commit format:
<gitmoji> <type>(<scope>): <subject>
<BLANK LINE>
<body>
<BLANK LINE>
<footer>
Examples:
docs(api): update api doc
Types | Description |
---|---|
feat |
New features |
fix |
Bug fix |
docs |
Documentation only changes |
build |
Changes that affect the build system or external dependencies |
chore |
Something that doesn’t fit the other types |
ci |
Changes to our CI configuration files and scripts |
perf |
Improve performance |
refactor |
Refactor code |
revert |
Revert a previous commit |
style |
Improve structure/format of the code |
test |
Add, update or pass tests |
All contributions will be licensed under the project's license: Apache License 2.0.