@raquezha/norpiv 0.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +154 -0
- package/bin/norpiv-install.cjs +166 -0
- package/cleanup/SKILL.md +53 -0
- package/frame/SKILL.md +38 -0
- package/grill-with-docs/SKILL.md +43 -0
- package/implement/SKILL.md +132 -0
- package/implement/scripts/enforce-branch.sh +122 -0
- package/package.json +49 -0
- package/plan/SKILL.md +34 -0
- package/scripts/reposcry-bootstrap.sh +84 -0
- package/scripts/reposcry-refresh.sh +19 -0
- package/scripts/reposcry-task-context.sh +32 -0
- package/scripts/triage_helper.sh +401 -0
- package/scripts/validate_active_task.sh +328 -0
- package/sync/SKILL.md +131 -0
- package/sync/design-brief.md +39 -0
- package/sync/jira_smart_sync.sh +156 -0
- package/triage/SKILL.md +102 -0
- package/update-docs/SKILL.md +32 -0
- package/update-docs/references/doc-destination-map.md +31 -0
- package/verify/SKILL.md +32 -0
package/triage/SKILL.md
ADDED
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: triage
|
|
3
|
+
description: "Ingest or resume a tracked/local task in the RPIV workspace. Use when starting or returning to jira:, github:, gitlab:, or local: work and you need canonical WORK.md state without duplicating scaffold."
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Skill: triage
|
|
7
|
+
|
|
8
|
+
Start RPIV by creating, resuming, or explicitly reopening a task workspace.
|
|
9
|
+
|
|
10
|
+
## Guardrails
|
|
11
|
+
- READ: user argument, `.workflow/active_task.json` when present, target `metadata.json`, and target `WORK.md` when resuming.
|
|
12
|
+
- WRITE: `.workflow/tasks/[source-id]/WORK.md`, `.workflow/tasks/[source-id]/metadata.json`, `.workflow/active_task.json`; optional `.reposcry/` cache files only when RepoScry is installed.
|
|
13
|
+
- On **create**, initialize required guarded sections only if absent: `[BRIEF]`, `[GRILL]`, `[PLAN]`, `[LOG]`, `[META]`.
|
|
14
|
+
- On **resume**, only update `.workflow/active_task.json`, metadata timestamps/state as needed, `[META]`, and append one concise `[LOG]` entry.
|
|
15
|
+
- NEVER: duplicate guarded sections.
|
|
16
|
+
- NEVER: overwrite existing `[BRIEF]`, `[GRILL]`, or `[PLAN]` during triage.
|
|
17
|
+
- NEVER: create `PROBLEM.md`, `PRD.md`, `PLAN.md`, or `EVIDENCE.md`.
|
|
18
|
+
- NEVER: implement code during triage.
|
|
19
|
+
- NEVER: guess source from `#123`; require explicit `jira:`, `github:`, `gitlab:`, or `local:`.
|
|
20
|
+
- NEVER: strip or hide the Jira key for `jira:` tasks; preserve it in `[META]` and in the triage log so `/implement` can require it in the commit subject.
|
|
21
|
+
- NEVER: mutate `done` or `archived` tasks unless the user explicitly requested `reopen`, `fresh`, or `reset`.
|
|
22
|
+
|
|
23
|
+
## Command forms
|
|
24
|
+
- `/triage local:setup-v2` — auto mode: create if missing, resume if active/blocked.
|
|
25
|
+
- `/triage resume local:setup-v2` — resume existing task; create if missing only when helper reports that behavior.
|
|
26
|
+
- `/triage reopen local:setup-v2` — explicitly reopen a done/archived task and mark it active.
|
|
27
|
+
- `/triage fresh local:setup-v2` — archive/reset the previous task workspace and create a fresh one.
|
|
28
|
+
- `/triage reset local:setup-v2` — alias for fresh/reset behavior when supported by the helper.
|
|
29
|
+
|
|
30
|
+
## Semantics
|
|
31
|
+
|
|
32
|
+
### Create
|
|
33
|
+
Use when the target task folder does not exist.
|
|
34
|
+
- Fetch remote issue data for `github:`, `gitlab:`, or `jira:` sources.
|
|
35
|
+
- Create `.workflow/tasks/[source-id]/metadata.json` with at least `id`, `source`, `taskFolder`, `branch`, `status`, `phase`, `createdAt`, `updatedAt`.
|
|
36
|
+
- Create `.workflow/tasks/[source-id]/WORK.md` with guarded RPIV sections.
|
|
37
|
+
- Set `status=active` and `phase=triaged`.
|
|
38
|
+
- Write canonical `.workflow/active_task.json`.
|
|
39
|
+
|
|
40
|
+
### Resume
|
|
41
|
+
Use when the task exists and `status` is `active`, `blocked`, or missing/legacy.
|
|
42
|
+
- Do not refetch remote data.
|
|
43
|
+
- Do not rewrite the brief, grill notes, or plan.
|
|
44
|
+
- Backfill missing metadata fields without destroying unknown fields.
|
|
45
|
+
- Refresh active pointer and human-readable `[META]`.
|
|
46
|
+
- Append one timestamped `[LOG]` entry such as `Task resumed via /triage`.
|
|
47
|
+
|
|
48
|
+
### Reopen
|
|
49
|
+
Use only when the user explicitly asks to reopen a task that is `done` or `archived`.
|
|
50
|
+
- Mark `status=active`.
|
|
51
|
+
- Preserve existing `WORK.md` history.
|
|
52
|
+
- Append a `[LOG]` entry explaining the reopen.
|
|
53
|
+
- Recommend returning to the next valid RPIV stage based on existing sections.
|
|
54
|
+
|
|
55
|
+
### Fresh / reset
|
|
56
|
+
Use only when the user explicitly asks to start over.
|
|
57
|
+
- Preserve or archive the old task workspace before creating a new one when the helper supports it.
|
|
58
|
+
- Create a new task workspace with clean guarded sections.
|
|
59
|
+
- Do not silently delete task history.
|
|
60
|
+
|
|
61
|
+
### Refuse
|
|
62
|
+
Use when auto/resume mode targets a `done` or `archived` task.
|
|
63
|
+
- Stop instead of mutating.
|
|
64
|
+
- Tell the user to choose `reopen` or `fresh/reset`.
|
|
65
|
+
|
|
66
|
+
## Workflow
|
|
67
|
+
1. Parse optional mode and required namespace:
|
|
68
|
+
- `jira:PROJ-123` -> `jira-PROJ-123`
|
|
69
|
+
- `github:42` -> `github-42`
|
|
70
|
+
- `gitlab:42` -> `gitlab-42`
|
|
71
|
+
- `local:name` -> `local-name`
|
|
72
|
+
2. Run the bundled helper script: `../scripts/triage_helper.sh <source> <id> [mode]`.
|
|
73
|
+
- Preferred absolute path: `<skill_dir>/../scripts/triage_helper.sh`.
|
|
74
|
+
3. Read the resulting active pointer, metadata, and `WORK.md`.
|
|
75
|
+
4. Determine action from helper output and task state: `created`, `resumed`, `reopened`, `refused`, or `fresh/reset`.
|
|
76
|
+
5. Optional RepoScry bootstrap: if the bundled `../scripts/reposcry-bootstrap.sh` is available, run it to seed `.reposcry/` for later `/frame` and `/grill-with-docs`. The helper must ensure `.reposcry/` is ignored, must stop if `.reposcry/` is tracked/staged, and should continue normally when RepoScry is unavailable.
|
|
77
|
+
6. **Technical Pre-check (Repo Pulse)** for created/reopened/resumed tasks:
|
|
78
|
+
- Extract key filenames, classes, commands, or keywords from the issue/task description.
|
|
79
|
+
- Verify existence on the current branch when concrete files are named.
|
|
80
|
+
- Check recent commits or open PRs only when relevant to the named files/scope.
|
|
81
|
+
- Version-check environment/dependencies only when the task depends on a version claim.
|
|
82
|
+
7. Classify the task: Problem / Proposal.
|
|
83
|
+
8. **Log Findings**: append concise Repo Pulse and classification findings to `[LOG]` only. Do not edit `[BRIEF]`, `[GRILL]`, or `[PLAN]`.
|
|
84
|
+
9. **Branch Guidance**: record the current branch in `[META]`. For `jira:` tasks, also preserve the Jira key in `[META]` and mention that `/implement` must use it in the commit subject. Planning on `main`/`master` is allowed; implementation must use `/implement` branch enforcement.
|
|
85
|
+
10. End by recommending the next valid command:
|
|
86
|
+
- newly created -> `/frame`
|
|
87
|
+
- existing with empty `[BRIEF]` -> `/frame`
|
|
88
|
+
- framed but not grilled -> `/grill-with-docs`
|
|
89
|
+
- grilled but not planned -> `/plan`
|
|
90
|
+
- planned -> await explicit `/implement` or `EXECUTE`
|
|
91
|
+
- refused -> ask user to choose `reopen` or `fresh/reset`
|
|
92
|
+
|
|
93
|
+
## Output contract
|
|
94
|
+
End with:
|
|
95
|
+
- **Active task**: `[source-id]`
|
|
96
|
+
- **Action**: created / resumed / reopened / refused / fresh-reset
|
|
97
|
+
- **Status**: active / blocked / done / archived / unknown
|
|
98
|
+
- **Phase**: triaged / framed / grilled / planned / implementing / verifying / synced / closed / unknown
|
|
99
|
+
- **Branch**: current branch
|
|
100
|
+
- **Repo Pulse**: Found / Missing / Outdated / Not applicable
|
|
101
|
+
- **Classification**: Problem / Proposal
|
|
102
|
+
- **Next step**: `/frame`, `/grill-with-docs`, `/plan`, `/implement`, or explicit reopen/fresh choice
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: update-docs
|
|
3
|
+
description: Curate durable repo documentation after workflow, skill, setup, or process changes. Use when the user asks to update AGENTS.md, README, skill docs, repo instructions, or document what changed without creating context bloat.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Skill: update-docs
|
|
7
|
+
|
|
8
|
+
Prevent docs drift and context bloat. Update durable repo documentation so future pi sessions match current repo reality.
|
|
9
|
+
|
|
10
|
+
## Guardrails
|
|
11
|
+
- READ first: `AGENTS.md`, `pi/AGENTS.md`, `README.md`, `pi/skills/README.md`, and relevant `SKILL.md` files.
|
|
12
|
+
- WRITE durable docs only; task state stays in `.workflow/tasks/*/WORK.md`.
|
|
13
|
+
- NEVER dump conversation history.
|
|
14
|
+
- NEVER add secrets, credentials, env values, or private tokens.
|
|
15
|
+
- NEVER edit docs during planning unless the user explicitly asks to update docs.
|
|
16
|
+
|
|
17
|
+
## Workflow
|
|
18
|
+
1. Identify what changed in workflow, setup, hats, skills, or repo process.
|
|
19
|
+
2. Classify each update using `references/doc-destination-map.md`.
|
|
20
|
+
3. Propose or apply the smallest durable doc edits that reflect the current state.
|
|
21
|
+
4. Prefer rules and decisions over event history.
|
|
22
|
+
5. Validate that docs match actual files, commands, hats, and skill names.
|
|
23
|
+
|
|
24
|
+
## Output contract
|
|
25
|
+
End with:
|
|
26
|
+
- **Docs updated**: paths changed
|
|
27
|
+
- **Why**: one-line reason per file
|
|
28
|
+
- **Not documented**: anything intentionally left out to avoid bloat
|
|
29
|
+
- **Reload needed**: whether to run `./scripts/setup.sh` or `/reload`
|
|
30
|
+
|
|
31
|
+
## References
|
|
32
|
+
- `references/doc-destination-map.md`
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
# Documentation destination map
|
|
2
|
+
|
|
3
|
+
Use this map to keep durable documentation minimal and accurate.
|
|
4
|
+
|
|
5
|
+
| Knowledge type | Destination | Rule |
|
|
6
|
+
| --- | --- | --- |
|
|
7
|
+
| Permanent agent behavior or safety rule | `AGENTS.md` | Keep short, imperative, and repo-wide. |
|
|
8
|
+
| Pi-specific agent/skill behavior | `pi/AGENTS.md` | Use for pi-local conventions and skill/harness behavior. |
|
|
9
|
+
| User-facing repo workflow | `README.md` | Explain how to use the repo, not internal debate. |
|
|
10
|
+
| Skill inventory or skill usage | `pi/skills/README.md` | List notable skills and categories. |
|
|
11
|
+
| Specific skill behavior | `pi/skills/**/SKILL.md` | Keep activation-time instructions only. |
|
|
12
|
+
| Long skill examples or decision maps | `pi/skills/**/references/*.md` | Move bulky details out of `SKILL.md`. |
|
|
13
|
+
| Domain or technical memory | `docs/agents/*.md` | Store condensed durable rules, not session logs. |
|
|
14
|
+
| Temporary task state | `.workflow/tasks/*/WORK.md` | Never copy wholesale into durable docs. |
|
|
15
|
+
|
|
16
|
+
## Anti-bloat checks
|
|
17
|
+
|
|
18
|
+
Before editing durable docs, ask:
|
|
19
|
+
|
|
20
|
+
1. Is this a durable rule or just a session event?
|
|
21
|
+
2. Will a future agent need this on most related tasks?
|
|
22
|
+
3. Is this already documented elsewhere?
|
|
23
|
+
4. Can this be one clear rule instead of a paragraph?
|
|
24
|
+
5. Does this belong in a skill reference instead of `AGENTS.md`?
|
|
25
|
+
|
|
26
|
+
## Never document
|
|
27
|
+
|
|
28
|
+
- Secrets, credentials, tokens, private URLs, or env values.
|
|
29
|
+
- Raw conversation transcripts.
|
|
30
|
+
- Temporary task progress that belongs in `.workflow/tasks/*/WORK.md`.
|
|
31
|
+
- The user's emotional venting, except as a neutral process rule when it affects future agent behavior.
|
package/verify/SKILL.md
ADDED
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: verify
|
|
3
|
+
description: Verify the active slice or task against WORK.md, quality gates, and review readiness. Use after implementation or manual changes to decide whether work is ready for sync, review, or cleanup.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Skill: verify
|
|
7
|
+
|
|
8
|
+
The final gate for a slice or task. Verify truth before reporting progress.
|
|
9
|
+
|
|
10
|
+
## Guardrails
|
|
11
|
+
- READ: `.workflow/active_task.json`, active `WORK.md` `[BRIEF]`, `[PLAN]`, and `[LOG]`.
|
|
12
|
+
- WRITE: `WORK.md` -> `[PLAN]` checkboxes and append to `[LOG]` only.
|
|
13
|
+
- NEVER: add `Signed-off-by`; tell the human to sign if needed.
|
|
14
|
+
- NEVER: transition tracker state if verification fails.
|
|
15
|
+
- NEVER: delete `.workflow` task folders without explicit user approval.
|
|
16
|
+
|
|
17
|
+
## Workflow
|
|
18
|
+
1. Compare code changes against `[BRIEF]` and the current `[PLAN]` slice.
|
|
19
|
+
2. Run stated verification commands and available quality gates.
|
|
20
|
+
3. If RepoScry is available, optionally add graph-aware evidence with commands such as `reposcry validate main HEAD` and `reposcry --repo . get_affected_flows main HEAD`. Treat RepoScry as supplemental evidence, not a hard requirement. Verify `.reposcry/` is not staged or tracked before reporting review readiness.
|
|
21
|
+
4. Check for AI artifacts: placeholder comments, fake APIs, dead code, inconsistent naming.
|
|
22
|
+
5. Confirm commit messages include Conventional Commit format and `Assisted-by: [AGENT]:[MODEL] [tools]` when AI contributed.
|
|
23
|
+
6. If passing, mark the slice checkbox complete in `[PLAN]` and append verification evidence to `[LOG]` (Format: `YYYY-MM-DD hh:mm AM/PM`).
|
|
24
|
+
7. Recommend `/sync` for tracker update, or cleanup if the task is fully merged and user approves.
|
|
25
|
+
|
|
26
|
+
## Output contract
|
|
27
|
+
End with:
|
|
28
|
+
- **Objective met**: yes/no
|
|
29
|
+
- **Verification used**
|
|
30
|
+
- **Slice status**
|
|
31
|
+
- **Tracker sync needed**: yes/no
|
|
32
|
+
- **Next step**
|