Skip to content
Back to skills

Trajectory Risk Supervisor

ASecurity

Classify task traces, detect risky engineering trajectories, score advisory bad-state risk, and route to the least disruptive intervention. Use when a repo has docs/observability/task-trace.jsonl, trajectory risk policy, repeated agent drift, skipped validation, broad diffs, or needs shadow-mode trajectory supervision.

  • 3 stars
  • 0 votes
  • 0 copies
  • 4 views
  • Added September 12, 2026
researchrustsecurity

Works with

  • cli

Security analysis

A100/100

Pro scans all 2 files and shows the line behind each finding

Scanned September 12, 2026

npx -y skills add pax-k/pax-fullstack-harness --skill trajectory-risk-supervisor --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Trajectory Risk Supervisor?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Trajectory Risk Supervisor
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/pax-k-trajectory-risk-supervisor/badge)](https://www.skillsdirectory.com/skills/pax-k-trajectory-risk-supervisor)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: trajectory-risk-supervisor
description: Classify task traces, detect risky engineering trajectories, score advisory bad-state risk, and route to the least disruptive intervention. Use when a repo has docs/observability/task-trace.jsonl, trajectory risk policy, repeated agent drift, skipped validation, broad diffs, or needs shadow-mode trajectory supervision.
---

# Trajectory Risk Supervisor

## Purpose

Use observable task traces to detect quality drift before finalization without turning the harness into a blocking daemon.

## Inspect First

- `docs/observability/task-trace.jsonl`
- `docs/observability/trajectory-risk-policy.json`
- `docs/observability/trajectory-risk-report.md`
- feature state, sprint contract, termination evidence, pre-edit evidence, review findings, and recent validation output

## Procedure

1. Collect or inspect trace events.
   - Use `docs/observability/task-trace.jsonl` as newline-delimited JSON.
   - Events should record task id, task type, phase, action, files read, files changed, commands run, validation, risk surfaces, intervention, outcome, and notes.
   - Use `scripts/append_task_trace.py` when a deterministic event append is useful.

2. Classify the current trajectory.
   - Run `scripts/classify_agent_trace.py <repo> --json`.
   - Derive task phase, task type, repo understanding, diff scope, test status, risk surfaces, repeated failure loops, and evidence coverage.

3. Check invariants and score risk.
   - Run `scripts/check_trajectory_invariants.py <repo> --json`.
   - Run `scripts/score_trajectory_risk.py <repo> --json`.
   - Treat scoring as shadow/advisory unless the target repo explicitly wires enforcement through its own wrapper.

4. Recommend the least disruptive intervention.
   - Editing before inspection routes to `$pre-edit-investigation-gate`.
   - Repeated failures route to `$agent-failure-introspection`.
   - Finalization without tests routes to `$termination-gatekeeper`.
   - Dependency choices without sources route to `$research-first-change`.
   - UI lifecycle gaps route to `$click-path-and-browser-qa`.
   - Security, migration, or broad-diff risks route to `$agent-reviewer` or a generated reviewer subagent.

5. Document risk when useful.
   - Use `assets/templates/trajectory-risk-report.md.tmpl`.
   - Keep hooks out of default behavior; plugin hooks are a future opt-in shadow layer only after users trust them.

## Validation

- Run `scripts/classify_agent_trace.py <repo> --json`.
- Run `scripts/score_trajectory_risk.py <repo> --json`.
- Confirm every risk cites trace evidence and maps to a concrete intervention or command.
- Confirm advisory mode does not block unrelated lightweight repos.

## Completion Criteria

- The current task trajectory has a clear state, risk level, evidence list, and recommended intervention.
- The repo can opt into `./scripts/check-trajectory-risk` without changing the stable baseline command interface.

Files in this skill

  • SKILL.md2.9 KB
  • agents/openai.yaml278 B

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.