一键导入
teach-oh
Project setup. Explore the codebase, ask about strategy and aims, write persistent context to AGENTS.md. Run when starting or when aims shift.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Project setup. Explore the codebase, ask about strategy and aims, write persistent context to AGENTS.md. Run when starting or when aims shift.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Do the work. Pre-flight, build, detect drift, salvage if needed. Use when you have a clear aim and are ready to implement.
Resolve multi-dependency fan-in by merging dependency PRs into a common base and updating issue dependencies
Review and merge open PRs for GitHub issues as a cohesive batch
Claim a GitHub issue, create its branch and draft PR before implementation, execute the work in isolation, and hand the completed draft to RNA's full ship gate.
Check work and detect drift before committing. A second opinion that catches misalignment early. Use at natural pause points, before PRs, or when something feels off.
Agent-led PR/working-tree review triage. Start from the diff, add RNA graph/business context only where it changes review decisions, and state when raw git diff is enough.
| name | teach-oh |
| description | Project setup. Explore the codebase, ask about strategy and aims, write persistent context to AGENTS.md. Run when starting or when aims shift. |
Setup that gathers project context and saves it to AGENTS.md (the cross-agent standard). Run when starting on a project or when strategy/aims have shifted.
Invoke /teach-oh when:
Do not use when: You're mid-task. This is setup, not execution.
Before exploring, check if RNA is available — it makes everything that follows richer.
Detection (in order):
search, repo_map, list_roots, or outcome_progress tools are available in the current sessionrepo-native-alignment is on PATH: which repo-native-alignment.mcp.json references repo-native-alignment or rna-serverIf RNA is available: Proceed to Step 1. Use repo_map for orientation and search for symbols, artifacts, neighbors, and impact instead of Grep/Read.
If RNA is NOT available: Offer to install it:
"I can set up Repo-Native Alignment (RNA) — it gives me semantic code search, graph traversal, and business context awareness across your codebase. Takes ~1 minute. Want me to install it?"
If accepted:
Detect platform and chip:
OS=$(uname -s)
ARCH=$(uname -m)
CHIP=$(sysctl -n machdep.cpu.brand_string 2>/dev/null || echo "")
Darwin + arm64 + brand_string contains "M4" → use darwin-arm64-m4Darwin + arm64 → use darwin-arm64Linux + x86_64 → use linux-x86_64Invoke the repo-local /rna-mcp:setup skill. It owns installation, selects a
successful CI release artifact for an immutable commit, verifies the artifact,
and configures the client. Never download a mutable latest artifact or use a
locally compiled binary as a shipped build.
Run setup for the current project:
repo-native-alignment setup --project .
This configures .mcp.json and verifies the pipeline.
Tell the user: "RNA is installed. Continuing with RNA CLI tools for this session. MCP tools (search, repo_map, list_roots, and outcome_progress) will be available after you restart the client."
If declined: Proceed without RNA. teach-oh works fine without it — exploration just uses standard tools (Grep, Read, Glob).
Before asking questions, scan the project independently:
Structure & Stack
Existing Context
.oh/, docs/adr/ directoriesPatterns & Conventions
Don't ask about what you can discover. Use exploration to form better questions.
After exploration, ask targeted questions about what couldn't be inferred. Focus on strategy and aims, not just code.
Ask only what you couldn't discover. Respect the user's time.
Synthesize findings into a structured section and offer to append to AGENTS.md (or create it if missing).
Offer two sections:
If phase agents were installed in Step 5, use the agents variant below. Otherwise use the skills variant.
Skills variant (no agents):
# Open Horizons Framework
**The shift:** Action is cheap. Knowing what to do is scarce.
**The sequence:** aim → problem-space → problem-statement → solution-space → draft PR → execute → ship
**Where to start (triggers):**
- Can't explain why you're building this → `/aim`
- Keep hitting the same blockers → `/problem-space`
- Solutions feel forced → `/problem-statement`
- About to start coding → `/solution-space`
- Work is drifting or reversing → `/salvage`
**Reflection skills (use anytime):**
- `/review` - Check alignment before committing
- `/dissent` - Seek contrary evidence before one-way doors
- `/salvage` - Extract learning, restart clean
- `/distill` - Curate accumulated metis; surface patterns for promotion
**Key insight:** Enter at the altitude you need. Climb back up when you drift.
---
# Project Context
## Purpose
[What this project does and why it matters]
## Current Aims
[Active goals and what success looks like]
## Key Constraints
- [Constraint 1]: [Why it exists]
- [Constraint 2]: [Why it exists]
## Patterns to Follow
- [Pattern]: [When/why to use it]
## Anti-Patterns to Avoid
- [Anti-pattern]: [Why it's problematic here]
## Decision Context
[How the team makes decisions, what "done" means]
Agents variant (phase agents installed):
# Open Horizons Framework
**The shift:** Action is cheap. Knowing what to do is scarce.
**The sequence:** aim → problem-space → problem-statement → solution-space → draft PR → execute → ship
Each phase runs as an agent with isolated context and scoped tools. Dispatch via
the `task` tool — each agent reads/writes `.oh/<session>.md` to pass context
between phases.
**Where to start (triggers):**
- Can't explain why you're building this → dispatch `oh-aim` agent
- Keep hitting the same blockers → dispatch `oh-problem-space` agent
- Solutions feel forced → dispatch `oh-problem-statement` agent
- About to start coding → dispatch `oh-solution-space` agent
- Ready to implement → create the draft PR, then dispatch `oh-execute` agent
- Code complete, need to deliver → dispatch `oh-ship` agent
- Work is drifting or reversing → `/salvage`
**Reflection skills (use anytime, in main session):**
- `/review` - Check alignment before committing
- `/dissent` - Seek contrary evidence before one-way doors
- `/salvage` - Extract learning, restart clean
- `/distill` - Curate accumulated metis; surface patterns for promotion
**Key insight:** Enter at the altitude you need. Climb back up when you drift.
---
# Project Context
## Purpose
[What this project does and why it matters]
## Current Aims
[Active goals and what success looks like]
## Key Constraints
- [Constraint 1]: [Why it exists]
- [Constraint 2]: [Why it exists]
## Patterns to Follow
- [Pattern]: [When/why to use it]
## Anti-Patterns to Avoid
- [Anti-pattern]: [Why it's problematic here]
## Decision Context
[How the team makes decisions, what "done" means]
Present findings for user approval before writing:
## Teach-OH Summary
### What I Discovered
- Stack: [technologies found]
- Structure: [key patterns observed]
- Existing context: [what docs already exist]
### Questions I Have
1. [Question about aims/strategy]
2. [Question about constraints]
3. [Question about team practices]
---
After your answers, I'll draft a AGENTS.md section for your approval.
After user answers:
## Proposed AGENTS.md Addition
[Draft the Project Context section]
---
**Write to AGENTS.md?** [Yes/No - show what will be added/updated]
/teach-oh
Agent explores, then:
## Teach-OH Summary
### What I Discovered
- Stack: TypeScript, React, Node.js, PostgreSQL
- Structure: Monorepo with apps/ and packages/
- Existing context: README exists, no AGENTS.md or CLAUDE.md
- Recent focus: Auth refactor (last 12 commits)
### Questions I Have
1. What's the main aim right now? The auth work—is that about security, UX, or maintenance?
2. I see both REST and GraphQL endpoints. Is one preferred, or context-dependent?
3. Any performance constraints? I see a Redis layer but no docs on when to use it.
4. What patterns should I follow vs. avoid?
User answers, agent drafts:
## Proposed AGENTS.md Addition
# Open Horizons Framework
**The shift:** Action is cheap. Knowing what to do is scarce.
**The sequence:** aim → problem-space → problem-statement → solution-space → draft PR → execute → ship
**Where to start (triggers):**
- Can't explain why you're building this → `/aim`
- Keep hitting the same blockers → `/problem-space`
- Solutions feel forced → `/problem-statement`
- About to start coding → `/solution-space`
- Work is drifting or reversing → `/salvage`
**Reflection skills:** `/review`, `/dissent`, `/salvage`, `/distill`
**Key insight:** Enter at the altitude you need. Climb back up when you drift.
---
# Project Context
## Purpose
Customer portal for B2B SaaS. Users are account admins managing their organization's settings, users, and billing.
## Current Aims
- Simplify auth flow so new SSO providers can be added in <1 day (currently takes 2 weeks)
- Success: Adding Okta support by end of Q1
## Key Constraints
- SOC2 compliance: All auth changes need security review
- <200ms API response time (SLA commitment)
- No breaking changes to existing OAuth integrations
## Patterns to Follow
- REST for public API, GraphQL for internal dashboard
- Redis for session state only, not general caching
- Feature flags via LaunchDarkly for gradual rollouts
## Anti-Patterns to Avoid
- Don't abstract OAuth providers into single interface (they have semantic differences)
- Avoid adding new environment variables without updating .env.example
## Decision Context
Tech lead approves architecture changes. PRs need one review. "Done" = deployed to staging with passing E2E tests.
---
**Write to AGENTS.md?** This will create a new file at ./AGENTS.md
If the user is running OMP (oh-my-pi), offer to install the phase-aware skills hook. This hook makes the framework self-guiding — it detects where the user is in the development cycle and suggests the right skill before each prompt.
When to offer: After writing AGENTS.md, if the project uses OMP. Detect OMP by checking for .omp/ directory or omp in the shell path.
What to ask:
"Install the phase-aware skills hook? It reads your
.oh/session files and suggests the right OH skill at the right moment. Copiesoh-skills-phase.tsto.omp/hooks/for auto-discovery."
If accepted:
Copy the hook only from a checked-in repo-local vendored asset into
.omp/hooks/oh-skills-phase.ts. If it is absent, skip installation and ask
that it be vendored through a reviewed PR. Never fetch mutable remote content.
Optionally create .oh/skills-config.json based on what you learned about the project. The config is loaded once at session start (changes require restarting OMP):
{
"projectSkills": ["aim", "problem-space", "solution-space", "execute", "review", "dissent"],
"disabledSkills": [],
"phaseOverrides": {
"execute": ["dissent"]
}
}
Customization guidance:
projectSkills: Include only the skills relevant to this project's workflow. A solo dev doing rapid iteration might skip problem-space. A team with compliance requirements might always want dissent before execute. Note: phaseOverrides targets must be included in projectSkills — override skills are filtered by the same allow list. Reflection skills (review, dissent, salvage, distill) are always-available and don't need to appear in projectSkills — they're invoked on demand, not phase-triggered.disabledSkills: Skills that don't fit this project (e.g., ship for a library that publishes via CI).phaseOverrides: Extra skills to suggest during specific phases. Common: adding dissent during execute for security-sensitive projects.If declined: Skip. The skills work fine without it — this is an enhancement, not a requirement.
If the user is not running OMP: Skip this step entirely. The hook requires the OMP hook API and will not work with other agents. Users can still install it manually later by copying the file to .omp/hooks/.
Phase skills benefit from running in isolated context windows with scoped tools — formalizing the pattern of clearing sessions between phases. Offer to install pre-built agent wrappers that give each phase its own context.
When to offer: After Step 4, if OMP detected.
What to ask:
"Install OH phase agents? Each phase gets isolated context and scoped tools — aim/problem-statement are read-only, execute gets full capabilities. Writes to
.omp/agents/."
If accepted:
Copy all 6 agent files from checked-in repo-local vendored assets into
.omp/agents/ (create the directory if needed):
Files:
oh-aim.md
oh-problem-space.md
oh-problem-statement.md
oh-solution-space.md
oh-execute.md
oh-ship.md
If the assets are absent, skip installation and ask that they be vendored through a reviewed PR. Do not fabricate them or fetch mutable remote content.
MCP preamble (only if OH MCP is configured — check for oh_get_endeavors in
the parent session's available tools, or for .oh/mcp.json in the project):
After writing all 6 files, append this block to each agent file:
## Open Horizons MCP
- Query related endeavors for context before starting analysis
- Log key outputs (aim statements, problem statements, decisions) to the graph
- Link session work to active endeavors
If OH MCP is not present, skip this block — the agents work without it.
RNA MCP preamble (only if repo-native-alignment MCP is configured — check for
RNA search or repo_map in the parent session's available tools, or for rna-server in
.mcp.json):
After writing all 6 files, append this block to each agent file:
## Repo-Native Alignment MCP
When rna-server tools are available:
- Before framing: call `search` with the task description and `include_artifacts: true` to find relevant outcomes, guardrails, and metis
- After producing output: write learnings to `.oh/metis/<slug>.md`
- When checking progress: call `outcome_progress` with the relevant outcome ID
- When discovering constraints: write to `.oh/guardrails/<slug>.md`
- When measuring progress: write to `.oh/signals/<slug>.md`
- After completing work: tag commits with `[outcome:X]`
If RNA MCP is not present, skip this block — the agents work without it.
Cross-cutting skills (review, dissent, salvage) stay as skills — they need conversation context to detect drift.
If declined: Skip. Skills continue to work as prompt injections.
If the user is running Claude Code (not OMP), offer to install phase agents to .claude/agents/.
When to offer: After writing AGENTS.md, if Claude Code detected (check for .claude/ directory or if running as Claude Code).
What to ask:
"Install OH phase agents for Claude Code? Each phase gets its own agent with scoped tools. Writes to
.claude/agents/."
If accepted:
Copy all 6 agent files from checked-in repo-local vendored assets into
.claude/agents/ (create the directory if needed):
Files:
oh-aim.md
oh-problem-space.md
oh-problem-statement.md
oh-solution-space.md
oh-execute.md
oh-ship.md
If the assets are absent, skip installation and ask that they be vendored through a reviewed PR. Do not fabricate them or fetch mutable remote content.
MCP preambles: The pre-packaged Claude Code agents already include OH MCP and RNA MCP preamble sections. No additional append needed.
If declined: Skip. Skills continue to work as slash commands.
With project context established:
/aim frames outcomes in your language/problem-space knows which constraints are real/dissent understands your risk tolerance/review checks against your definition of done/execute follows your patternsRemember: This is setup, not ongoing work. Invest 10 minutes when starting or when things have shifted.