@davidorex/pi-jit-agents 0.14.6 → 0.28.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.
Files changed (96) hide show
  1. package/CHANGELOG.md +49 -0
  2. package/README.md +2 -2
  3. package/dist/agent-spec.d.ts.map +1 -1
  4. package/dist/agent-spec.js +69 -5
  5. package/dist/agent-spec.js.map +1 -1
  6. package/dist/budget-enforcer.d.ts +43 -0
  7. package/dist/budget-enforcer.d.ts.map +1 -0
  8. package/dist/budget-enforcer.js +172 -0
  9. package/dist/budget-enforcer.js.map +1 -0
  10. package/dist/compile.d.ts +39 -0
  11. package/dist/compile.d.ts.map +1 -1
  12. package/dist/compile.js +363 -24
  13. package/dist/compile.js.map +1 -1
  14. package/dist/dispatch-inline.d.ts +25 -0
  15. package/dist/dispatch-inline.d.ts.map +1 -0
  16. package/dist/dispatch-inline.js +41 -0
  17. package/dist/dispatch-inline.js.map +1 -0
  18. package/dist/field-path.d.ts +32 -0
  19. package/dist/field-path.d.ts.map +1 -0
  20. package/dist/field-path.js +48 -0
  21. package/dist/field-path.js.map +1 -0
  22. package/dist/index.d.ts +11 -4
  23. package/dist/index.d.ts.map +1 -1
  24. package/dist/index.js +9 -4
  25. package/dist/index.js.map +1 -1
  26. package/dist/jit-runtime.d.ts +14 -3
  27. package/dist/jit-runtime.d.ts.map +1 -1
  28. package/dist/jit-runtime.js +41 -5
  29. package/dist/jit-runtime.js.map +1 -1
  30. package/dist/markers.d.ts +28 -0
  31. package/dist/markers.d.ts.map +1 -0
  32. package/dist/markers.js +36 -0
  33. package/dist/markers.js.map +1 -0
  34. package/dist/renderer-registry.d.ts +60 -0
  35. package/dist/renderer-registry.d.ts.map +1 -0
  36. package/dist/renderer-registry.js +141 -0
  37. package/dist/renderer-registry.js.map +1 -0
  38. package/dist/template.d.ts +15 -0
  39. package/dist/template.d.ts.map +1 -1
  40. package/dist/template.js +29 -3
  41. package/dist/template.js.map +1 -1
  42. package/dist/trace-redactor.d.ts +1 -1
  43. package/dist/trace-redactor.js +1 -1
  44. package/dist/trace-writer.js +2 -2
  45. package/dist/types.d.ts +86 -4
  46. package/dist/types.d.ts.map +1 -1
  47. package/package.json +11 -4
  48. package/schemas/agent-trace.schema.json +30 -2
  49. package/templates/analyzers/base-analyzer.md +9 -0
  50. package/templates/analyzers/patterns-task.md +11 -0
  51. package/templates/analyzers/patterns.md +15 -0
  52. package/templates/analyzers/quality-task.md +11 -0
  53. package/templates/analyzers/quality.md +15 -0
  54. package/templates/analyzers/structure-task.md +17 -0
  55. package/templates/analyzers/structure.md +15 -0
  56. package/templates/architecture-designer/task.md +117 -0
  57. package/templates/architecture-inferrer/task.md +61 -0
  58. package/templates/audit-finding-verifier/task.md +59 -0
  59. package/templates/audit-fixer/task.md +67 -0
  60. package/templates/audit-results-router/task.md +37 -0
  61. package/templates/decomposer/task.md +56 -0
  62. package/templates/explorer/system.md +3 -0
  63. package/templates/explorer/task.md +9 -0
  64. package/templates/gap-identifier/task.md +103 -0
  65. package/templates/gap-resolution-assessor/task.md +48 -0
  66. package/templates/handoff-writer/task.md +101 -0
  67. package/templates/investigator/task.md +30 -0
  68. package/templates/items/architecture.md +33 -0
  69. package/templates/items/conformance.md +26 -0
  70. package/templates/items/conventions.md +19 -0
  71. package/templates/items/decisions.md +47 -0
  72. package/templates/items/domain.md +21 -0
  73. package/templates/items/features.md +63 -0
  74. package/templates/items/framework-gaps.md +43 -0
  75. package/templates/items/issues.md +21 -0
  76. package/templates/items/layer-plans.md +50 -0
  77. package/templates/items/project.md +48 -0
  78. package/templates/items/requirements.md +20 -0
  79. package/templates/items/research.md +57 -0
  80. package/templates/items/spec-reviews.md +51 -0
  81. package/templates/items/tasks.md +29 -0
  82. package/templates/phase-author/task.md +82 -0
  83. package/templates/plan-creator/task.md +143 -0
  84. package/templates/plan-decomposer/task.md +46 -0
  85. package/templates/project-definer/task.md +67 -0
  86. package/templates/project-inferrer/task.md +56 -0
  87. package/templates/requirements-gatherer/task.md +90 -0
  88. package/templates/researcher/task.md +26 -0
  89. package/templates/shared/macros.md +169 -0
  90. package/templates/shared/render-helpers.md +106 -0
  91. package/templates/spec-implementer/task.md +53 -0
  92. package/templates/synthesizer/system.md +3 -0
  93. package/templates/synthesizer/task.md +38 -0
  94. package/templates/task-verifier/task.md +44 -0
  95. package/templates/task-worker/task.md +52 -0
  96. package/templates/verifier/task.md +57 -0
