Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add skills/code-yeongyu/senpi/merge-upstreamnpx skills add code-yeongyu/senpi --skill merge-upstreamgit clone --depth 1 https://github.com/code-yeongyu/senpiWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/code-yeongyu/senpi/merge-upstream)<a href="https://agentmods.dev/skills/code-yeongyu/senpi/merge-upstream"><img src="https://agentmods.dev/badge/skills/code-yeongyu/senpi/merge-upstream.svg" alt="Measured on agentmods" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00052 | $0.01601 |
| Opus 5 | $0.00026 | $0.00800 |
| Sonnet 5 | $0.00010 | $0.00320 |
| Haiku 4.5 | $0.00005 | $0.00160 |
Grade A, and why
merge-upstream scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 5d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 168 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Merge Upstream
Sync the current fork branch with upstream/<branch> using a merge commit by default. Preserve local commit hashes, keep push non-destructive, and never rewrite history.
Usage
Treat these as equivalent triggers:
/merge-upstream [--base=<branch>] [--ff-allow]
merge upstream [--base=<branch>] [--ff-allow]
sync fork with upstream
Options:
--base=<branch>: use that upstream branch instead of auto-detecting the upstream default branch.--ff-allow: allowgit merge --ff-onlywhen the current branch has no unique local commits. Without this, usegit merge --no-ffto leave an explicit sync commit.
Invariants
- Do not run
git rebase. - Do not run
git push --forceorgit push --force-with-lease. - Do not bypass hooks or signing with
--no-verifyor--no-gpg-sign. - Ask before pushing.
Workflow
-
Validate the repository:
git rev-parse --is-inside-work-tree git branch --show-current git remote get-url upstream git remote get-url originAbort on detached HEAD or missing
upstream. Iforiginis missing, continue locally and skip push. -
Require a clean worktree:
worktree_status=$(git status --porcelain) || exit 1 test -z "$worktree_status"If dirty, stop and ask the user to clean or commit the changes, or use a clean task worktree.
-
Detect the upstream target branch:
- If
--base=<branch>is provided, fetch and verifyupstream/<branch>. - Otherwise run
git remote set-head upstream -a, then readrefs/remotes/upstream/HEAD. - If detection fails, ask the user for
--base=<branch>.
- If
-
Fetch enough history for a reliable merge base:
git rev-parse --is-shallow-repository git fetch --tags upstream "+refs/heads/${upstream_branch}:refs/remotes/upstream/${upstream_branch}" origin_branch_exists=false if git remote get-url origin >/dev/null 2>&1; then if ! origin_branch=$(git ls-remote --heads origin "refs/heads/${current_branch}"); then echo "failed to inspect origin/${current_branch}" >&2 exit 1 elif [ -n "$origin_branch" ]; then git fetch origin "+refs/heads/${current_branch}:refs/remotes/origin/${current_branch}" || exit 1 origin_branch_exists=true else echo "origin/${current_branch} does not exist; current branch is unpublished" fi fi git merge-base HEAD "upstream/${upstream_branch}"
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 5d ago First seen · 168 lines · 52 tokens per session scan A 8e07c9ecdb30
merge-upstream is a skill published in the GitHub repository code-yeongyu/senpi (420 stars, last pushed today), licensed MIT. It adds 52 tokens to every session and 1,601 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other skills, from other repositories
transformers
This skill should be used when working with pre-trained transformer models for natural language processing, computer vision, audio, or multimodal tasks. Use for text generation, classification, question answering, translation, summarization, image classification, object detection, speech recognition, and fine-tuning…
generate-image
Generate or edit images using AI models (FLUX, Gemini). Use for general-purpose image generation including photos, illustrations, artwork, visual assets, concept art, and any image that isn't a technical diagram or schematic. For flowcharts, circuits, pathways, and technical diagrams, use the scientific-schematics…
pi
Use when needing a minimal, extensible terminal AI coding agent harness in TypeScript with plugin architecture. Pi: minimalist terminal AI coding agent emphasizing simplicity and composability.
speckit-archive
Archive a feature specification into main project memory after merge, resolving gaps and conflicts.
speckit-critique-run
Perform a dual-lens critical review of the specification and plan from both product strategy and engineering risk perspectives before implementation.
speckit-extract-run
Extract knowledge, guidelines, and ADRs from one or more completed spec directories into the project documentation system.