一键导入
oat-project-import-plan
Use when you have an external markdown plan to execute with OAT. Preserves the source plan and normalizes it into canonical plan.md format.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Use when you have an external markdown plan to execute with OAT. Preserves the source plan and normalizes it into canonical plan.md format.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Run when you need to evaluate agent instruction file coverage, quality, and drift. Produces a severity-rated analysis artifact. Run before oat-agent-instructions-apply to identify what needs improvement.
Run when you need to evaluate documentation structure, navigation, and coverage against the OAT docs app contract. Produces a severity-rated analysis artifact for oat-docs-apply.
Use when the user explicitly asks to continue discovery for an active spec-driven OAT project — e.g. "continue discovery", "run discovery", or confirms a previously offered discovery step. Do NOT auto-invoke for new ideas or quick-mode projects. Gathers requirements and context before spec/design.
Use when design.md is complete and executable implementation tasks are needed. Breaks design into bite-sized TDD tasks in canonical plan.md format.
Use when authoring or mutating plan.md in any OAT workflow. Defines canonical format invariants — stable task IDs, required sections, review table rules, and resume guardrails.
Use when the user explicitly asks to check OAT project progress — e.g. "check progress", "what's next", "where are we", or confirms a previously offered progress check. Do NOT auto-invoke just because a workflow step completed. Reads project status and offers the next route.
| name | oat-project-import-plan |
| version | 1.3.3 |
| description | Use when you have an external markdown plan to execute with OAT. Preserves the source plan and normalizes it into canonical plan.md format. |
| argument-hint | <path-to-plan.md> [--provider codex|cursor|claude] [--project <name>] |
| disable-model-invocation | true |
| user-invocable | true |
| allowed-tools | Read, Write, Bash, Glob, Grep, AskUserQuestion |
Import a markdown plan from an external coding provider and normalize it into OAT project artifacts.
OAT MODE: Plan Import
Purpose: Preserve the original plan and generate a runnable canonical plan.md for OAT execution.
BLOCKED Activities:
ALLOWED Activities:
Self-Correction Protocol: If you catch yourself:
pNN-tNN tasks.Recovery:
references/imported-plan.md.plan.md in OAT structure.When executing this skill, provide lightweight progress feedback so the user can tell what’s happening after they confirm.
Print a phase banner once at start using horizontal separators, e.g.:
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ OAT ▸ IMPORT PLAN ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Before multi-step work, print step indicators, e.g.:
[0/7] Checking inherited git state...[1/7] Resolving project + source plan…[2/7] Preserving imported source…[3/7] Normalizing plan to OAT task structure…[4/7] Updating plan metadata…[5/7] Running import-aware plan review…[6/7] Updating project state + dashboard…[7/7] Ensuring implementation tracker…Before scaffolding, surface the working tree state so unrelated changes don't get carried into the project workflow's bookkeeping commits.
git status --porcelain. If empty, continue silently to the next step..oat/sync/manifest.json or paths under .claude/, .cursor/, .codex/ appear in the list, note: "These are generated by oat sync (often by pnpm run worktree:init or oat-worktree-bootstrap-auto) and are typically safe to commit as chore: run sync."AskUserQuestion:
chore: run sync; otherwise ask the user for the commit message.Tool availability is not the same as interactivity. If
AskUserQuestionis unavailable but chat is available, present the three choices as a plain chat message and wait for the user's reply. Only fall back to "Proceed anyway" whenOAT_NON_INTERACTIVE=1is set or there is no user-response channel at all.
Do not advance past this gate without an explicit choice.
PROJECT_PATH=$(oat config get activeProject 2>/dev/null || true)
PROJECTS_ROOT="${OAT_PROJECTS_ROOT:-$(oat config get projects.root 2>/dev/null || echo ".oat/projects/shared")}"
PROJECTS_ROOT="${PROJECTS_ROOT%/}"
If no valid active project exists:
--project if provided, else ask user.TARGET_PROJECT_PATH="${PROJECTS_ROOT}/{project-name}".TARGET_PROJECT_PATH/state.md exists, set:
oat config set activeProject "$TARGET_PROJECT_PATH"
PROJECT_PATH="$TARGET_PROJECT_PATH"
oat project new "{project-name}" --mode import
PROJECT_PATH="$TARGET_PROJECT_PATH"
Inputs:
$ARGUMENTS--providerIf source path is not provided, discover likely recent plans first. The discovery script checks both provider plan directories and this repository's external plan directory by default:
.oat/repo/reference/external-plans/bash .agents/skills/oat-project-import-plan/scripts/find-recent-provider-plans.sh --hours 24
Optional: extend discovery roots via OAT_PROVIDER_PLAN_DIRS (colon-separated):
export OAT_PROVIDER_PLAN_DIRS="$HOME/custom-plans:$HOME/tmp/provider-plans"
Then ask user to either:
Validation rules:
.md (or user explicitly confirms nonstandard markdown extension).Create references directory if missing:
mkdir -p "$PROJECT_PATH/references"
cp "{source-path}" "$PROJECT_PATH/references/imported-plan.md"
Never overwrite an existing source snapshot without user confirmation. If already present, write timestamped copy:
references/imported-plan-YYYY-MM-DD-HHMM.mdCreate/update "$PROJECT_PATH/plan.md" using .oat/templates/plan.md and map imported content into the canonical structure. Apply oat-project-plan-writing invariants after mapping:
## Phase N### Task pNN-tNN (stable task IDs)## Reviews, ## Implementation Complete, ## ReferencesNormalization rules:
oat-project-plan-writing format (pNN-tNN).Dispatch Profile import handling:
## Dispatch Profile rows as user-authored constraints or preferences.Set frontmatter in "$PROJECT_PATH/plan.md":
oat_status: completeoat_ready_for: null (Step 4.5 sets this after the import-aware plan review)oat_phase: planoat_phase_status: completeoat_plan_source: importedoat_import_reference: references/imported-plan.mdoat_import_source_path: {source-path}oat_import_provider: {codex|cursor|claude|null}Invoke the shared Auto Artifact-Review Loop from oat-project-plan-writing with target plan before advancing project state or handing off to implementation.
Required payload:
target: plantype: artifactscope: planartifact_path: "$PROJECT_PATH/plan.md"oat_output_mode: structuredimport_aware: truereview_note: "Review for canonical OAT plan conformance, executable completeness, stable task IDs, required sections, review-row preservation, and verification clarity. Preserve the imported source's intent and ordering; do not rewrite the author's plan goals or product decisions unless required for OAT conformance or completeness."Apply the shared loop exactly:
workflow.autoArtifactReview.plan; only an explicit false skips the loop.oat_orchestration_retry_limit from project state, defaulting to 2.oat-reviewer in structured mode using Tier 1 subagent when available and Tier 2 inline fallback otherwise.plan artifact row in the ## Reviews table to passed when clean. If residual findings remain, preserve the row and surface the residual findings before downstream handoff.After the loop completes or is explicitly skipped, set "$PROJECT_PATH/plan.md" frontmatter:
oat_ready_for: oat-project-implementSet "$PROJECT_PATH/state.md" frontmatter:
oat_workflow_mode: importoat_workflow_origin: importedoat_phase: planoat_phase_status: completeoat_current_task: nulloat_project_state_updated: "{ISO 8601 UTC timestamp, e.g. 2026-03-10T14:30:00Z}"Import mode must leave the imported project as active for immediate execution.
Validate target project before writing pointer:
if [[ ! -f "$PROJECT_PATH/state.md" ]]; then
echo "Error: Project missing state.md: $PROJECT_PATH/state.md" >&2
exit 1
fi
oat config set activeProject "$PROJECT_PATH"
oat state refresh
If activeProject in local config already exists with a different path, treat this as a project switch and note it in output.
If missing, scaffold from template:
.oat/templates/implementation.md → "$PROJECT_PATH/implementation.md"Initialize pointer to first plan task ID.
Report:
oat-project-implement (sequential by default; parallel when oat_plan_parallel_groups is declared)references/imported-plan.md.plan.md generated with OAT task structure.plan.md metadata marks oat_plan_source: imported.plan.md records the import-aware plan artifact review row unless workflow.autoArtifactReview.plan was explicitly disabled.state.md marks oat_workflow_mode: import.implementation.md is present and resumable.oat_plan_hill_phases left unset in frontmatter (deferred to oat-project-implement Step 2.5).## Planning Checklist items left unchecked (HiLL configuration deferred to implementation).activeProject in .oat/config.local.json points to the imported project..oat/state.md has been refreshed locally after pointer update; it is not staged or committed.