rebase-assistant
Skill6 starsChanged 5 months agoApache-2.0View on GitHub
Rebase custom fork commits onto a new upstream vllm tag, with conflict resolution and post-rebase verification via user-specified checks. Use when the user asks to rebase to a new upstream tag, update the fork base version, move custom patches to a newer vllm release, or resolve rebase conflicts against upstream.
- Commits and pushes
1 other project uses a version of this.
Adopted by
Most recently taken up by
- jMerta/codex-skillstheir own version, first seen Dec 14, 2025
Other versions1 project uses a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 1
- jMerta/codex-skills★ 130same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository4 other files it gives its agents.
- auto-rebaseSkill
- detect-upstream-baseSkill
- install-vllmSkill
- local-test-runnerSkill
The file
Show its rules and text
We split this skill into the rules it gives an agent
28 rules. About 0 are common, 20 are distinctive, and 8 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈20
Distinctive · estimate
This author's own choices. Worth a look.
8
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 22
Wheel rule: when running checks via local-test-runner, always use the stable release wheel matching the base tag of the branch being tested …
- Distinctive: line 37
If the user supplies v1 explicitly, skip detection and validate:
- Very specific: line 69
If not provided, HEAD on b1 is used as the implicit reference.
- Distinctive: line 93
Do not skip this step: Before any rebase work, run every verification check from Step 1.3 to confirm they pass on the reference state.
- Distinctive: line 96
If no explicit reference commit was provided, run checks on b1 HEAD.
- Distinctive: line 97
If an explicit reference commit was provided, check it out and run there.
- Very specific: line 99
Use the local-test-runner skill for execution.
- Distinctive: line 103
If any check fails, stop and ask the user to:
- Distinctive: line 108
Only proceed to Step 4 once all checks pass (or the user explicitly opts to skip).
- Distinctive: line 113
Create safety nets, then prepare b2.
- Distinctive: line 121
Create b2 for the rebase:
- Distinctive: line 126
If there are multiple custom commits, ask whether to squash:
- Very specific: line 128
Ask user: "There are $COMMIT_COUNT custom commits.
- Very specific: line 150
If you do end up detached after a rebase, recover with git checkout -B "$B1-$V2" to re-point the branch to the rebased HEAD.
- Distinctive: line 153
If conflicts arise, resolve them one at a time:
- Distinctive: line 156
Read the conflict markers
- Very specific: line 159
If the reference commit was provided, compare: git show <reference-commit>:<file> for guidance
- Distinctive: line 164
If uncertain about a resolution, stop and ask the user.
- Distinctive: line 171
If upstream deleted a file the fork doesn't modify, keep it deleted.
- Distinctive: line 172
Document non-obvious resolution decisions.
- Distinctive: line 176
Run the checks collected in Step 1 on b2 to confirm the rebase is correct.
- Very specific: line 184
Run verification checks using the local-test-runner skill.
- Distinctive: line 188
If a check fails, debug and iterate:
- Distinctive: line 202
If the diff is large, inspect individual commits from the log to narrow down which upstream change introduced the breakage.
- Very specific: line 205
If the source files on the failing path are unchanged across v1..v2, the regression likely lives in a transitive dependency.
- Distinctive: line 241
Check results (pass/fail for each, with log file paths)
- Distinctive: line 246
After user confirms b2 is satisfactory:
- Distinctive: line 250
If the user wants to push b2:
≈ “Common” is an estimate: at least 1 in 5 of the 213,897 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Rebase Assistant
Rebase this repository's custom fork commits onto a newer upstream vllm tag in a safe, repeatable way.
Notation used throughout this document:
- v1 — the upstream tag the branch is currently based on
- v2 — the target upstream tag to rebase onto
- b1 — the branch before rebase (custom commits on top of v1)
- b2 — the branch after rebase (custom commits replayed onto v2)
Wheel rule: when running checks via local-test-runner, always use the
stable release wheel matching the base tag of the branch being tested — v1
wheel for b1, v2 wheel for b2. Skip the local-test-runner wheel prompt and
go straight to "Switch to stable release" with the matching version, unless the
user explicitly requested a different wheel.
Step 1: Collect Inputs
Gather the following from the user before proceeding.
Auto-detected or user-provided
- Current base tag (v1): Either provided directly by the user, or
auto-detected via the
detect-upstream-baseskill. See detect-upstream-base. If the user supplies v1 explicitly, skip detection and validate:git rev-parse "upstream/$V1" 2>/dev/null \ || git rev-parse "$V1" 2>/dev/null \ || echo "ERROR: tag $V1 not found"
Required
- Target upstream tag (v2): The upstream tag to rebase onto (e.g.
v0.20.0). Validate it exists:git rev-parse "upstream/$V2" 2>/dev/null \ || git rev-parse "$V2" 2>/dev/null \ || echo "ERROR: tag $V2 not found" Verification checks: One or more commands to run after rebase to confirm correctness. Examples:
- Test command:
.venv/bin/python -m pytest tests/path/to/test.py -v - Lint command:
pre-commit run --all-files - Metric threshold: "WER < 15% on transcription tests"
Store these verbatim — they are run as-is during verification.
- Test command:
Optional
- Reference commit: A known-good commit where the checks pass. Used to
diff against when debugging failures after rebase.
If not provided,git rev-parse --verify <reference-commit> 2>/dev/nullHEADon b1 is used as the implicit reference. Either way, Step 3 verifies the checks pass on the reference state before rebasing.
Step 2: Analyze b1
Understand the custom commits on b1 that sit on top of v1. Use the
confirmed v1 from Step 1 — the merge-base between HEAD and upstream/$V1
is the fork point (FORK_POINT), used throughout the remaining steps.
FORK_POINT=$(git merge-base HEAD "upstream/$V1")
git log --oneline "$FORK_POINT"..HEAD
COMMIT_COUNT=$(git rev-list --count "$FORK_POINT"..HEAD)
git diff --stat "$FORK_POINT"..HEADPresent summary to user:
- Number of custom commits
- Files modified/added/deleted
- Overall diff summary (what the fork changes at a high level)
Step 3: Verify checks pass on b1 (gate)
Do not skip this step. Before any rebase work, run every verification check from Step 1.3 to confirm they pass on the reference state.
- If no explicit reference commit was provided, run checks on b1 HEAD.
- If an explicit reference commit was provided, check it out and run there.
Use the local-test-runner skill for execution. See
local-test-runner. Use the v1 wheel
(see Wheel rule above).
If any check fails, stop and ask the user to:
- Fix the issue before proceeding, or
- Provide a different reference commit where the checks pass, or
- Proceed anyway and fix the failures on b2 after rebase
Only proceed to Step 4 once all checks pass (or the user explicitly opts to skip).
Step 4: Backup, Branch, and Prepare
Create safety nets, then prepare b2. b1 is never modified.
- Back up b1:
B1=$(git rev-parse --abbrev-ref HEAD) git branch "backup-$B1-$(date +%Y%m%d-%H%M%S)" - Create b2 for the rebase:
git checkout -b "$B1-$V2" # e.g. v0.19.1-asr-fix-v0.20.0 If there are multiple custom commits, ask whether to squash:
Ask user: "There are $COMMIT_COUNT custom commits. Squash into one before rebasing? (recommended for cleaner conflict resolution)"
If yes:
git reset --soft "$FORK_POINT" git commit -m "squashed custom changes on top of $V1"
Step 5: Rebase b2 onto v2
Replay the custom commits from b1 onto v2, producing b2.
- Rebase. Do not pass literal
HEADas the third argument — git treats it as a commit-ish rather than the current branch, and a successful rebase leaves you in detached state. Either omit the third argument (b2 is already checked out from Step 4.2) or pass the branch name explicitly:
If you do end up detached after a rebase, recover withgit rebase --onto "upstream/$V2" "$FORK_POINT" # or, equivalently: git rebase --onto "upstream/$V2" "$FORK_POINT" "$B1-$V2"git checkout -B "$B1-$V2"to re-point the branch to the rebased HEAD. - If conflicts arise, resolve them one at a time:
- Show conflicted files:
git status - For each conflict:
- Read the conflict markers
- Compare what changed upstream:
git diff "upstream/$V1".."upstream/$V2" -- <file> - Preserve custom intent while integrating upstream changes
- If the reference commit was provided, compare:
git show <reference-commit>:<file>for guidance
- Stage resolved file:
git add <file> - Continue:
git rebase --continue
- Show conflicted files:
- If uncertain about a resolution, stop and ask the user.
Conflict Resolution Rules
- Understand both sides before editing.
- Preserve custom branch intent — that's the whole point of the fork.
- Integrate upstream improvements that don't break custom behavior.
- If upstream deleted a file the fork doesn't modify, keep it deleted.
- Document non-obvious resolution decisions.
Step 6: Verify b2
Run the checks collected in Step 1 on b2 to confirm the rebase is correct.
- Confirm branch shape:
Expect: custom commit(s) on top ofgit log --oneline "upstream/$V2"..HEADupstream/$V2. - Run verification checks using the
local-test-runnerskill. See local-test-runner. Use the v2 wheel (see Wheel rule above). If a check fails, debug and iterate:
a) Create a findings file and update it as you investigate:
mkdir -p .cache/investigation # Log each finding: what failed, hypotheses, what you tried, outcomeThis avoids re-treading ground across multiple fix attempts.
b) Compare v1 vs v2 to find relevant upstream changes:
git diff "upstream/$V1".."upstream/$V2" -- <failing-file-or-dir> git log --oneline "upstream/$V1".."upstream/$V2" -- <failing-file-or-dir>If the diff is large, inspect individual commits from the log to narrow down which upstream change introduced the breakage.
If the source files on the failing path are unchanged across v1..v2, the regression likely lives in a transitive dependency. Also diff
requirements/between the tags and compare runtime signals — not just pass/fail — between the b1 and b2 test logs:git diff "upstream/$V1".."upstream/$V2" -- requirements/ # Compare per-request token throughput, tokens generated per request, # warning/error log lines between b1 and b2 runs.Major-version bumps of transformers, torch, peft, or tokenizers frequently cause silent behaviour changes — especially for models loaded via
trust_remote_code=True, where transformers-version-specific semantics (e.g.split_special_tokens,use_fast) can flip without any code change in vllm itself.c) Check if v2 has related test cases that test the same area — they may reveal expected behavior changes or new APIs:
git diff "upstream/$V1".."upstream/$V2" -- tests/d) Compare against the reference state (Step 1.4 / Step 3):
git diff <reference-commit> -- <failing-file>e) Fix, amend, re-run:
git add -A && git commit --amend --no-editRe-run the failing check via local-test-runner. Repeat until the check passes or escalate to user.
- Once all checks pass, provide summary:
- Custom commits replayed
- Conflicts resolved (list files and decisions)
- Check results (pass/fail for each, with log file paths)
- Any follow-up items needing manual review
Step 7: Cleanup
After user confirms b2 is satisfactory:
- Report backup branch name (snapshot of b1) for reference.
- Note b1 can be deleted if no longer needed.
- If the user wants to push b2:
git push origin HEAD
Command Reference
# Detect v1 — see detect-upstream-base skill
# Analyze b1: fork point and custom commits
FORK_POINT=$(git merge-base HEAD "upstream/$V1")
git log --oneline "$FORK_POINT"..HEAD
# Backup b1, create b2, squash (optional)
B1=$(git rev-parse --abbrev-ref HEAD)
git branch "backup-$B1-<timestamp>"
git checkout -b "$B1-$V2"
git reset --soft "$FORK_POINT"
git commit -m "squashed custom changes on top of $V1"
# Rebase b2 onto v2 (b2 already checked out, do NOT pass HEAD)
git rebase --onto "upstream/$V2" "$FORK_POINT"
# Conflict resolution loop
git status
git diff "upstream/$V1".."upstream/$V2" -- <file>
git add <resolved-file>
git rebase --continue
# Abort and return to b1
git rebase --abortUsage Examples
Rebase this branch from v0.19.1 to v0.20.0. Run transcription tests to verify.Use rebase-assistant to move custom patches to upstream/v0.20.0.
Checks: pytest tests/entrypoints/openai/correctness/test_transcription_api_correctness.py
Reference commit: c9a168488Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

