okstra 0.225.1 → 0.227.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/README.md +1 -0
- package/dist/cli-registry.mjs +6 -0
- package/dist/cli-registry.mjs.map +1 -1
- package/dist/commands/execute/render-bundle.mjs +5 -0
- package/dist/commands/execute/render-bundle.mjs.map +1 -1
- package/dist/commands/execute/wizard.mjs +12 -15
- package/dist/commands/execute/wizard.mjs.map +1 -1
- package/docs/cli.md +46 -6
- package/docs/project-structure-overview.md +3 -1
- package/package.json +1 -1
- package/runtime/BUILD.json +2 -2
- package/runtime/agents/operations/code-review.json +1 -1
- package/runtime/bin/lib/okstra/cli.sh +5 -1
- package/runtime/bin/lib/okstra/globals.sh +1 -0
- package/runtime/bin/lib/okstra/usage.sh +3 -0
- package/runtime/bin/okstra.sh +2 -0
- package/runtime/prompts/duties/technical-verification-worker.json +2 -1
- package/runtime/prompts/lead/convergence.md +4 -1
- package/runtime/prompts/lead/okstra-lead-contract.md +1 -1
- package/runtime/prompts/lead/phase-routing.md +7 -3
- package/runtime/prompts/lead/team-contract.md +1 -1
- package/runtime/prompts/wizard/prompts.ko.json +59 -0
- package/runtime/python/okstra_ctl/adapters/providers/codex/adapter.py +5 -0
- package/runtime/python/okstra_ctl/adapters/worker_defaults.py +63 -0
- package/runtime/python/okstra_ctl/agent/prompt_cli/cli.py +3 -0
- package/runtime/python/okstra_ctl/agent/prompt_cli/corrections.py +5 -0
- package/runtime/python/okstra_ctl/analysis_packet.py +108 -2
- package/runtime/python/okstra_ctl/approved_plan_stage_extract.py +206 -0
- package/runtime/python/okstra_ctl/brief_sources.py +200 -0
- package/runtime/python/okstra_ctl/business_flow/store.py +15 -2
- package/runtime/python/okstra_ctl/cmux.py +18 -3
- package/runtime/python/okstra_ctl/code_review_coverage.py +70 -18
- package/runtime/python/okstra_ctl/code_review_target.py +77 -53
- package/runtime/python/okstra_ctl/convergence_critic_prompt.py +4 -1
- package/runtime/python/okstra_ctl/correction_cli.py +6 -5
- package/runtime/python/okstra_ctl/correction_round.py +1 -1
- package/runtime/python/okstra_ctl/design_surfaces.py +19 -7
- package/runtime/python/okstra_ctl/domain/worker_defaults.py +106 -0
- package/runtime/python/okstra_ctl/execution_mutation_audit.py +20 -18
- package/runtime/python/okstra_ctl/file_size_cap.py +56 -6
- package/runtime/python/okstra_ctl/implementation_direction.py +10 -0
- package/runtime/python/okstra_ctl/initial_prompt_materialization.py +41 -0
- package/runtime/python/okstra_ctl/manager_split.py +185 -27
- package/runtime/python/okstra_ctl/next_phase.py +3 -1
- package/runtime/python/okstra_ctl/phases/final_verification/prior_blockers.py +128 -0
- package/runtime/python/okstra_ctl/phases/final_verification/profile.md +8 -5
- package/runtime/python/okstra_ctl/phases/final_verification/report_assets/final-verification.template.html +1 -1
- package/runtime/python/okstra_ctl/phases/final_verification/validation.py +84 -0
- package/runtime/python/okstra_ctl/phases/implementation/instructions/_implementation-deliverable.md +2 -2
- package/runtime/python/okstra_ctl/phases/implementation/instructions/_implementation-executor.md +2 -2
- package/runtime/python/okstra_ctl/phases/implementation/instructions/_implementation-self-check.md +1 -1
- package/runtime/python/okstra_ctl/phases/implementation/instructions/_implementation-verifier.md +2 -2
- package/runtime/python/okstra_ctl/phases/implementation_option_selection/authoring.py +13 -5
- package/runtime/python/okstra_ctl/phases/implementation_option_selection/boundary.json +1 -1
- package/runtime/python/okstra_ctl/phases/implementation_option_selection/entry.py +67 -0
- package/runtime/python/okstra_ctl/phases/implementation_option_selection/profile.md +4 -2
- package/runtime/python/okstra_ctl/phases/implementation_option_selection/report_assets/implementation-option-selection.template.html +2 -1
- package/runtime/python/okstra_ctl/phases/implementation_option_selection/validation.py +127 -18
- package/runtime/python/okstra_ctl/phases/implementation_planning/authoring.py +22 -0
- package/runtime/python/okstra_ctl/phases/implementation_planning/instructions/plan-body-verification.md +1 -1
- package/runtime/python/okstra_ctl/phases/implementation_planning/profile.md +2 -1
- package/runtime/python/okstra_ctl/phases/technical_verification/profile.md +2 -2
- package/runtime/python/okstra_ctl/ports/worker_defaults.py +25 -0
- package/runtime/python/okstra_ctl/registry/worker_defaults_store.py +8 -0
- package/runtime/python/okstra_ctl/report_assembly.py +23 -2
- package/runtime/python/okstra_ctl/report_views.py +2 -1
- package/runtime/python/okstra_ctl/run.py +61 -2
- package/runtime/python/okstra_ctl/run_context.py +13 -8
- package/runtime/python/okstra_ctl/stage_done.py +5 -4
- package/runtime/python/okstra_ctl/wizard/cli.py +16 -4
- package/runtime/python/okstra_ctl/wizard/confirmation.py +27 -0
- package/runtime/python/okstra_ctl/wizard/engine.py +25 -3
- package/runtime/python/okstra_ctl/wizard/ids.py +29 -0
- package/runtime/python/okstra_ctl/wizard/registry.py +21 -0
- package/runtime/python/okstra_ctl/wizard/render.py +6 -2
- package/runtime/python/okstra_ctl/wizard/roles.py +73 -23
- package/runtime/python/okstra_ctl/wizard/sources.py +33 -11
- package/runtime/python/okstra_ctl/wizard/state.py +59 -14
- package/runtime/python/okstra_ctl/wizard/steps_options.py +74 -9
- package/runtime/python/okstra_ctl/wizard/steps_roles.py +5 -3
- package/runtime/python/okstra_ctl/wizard/worker_settings.py +334 -0
- package/runtime/python/okstra_ctl/worker_defaults.py +135 -0
- package/runtime/python/okstra_ctl/worker_prompt_body.py +21 -1
- package/runtime/python/okstra_ctl/worker_prompt_headers.py +11 -4
- package/runtime/python/okstra_ctl/worker_prompt_policy.py +3 -0
- package/runtime/python/okstra_ctl/write_policy.py +33 -18
- package/runtime/schemas/final-report-v2.0.schema.json +74 -0
- package/runtime/schemas/final-report-v3.0.schema.json +99 -2
- package/runtime/skills/okstra-brief-gen/SKILL.md +26 -0
- package/runtime/skills/okstra-code-review/SKILL.md +25 -23
- package/runtime/skills/okstra-code-review/references/review-calibration.md +2 -2
- package/runtime/skills/okstra-manager/SKILL.md +15 -2
- package/runtime/skills/okstra-run/SKILL.md +21 -1
- package/runtime/templates/reports/brief.template.md +10 -1
- package/runtime/templates/reports/html/i18n/en.json +8 -0
- package/runtime/templates/reports/html/i18n/ko.json +8 -0
- package/runtime/templates/worker-prompt-preamble.md +1 -1
- package/runtime/validators/validate-brief.py +39 -1
- package/runtime/validators/validate-run.py +5 -0
|
@@ -51,6 +51,15 @@ Checks performed per brief file:
|
|
|
51
51
|
template's `<...>` scaffolding — a paragraph wrapped in angle brackets,
|
|
52
52
|
a `- <...>` bullet, or a `> augmented: <label>` line. Source Material is
|
|
53
53
|
exempt because it holds the reporter's words verbatim.
|
|
54
|
+
17. Every git-untracked document under the project root (`.md`, `.txt`, …)
|
|
55
|
+
that the brief names outside `## Source Material` has its own
|
|
56
|
+
`### Source N — file` entry there. The task worktree is a checkout and
|
|
57
|
+
lacks such a file; prepare copies only Source Material file entries into
|
|
58
|
+
the analysis packet. `okstra brief-sources attach` appends the missing
|
|
59
|
+
entries in place. The project root is the parent of a `--briefs-root`
|
|
60
|
+
of the form `<root>/.okstra/briefs`; for any other briefs root, or
|
|
61
|
+
outside a git checkout, the check is skipped. The codebase-scan variant
|
|
62
|
+
has no Source Material section and is not checked.
|
|
54
63
|
|
|
55
64
|
Exit code 0 on PASS, 1 on FAIL.
|
|
56
65
|
"""
|
|
@@ -76,6 +85,7 @@ from okstra_ctl.phases.improvement_discovery.lenses import (
|
|
|
76
85
|
MIN_PRIORITY_LENSES,
|
|
77
86
|
)
|
|
78
87
|
from okstra_ctl.group_context import GROUP_CONTEXT_TYPE, validate_group_context
|
|
88
|
+
from okstra_ctl.brief_sources import uncited_local_documents
|
|
79
89
|
from okstra_ctl.ids import slugify_task_segment
|
|
80
90
|
|
|
81
91
|
REQUIRED_FRONTMATTER_KEYS = {
|
|
@@ -747,7 +757,32 @@ def check_reporter_confirmations(
|
|
|
747
757
|
)
|
|
748
758
|
|
|
749
759
|
|
|
750
|
-
def
|
|
760
|
+
def project_root_of(briefs_root: Path) -> Path | None:
|
|
761
|
+
"""`<root>/.okstra/briefs` 이면 `<root>`, 아니면 None."""
|
|
762
|
+
resolved = briefs_root.resolve()
|
|
763
|
+
if resolved.name == "briefs" and resolved.parent.name == ".okstra":
|
|
764
|
+
return resolved.parent.parent
|
|
765
|
+
return None
|
|
766
|
+
|
|
767
|
+
|
|
768
|
+
def check_cited_local_documents(
|
|
769
|
+
text: str, scope: str, project_root: Path | None, errors: list[str]
|
|
770
|
+
) -> None:
|
|
771
|
+
if project_root is None or scope == "codebase":
|
|
772
|
+
return
|
|
773
|
+
for relative in uncited_local_documents(text, project_root):
|
|
774
|
+
errors.append(
|
|
775
|
+
f"local document {relative!r} is cited in the brief but has no "
|
|
776
|
+
"`### Source N — file` entry in Source Material; it is untracked, "
|
|
777
|
+
"so the task worktree lacks it and no run will show it to workers. "
|
|
778
|
+
f"Run `okstra brief-sources attach --project-root {project_root} "
|
|
779
|
+
"--brief <this brief>` to append it by reference"
|
|
780
|
+
)
|
|
781
|
+
|
|
782
|
+
|
|
783
|
+
def validate_brief(
|
|
784
|
+
path: Path, briefs_root: Path, project_root: Path | None = None
|
|
785
|
+
) -> list[str]:
|
|
751
786
|
text = strip_html_comments(path.read_text(encoding="utf-8"))
|
|
752
787
|
errors: list[str] = []
|
|
753
788
|
|
|
@@ -795,6 +830,9 @@ def validate_brief(path: Path, briefs_root: Path) -> list[str]:
|
|
|
795
830
|
check_end_state_sections(text, scope, errors)
|
|
796
831
|
check_variant_required_sections(text, scope, errors)
|
|
797
832
|
check_template_scaffold(text, scope, errors)
|
|
833
|
+
check_cited_local_documents(
|
|
834
|
+
text, scope, project_root or project_root_of(briefs_root), errors
|
|
835
|
+
)
|
|
798
836
|
|
|
799
837
|
# 2. brief-id matches filename stem
|
|
800
838
|
stem = path.stem
|
|
@@ -242,6 +242,7 @@ from okstra_ctl.report_routing import technical_verification_routing_errors
|
|
|
242
242
|
from okstra_ctl.phases.implementation_option_selection.validation import ( # noqa: E402
|
|
243
243
|
validate_blocked_answer_channel,
|
|
244
244
|
validate_implementation_option_selection,
|
|
245
|
+
validate_split_acceptance,
|
|
245
246
|
)
|
|
246
247
|
from okstra_ctl.phases.implementation_planning.validation import (
|
|
247
248
|
_validate_requirement_provenance, _validate_stage_has_requirement,
|
|
@@ -3197,6 +3198,10 @@ def validate_final_report_data(
|
|
|
3197
3198
|
f"implementation-option-selection: {error}"
|
|
3198
3199
|
for error in validate_blocked_answer_channel(data)
|
|
3199
3200
|
)
|
|
3201
|
+
failures.extend(
|
|
3202
|
+
f"implementation-option-selection: {error}"
|
|
3203
|
+
for error in validate_split_acceptance(data)
|
|
3204
|
+
)
|
|
3200
3205
|
elif task_type == "implementation":
|
|
3201
3206
|
_validate_stage_carry_sidecar_exists(data, report_path, failures)
|
|
3202
3207
|
_validate_lead_fixes(data, failures)
|