Contrib and Codebase Guide#
Checkout and push ready#
Fork the Repository
- Navigate to https://github.com/jaseci-labs/jaseci
- Click the Fork button in the top-right corner
- Select your GitHub account to create the fork
Clone and Set Up Upstream
After forking, clone your fork and set up the upstream remote:
# Clone your fork (replace YOUR_USERNAME with your GitHub username)
git clone https://github.com/YOUR_USERNAME/jaseci.git
cd jaseci
# Add the original repository as upstream (may already exist)
git remote add upstream https://github.com/jaseci-labs/jaseci.git
# Verify your remotes
git remote -v
# You should see:
# origin https://github.com/YOUR_USERNAME/jaseci.git (fetch)
# origin https://github.com/YOUR_USERNAME/jaseci.git (push)
# upstream https://github.com/jaseci-labs/jaseci.git (fetch)
# upstream https://github.com/jaseci-labs/jaseci.git (push)
Pushing Your First PR
-
Create a new branch for your changes:
-
Make your changes and commit them:
-
Keep your fork synced with upstream:
-
Push to your fork:
-
Create a Pull Request:
- Go to your fork on GitHub
- Click Compare & pull request
- Fill in the PR description with details about your changes
- Submit the pull request to the
mainbranch ofjaseci-labs/jaseci
PR Best Practices
- Make sure all pre-commit checks pass before pushing
- Run tests locally using the test script above
- Keep your PR focused on a single feature or fix
- Write clear commit messages and PR descriptions
General Setup and Information#
To get setup run
# Install black
python3 -m venv ~/.jacenv/
source ~/.jacenv/bin/activate
pip3 install pre-commit pytest pytest-xdist
pre-commit install
To understand our linting and mypy type checking have a look at our pre-commit actions. You can set up your enviornment accordingly. For help interpreting this if you need it, call upon our friend Mr. ChatGPT or one of his colleagues.
Our pre-commit process
This is how we run checks on demand.
This is how we run our tests.
pytest -n auto jac
pytest jac-cloud
pytest jac-byllm
pytest jac-streamlit
jac test jac/examples/littleX/littleX.test.jac
Run docs site locally#
This is how we run the docs.
Build VSCode Extention#
cd jac/support/vscode_ext/jac
npm install
npm install -g @vscode/vsce
vsce package
code --install-extension jaclang-*.vsix # aslo works with cursor, etc
cd -
Release Flow (for the empowered)#
- Version bump jac, jac-cloud, byllm
- Remember to version bump requirement of jaclang in jac-cloud and byllm
- Update release notes (unreleased becomes released)
- Push to main
- Go to GitHub, run
Release jaclang to PYPIaction manually - After success
- Run
Release jac-cloud to PYPIaction manually - Run
Release jac-byllm to PYPIaction manually - Run
RElease jac-mtllm to PYPIaction manually, for deprecated library - If All success, W for you!!