cw-orient

cw-orient is a skill for Claude Code, Codex from Hmbown/Codewhale. It costs 43 tokens per session (1,098 once invoked), scanned A, original, MIT.

A session-start workflow for checking which repository checkout, branch, worktree, and files are authoritative. A worktree is a separate working directory connected to the same Git repository.

In plain words
What is it for?
Use it when starting or resuming work, taking over from another agent, or feeling unsure which branch owns the files.
Why use it?
It prevents editing the wrong checkout or trusting an old handoff note when several agents or branches are active. It establishes the live repository state before planning or editing.

Skill for Claude CodeCodex

Which agent this was written for is unclear — built for codewhale. Also seen: mentions AGENTS.md; built for codewhale.

Needs its repository: it runs a file that does not travel with it, so clone the repository first. The line is ./scripts/release/check-versions.sh.

Good fit Use it when starting or resuming work, taking over from another agent…

Compare 6 skills from other repositories ↓
About the project

Codewhale is an open-source coding agent that runs in the terminal and can read repositories, edit files, execute commands, and inspect results while pursuing a task. Developers use it with hosted providers or local models, with controls for how much access it receives.

Hmbown/Codewhale · 40,916 stars · on GitHub · codewhale.net

Install

Getting it into your agent

It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.

Clone the repo
git clone --depth 1 https://github.com/Hmbown/Codewhale
agentmods
npx agentmods add skills/hmbown/codewhale/cw-orient

Made for: Claude Code, Codex.

Wrote 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.

agentmods badge for cw-orient

README.md
[![agentmods](https://agentmods.dev/badge/skills/hmbown/codewhale/cw-orient.svg)](https://agentmods.dev/skills/hmbown/codewhale/cw-orient)
Your own site
<a href="https://agentmods.dev/skills/hmbown/codewhale/cw-orient"><img src="https://agentmods.dev/badge/skills/hmbown/codewhale/cw-orient.svg" alt="Measured on agentmods" height="20"></a>
Per session 43 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,098 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. ✓ AI security review Sonnet 5 · 6 Sept 2026
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5.1 $0.00043 $0.01098
Opus 5 $0.00022 $0.00549
Sonnet 5 $0.00009 $0.00220
Haiku 4.5 $0.00004 $0.00110

Measured today against content hash 5ae1554b2cac, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-07, from the pricing page.

Security

Grade A, and why

cw-orient 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 today.

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.

docs/skills/cw-orient/SKILL.md · 100 lines

How it starts

The opening of the file, as written. The whole thing — 100 lines — stays where its author put it; the contents beside it link to each section on GitHub.

cw-orient

Open every session on live truth, not on a handoff note, a directory name, or what was true last time. This repo runs many worktrees at once; the cheapest bug to avoid is editing the wrong one. Five commands, then you know where you are.

This is stage 1 of the loop: orient → cw-slicecw-gatescw-dogfoodcw-landcw-handoff.

When to use

  • Starting a session, resuming one, or taking over from another agent.
  • A handoff, issue, or plan tells you the state of the repo — verify before trusting it.
  • You are about to edit and are not certain this checkout owns the files.

Workflow

  1. Locate yourself. Checkout, branch, dirt, and how far you are from the remote:

    git rev-parse --show-toplevel && git branch --show-current
    git status --short --branch
    git log --oneline --decorate -10
    

    A detached HEAD or a branch with no upstream is normal here — note it, don't "fix" it silently.

  2. See the other lanes. Worktree sprawl is the standing hazard: several checkouts of this repo are usually live, each with its own dirty state.

    git worktree list
    git branch --sort=-committerdate --format='%(committerdate:short) %(refname:short)' | head -20
    

    If the work you were asked to do already has a worktree, use it. Do not start a second copy of the same lane.

  3. Read the dirt before you touch it. Modified files you did not write belong to someone else — another agent, another lane, an in-flight slice:

    git status --porcelain
    git diff --stat
    

    Preserve them. Leave them unstaged, and do not git checkout -- or stash another writer's work to get a clean tree. If your change genuinely conflicts with the dirt, work in a fresh worktree instead.

  4. Fix which guidance applies. The nearest scoped AGENTS.md wins over the root one, and it is where the per-area rules actually live:

    find . -name AGENTS.md -not -path './tmp/*' -not -path '*/node_modules/*' -not -path './target/*'
    

    Today: root AGENTS.md, crates/tui/AGENTS.md, crates/tui/locales/AGENTS.md, web/AGENTS.md. Read the one that owns the files you are about to touch.

Read the full file on GitHub · 100 lines

Changes

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.

  1. today First seen · 100 lines · 43 tokens per session scan A 5ae1554b2cac

Subscribe to this mod's changes

cw-orient is a skill published in the GitHub repository Hmbown/Codewhale (40,916 stars, last pushed today), licensed MIT. It adds 43 tokens to every session and 1,098 once invoked, about $0.0002 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-09-06.