code-yeongyu/oh-my-openagent / .agents/skills/senpi-qa
senpi-qa
VerifiedQA the omo Senpi adapter (packages/omo-senpi, packages/senpi-task) against the REAL senpi binary in strict isolation, and write every artifact to the one canonical evidence path .omo/evidence/omo-senpi-adapter/<slug>/. The live drivers under packages/omo-senpi/scripts/qa/ create their own isolated SENPI_CODING_AGENT_DIR and ignore the caller's, so the real ~/.senpi/agent is never written. Ships scripts/resolve-evidence-dir.mjs, which is the ONLY sanctioned way to pick an evidence directory: it rejects traversal, separators, absolute paths, and stray roots such as local-ignore/qa-evidence. Use whenever someone changes anything under packages/omo-senpi or packages/senpi-task, or wants to QA, smoke-test, verify, or debug the Senpi adapter, the task/team engine, the DAG, task RPC, or skill delivery. Triggers: senpi qa, qa senpi, senpi-qa, test senpi adapter, verify senpi task, senpi task e2e, senpi team e2e, task dag qa, live senpi driver, senpi evidence path.
| File | Kind | Size |
|---|---|---|
| SKILL.md | skill md | 5.3 KB |
| scripts/resolve-evidence-dir.mjs | script | 2.8 KB |
| scripts/resolve-evidence-dir.test.mjs | script | 5.6 KB |
scripts/resolve-evidence-dir.mjs
View on GitHub#!/usr/bin/env node
// resolve-evidence-dir.mjs - pick the canonical evidence directory for a live Senpi QA run.
//
// Live Senpi QA artifacts belong under .omo/evidence/omo-senpi-adapter/<slug>/ and nowhere else.
// That path is the repository-standard location every AGENTS.md rule points at, and it is gitignored,
// so a hand-typed alternative (local-ignore/qa-evidence/..., .qa-evidence/ at the worktree root, a temp
// dir, a traversal) either strands the evidence or lands it in a commit (#8703). Resolving through
// this script makes the path a checked contract instead of a convention.
//
// The resolver COMPUTES and VALIDATES only; creating the directory stays the caller's decision, so
// a rejected slug never leaves a stray directory behind.
//
// node resolve-evidence-dir.mjs --repo-root "$(git rev-parse --show-toplevel)" --slug 20260820-my-run
//
// Prints the absolute path to stdout. Exit 0 iff the root is a git worktree and the slug is safe.
import { existsSync, realpathSync } from "node:fs"
import { join, resolve } from "node:path"
import { fileURLToPath } from "node:url"
export const EVIDENCE_RELATIVE_ROOT = join(".omo", "evidence", "omo-senpi-adapter")
// One relative segment: lowercase alphanumerics joined by single hyphens. This is what makes the
// path predictable - it also rejects every separator, traversal, and absolute form outright, since
// none of them can match.
const SAFE_SLUG = /^[a-z0-9]+(?:-[a-z0-9]+)*$/
/**
* @param {{ repoRoot: string, slug: string }} input
* @returns {string} absolute evidence directory; NOT created
*/
export function resolveEvidenceDir({ repoRoot, slug }) {
if (typeof repoRoot !== "string" || repoRoot.length === 0) {
throw new Error("repoRoot must be a non-empty path to a git worktree")
}
if (!existsSync(join(repoRoot, ".git"))) {
throw new Error(`repoRoot is not a git worktree: ${repoRoot}`)
}
if (typeof slug !== "string" || !SAFE_SLUG.test(slug)) {
throw new Error(
`slug must be one lowercase alphanumeric-and-hyphen segment (got ${JSON.stringify(slug)}); ` +
`evidence lives under ${EVIDENCE_RELATIVE_ROOT}/<slug>`,
)
}
return resolve(repoRoot, EVIDENCE_RELATIVE_ROOT, slug)
}
const isDirectRun =
process.argv[1] !== undefined &&
existsSync(process.argv[1]) &&
realpathSync(process.argv[1]) === realpathSync(fileURLToPath(import.meta.url))
if (isDirectRun) {
const args = process.argv.slice(2)
const read = (flag) => {
const at = args.indexOf(flag)
return at === -1 ? undefined : args[at + 1]
}
try {
const dir = resolveEvidenceDir({ repoRoot: read("--repo-root") ?? process.cwd(), slug: read("--slug") })
process.stdout.write(`${dir}\n`)
} catch (error) {
process.stderr.write(`${error instanceof Error ? error.message : String(error)}\n`)
process.exit(1)
}
}
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| finishing-a-development-branchobra/superpowersUse when implementation is complete, all tests pass, and you need to decide how to integrate the work | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| systematic-debuggingobra/superpowersUse when encountering any bug, test failure, or unexpected behavior, before proposing fixes | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| test-driven-developmentobra/superpowersUse when implementing any feature or bugfix, before writing implementation code | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| skill-creatoranthropics/skillsCreate new skills, modify and improve existing skills, and measure skill performance. Use when users want to create a skill from scratch, edit, or optimize an existing skill, run evals to test a skill, benchmark skill performance with variance analysis, or optimize a skill's description for better triggering accuracy. | Stars: 198k | Updated | Claude CodeCodex | Verified | Install |