engineer/skills/reorient/SKILL.md
Use mid-task when the working thread is lost — after a context compaction, a long agent run, or coming back to a feature unsure of the role, the current checkpoint, or the next action. Triggers — "/engineer.reorient", "reorient", "re-anchor", "what should I be doing right now", "I lost track", "where was I".
npx skillsauth add swingerman/atdd reorientInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Restore the working contract mid-task. After a context compaction or a long
run, an agent loses role identity, invents constraints that do not exist, skips
required steps, and loses the task thread. reorient reloads the durable state
that should have survived — the discipline contract first, the task pointer
second.
Read-only and advisory. It changes nothing, produces no artifact, and emits
no handoff — like next, the orientation block is the whole output; a
handoff would only restate it. The third skill exempt from the agentic summary
contract.
reorient is the mid-task, feature-scoped counterpart to next (project-scoped,
session-start).
SessionStart hook can auto-invoke it).Not for: session-start "what should I pick up across the project" (next);
loading a feature not yet started (prime-context); validating artifacts
(consistency-check).
Resolve the methodology root + manifest via
${CLAUDE_PLUGIN_ROOT}/scripts/dae_resolve.py (see references/resolving.md).
Locate the feature (slug arg or branch name). If no feature is in scope, say so
and suggest next instead.
Read, read-only, in this order:
CHARTER.md + manifest: the autonomy level in force,
and what the agent may and may not decide. Counters invented constraints.progress.md shows in
progress: its goal, its exit criteria, and which are already met. Run
${CLAUDE_PLUGIN_ROOT}/scripts/dae_progress.py <feature-dir> and show its
breadcrumb — the same pipeline-position line the checkpoint skills surface
at Step 0.progress.md CURRENT header.feature.md outcome + scope. Counters goal drift.Also run ${CLAUDE_PLUGIN_ROOT}/scripts/dae_handoff.py <feature-dir> — report any
checkpoint marked done without a complete handoff as a discipline gap.
Output one tight block, nothing else:
You are <role> at autonomy <level>.
Feature NNN-slug — Checkpoint N (<goal>).
Exit criteria: <m>/<n> met — unmet: <list>.
Current task: <task> -> next action: <action>.
Must not skip: <non-negotiables>.
Constraints: <charter / autonomy limits>.
Before stopping, scan the feature's recent handoffs for a stuck loop. A loop is "stuck" when three or more consecutive handoffs from the same skill share:
status (typically interrupted or complete-with-unmet-criteria), ANDfindings_summary / failure signature (e.g. same error class, same blocker name, same infra failure type).A stuck loop is the agent re-attempting the same operation expecting different results. nexthq saw 60+ identical ticks over 12 hours on a Functions emulator blocker — the autonomous loop never escalated to the human.
Threshold is tunable via manifest.autonomy.stuck_loop_threshold (default 3).
When detected: STOP. Do not silently re-run. Emit (just this once — break the no-handoff rule) a session-summary-style escalation handoff that:
human_action_needed: decision and human_action_kind: unblock-stuck-loop.recommended_next: "human review required — N consecutive identical failures from <skill>".The escalation handoff lives in .engineer/handoffs/ (it's project-scope, not feature-scope progress). The human picks the unblock — a different approach, a charter amendment, an environment fix, or a deferred re-try.
If Step 4 found no loop: reorient orients; it does not act. The human resumes the work. No handoff.
If Step 4 escalated: the escalation handoff is the output. The loop is broken — wait for the human.
A project may add a SessionStart hook (source: compact) that nudges
/engineer.reorient after every compaction. See
${CLAUDE_PLUGIN_ROOT}/examples/session-start-reorient.md. The hook is optional
project config, not part of this skill.
next — the project-scoped, session-start counterpartdata-ai
Use immediately after a PR is merged to clean up the local feature branch and resync main. Triggers — "/engineer.post-merge", "did we merge", "did we push", "PR merged", "post-merge cleanup", or right after a `gh pr merge` succeeds in the same session.
data-ai
Use to drive a bug fix from first report through close, with a "why didn't we catch it?" loop at the end. Triggers — "/engineer.fix", "a bug came in", "this is broken", "a user reported X", "there's a defect", "we have a regression", "this needs a fix", "another report", "more issues", "still failing", "validation failed again", "another bug", "next defect", "more fixes".
development
Use to check a feature's code against the charter's architecture rules — dependency layering, cycles, forbidden patterns, file naming, file size. Triggers — "/engineer.arch-check", "architecture check", "check architecture fitness", "does this follow the charter", "check layering".
tools
Use at the start of a work session, or any time the question is "what should I pick up now" across the whole project. Triggers — "/engineer.next", "what's next", "what should I work on", "what should I do next", "where do I pick up".