Repoint every remaining literal `.specify/...` / `docs/input` reference to the real package/domain location and delete all compat symlinks. The harness now runs purely via packages/casan-harness/... with no .specify facade; .specify holds ONLY runtime state (logs/, agentops/alerts.log, level5/central-governance). Refs fixed (Phase 0.5 only caught `$VAR/.specify/` — these were bare/`__file__`/literal): - secrets-scan.sh: scan-target excludes -> packages/casan-harness/... (+ apps/okr/domain/corpus) - loop_common.py: loop-policy.yaml -> harness config (package-relative) - evidence-pack-build.py: judge-gate test + traceability-matrix.py -> harness/sibling - phase10-traceability: REQ -> $CASAN_DOMAIN_ROOT/input - run-casan-pipeline.mjs: model-fallback/drift-detect/rollback-manager -> HARNESS_BASH, golden -> GOLDEN_PLAN (apps/okr/domain), with .specify/logs state kept - casan-step.mjs: requirement fallback restored to docs/input for hermetic sandboxes - descriptive config (tool-registry/harness-package/drift-policy/hallucination/risk-registry/ loop-policy.schema + docstrings) repointed for accuracy - policy-bundle.yaml: 8 policy paths -> packages/casan-harness/...; manifest regenerated + re-signed (POLICY_HASHES_VALID files=8, POLICY_SIGNATURE_VALID) Removed 22 .specify code/config symlinks + docs/input symlink. Full gate via packages path, NO facade: PASS=64 FAIL=0 SKIP=3. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
60 lines
2.2 KiB
JSON
60 lines
2.2 KiB
JSON
{
|
|
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
"$id": "https://casan.fpt/loop-policy.schema.json",
|
|
"title": "CASAN Loop Budget Governor policy",
|
|
"description": "Schema for packages/casan-harness/config/loop-policy.yaml (Plan-17 Track 1). Budgets are non-negative numbers; on_exceed is halt|escalate. Absence of a rule means the strictest built-in ceiling applies (deny-by-default).",
|
|
"type": "object",
|
|
"required": ["version", "profiles"],
|
|
"additionalProperties": false,
|
|
"properties": {
|
|
"version": { "type": "integer", "minimum": 1 },
|
|
"org_ceiling": { "$ref": "#/definitions/budget" },
|
|
"profiles": {
|
|
"type": "object",
|
|
"minProperties": 1,
|
|
"additionalProperties": { "$ref": "#/definitions/profileBlock" }
|
|
}
|
|
},
|
|
"definitions": {
|
|
"budget": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"properties": {
|
|
"max_steps": { "type": "number", "minimum": 0 },
|
|
"max_tokens": { "type": "number", "minimum": 0 },
|
|
"max_wall_clock_sec": { "type": "number", "minimum": 0 },
|
|
"max_cost_usd": { "type": "number", "minimum": 0 },
|
|
"max_corrections_per_step": { "type": "number", "minimum": 0 },
|
|
"on_exceed": { "type": "string", "enum": ["halt", "escalate"] }
|
|
}
|
|
},
|
|
"convergence": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"properties": {
|
|
"oscillation_repeat": { "type": "integer", "minimum": 1 },
|
|
"thrash_window": { "type": "integer", "minimum": 1 },
|
|
"no_progress_window": { "type": "integer", "minimum": 1 },
|
|
"on_stall": { "type": "string", "enum": ["halt", "escalate"] }
|
|
}
|
|
},
|
|
"profileBlock": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"properties": {
|
|
"defaults": { "$ref": "#/definitions/budget" },
|
|
"delegation_levels": {
|
|
"type": "object",
|
|
"propertyNames": { "pattern": "^L[0-5]$" },
|
|
"additionalProperties": { "$ref": "#/definitions/budget" }
|
|
},
|
|
"projects": {
|
|
"type": "object",
|
|
"additionalProperties": { "$ref": "#/definitions/budget" }
|
|
},
|
|
"convergence": { "$ref": "#/definitions/convergence" }
|
|
}
|
|
}
|
|
}
|
|
}
|