Now liveThe Skillselion MCP - thousands of ranked skills, loaded into your agent mid-task. No install.Get it →
athola avatar

Sem Integration

  • 80 installs
  • 325 repo stars
  • Updated August 2, 2026
  • athola/claude-night-market

sem-integration is an agent skill that detects or installs the sem CLI so code review can use entity-level semantic diffs instead of line-level git diffs.

About

sem-integration is a small agent skill slice for Claude Night Market / Leyline that ensures the sem semantic diff CLI is available before your agent relies on it. Detection checks a session cache file, then falls back to `command -v sem`. If sem is missing, the agent offers prioritized install options: `cargo install --locked sem-cli` on any Rust toolchain, optional Homebrew on macOS when a formula exists, or a curl-based Linux binary into `~/.local/bin`. Users can decline and continue with ordinary git diffs. Solo builders who review large refactors install it to reduce diff noise—renames and moves read as semantic changes rather than delete/add line storms. It is an integration helper, not sem itself; you still need Rust or curl access for first-time setup.

  • Session cache at `$CLAUDE_CODE_TMPDIR/sem-available` to avoid repeated detection
  • Install-on-first-use with cargo, Homebrew search fallback, and Linux binary download paths
  • Prompt template when sem is missing so the user can install or skip to standard git diff
  • Entity-level semantic diffs via sem-cli instead of line-level diffs

Sem Integration by the numbers

  • 80 all-time installs (skills.sh)
  • Ranked #251 of 733 Git & Pull Requests skills by installs in the Skillselion catalog
  • Security screen: HIGH risk (skills.sh audit)
  • Data as of Aug 5, 2026 (Skillselion catalog sync)
npx skills add https://github.com/athola/claude-night-market --skill sem-integration

Add your badge

Show developers this skill is listed on Skillselion. Paste this into your README.

Listed on Skillselion
Installs80
repo stars325
Security audit1 / 3 scanners passed
Last updatedAugust 2, 2026
Repositoryathola/claude-night-market

What it does

Detect or install the sem semantic-diff CLI on first use so reviews get entity-level diffs instead of noisy line-level git output.

Who is it for?

Agents doing PR review or refactor summaries on Rust-friendly machines where one-time sem install is acceptable.

Skip if: Environments that forbid shell installs or curl downloads during agent sessions.

When should I use this skill?

The agent needs sem for semantic diffs and sem may not be installed yet.

What you get

sem is detected or installed once per session with a clear skip path, enabling semantic diffs—or standard git diff if you opt out.

  • sem CLI available on PATH or explicit user skip to git diff
  • Prompted install choice with platform-specific commands

By the numbers

  • Session cache path: `$CLAUDE_CODE_TMPDIR/sem-available`
  • Estimated_tokens: 250 in skill frontmatter

Files

SKILL.mdMarkdownGitHub ↗

sem Integration

Foundation patterns for using sem semantic diffs in night-market skills.

When To Use

Consult this skill when building or modifying skills that consume git diff output. It provides the detection, installation, and fallback patterns.

When NOT To Use

  • Direct sem CLI usage (just run sem diff yourself)
  • Skills that don't consume diff output

Detection Pattern

Check sem availability once per session:

# Detection (cache per session)
_sem_check() {
  local cache="${CLAUDE_CODE_TMPDIR:-/tmp}/sem-available"
  if [ -f "$cache" ]; then
    cat "$cache"
    return
  fi
  if command -v sem &>/dev/null; then
    echo "1" | tee "$cache"
  else
    echo "0" | tee "$cache"
  fi
}

When _sem_check returns 0, offer installation. See modules/detection.md for install-on-first-use logic and platform-specific commands.

Semantic Diff Pattern

Primary path (sem available):

sem diff --format json <baseline>

Fallback path (sem unavailable):

git diff --name-only --diff-filter=A <baseline>
git diff --name-only --diff-filter=M <baseline>
git diff --name-only --diff-filter=D <baseline>
git diff --name-only --diff-filter=R <baseline>

See modules/fallback.md for output normalization that produces the same entity schema from both paths.

Impact Analysis Pattern

Primary path (sem available):

sem impact --json <file-or-entity>

Fallback path (sem unavailable): use rg/grep to trace callers by filename. See modules/fallback.md.

Related skills

How it compares

Integration wrapper for sem-cli—not a replacement for git diff or full static-analysis review suites.

FAQ

Who is sem-integration for?

Developers using Claude Code-style agents who want semantic diffs during review without hand-maintaining sem in every project.

When should I use sem-integration?

During Ship review when comparing branches or summarizing changes and entity-level diffs would clarify refactors versus churn.

Is sem-integration safe to install?

It may run shell installs and download binaries from GitHub releases; review the Security Audits panel on this page and trust the sem-cli source before allowing network installs.

This week in AI coding

Five minutes, every Monday - the tools, releases and tactics for developers.

unsubscribe anytime.