-
Notifications
You must be signed in to change notification settings - Fork 1.4k
ggml : introduce semantic versioning #1336
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
@ggerganov @slaren Any thoughts about having a process like this? |
After making a release there is one more step to sync back ggml into llama.cpp and whisper.cpp. Otherwise, they would point to the old ggml version. |
This commit introduces semantic versioning for the GGML library. The motivation for this is that the current versioning, using build numbers, makes it difficult to track changes and releases for projects that use ggml. The release steps are the following: 1. Sync the changes from llama.cpp using sync-llama-am.sh and after the PR has been approved and merged move to step 2. 2. Run scripts/release.sh and specify the type of release, major, minor, or patch. This script will handle incrementing the version (major|minor|patch), create a new commit with the version change, create a tag for the version, and prepare for the next development iteration. 3. Inspect the commits/tag and push to master. This will trigger the github release workflow which is triggered for new tags which will then publish a new release on github. Example usage: ```console $ ./scripts/release.sh major --dry-run [dry-run] - No changes will be made Step 1: Reading current version... Current version: 0.9.0-dev New release version: 1.0.0 Step 2: Updating version in CMakeLists.txt... [dry-run] Would update GGML_VERSION_MAJOR to 1 [dry-run] Would update GGML_VERSION_MINOR to 0 [dry-run] Would update GGML_VERSION_PATCH to 0 [dry-run] Would remove -dev suffix Step 3: Committing version bump... [dry-run] Would commit: 'ggml : bump version to 1.0.0' Step 4: Creating git tag... [dry-run] Would create tag: v1.0.0 with message 'Release version 1.0.0' Step 5: Preparing for next development cycle... [dry-run] Would update GGML_VERSION_MINOR to 1 [dry-run] Would add -dev suffix back Step 6: Committing development version... [dry-run] Would commit: 'ggml : prepare for development of 1.1.0-dev' [dry-run] Summary (no changes were made): • Would have released version: 1.0.0 • Would have created tag: v1.0.0 • Would have set next development version: 1.1.0-dev ``` Refs: ggml-org#1333
35595ce
to
ba57d59
Compare
A suggestion to handle the CI failure has been opened in ggml-org/llama.cpp#15922. |
@ggerganov When get a chance can you give this another review and see what you think? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess we can give it a try.
I'm hesitating because I'm a bit unsure about how the version is going to be used by downstream projects. We can adapt based on feedback.
Speaking as a downstream, this is great! Some additional feedback:
|
I spotted 2 problems with the release script:
|
Instead of hardcoding 0.0.0 If the 0.9.2-dev version is supposed to mean "less than" 0.9.2 instead of equal, then the .pc version format would need to be changed to 0.9.2dev, since pkgconf uses RPM version comparison. But let's keep it simple for now. The version in CMake was added in ggml-org#1336
Instead of hardcoding 0.0.0 If the 0.9.2-dev version is supposed to mean "less than" 0.9.2 instead of equal, then the .pc version format would need to be changed to 0.9.2dev, since pkgconf uses RPM version comparison. But let's keep it simple for now. The version in CMake was added in #1336
This commit introduces semantic versioning for the GGML library.
The motivation for this is that the current versioning, using build numbers, makes it difficult to track changes and releases for projects that use ggml.
Suggested release process/steps:
sync-llama-am.sh
and after the PR has been approved and merged move to step 2.scripts/release.sh
and specify the type of release, major, minor, or patch. This script will handle incrementing the version (major|minor|patch), create a new commit with the version change, create a tag for the version, and prepare for the next development iteration.Example usage:
Refs: #1333
For changes to the core
ggml
library (including to the CMake build system), please open a PR in https://github.com/ggml-org/llama.cpp. Doing so will make your PR more visible, better tested and more likely to be reviewed.This PR requires adding a file to the
scripts
directory which is not available in llama.cpp and is the reason for opening this PR here instead of in llama.cpp. It also contains changes toCMakeLists.txt
but it would make it more difficult to test and review separating the commits/prs.