@devenius/junamis-skills 0.0.0-stage → 1.1.0
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/CHANGELOG.md +150 -0
- package/LICENSE +21 -0
- package/README.md +231 -2
- package/SECURITY.md +81 -0
- package/bin/junamis-skills.js +7 -0
- package/dist/cli.d.ts +59 -0
- package/dist/cli.d.ts.map +1 -0
- package/dist/cli.js +564 -0
- package/dist/cli.js.map +1 -0
- package/dist/color.d.ts +40 -0
- package/dist/color.d.ts.map +1 -0
- package/dist/color.js +55 -0
- package/dist/color.js.map +1 -0
- package/dist/design/atomic.d.ts +4 -0
- package/dist/design/atomic.d.ts.map +1 -0
- package/dist/design/atomic.js +14 -0
- package/dist/design/atomic.js.map +1 -0
- package/dist/design/bootstrap.d.ts +23 -0
- package/dist/design/bootstrap.d.ts.map +1 -0
- package/dist/design/bootstrap.js +411 -0
- package/dist/design/bootstrap.js.map +1 -0
- package/dist/design/cli.d.ts +86 -0
- package/dist/design/cli.d.ts.map +1 -0
- package/dist/design/cli.js +425 -0
- package/dist/design/cli.js.map +1 -0
- package/dist/design/delta.d.ts +45 -0
- package/dist/design/delta.d.ts.map +1 -0
- package/dist/design/delta.js +557 -0
- package/dist/design/delta.js.map +1 -0
- package/dist/design/drift.d.ts +26 -0
- package/dist/design/drift.d.ts.map +1 -0
- package/dist/design/drift.js +341 -0
- package/dist/design/drift.js.map +1 -0
- package/dist/design/errors.d.ts +25 -0
- package/dist/design/errors.d.ts.map +1 -0
- package/dist/design/errors.js +30 -0
- package/dist/design/errors.js.map +1 -0
- package/dist/design/events.d.ts +18 -0
- package/dist/design/events.d.ts.map +1 -0
- package/dist/design/events.js +44 -0
- package/dist/design/events.js.map +1 -0
- package/dist/design/fingerprint.d.ts +10 -0
- package/dist/design/fingerprint.d.ts.map +1 -0
- package/dist/design/fingerprint.js +66 -0
- package/dist/design/fingerprint.js.map +1 -0
- package/dist/design/index-gen.d.ts +16 -0
- package/dist/design/index-gen.d.ts.map +1 -0
- package/dist/design/index-gen.js +94 -0
- package/dist/design/index-gen.js.map +1 -0
- package/dist/design/schema.d.ts +54 -0
- package/dist/design/schema.d.ts.map +1 -0
- package/dist/design/schema.js +408 -0
- package/dist/design/schema.js.map +1 -0
- package/dist/design/yaml.d.ts +12 -0
- package/dist/design/yaml.d.ts.map +1 -0
- package/dist/design/yaml.js +264 -0
- package/dist/design/yaml.js.map +1 -0
- package/dist/external.d.ts +61 -0
- package/dist/external.d.ts.map +1 -0
- package/dist/external.js +426 -0
- package/dist/external.js.map +1 -0
- package/dist/guide.d.ts +17 -0
- package/dist/guide.d.ts.map +1 -0
- package/dist/guide.js +219 -0
- package/dist/guide.js.map +1 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +7 -0
- package/dist/index.js.map +1 -0
- package/dist/install-external.d.ts +3 -0
- package/dist/install-external.d.ts.map +1 -0
- package/dist/install-external.js +37 -0
- package/dist/install-external.js.map +1 -0
- package/dist/library-install.d.ts +39 -0
- package/dist/library-install.d.ts.map +1 -0
- package/dist/library-install.js +663 -0
- package/dist/library-install.js.map +1 -0
- package/dist/orchestrator/boot.d.ts +3 -0
- package/dist/orchestrator/boot.d.ts.map +1 -0
- package/dist/orchestrator/boot.js +515 -0
- package/dist/orchestrator/boot.js.map +1 -0
- package/dist/orchestrator/cli.d.ts +37 -0
- package/dist/orchestrator/cli.d.ts.map +1 -0
- package/dist/orchestrator/cli.js +563 -0
- package/dist/orchestrator/cli.js.map +1 -0
- package/dist/orchestrator/commands.d.ts +46 -0
- package/dist/orchestrator/commands.d.ts.map +1 -0
- package/dist/orchestrator/commands.js +752 -0
- package/dist/orchestrator/commands.js.map +1 -0
- package/dist/orchestrator/compaction.d.ts +21 -0
- package/dist/orchestrator/compaction.d.ts.map +1 -0
- package/dist/orchestrator/compaction.js +93 -0
- package/dist/orchestrator/compaction.js.map +1 -0
- package/dist/orchestrator/drift.d.ts +11 -0
- package/dist/orchestrator/drift.d.ts.map +1 -0
- package/dist/orchestrator/drift.js +181 -0
- package/dist/orchestrator/drift.js.map +1 -0
- package/dist/orchestrator/errors.d.ts +52 -0
- package/dist/orchestrator/errors.d.ts.map +1 -0
- package/dist/orchestrator/errors.js +96 -0
- package/dist/orchestrator/errors.js.map +1 -0
- package/dist/orchestrator/frontmatter.d.ts +6 -0
- package/dist/orchestrator/frontmatter.d.ts.map +1 -0
- package/dist/orchestrator/frontmatter.js +50 -0
- package/dist/orchestrator/frontmatter.js.map +1 -0
- package/dist/orchestrator/fsx.d.ts +45 -0
- package/dist/orchestrator/fsx.d.ts.map +1 -0
- package/dist/orchestrator/fsx.js +295 -0
- package/dist/orchestrator/fsx.js.map +1 -0
- package/dist/orchestrator/handoff.d.ts +8 -0
- package/dist/orchestrator/handoff.d.ts.map +1 -0
- package/dist/orchestrator/handoff.js +246 -0
- package/dist/orchestrator/handoff.js.map +1 -0
- package/dist/orchestrator/hash.d.ts +10 -0
- package/dist/orchestrator/hash.d.ts.map +1 -0
- package/dist/orchestrator/hash.js +65 -0
- package/dist/orchestrator/hash.js.map +1 -0
- package/dist/orchestrator/journal.d.ts +35 -0
- package/dist/orchestrator/journal.d.ts.map +1 -0
- package/dist/orchestrator/journal.js +163 -0
- package/dist/orchestrator/journal.js.map +1 -0
- package/dist/orchestrator/lease.d.ts +31 -0
- package/dist/orchestrator/lease.d.ts.map +1 -0
- package/dist/orchestrator/lease.js +175 -0
- package/dist/orchestrator/lease.js.map +1 -0
- package/dist/orchestrator/plan.d.ts +27 -0
- package/dist/orchestrator/plan.d.ts.map +1 -0
- package/dist/orchestrator/plan.js +240 -0
- package/dist/orchestrator/plan.js.map +1 -0
- package/dist/orchestrator/report.d.ts +49 -0
- package/dist/orchestrator/report.d.ts.map +1 -0
- package/dist/orchestrator/report.js +244 -0
- package/dist/orchestrator/report.js.map +1 -0
- package/dist/orchestrator/state.d.ts +43 -0
- package/dist/orchestrator/state.d.ts.map +1 -0
- package/dist/orchestrator/state.js +369 -0
- package/dist/orchestrator/state.js.map +1 -0
- package/dist/orchestrator/store.d.ts +42 -0
- package/dist/orchestrator/store.d.ts.map +1 -0
- package/dist/orchestrator/store.js +202 -0
- package/dist/orchestrator/store.js.map +1 -0
- package/dist/orchestrator/test-hooks.d.ts +5 -0
- package/dist/orchestrator/test-hooks.d.ts.map +1 -0
- package/dist/orchestrator/test-hooks.js +31 -0
- package/dist/orchestrator/test-hooks.js.map +1 -0
- package/dist/orchestrator/time.d.ts +11 -0
- package/dist/orchestrator/time.d.ts.map +1 -0
- package/dist/orchestrator/time.js +38 -0
- package/dist/orchestrator/time.js.map +1 -0
- package/dist/paths.d.ts +9 -0
- package/dist/paths.d.ts.map +1 -0
- package/dist/paths.js +42 -0
- package/dist/paths.js.map +1 -0
- package/dist/pinned-source.d.ts +13 -0
- package/dist/pinned-source.d.ts.map +1 -0
- package/dist/pinned-source.js +238 -0
- package/dist/pinned-source.js.map +1 -0
- package/dist/reconcile/cli.d.ts +17 -0
- package/dist/reconcile/cli.d.ts.map +1 -0
- package/dist/reconcile/cli.js +171 -0
- package/dist/reconcile/cli.js.map +1 -0
- package/dist/reconcile/detectors.d.ts +29 -0
- package/dist/reconcile/detectors.d.ts.map +1 -0
- package/dist/reconcile/detectors.js +294 -0
- package/dist/reconcile/detectors.js.map +1 -0
- package/dist/reconcile/manifest.d.ts +11 -0
- package/dist/reconcile/manifest.d.ts.map +1 -0
- package/dist/reconcile/manifest.js +118 -0
- package/dist/reconcile/manifest.js.map +1 -0
- package/dist/reconcile/queue.d.ts +3 -0
- package/dist/reconcile/queue.d.ts.map +1 -0
- package/dist/reconcile/queue.js +723 -0
- package/dist/reconcile/queue.js.map +1 -0
- package/dist/reconcile/score.d.ts +19 -0
- package/dist/reconcile/score.d.ts.map +1 -0
- package/dist/reconcile/score.js +58 -0
- package/dist/reconcile/score.js.map +1 -0
- package/dist/scripts/check-opencode-config.d.ts +12 -0
- package/dist/scripts/check-opencode-config.d.ts.map +1 -0
- package/dist/scripts/check-opencode-config.js +216 -0
- package/dist/scripts/check-opencode-config.js.map +1 -0
- package/dist/scripts/check-pack.d.ts +3 -0
- package/dist/scripts/check-pack.d.ts.map +1 -0
- package/dist/scripts/check-pack.js +74 -0
- package/dist/scripts/check-pack.js.map +1 -0
- package/dist/scripts/check-pins.d.ts +9 -0
- package/dist/scripts/check-pins.d.ts.map +1 -0
- package/dist/scripts/check-pins.js +65 -0
- package/dist/scripts/check-pins.js.map +1 -0
- package/dist/scripts/check-security.d.ts +3 -0
- package/dist/scripts/check-security.d.ts.map +1 -0
- package/dist/scripts/check-security.js +47 -0
- package/dist/scripts/check-security.js.map +1 -0
- package/dist/scripts/check-skills-lock.d.ts +7 -0
- package/dist/scripts/check-skills-lock.d.ts.map +1 -0
- package/dist/scripts/check-skills-lock.js +36 -0
- package/dist/scripts/check-skills-lock.js.map +1 -0
- package/dist/scripts/check-skills-sync.d.ts +7 -0
- package/dist/scripts/check-skills-sync.d.ts.map +1 -0
- package/dist/scripts/check-skills-sync.js +146 -0
- package/dist/scripts/check-skills-sync.js.map +1 -0
- package/dist/scripts/check-yaml.d.ts +3 -0
- package/dist/scripts/check-yaml.d.ts.map +1 -0
- package/dist/scripts/check-yaml.js +41 -0
- package/dist/scripts/check-yaml.js.map +1 -0
- package/dist/scripts/publish-npm.d.ts +3 -0
- package/dist/scripts/publish-npm.d.ts.map +1 -0
- package/dist/scripts/publish-npm.js +67 -0
- package/dist/scripts/publish-npm.js.map +1 -0
- package/dist/scripts/release-check.d.ts +3 -0
- package/dist/scripts/release-check.d.ts.map +1 -0
- package/dist/scripts/release-check.js +97 -0
- package/dist/scripts/release-check.js.map +1 -0
- package/dist/scripts/support.d.ts +41 -0
- package/dist/scripts/support.d.ts.map +1 -0
- package/dist/scripts/support.js +78 -0
- package/dist/scripts/support.js.map +1 -0
- package/dist/targets/claude.d.ts +4 -0
- package/dist/targets/claude.d.ts.map +1 -0
- package/dist/targets/claude.js +42 -0
- package/dist/targets/claude.js.map +1 -0
- package/dist/targets/cline.d.ts +4 -0
- package/dist/targets/cline.d.ts.map +1 -0
- package/dist/targets/cline.js +39 -0
- package/dist/targets/cline.js.map +1 -0
- package/dist/targets/cursor.d.ts +4 -0
- package/dist/targets/cursor.d.ts.map +1 -0
- package/dist/targets/cursor.js +40 -0
- package/dist/targets/cursor.js.map +1 -0
- package/dist/targets/index.d.ts +4 -0
- package/dist/targets/index.d.ts.map +1 -0
- package/dist/targets/index.js +11 -0
- package/dist/targets/index.js.map +1 -0
- package/dist/targets/opencode.d.ts +4 -0
- package/dist/targets/opencode.d.ts.map +1 -0
- package/dist/targets/opencode.js +48 -0
- package/dist/targets/opencode.js.map +1 -0
- package/dist/targets/windsurf.d.ts +4 -0
- package/dist/targets/windsurf.d.ts.map +1 -0
- package/dist/targets/windsurf.js +41 -0
- package/dist/targets/windsurf.js.map +1 -0
- package/dist/types/common.d.ts +193 -0
- package/dist/types/common.d.ts.map +1 -0
- package/dist/types/common.js +6 -0
- package/dist/types/common.js.map +1 -0
- package/dist/types/design.d.ts +185 -0
- package/dist/types/design.d.ts.map +1 -0
- package/dist/types/design.js +3 -0
- package/dist/types/design.js.map +1 -0
- package/dist/types/guards.d.ts +13 -0
- package/dist/types/guards.d.ts.map +1 -0
- package/dist/types/guards.js +64 -0
- package/dist/types/guards.js.map +1 -0
- package/dist/types/handoff.d.ts +29 -0
- package/dist/types/handoff.d.ts.map +1 -0
- package/dist/types/handoff.js +3 -0
- package/dist/types/handoff.js.map +1 -0
- package/dist/types/index.d.ts +7 -0
- package/dist/types/index.d.ts.map +1 -0
- package/dist/types/index.js +11 -0
- package/dist/types/index.js.map +1 -0
- package/dist/types/orchestrator.d.ts +414 -0
- package/dist/types/orchestrator.d.ts.map +1 -0
- package/dist/types/orchestrator.js +4 -0
- package/dist/types/orchestrator.js.map +1 -0
- package/dist/types/reconcile.d.ts +160 -0
- package/dist/types/reconcile.d.ts.map +1 -0
- package/dist/types/reconcile.js +3 -0
- package/dist/types/reconcile.js.map +1 -0
- package/docs/RECONCILE.md +505 -0
- package/docs/design/_schema.md +506 -0
- package/junamis-skills.yml +328 -0
- package/library/EXTERNAL.md +35 -0
- package/library/HANDOFF.md +93 -0
- package/library/RESUME.md +429 -0
- package/library/SAFETY.md +83 -0
- package/library/agents/context-keeper.md +41 -0
- package/library/agents/frontend.md +43 -0
- package/library/agents/maintainer.md +44 -0
- package/library/agents/nestjs.md +40 -0
- package/library/agents/nextjs.md +40 -0
- package/library/agents/operator.md +42 -0
- package/library/agents/orchestrator.md +313 -0
- package/library/agents/researcher.md +40 -0
- package/library/agents/reviewer.md +40 -0
- package/library/skills/db-migrate/SKILL.md +50 -0
- package/library/skills/decision-record/SKILL.md +74 -0
- package/library/skills/dependency-upgrade/SKILL.md +57 -0
- package/library/skills/deploy-verify/SKILL.md +51 -0
- package/library/skills/document/SKILL.md +51 -0
- package/library/skills/env-doctor/SKILL.md +65 -0
- package/library/skills/frontend/SKILL.md +63 -0
- package/library/skills/handoff/SKILL.md +79 -0
- package/library/skills/incident-response/SKILL.md +69 -0
- package/library/skills/nestjs/SKILL.md +49 -0
- package/library/skills/nextjs/SKILL.md +48 -0
- package/library/skills/perf-budget/SKILL.md +62 -0
- package/library/skills/refactor-safely/SKILL.md +48 -0
- package/library/skills/release-prep/SKILL.md +75 -0
- package/library/skills/research/SKILL.md +66 -0
- package/library/skills/rollback/SKILL.md +49 -0
- package/library/skills/route/SKILL.md +107 -0
- package/library/skills/route-external/SKILL.md +67 -0
- package/library/skills/security-audit/SKILL.md +64 -0
- package/library/skills/skill-author/SKILL.md +49 -0
- package/opencode.json +5906 -0
- package/package.json +88 -4
- package/scripts/design-registry.mjs +7 -0
- package/scripts/orchestrator-state.mjs +7 -0
- package/scripts/reconcile.mjs +7 -0
- package/skills-lock.json +197 -0
|
@@ -0,0 +1,328 @@
|
|
|
1
|
+
# junamis-skills — complete project reference
|
|
2
|
+
# This file is the single source of truth for the project's structure, features,
|
|
3
|
+
# setup, runtime functionality, decisions, and validation. Keep it in sync with
|
|
4
|
+
# bin/, src/**/*.ts, dist/ (build output), scripts/, library/, skills-lock.json,
|
|
5
|
+
# and SECURITY.md.
|
|
6
|
+
Name: junamis-skills
|
|
7
|
+
CLI: junamis-skills
|
|
8
|
+
Bins: [junamis-skills, junamis-orchestrator, junamis-design-registry, junamis-reconcile]
|
|
9
|
+
License: MIT
|
|
10
|
+
Status: 1.1.x (Node 26+; ESM; external installs also need the system git CLI)
|
|
11
|
+
|
|
12
|
+
Description: >
|
|
13
|
+
Install and manage Agent Skills (SKILL.md workflows) for AI coding agents. The
|
|
14
|
+
package ships the installer, a pinned external-skill manifest, and the owned
|
|
15
|
+
library (orchestrator plus specialist agents and their skills). It never
|
|
16
|
+
vendors third-party SKILL.md content: external skills are fetched at locked
|
|
17
|
+
commits, verified against the recorded scan, and installed non-interactively.
|
|
18
|
+
|
|
19
|
+
Architecture:
|
|
20
|
+
PackageContent:
|
|
21
|
+
- "bin/junamis-skills.js is the only executable entry point for the installer."
|
|
22
|
+
- "src/**/*.ts holds all runtime code as TypeScript: the CLI, the external installer, the pinned-source checkout, the library installer, and the guide writer."
|
|
23
|
+
- "src/orchestrator/ holds the journal-first resume state engine."
|
|
24
|
+
- "src/**/*.ts is the source of truth; the published package ships only the built dist/ output and its declarations."
|
|
25
|
+
- "dist/ is generated by pnpm build (JavaScript, .d.ts declarations, source maps) and is never committed."
|
|
26
|
+
- "bin/junamis-skills.js and scripts/*.mjs are thin launchers that import their implementation from dist/."
|
|
27
|
+
- "scripts/orchestrator-state.mjs is the thin launcher over dist/orchestrator/cli.js for the junamis-orchestrator bin."
|
|
28
|
+
- "src/targets/ is the only place that knows agent-specific paths and agent-definition formats."
|
|
29
|
+
- "library/ holds owned skills, agents, and shared docs; it is published with the package."
|
|
30
|
+
- "library/RESUME.md is the normative persistence and resume contract."
|
|
31
|
+
- "docs/RECONCILE.md is the work-queue contract and installs as a shared doc next to RESUME.md."
|
|
32
|
+
- "skills-lock.json is the single source of truth for external skills."
|
|
33
|
+
- "SECURITY.md is the scan record for every internal and external skill."
|
|
34
|
+
WorkIsolation:
|
|
35
|
+
- "Every orchestrator prompt starts with git branch --show-current. On main or a detached HEAD it runs git fetch origin and git switch -c task/<task-slug> origin/main (or git switch -c task/<task-slug> main with no remote) and continues on that branch; on a task branch it continues; it never works on main."
|
|
36
|
+
- "The orchestrator works in the project checkout on task/<task-slug> and commits there; the state root (<project>/.orchestrator/) and the design registry (<project>/docs/design/) live in that checkout."
|
|
37
|
+
- "The Delegation plan in <state-root>/delegation.md assigns every file to exactly one task and records owner, depends on, worktree, branch, allowed files, and done proof; dependency order decides dispatch."
|
|
38
|
+
- "Each delegated task runs in <project>/.worktrees/<task-slug>-<subtask> on task/<task-slug>-<subtask>, cut from the task branch, and may edit only the allowed files; any other file asks the orchestrator, and the sub-agent never creates a pull request."
|
|
39
|
+
- "When a sub-agent finishes, the orchestrator verifies the diff is a subset of the allowed files, runs the task checks, merges with git merge --no-ff, removes the worktree with git worktree remove, and deletes the merged sub-branch with git branch -d; on conflict it runs git merge --abort, stops, and asks the user."
|
|
40
|
+
- "Worktree limit is 8: before creating one, count git worktree list entries under .worktrees/ and prune only a worktree merged into the task branch and clean with git worktree remove, never rm -rf; ask the user when none qualifies."
|
|
41
|
+
- "After every task is merged and the full gate passes, the orchestrator asks the user for approval, pushes task/<task-slug> with git push -u origin task/<task-slug>, opens one pull request with gh pr create, reports the URL, and stops. Creating the pull request is the end of its authority: it never merges, never uses --admin, never pushes main, never force-pushes, never tags, and never rebases or resets main. The user reviews and merges."
|
|
42
|
+
- "Approvals are single-use: an approval covers one command in one prompt exactly once, ends when that command finishes or fails, and never carries to a retry, a second command, a later step, another task, another pull request, or another session; a general go-ahead is not approval and every gated command must be asked for again. Commands allowed by opencode.json (read-only git, build, test, task-branch pushes, gh pr create, and gh pr reads) are not gated."
|
|
43
|
+
Persistence:
|
|
44
|
+
- "State root: <project>/.orchestrator/ by default; ORCH_STATE_ROOT overrides it."
|
|
45
|
+
- "journal.ndjson is the append-only source of truth with a hash chain; state.json, plan.json, and tasks/<task_id>/task.json are derived snapshots."
|
|
46
|
+
- "boot runs before route, acquires the lease, verifies the journal and fingerprints, reconciles in-flight work, and writes resume-report.md and STATE.md."
|
|
47
|
+
- "A live lease halts a second session; a stale lease is taken over. Idempotent interruptions retry; non-idempotent interruptions escalate."
|
|
48
|
+
- "The engine uses only Node 26 built-in modules and adds no runtime dependency."
|
|
49
|
+
InstallLayout:
|
|
50
|
+
- "Config root: ~/.config/junamis/skills/ (the project segment for junamis-skills is skills)."
|
|
51
|
+
- "OpenCode internal skills: ~/.config/junamis/skills/skills/<name>/SKILL.md."
|
|
52
|
+
- "Canonical agents: ~/.config/junamis/skills/agents/<name>.md."
|
|
53
|
+
- "OpenCode agent links: ~/.config/opencode/agents/<name>.md -> the canonical file."
|
|
54
|
+
- "OpenCode shared docs: ~/.config/junamis/skills/{HANDOFF,SAFETY,EXTERNAL,SECURITY,RESUME}.md."
|
|
55
|
+
- "Installed skill manifest for the state engine: ~/.config/junamis/skills/skills-lock.json."
|
|
56
|
+
- "OpenCode install manifest: ~/.config/junamis/skills/installed/library-opencode.json."
|
|
57
|
+
- "OpenCode external skills: ~/.agents/skills/<name>/SKILL.md."
|
|
58
|
+
- "Execution state: <project>/.orchestrator/ (gitignored; never inside the OS temp directory)."
|
|
59
|
+
- "Claude Code uses one skills directory (~/.claude/skills) for internal and external skills; canonical agents are still linked into ~/.claude/agents."
|
|
60
|
+
- "Project scope mirrors the config root under <project>/.config/junamis/skills/{skills,agents,*.md,installed}; external skills stay at <project>/.agents/skills and project agent links at <project>/.opencode/agents (OpenCode)."
|
|
61
|
+
- "No automatic migration: init writes only the nested layout, and status reports old flat files as legacy without deleting them."
|
|
62
|
+
SupplyChain:
|
|
63
|
+
- "skills-lock.json pins a 40-character upstream commit and a 40-character skill tree SHA for every external skill."
|
|
64
|
+
- "The checkout is a Git tree at the locked commit (HEAD === ref). In-tree symlinks are allowed; absolute and escaping symlinks and gitlinks are rejected."
|
|
65
|
+
- "The scanner is skillsio@1.1.3 from the public npm registry, with a pinned tarball URL and SHA-512 integrity."
|
|
66
|
+
- "Auto-install passes --skip-scan: -y cannot bypass the high/critical scan prompt, so the recorded scan is the gate."
|
|
67
|
+
- "After each successful group every expected <name>/SKILL.md is verified on disk; only verified skills count as installed."
|
|
68
|
+
- "No branch heads, raw-file downloads, or unscanned installers are used."
|
|
69
|
+
Targets:
|
|
70
|
+
- "claude, opencode, cursor, windsurf, cline. External auto-install supports OpenCode and Claude Code only."
|
|
71
|
+
|
|
72
|
+
Features:
|
|
73
|
+
|
|
74
|
+
Init:
|
|
75
|
+
Description: >
|
|
76
|
+
One non-interactive command performs the whole install in order: guide,
|
|
77
|
+
OpenCode config, library, then every pinned external skill.
|
|
78
|
+
Order:
|
|
79
|
+
- "writeGuide writes junamis-skills-guide.md and .junamis/junamis-skills.json once."
|
|
80
|
+
- "writeOpencodeConfig writes opencode.json only when missing, or with --force; no prompt."
|
|
81
|
+
- "planLibraryInstall/applyLibraryInstall copy skills and shared docs, write canonical agents, and link them into the target agents directory."
|
|
82
|
+
- "installExternal installs every lock entry through the pinned scanner."
|
|
83
|
+
DryRun: "init --dry-run reports all four steps and writes nothing, with no network."
|
|
84
|
+
|
|
85
|
+
Status:
|
|
86
|
+
Description: >
|
|
87
|
+
Reports guide and marker state, per-target internal/external skill counts,
|
|
88
|
+
canonical agents and their link state, legacy leftovers (informational),
|
|
89
|
+
library manifest validity, opencode.json validity, external coverage
|
|
90
|
+
(every lock skill present under ~/.agents/skills), and the SECURITY.md
|
|
91
|
+
scan record and last external scan month.
|
|
92
|
+
Exit: "1 when a required piece is missing for the selected scope; 0 otherwise. Legacy leftovers never fail status."
|
|
93
|
+
|
|
94
|
+
Persistence:
|
|
95
|
+
Description: >
|
|
96
|
+
Journal-first execution state under <project>/.orchestrator/. Every session
|
|
97
|
+
boots before route, rehydrates the cursor, checks the lease and
|
|
98
|
+
fingerprints, reconciles in-flight work, and writes resume-report.md and
|
|
99
|
+
STATE.md.
|
|
100
|
+
Commands: "boot, plan set, plan show, start, end, resolve, status, checkpoint, lease acquire|heartbeat|release|status, finish"
|
|
101
|
+
Journal: "journal.ndjson is append-only with a hash chain; state.json, plan.json, and tasks/<task_id>/task.json are derived snapshots."
|
|
102
|
+
Lease: "Single-writer lease with a 60s base TTL; start raises it to 900s. A live lease halts a second session; a stale lease is taken over."
|
|
103
|
+
Drift: "skills-lock.json, library override, and design registry fingerprints gate boot, plan set, and start; a mismatch is BLOCKED_DRIFT with exit 3."
|
|
104
|
+
Reports: "resume-report.md is regenerated on every boot; STATE.md is a generated view regenerated on boot and checkpoint and never read as input."
|
|
105
|
+
Reconcile: "B7.5 runs the MVP reconcile pass and writes work-queue.json plus reconcile-report.md before B8 hands the queue to route."
|
|
106
|
+
CrashSafety: "Interrupted idempotent tasks retry; interrupted non-idempotent tasks escalate to needs_review."
|
|
107
|
+
Tests: "T1 crash, T2 replay, T3 manifest drift, T4 override drift, T5 lease safety, T6 escalation, T7 torn-write recovery, and SIM-T1/SIM-T2 end-to-end simulation of the built CLIs from design bootstrap to no_work; D-T1 to D-T8 cover the design registry contract."
|
|
108
|
+
|
|
109
|
+
DesignRegistry:
|
|
110
|
+
Description: >
|
|
111
|
+
A durable design surface registry under <project>/docs/design/ that the
|
|
112
|
+
orchestrator fingerprints, loads by code path before dispatch, and skills
|
|
113
|
+
update only through design deltas.
|
|
114
|
+
Commands: "junamis-design-registry validate, load --surface|--code-path, apply, index, drift, bootstrap, fingerprint"
|
|
115
|
+
Bootstrap: "Always writes the project-wide map docs/design/other/project.md, plus one draft overview per project, or per app/package in a monorepo; copies the package schema, creates _registry.json with bootstrap_complete false, regenerates INDEX.md, and never promotes a draft."
|
|
116
|
+
Schemas: "web, api, data, infra, cli, and other; common Intent, Current state, Known gaps, and Change log sections plus kind sections."
|
|
117
|
+
Checksum: "sha256 over the canonicalized body in fixed section order; frontmatter excluded."
|
|
118
|
+
Deltas: "replace, append, prepend, remove_line with a base_checksum guard, version bump, change log, atomic write, and design_update or design_delta_rejected journal event."
|
|
119
|
+
Drift: "CODE_DRIFT, DEPENDENCY_DRIFT, and COVERAGE_GAP; coverage failure is gated by docs/design/_registry.json bootstrap_complete."
|
|
120
|
+
Tests: "D-T1 schema, D-T2 INDEX determinism, D-T3 delta idempotency, D-T4 checksum guard, D-T5 code drift, D-T6 coverage, D-T7 deprecated guard, D-T8 resume drift; project/monorepo bootstrap and load --code-path tests."
|
|
121
|
+
PackageRegistry: "This repository's own registry holds 4 surfaces: cli/overview (the single-project bootstrap overview, detected as cli from package.json bin), other/project (the project-wide map), plus the canonical web/homepage and api/get-user examples; D-T1 asserts those canonical surfaces."
|
|
122
|
+
|
|
123
|
+
Reconcile:
|
|
124
|
+
Description: >
|
|
125
|
+
A deterministic work queue that turns durable state and the design
|
|
126
|
+
registry into the next dispatchable candidate. It reads state, journal,
|
|
127
|
+
plan, design, and the detector manifest; it never executes a skill.
|
|
128
|
+
Commands: "junamis-reconcile pass --trigger <name>"
|
|
129
|
+
Detectors: "plan_pending, code_drift, failed_step, coverage_gap, dependency_drift, needs_review, stale_surface, and shadow_conflict; the extended detectors are present and disabled by default."
|
|
130
|
+
Scoring: "Full severity base plus reason weight with plan_position_frac for plan_pending; p0..p3 buckets; unknown reasons use weight 100 and journal unknown_reason."
|
|
131
|
+
Queue: "work-queue.json is derived and deterministic for one input snapshot; reconcile-report.md is its human companion; queue_stale reports a changed input fingerprint."
|
|
132
|
+
Escalation: "Blocked heads journal queue_blocked; shadowed heads journal escalation shadow_conflict; empty all-done queues journal run_complete; stalled queues keep status no_work with a stalled flag and blocking set."
|
|
133
|
+
Overrides: "Journal priority_override events apply after scoring; an override without a rationale is journaled priority_override_rejected."
|
|
134
|
+
Tick: "A periodic tick runs after N step_end events (default 10, from detectors.yaml tick_every) and records tick on reconcile_pass."
|
|
135
|
+
Tests: "R-T1 through R-T12: determinism, stable ids, scoring, drift guard, shadow safety, dependency closure, dedup, triggers, empty queue, stalled queue, crash recovery, and override audit."
|
|
136
|
+
|
|
137
|
+
Library:
|
|
138
|
+
OwnedSkills: 20
|
|
139
|
+
OwnedAgents: 9
|
|
140
|
+
SharedDocs: [HANDOFF.md, SAFETY.md, EXTERNAL.md, SECURITY.md, RESUME.md, RECONCILE.md]
|
|
141
|
+
CanonicalAgents: "Written once to <configRoot>/agents; linked into the target agents directory."
|
|
142
|
+
LinkRules: "A correct link is unchanged; a missing link is created; an identical regular file is adopted; a differing file or wrong link is a conflict unless --force; a failed symlink falls back to a copy with a warning."
|
|
143
|
+
ConflictRule: "Never overwrite a file the user edited unless --force."
|
|
144
|
+
Manifest: "Records every written file and its SHA-256; stale unmodified files are removed."
|
|
145
|
+
|
|
146
|
+
External:
|
|
147
|
+
Count: 24
|
|
148
|
+
ExistingSkills: "Skipped, not overwritten and not counted as failures."
|
|
149
|
+
Return: "{ groups, installed, skipped, failed }"
|
|
150
|
+
Verification: "After a successful group, installed counts only skills whose <name>/SKILL.md exists on disk; a missing skill is a logged failure."
|
|
151
|
+
Scan: "Always runs with --skip-scan because -y cannot bypass the high/critical prompt; SECURITY.md plus library/SAFETY.md is the vetting record."
|
|
152
|
+
FailureRule: "init exits 1 only when failed > 0; a declined or missing install is a failure and is not retried."
|
|
153
|
+
|
|
154
|
+
Security:
|
|
155
|
+
Record: "SECURITY.md lists kind, source, license, scan status, and last review month for all 44 skill rows (20 internal + 24 external; document has one row of each kind)."
|
|
156
|
+
Scanner: "skillsio 1.1.3 (Trust Hub, Socket, Snyk)"
|
|
157
|
+
Gate: "Install-time scanning is skipped by design (--skip-scan); SECURITY.md and library/SAFETY.md define the gate, and flagged findings are reviewed there."
|
|
158
|
+
PinCheck: "pnpm run check:pins fetches each locked source/ref and compares the actual tree SHA; network check, not in CI/release."
|
|
159
|
+
|
|
160
|
+
Publishing:
|
|
161
|
+
Description: >
|
|
162
|
+
npmjs is the primary public registry for @devenius/junamis-skills;
|
|
163
|
+
GitHub Packages is the mirror. The package is scoped, publishConfig sets
|
|
164
|
+
access public and no registry, and CI publishes through a trusted
|
|
165
|
+
publisher.
|
|
166
|
+
Workflow: ".github/workflows/publish.yml (name Publish) runs publish-github (GITHUB_TOKEN, packages write) then publish-npm (needs publish-github, id-token write, environment npm-publish, OIDC, npm stage publish to registry.npmjs.org)."
|
|
167
|
+
Checklist: "pnpm publish:npm runs scripts/publish-npm.mjs over src/scripts/publish-npm.ts; it validates the name, publishConfig.access, and the absence of publishConfig.registry, then prints the exact npm stage publish command and never runs it."
|
|
168
|
+
Command: "npm stage publish --access public --tag <tag> --registry=https://registry.npmjs.org; the user approves the staged version on npmjs.com with 2FA."
|
|
169
|
+
Release: "The first usable npm release is 1.1.0: package.json is 1.1.0, CHANGELOG.md has ## [1.1.0] - 2026-11-13, and docs/releases/1.1.0.md is the release note. Tag v1.1.0 to run publish.yml (publish-github mirrors to GitHub Packages, publish-npm stages 1.1.0 to npmjs with OIDC and the npm-publish environment); the user approves the staged 1.1.0 on npmjs.com with 2FA, then deprecates 1.0.0-placeholder.0."
|
|
170
|
+
Gate: "The agent never runs npm publish, npm stage publish, npm deprecate, npm unpublish, npm dist-tag, npm owner, or npm access; library/SAFETY.md gates each one on a single-use approval."
|
|
171
|
+
|
|
172
|
+
Setup:
|
|
173
|
+
Install:
|
|
174
|
+
- "pnpm install"
|
|
175
|
+
- "pnpm build"
|
|
176
|
+
- "node bin/junamis-skills.js help"
|
|
177
|
+
Prerequisites:
|
|
178
|
+
- "Node.js 26 or newer"
|
|
179
|
+
- "pnpm 12.15.0 for development"
|
|
180
|
+
- "git CLI for external checkouts"
|
|
181
|
+
- "skillsio is never installed globally; it runs through pnpm dlx at the pinned version"
|
|
182
|
+
Run:
|
|
183
|
+
- "npx github:devenius/junamis-skills init"
|
|
184
|
+
- "npx @devenius/junamis-skills init"
|
|
185
|
+
Validate:
|
|
186
|
+
- "pnpm test"
|
|
187
|
+
- "pnpm lint"
|
|
188
|
+
- "pnpm run check:config"
|
|
189
|
+
- "pnpm run check:skills-lock"
|
|
190
|
+
- "pnpm run check:security"
|
|
191
|
+
- "pnpm run check:pins"
|
|
192
|
+
- "pnpm run check:pack"
|
|
193
|
+
- "pnpm run check:yaml"
|
|
194
|
+
Scripts:
|
|
195
|
+
- "test: node --test test/*.test.js"
|
|
196
|
+
- "check:config: validates the shipped opencode.json invariants."
|
|
197
|
+
- "check:skills-lock: validates every lock pin and license."
|
|
198
|
+
- "check:security: requires every internal and external skill in SECURITY.md plus a Last external scan line."
|
|
199
|
+
- "check:pins: fetches every locked source/ref and compares the actual folder tree SHA with skills-lock.json (network; not in CI)."
|
|
200
|
+
- "check:pack: asserts the published file set and no nested upstream clones."
|
|
201
|
+
- "release:check: runs the full gate, including tests and SECURITY.md coverage."
|
|
202
|
+
|
|
203
|
+
Functionality:
|
|
204
|
+
|
|
205
|
+
InitFlow:
|
|
206
|
+
- "Resolve scope: global (default) or project; reject any agent other than opencode or claude."
|
|
207
|
+
- "Guide: write once, keep a user-authored file, rewrite only with --force."
|
|
208
|
+
- "Config: for OpenCode only; identical file is unchanged, a different file is left unchanged with a --force hint, --force replaces it."
|
|
209
|
+
- "Library: plan, then apply; conflicts are listed and set exit 1; --dry-run never writes."
|
|
210
|
+
- "External: install every source group through the scanner; existing skill directories are skipped."
|
|
211
|
+
- "Summary: prints guide, config, library, external counts, and the exit state."
|
|
212
|
+
|
|
213
|
+
StatusChecks:
|
|
214
|
+
- "Guide and marker are required when the project scope is selected."
|
|
215
|
+
- "At least one target must have a valid library manifest per selected scope."
|
|
216
|
+
- "An existing opencode.json must use V2 permissions, policies, mcp.servers, and plugins; a malformed or V1-only file fails."
|
|
217
|
+
- "External coverage is required when the global scope is selected."
|
|
218
|
+
- "SECURITY.md and its Last external scan line are always required."
|
|
219
|
+
|
|
220
|
+
ExternalInstall:
|
|
221
|
+
- "Group lock entries by source and commit; one scanner call per group."
|
|
222
|
+
- "Partition existing skills before checkout and again after checkout; both are skipped."
|
|
223
|
+
- "Verify every skill tree SHA (in-tree symlinks allowed, escapes rejected), then verify the scanner integrity once per run."
|
|
224
|
+
- "Run with --skip-scan so the high/critical prompt cannot silently skip skills; install-time scanning is skipped by design."
|
|
225
|
+
- "After a successful group, count only skills whose <name>/SKILL.md exists; log and fail a missing one."
|
|
226
|
+
- "Run with a sanitized environment, neutral cwd, inherited stdin, no shell, and a timeout that kills the process group."
|
|
227
|
+
- "Convert scanner cancellation output to exit 125 and never retry it."
|
|
228
|
+
|
|
229
|
+
LibraryInstall:
|
|
230
|
+
- "Plan every owned skill file, canonical agent definition, shared doc, and the agent links."
|
|
231
|
+
- "Reject symlinked managed roots and destinations before any write or delete; link destinations check their parent only so a wrong target is a conflict, not an escape."
|
|
232
|
+
- "Write atomically, back up changes, apply links (adopt identical files, relink with --force), and roll back on failure."
|
|
233
|
+
- "Fall back to copying a canonical agent when symlink creation fails with EPERM or EACCES, and report a warning."
|
|
234
|
+
|
|
235
|
+
CLIOptions:
|
|
236
|
+
- "init [--agent opencode|claude] [--scope global|project] [--dir <path>] [--force] [--dry-run] : install guide, config, library, and every pinned external skill"
|
|
237
|
+
- "status [--dir <path>] [--scope global|project|all] : report install and security state; exits 1 when a required piece is missing"
|
|
238
|
+
- "help, --help, -h : usage"
|
|
239
|
+
- "--force : overwrite the guide, opencode.json, or edited library files"
|
|
240
|
+
- "--dry-run : print the plan; no writes and no network"
|
|
241
|
+
- "--dir : project directory (default: current directory)"
|
|
242
|
+
- "--scope : global or project for init; global, project, or all for status"
|
|
243
|
+
- "removed commands : install-library, install-external, sync, doctor, init-config; each fails with a pointer to init/status"
|
|
244
|
+
|
|
245
|
+
InstalledPaths:
|
|
246
|
+
"~/.config/junamis/skills/skills": "internal (library) skills, OpenCode"
|
|
247
|
+
"~/.config/junamis/skills/agents": "canonical agent definitions"
|
|
248
|
+
"~/.config/junamis/skills/*.md": "shared docs: HANDOFF.md, SAFETY.md, EXTERNAL.md, SECURITY.md, RESUME.md, RECONCILE.md"
|
|
249
|
+
"~/.config/junamis/skills/skills-lock.json": "installed external-skill manifest used by the state engine fingerprint"
|
|
250
|
+
"~/.config/junamis/skills/installed/library-<agent>.json": "library install manifest"
|
|
251
|
+
"~/.config/opencode/agents": "OpenCode agent links to the canonical files"
|
|
252
|
+
"~/.agents/skills": "external skills, OpenCode"
|
|
253
|
+
"~/.claude/skills": "internal and external skills, Claude Code"
|
|
254
|
+
"~/.claude/agents": "Claude Code agent links"
|
|
255
|
+
"<project>/.config/junamis/skills/...": "project-scope internal skills, canonical agents, docs, and manifest"
|
|
256
|
+
"<project>/.agents/skills": "project-scope external skills, OpenCode"
|
|
257
|
+
"<project>/.opencode/agents": "project-scope OpenCode agent links"
|
|
258
|
+
"<project>/.orchestrator/": "execution state root: journal, snapshots, checkpoints, leases, resume report, and STATE.md (gitignored)"
|
|
259
|
+
"<project>/.junamis/junamis-skills.json": "guide marker"
|
|
260
|
+
"<project>/junamis-skills-guide.md": "setup guide (project file, not a skill)"
|
|
261
|
+
|
|
262
|
+
Utilities:
|
|
263
|
+
- "bin/junamis-skills.js : executable entry point, imports dist/cli.js"
|
|
264
|
+
- "src/cli.ts : parseArgs, runInit, writeOpencodeConfig, status, run"
|
|
265
|
+
- "src/external.ts : lock grouping, scanner command, integrity check, sandboxed runner, installExternal"
|
|
266
|
+
- "src/pinned-source.ts : pinned Git checkout and skill tree SHA verification"
|
|
267
|
+
- "src/library-install.ts : plan/apply, manifest validation, containment, canonical agents, links, rollback"
|
|
268
|
+
- "src/paths.ts : single source of truth for the nested config root and install paths"
|
|
269
|
+
- "src/guide.ts : guide rendering, the shared PACKAGE_ROOT, and the atomic writer"
|
|
270
|
+
- "src/orchestrator/ : journal-first resume engine (journal, state, plan, lease, drift, compaction, report, boot, handoff, commands, CLI)"
|
|
271
|
+
- "src/design/ : design registry schema, delta applier, index generator, drift detectors, bootstrap, and fingerprint"
|
|
272
|
+
- "src/reconcile/ : MVP work queue detectors, scoring, manifest, and pass runner"
|
|
273
|
+
- "dist/ : build output (JavaScript, declarations, source maps); never committed, always built before a check runs"
|
|
274
|
+
- "scripts/orchestrator-state.mjs : thin launcher over dist/orchestrator/cli.js for the junamis-orchestrator bin"
|
|
275
|
+
- "scripts/design-registry.mjs : thin launcher over dist/design/cli.js for the design registry"
|
|
276
|
+
- "scripts/reconcile.mjs : thin launcher over dist/reconcile/cli.js for the junamis-reconcile bin"
|
|
277
|
+
- "src/targets/ : one adapter per agent"
|
|
278
|
+
- "scripts/check-*.mjs : config, lock, security, pack, and YAML checks, each a launcher over dist/scripts/*.js"
|
|
279
|
+
- "scripts/release-check.mjs : release gate, a launcher over dist/scripts/release-check.js"
|
|
280
|
+
- "src/color.ts : dependency-free ANSI palette, stripAnsi, and colorsEnabled (NO_COLOR, TERM=dumb, TTY)"
|
|
281
|
+
- "scripts/publish-npm.mjs : thin launcher over dist/scripts/publish-npm.js for the read-only publish checklist (pnpm publish:npm)"
|
|
282
|
+
- "test/orchestrator-simulation.test.js : end-to-end simulation of design bootstrap, boot, plan set, reconcile, start, end, and no_work"
|
|
283
|
+
|
|
284
|
+
Decisions:
|
|
285
|
+
- "0001: External skills are auto-installed by init and are never vendored."
|
|
286
|
+
- "0002: The scanner is pinned and integrity-checked; -y is required for non-interactive init."
|
|
287
|
+
- "0003: A declined security scan is a failure, not a prompt to skip."
|
|
288
|
+
- "0004: Existing external skills are skipped, not failures."
|
|
289
|
+
- "0005: SECURITY.md is the scan record; SAFETY.md keeps the approval gate."
|
|
290
|
+
- "0006: Only init, status, and help remain as commands."
|
|
291
|
+
- "0007: OpenCode splits internal skills, shared docs, and external skills; other targets share one skills directory."
|
|
292
|
+
- "0008: Project scope mirrors the internal side and keeps external skills at the target's project paths."
|
|
293
|
+
- "0009: Library files edited by the user are conflicts unless --force."
|
|
294
|
+
- "0010: Install-time scanning is skipped with --skip-scan; SECURITY.md plus SAFETY.md is the vetting record, and every install is verified on disk."
|
|
295
|
+
- "0011: An in-tree symlink inside a verified skill folder is allowed; absolute and escaping symlinks are rejected."
|
|
296
|
+
- "0012: check:pins is a manual network check, not part of CI or release."
|
|
297
|
+
- "0013: The config root is ~/.config/junamis/skills; skills, canonical agents, docs, and the manifest are nested under it."
|
|
298
|
+
- "0014: Agent definitions are written once to the canonical agents directory and symlinked into each target; a failed symlink falls back to a copy with a warning."
|
|
299
|
+
- "0015: No automatic migration; status reports legacy flat files and never deletes them."
|
|
300
|
+
- "0016: The orchestrator is resumable through a journal-first state engine under src/orchestrator/; boot runs before route, skills declare idempotent, and the state root is <project>/.orchestrator/ with no new runtime dependency."
|
|
301
|
+
- "0017: Every writing task runs in <project-root>/.worktrees/<task-slug> on task/<task-slug>, that worktree is the project root for setup, state, design, and routing, the limit is 8 worktrees pruned only when merged and clean, and opencode.json allows /tmp, /var/tmp, and .worktrees while keeping main, force, and --no-verify pushes denied. Superseded by 0019 for the branch-per-prompt and per-subtask worktree model; the 8-worktree limit and path allows still apply."
|
|
302
|
+
- "0018: The orchestrator's authority ends at gh pr create; it never merges, uses --admin, pushes main, force-pushes, tags, or rebases/resets main, and the user reviews and merges. Every approval is single-use: one command in one prompt, consumed when that command runs or fails, never standing, never reused. gh pr merge, main pushes, HEAD:main, and --force-with-lease are hard-denied in opencode.json and mirrored in HARD_DENY_POLICIES."
|
|
303
|
+
- "0019: The orchestrator checks git branch --show-current at the start of every prompt and creates task/<task-slug> from the latest default branch when on main or a detached HEAD. It works and commits in the project checkout on that branch, plans the delegation with one owner per file, gives each delegated task its own .worktrees/<task-slug>-<subtask> worktree and allowed-file list, merges each sub-branch back with git merge --no-ff, removes the worktree, and opens one pull request per approved batch. Sub-agents commit only their allocated files on their sub-branch, never merge, and never create a pull request. git switch/checkout main and git branch -d/-D main are hard-denied."
|
|
304
|
+
- "0020: npmjs is the primary public registry for @devenius/junamis-skills and GitHub Packages is the mirror. The package name is already scoped, publishConfig sets access public and no registry, CI stages to npmjs through a GitHub Actions trusted publisher (publish.yml, environment npm-publish, OIDC with id-token write, npm stage publish) and a maintainer approves with 2FA. The agent never runs a registry mutation; pnpm publish:npm is a read-only checklist that prints the exact command."
|
|
305
|
+
|
|
306
|
+
Limitations:
|
|
307
|
+
- "No third-party skill content is shipped; init needs network access to fetch and scan external skills."
|
|
308
|
+
- "Scanned external auto-install supports only OpenCode and Claude Code; other targets receive the library only."
|
|
309
|
+
- "Scanner trust is pinned to skillsio@1.1.3 and its recorded scan results; new upstream content needs a fresh scan."
|
|
310
|
+
- "Auto-install skips scanning (--skip-scan) because -y cannot bypass the high/critical prompt; on-disk verification is the runtime backstop."
|
|
311
|
+
- "Global installs are shared: a second agent with the same skills directory can see files from another target."
|
|
312
|
+
- "The legacy .agents/, .opencode/ agent layer and nested upstream clones (skills/, nestjs-agent-skills/) are not part of the package."
|
|
313
|
+
- "Execution state is host-local: resume does not work across machines, and the lease does not coordinate across hosts."
|
|
314
|
+
- "The journal grows until compaction; checkpoint truncation is the one place an append-only journal is rewritten."
|
|
315
|
+
- "A crash in a non-idempotent step waits for a human review by design; the engine never guesses."
|
|
316
|
+
- "The handoff parser is a strict subset because a runtime YAML dependency is not allowed."
|
|
317
|
+
|
|
318
|
+
Validation:
|
|
319
|
+
- "pnpm test (292 tests)"
|
|
320
|
+
- "pnpm lint"
|
|
321
|
+
- "pnpm audit"
|
|
322
|
+
- "pnpm run check:config"
|
|
323
|
+
- "pnpm run check:skills-lock"
|
|
324
|
+
- "pnpm run check:security"
|
|
325
|
+
- "pnpm run check:pins"
|
|
326
|
+
- "pnpm run check:pack"
|
|
327
|
+
- "pnpm run check:yaml"
|
|
328
|
+
- "pnpm run release:check"
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
# External skills referenced by the library
|
|
2
|
+
|
|
3
|
+
These skills are installed from `skills-lock.json` into the global skills directory (`~/.agents/skills/` for OpenCode, as `skillsio -g` writes it). Each lock entry pins a Git commit and the skill folder's Git tree SHA; the installer verifies both before scanning and installation. They are not owned by this project. The library refers to them by name only. Each reference must resolve to a lock entry, which `test/library.test.js` checks.
|
|
4
|
+
|
|
5
|
+
The orchestrator runs `route-external` before dispatching any external skill, so the run ends with a HANDOFF block. The adapter lives in `.junamis/adapters/<skill>.md`; upstream content is never edited.
|
|
6
|
+
|
|
7
|
+
| Name | Lock source | License | Referenced by | Used for |
|
|
8
|
+
|---|---|---|---|---|
|
|
9
|
+
| debug | JavaScript-Mastery-Pro/skills | MIT | route, orchestrator | bug path: reproduce, root cause, minimal fix |
|
|
10
|
+
| architect | JavaScript-Mastery-Pro/skills | MIT | route, orchestrator | feature path: decision and build spec |
|
|
11
|
+
| develop | JavaScript-Mastery-Pro/skills | MIT | route, orchestrator | feature path: build from spec |
|
|
12
|
+
| test | JavaScript-Mastery-Pro/skills | MIT | route, orchestrator | tests written after a change |
|
|
13
|
+
| tdd | mattpocock/skills | MIT | route, orchestrator | build a behavior test-first (red-green) |
|
|
14
|
+
| check | JavaScript-Mastery-Pro/skills | MIT | release-prep | `check review` on the release diff before tagging |
|
|
15
|
+
|
|
16
|
+
Routing between `test` and `tdd` is in `library/skills/route/SKILL.md`. Both are installed; the route decides which runs.
|
|
17
|
+
|
|
18
|
+
External skills assigned to library agents (by reference, not ownership):
|
|
19
|
+
|
|
20
|
+
- `scope`, `document` → orchestrator (workflow planning and release documentation)
|
|
21
|
+
- `find-skills` → maintainer agent (skill discovery and installation)
|
|
22
|
+
- `mcp-builder`, `skill-creator` → maintainer agent (MCP servers, skill authoring)
|
|
23
|
+
- `shadcn`, `shadcn-component-discovery`, `shadcn-component-review` → frontend agent (UI components)
|
|
24
|
+
- `frontend-design`, `theme-factory` → frontend agent (design guidance)
|
|
25
|
+
- `webapp-testing` → frontend agent (browser-based UI testing)
|
|
26
|
+
- `nestjs-best-practices` → nestjs agent (deep NestJS patterns)
|
|
27
|
+
- `agent-browser` → reviewer agent (browser-based verification)
|
|
28
|
+
- `driftlock` → context-keeper agent (documentation governance)
|
|
29
|
+
- `agent-rules` → context-keeper agent (AGENTS.md generation and maintenance)
|
|
30
|
+
- `grill-me`, `grill-with-docs` → architect agent (stress-testing plans and designs)
|
|
31
|
+
- `doc-coauthoring` → orchestrator (structured documentation workflow)
|
|
32
|
+
|
|
33
|
+
Their licenses and safety status are in `skills-lock.json` and `~/.config/junamis/skills/SAFETY.md`.
|
|
34
|
+
|
|
35
|
+
If an external name is not installed, the orchestrator stops and tells the user which one is missing. It does not perform that skill's work itself.
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
This file defines the step output block. Execution state and resume behavior are in RESUME.md.
|
|
2
|
+
|
|
3
|
+
# Handoff contract
|
|
4
|
+
|
|
5
|
+
Every skill and agent in `library/` ends its work with exactly one YAML block. The orchestrator reads only this block to decide what happens next. Nothing else is trusted for control flow.
|
|
6
|
+
|
|
7
|
+
```yaml
|
|
8
|
+
agent: <skill or agent name>
|
|
9
|
+
job: <one line: what was asked>
|
|
10
|
+
status: complete | blocked | needs-decision | failed
|
|
11
|
+
artifacts:
|
|
12
|
+
- path: <repo-relative path>
|
|
13
|
+
kind: created | updated | read-only
|
|
14
|
+
findings: # at most 5, worst first
|
|
15
|
+
- id: F1
|
|
16
|
+
severity: critical | high | medium | low
|
|
17
|
+
summary: <one line>
|
|
18
|
+
evidence: <file:line, or command and its output>
|
|
19
|
+
decisions_owed: # questions only the user can answer
|
|
20
|
+
- <question>
|
|
21
|
+
next: <one skill name, one agent name, "user", or "none">
|
|
22
|
+
```
|
|
23
|
+
|
|
24
|
+
## Schema version
|
|
25
|
+
|
|
26
|
+
The handoff schema version is 1. The fields in the block above are the whole schema. A field change requires a version bump and a matching change in the state engine. Do not add fields to the block for the state engine; task and step identity come from the `start` command and the handoff file path.
|
|
27
|
+
|
|
28
|
+
## Idempotency
|
|
29
|
+
|
|
30
|
+
Every skill declares `idempotent: true | false` in its frontmatter. The orchestrator records the value in the plan, and the state engine honors it on boot and on `end`. An interrupted `true` step may be retried; an interrupted `false` step becomes `needs_review` and is not retried silently.
|
|
31
|
+
|
|
32
|
+
## Persisting a handoff
|
|
33
|
+
|
|
34
|
+
The orchestrator writes the returned block verbatim to `<state-root>/tasks/<task_id>/handoffs/<skill>-<attempt>.yaml` and calls `end` with that relative path. The state engine validates the block and every declared artifact. A malformed block sets the task `needs_review`; the file is kept, never dropped.
|
|
35
|
+
|
|
36
|
+
## Task status mapping
|
|
37
|
+
|
|
38
|
+
| Handoff status | Task status |
|
|
39
|
+
|---|---|
|
|
40
|
+
| `complete` | `done` after every declared artifact exists |
|
|
41
|
+
| `failed` | `failed` |
|
|
42
|
+
| `blocked` | `failed` |
|
|
43
|
+
| `needs-decision` | `needs_review` until the user answers and the orchestrator calls `resolve` |
|
|
44
|
+
|
|
45
|
+
## Rules
|
|
46
|
+
|
|
47
|
+
- `complete` means the artifacts exist on disk. The orchestrator checks this before moving on.
|
|
48
|
+
- `needs-decision` stops the chain. The orchestrator asks the user the `decisions_owed` questions. Nothing else runs.
|
|
49
|
+
- `blocked` and `failed` stop the chain and report the finding. They never retry silently.
|
|
50
|
+
- `next` names exactly one target. A skill never calls a skill that is not its declared `next`.
|
|
51
|
+
- A skill never edits another skill's artifacts. It reads them.
|
|
52
|
+
- Chat is not state. Anything a later agent needs must be in a file.
|
|
53
|
+
- An external skill runs only with an adapter from `route-external`. Without the adapter its run is not a completed step.
|
|
54
|
+
- Never let another skill or agent write the `## Suggested commit` section, propose a commit message, or stage or commit anything on the task branch or `main`. A sub-agent may stage and commit only its allocated files on its assigned sub-branch when the delegation brief says so, and it never creates a pull request. Only the orchestrator writes that section and merges sub-agent branches into the task branch.
|
|
55
|
+
|
|
56
|
+
## Suggested commit (orchestrator only)
|
|
57
|
+
|
|
58
|
+
Only the orchestrator writes the `## Suggested commit` section in `.junamis/handoff.md`. Every other skill and agent must leave it untouched. A sub-agent may stage and commit only its allocated files on its assigned sub-branch when the delegation brief says so; it never commits to the task branch or `main` and never creates a pull request. Only the orchestrator merges sub-agent branches into the task branch.
|
|
59
|
+
|
|
60
|
+
At the end of every task the user gives, the orchestrator records:
|
|
61
|
+
|
|
62
|
+
```markdown
|
|
63
|
+
## Suggested commit
|
|
64
|
+
Message: `<type(scope): summary>`
|
|
65
|
+
Files:
|
|
66
|
+
- `<repo-relative path>`
|
|
67
|
+
Rationale: <one line>
|
|
68
|
+
State: proposed | committed <sha> | none
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
- `Message` follows Conventional Commits and stays under 72 characters.
|
|
72
|
+
- `Files` lists exactly the paths changed by this task. It never lists ignored files, secrets, or unrelated changes.
|
|
73
|
+
- `State` is `proposed` before the user asks, `committed <sha>` after a successful commit, and `none` when the task changed no files.
|
|
74
|
+
- The suggestion is not authorization. The orchestrator commits only after the user asks.
|
|
75
|
+
- When the user says "commit" without a message or scope, the orchestrator uses the suggestion exactly, after refreshing it if the working tree changed. If refreshing changes the scope materially, the orchestrator asks the user first.
|
|
76
|
+
- A specialist that believes a commit is needed outside its allocated files on its assigned sub-branch reports it in `findings` or returns `next: orchestrator`. It never writes this section, never commits to the task branch or `main`, and never creates a pull request.
|
|
77
|
+
|
|
78
|
+
## Artifact locations
|
|
79
|
+
|
|
80
|
+
| Artifact | Path | Owner |
|
|
81
|
+
|---|---|---|
|
|
82
|
+
| Session state | `.junamis/handoff.md` | `handoff` |
|
|
83
|
+
| Suggested commit | `.junamis/handoff.md` (`## Suggested commit`) | `orchestrator` |
|
|
84
|
+
| Decisions | `docs/decisions/NNNN-slug.md` | `decision-record` |
|
|
85
|
+
| Environment report | `docs/env-report.md` | `env-doctor` |
|
|
86
|
+
| Release notes | `docs/releases/<version>.md` | `release-prep` |
|
|
87
|
+
| Rollback plan | `docs/releases/rollback-<version>.md` | `rollback` |
|
|
88
|
+
| Incident record | `docs/incidents/<YYYY-MM-DD>-<slug>.md` | `incident-response` |
|
|
89
|
+
| Review findings | `docs/reviews/<kind>-<YYYY-MM-DD>.md` | `security-audit`, `perf-budget` |
|
|
90
|
+
| Perf budgets | `docs/perf/budgets.md` | `perf-budget` (created on first run) |
|
|
91
|
+
| External skill adapter | `.junamis/adapters/<skill>.md` | `route-external` |
|
|
92
|
+
|
|
93
|
+
Execution state lives under `<project>/.orchestrator/` (gitignored) and follows `RESUME.md`.
|