@@ -0,0 +1,52 @@
1
+ ## Task: {{ task.id }}
2
+
3
+ ### Description
4
+ {{ task.description }}
5
+
6
+ {% if task.phase %}
7
+ ### Phase
8
+ {{ task.phase }}
9
+ {% endif %}
10
+
11
+ ### Files
12
+ {% for f in task.files %}
13
+ - `{{ f }}`
14
+ {% endfor %}
15
+
16
+ ### Acceptance Criteria
17
+ {% for criterion in task.acceptance_criteria %}
18
+ - [ ] {{ criterion }}
19
+ {% endfor %}
20
+
21
+ {% if task.depends_on %}
22
+ ### Dependencies (completed)
23
+ {% for dep in task.depends_on %}
24
+ - {{ dep }}
25
+ {% endfor %}
26
+ {% endif %}
27
+
28
+ {% if task.notes %}
29
+ ### Notes
30
+ {{ task.notes }}
31
+ {% endif %}
32
+
33
+ {% if context %}
34
+ ### Context
35
+ {{ context }}
36
+ {% endif %}
37
+
38
+ ## Instructions
39
+
40
+ Implement this task. Follow these steps:
41
+
42
+ 1. **Read the target files** listed above to understand the current state
43
+ 2. **Implement changes** that satisfy each acceptance criterion
44
+ 3. **Stay within scope** — only modify the files listed, unless a new file is strictly necessary
45
+ 4. **Run tests** after implementation to verify nothing is broken
46
+ 5. **Validate each criterion** — confirm every acceptance criterion is addressed
47
+
48
+ Produce a JSON result conforming to this schema:
49
+
50
+ ```json
51
+ {{ output_schema }}
52
+ ```
@@ -0,0 +1,57 @@
1
+ You are verifying the output of a prior step against declared success criteria.
2
+
3
+ ## Success Criteria
4
+
5
+ {% for criterion in criteria %}
6
+ - {{ criterion }}
7
+ {% endfor %}
8
+
9
+ ## Step Output to Verify
10
+
11
+ ```json
12
+ {{ step_output | dump(2) }}
13
+ ```
14
+
15
+ {% if files_to_check %}
16
+ ## Files to Check
17
+
18
+ {% for f in files_to_check %}
19
+ - `{{ f }}`
20
+ {% endfor %}
21
+ {% endif %}
22
+
23
+ ## Instructions
24
+
25
+ For each criterion, choose the appropriate verification method and execute it:
26
+
27
+ 1. **command** — Run a shell command (test suite, build, lint) and report exit code + output as evidence
28
+ 2. **grep** — Search for specific patterns in files and report matches as evidence
29
+ 3. **inspect** — Read files and assess their content (use your judgment)
30
+ 4. **human** — Flag items that require human eyes and explain why automation cannot verify them
31
+
32
+ ### Process
33
+
34
+ 1. Evaluate each success criterion using the most appropriate verify method
35
+ 2. For `command` criteria: actually run the command and capture the output
36
+ 3. For `grep` criteria: search the relevant files and report what you find
37
+ 4. For `inspect` criteria: read the files and assess whether they meet the criterion
38
+ 5. For `human` criteria: describe what needs to be checked and why it needs a person
39
+ 6. Build truth claims from your observations, marking each as `verified`, `failed`, or `uncertain`
40
+ 7. Check that all referenced artifacts exist and are substantive (not stubs)
41
+ 8. Compute an overall score as "N/M" where N = passed criteria, M = total criteria
42
+ 9. Set status: `passed` if all criteria pass, `gaps_found` if any fail, `human_needed` if any require human review
43
+
44
+ ### Output Format
45
+
46
+ Produce JSON conforming to the verifier-output schema with these fields:
47
+
48
+ - `status`: "passed" | "gaps_found" | "human_needed"
49
+ - `score`: "N/M" format
50
+ - `truths[]`: observable claims with status and evidence
51
+ - `criteria_results[]`: one entry per criterion with verify_method, status, expected/actual outcome, evidence
52
+ - `artifacts[]`: (optional) file paths checked with existence/substance status
53
+ - `requirements_coverage[]`: (optional) requirement satisfaction mapping
54
+ - `human_verification[]`: (optional) items needing human review
55
+ - `gaps[]`: (optional) failed or uncertain truths with reasons
56
+
57
+ Be thorough. Run actual commands. Read actual files. Report what you observe, not what you assume.