refactor(autonomy): rename automation profile task flags to spec names #1147

Merged
CoreRasurae merged 1 commits from feature/m5-automation-profile-fields into master 2026-03-30 12:34:21 +00:00
62 changed files with 1678 additions and 1312 deletions
+31
View File
@@ -154,6 +154,37 @@
naive datetime rejection, domain model naive datetime normalisation,
and corrupted DB state handling in `update_state()`.
(#920)
- Hardened automation profile configuration validation after the task-flag
rename: `AutomationProfile` now rejects unknown top-level fields instead of
silently ignoring them, and raises an actionable ``ValueError`` listing the
required renames when legacy ``auto_*`` keys are supplied (instead of a
generic Pydantic "Extra inputs are not permitted" error). Updated
automation profile schema and documentation references (`specification`,
ADRs, and reference docs) to the task-type field names, added BDD coverage
for rejecting legacy threshold keys in `automation-profile add`, restored
docs-schema parity for optional `guards` profile configs, aligned the
`m5_001` migration header metadata text with its actual revision chain,
updated M6 fixture files to use the spec-defined field names, added
phase-transition semantic bridge comments in `PlanLifecycleService`.
Restored categorised CLI ``automation-profile show`` output to match the
specification (Phase Transitions / Decision Automation / Self-Repair /
Execution Controls), added missing ``access_network`` field to spec ``show``
output examples, aligned ADR-017 and reference doc descriptions with the
specification's Automatable Tasks table (all 11 fields), and extended the
repository roundtrip test to assert all 11 threshold fields. Fixed
benchmark ``_make_profile()`` helper passing safety fields as top-level
kwargs instead of via ``SafetyProfile`` sub-model (incompatible with
``extra="forbid"``). Aligned CLI JSON/YAML output structure for
``automation-profile show`` with the specification's grouped format
(``phase_transitions``, ``decision_automation``, ``self_repair``,
``execution_controls``). Moved safety boolean fields into the Execution
Controls section of Rich output per spec examples. Reverted ``auto``
profile description to "Fully automatic except apply" per specification.
Added comprehensive field-name mapping table to ``automation_profile.py``
module docstring documenting the old phase-transition names to new
spec task-type names correspondence and added cross-reference in
``AutonomyController._get_threshold()`` docstring.
(#902)
- Added TDD bug-capture tests for bug #1141 — session create does not persist
into subsequent session list output. Added a Behave scenario and Robot E2E
test with required tags (`@tdd_bug`, `@tdd_bug_1141`, `@tdd_expected_fail` /
@@ -0,0 +1,50 @@
"""Rename automation profile task-type threshold columns.
Renames all 11 task-type confidence threshold columns in the
``automation_profiles`` table from phase-transition semantics to the
spec-defined task-type semantics.
Revision ID: m5_001_rename_profile_fields
Revises: m4_003_plan_env_columns
Create Date: 2026-03-24 10:00:00
"""
from collections.abc import Sequence
from alembic import op
# revision identifiers, used by Alembic.
revision: str = "m5_001_rename_profile_fields"
down_revision: str | Sequence[str] | None = "m4_003_plan_env_columns"
branch_labels: str | Sequence[str] | None = None
depends_on: str | Sequence[str] | None = None
# Mapping of (old_name, new_name) for every renamed column.
_COLUMN_RENAMES: list[tuple[str, str]] = [
("auto_strategize", "decompose_task"),
("auto_execute", "create_tool"),
("auto_apply", "select_tool"),
("auto_decisions_strategize", "edit_code"),
("auto_decisions_execute", "execute_command"),
("auto_validation_fix", "create_file"),
("auto_strategy_revision", "delete_content"),
("auto_reversion_from_apply", "access_network"),
("auto_child_plans", "install_dependency"),
("auto_retry_transient", "modify_config"),
("auto_checkpoint_restore", "approve_plan"),
]
def upgrade() -> None:
"""Rename threshold columns to spec-defined task-type names."""
with op.batch_alter_table("automation_profiles") as batch_op:
for old_name, new_name in _COLUMN_RENAMES:
batch_op.alter_column(old_name, new_column_name=new_name)
def downgrade() -> None:
"""Revert threshold columns to phase-transition names."""
with op.batch_alter_table("automation_profiles") as batch_op:
for old_name, new_name in _COLUMN_RENAMES:
batch_op.alter_column(new_name, new_column_name=old_name)
@@ -0,0 +1,32 @@
"""Merge profile-rename and correction-attempts heads.
Both m5_001_rename_profile_fields and m8_001_correction_attempts branched
from m4_003_plan_env_columns, creating two Alembic heads. This no-op
merge migration resolves them into a single head.
Revision ID: m8_002_merge_profile_rename_and_corrections
Revises: m5_001_rename_profile_fields, m8_001_correction_attempts
Create Date: 2026-03-29 00:00:00
"""
from collections.abc import Sequence
# revision identifiers, used by Alembic.
revision: str = "m8_002_merge_profile_rename_and_corrections"
down_revision: str | Sequence[str] | None = (
"m5_001_rename_profile_fields",
"m8_001_correction_attempts",
)
branch_labels: str | Sequence[str] | None = None
depends_on: str | Sequence[str] | None = None
def upgrade() -> None:
"""Upgrade schema."""
pass
def downgrade() -> None:
"""Downgrade schema."""
pass
+32 -28
View File
@@ -23,6 +23,7 @@ try:
AutomationProfile,
get_builtin_profile,
)
from cleveragents.domain.models.core.safety_profile import SafetyProfile
except ModuleNotFoundError:
sys.path.insert(0, str(Path(__file__).resolve().parents[1] / "src"))
from cleveragents.domain.models.core.automation_guard import (
@@ -33,6 +34,7 @@ except ModuleNotFoundError:
AutomationProfile,
get_builtin_profile,
)
from cleveragents.domain.models.core.safety_profile import SafetyProfile
def _make_profile() -> AutomationProfile:
@@ -40,20 +42,22 @@ def _make_profile() -> AutomationProfile:
return AutomationProfile(
name="bench/test-profile",
description="Benchmark profile",
auto_strategize=0.7,
auto_execute=0.5,
auto_apply=1.0,
auto_decisions_strategize=0.6,
auto_decisions_execute=0.8,
auto_validation_fix=0.3,
auto_strategy_revision=0.9,
auto_reversion_from_apply=0.4,
auto_child_plans=0.7,
auto_retry_transient=0.1,
auto_checkpoint_restore=0.5,
require_sandbox=True,
require_checkpoints=True,
allow_unsafe_tools=False,
decompose_task=0.7,
create_tool=0.5,
select_tool=1.0,
edit_code=0.6,
execute_command=0.8,
create_file=0.3,
delete_content=0.9,
access_network=0.4,
install_dependency=0.7,
modify_config=0.1,
approve_plan=0.5,
safety=SafetyProfile(
require_sandbox=True,
require_checkpoints=True,
allow_unsafe_tools=False,
),
)
@@ -72,17 +76,17 @@ class ProfileValidationSuite:
"""Benchmark profile with all thresholds at 1.0."""
AutomationProfile(
name="bench/max",
auto_strategize=1.0,
auto_execute=1.0,
auto_apply=1.0,
auto_decisions_strategize=1.0,
auto_decisions_execute=1.0,
auto_validation_fix=1.0,
auto_strategy_revision=1.0,
auto_reversion_from_apply=1.0,
auto_child_plans=1.0,
auto_retry_transient=1.0,
auto_checkpoint_restore=1.0,
decompose_task=1.0,
create_tool=1.0,
select_tool=1.0,
edit_code=1.0,
execute_command=1.0,
create_file=1.0,
delete_content=1.0,
access_network=1.0,
install_dependency=1.0,
modify_config=1.0,
approve_plan=1.0,
)
@@ -110,9 +114,9 @@ class ProfileFromConfigSuite:
self.config = {
"name": "bench/from-config",
"description": "Config benchmark",
"auto_strategize": 0.7,
"auto_execute": 0.5,
"auto_apply": 1.0,
"decompose_task": 0.7,
"create_tool": 0.5,
"select_tool": 1.0,
}
def time_profile_from_config(self) -> None:
+11 -11
View File
@@ -65,17 +65,17 @@ _VALID_YAML = """\
name: bench/test-profile
description: Benchmark test profile
schema_version: "1.0"
auto_strategize: 0.5
auto_execute: 0.5
auto_apply: 1.0
auto_decisions_strategize: 0.5
auto_decisions_execute: 0.5
auto_validation_fix: 0.5
auto_strategy_revision: 0.5
auto_reversion_from_apply: 0.5
auto_child_plans: 0.5
auto_retry_transient: 0.0
auto_checkpoint_restore: 0.5
decompose_task: 0.5
create_tool: 0.5
select_tool: 1.0
edit_code: 0.5
execute_command: 0.5
create_file: 0.5
delete_content: 0.5
access_network: 0.5
install_dependency: 0.5
modify_config: 0.0
approve_plan: 0.5
safety:
require_sandbox: true
require_checkpoints: true
+5 -5
View File
@@ -107,7 +107,7 @@ class EscalationDecisionSuite:
risk_assessment=0.15,
invariant_complexity=0.2,
)
self.operation = OperationContext(operation_type="auto_execute")
self.operation = OperationContext(operation_type="create_tool")
self.profile_cautious = BUILTIN_PROFILES["cautious"]
self.profile_fullauto = BUILTIN_PROFILES["full-auto"]
self.profile_manual = BUILTIN_PROFILES["manual"]
@@ -144,11 +144,11 @@ class HistoricalTrackingSuite:
"""Set up controller with pre-populated history."""
self.controller = AutonomyController()
self.outcome_success = HistoricalOutcome(
operation_type="auto_execute",
operation_type="create_tool",
succeeded=True,
)
self.outcome_failure = HistoricalOutcome(
operation_type="auto_execute",
operation_type="create_tool",
succeeded=False,
)
# Pre-populate history
@@ -161,8 +161,8 @@ class HistoricalTrackingSuite:
def time_get_success_rate(self) -> None:
"""Benchmark retrieving historical success rate."""
self.controller.get_historical_success_rate("auto_execute")
self.controller.get_historical_success_rate("create_tool")
def time_get_history_count(self) -> None:
"""Benchmark retrieving history count."""
self.controller.get_history_count("auto_execute")
self.controller.get_history_count("create_tool")
+2 -2
View File
@@ -102,9 +102,9 @@ There is no `strategize` command. The `use` verb transitions from Action to Stra
Both Execute and Apply may revert to Strategize (never to any other phase):
**Execute → Strategize**: Triggered when the execution actor discovers that Strategize-phase constraints are too restrictive to complete the work. Rather than violating those constraints, the plan reverts so the strategy actor can adjust the decision tree. Controlled by the `auto_strategy_revision` automation profile flag.
**Execute → Strategize**: Triggered when the execution actor discovers that Strategize-phase constraints are too restrictive to complete the work. Rather than violating those constraints, the plan reverts so the strategy actor can adjust the decision tree. Controlled by the `delete_content` automation profile flag.
**Apply → Strategize**: Triggered when the changeset cannot be applied within the current strategy's constraints (merge conflicts, validation failures at apply time, resource state drift). The plan enters the `constrained` terminal state, then may revert either automatically or after manual approval. Controlled by the `auto_reversion_from_apply` flag.
**Apply → Strategize**: Triggered when the changeset cannot be applied within the current strategy's constraints (merge conflicts, validation failures at apply time, resource state drift). The plan enters the `constrained` terminal state, then may revert either automatically or after manual approval. Controlled by the `access_network` flag.
### Plan Identity
@@ -115,11 +115,11 @@ Each decision record contains:
Who makes decisions depends on the automation profile:
- `auto_decisions_strategize = 1.0` (always manual): User is prompted for each decision during Strategize.
- `auto_decisions_strategize = 0.0` (always automatic): Strategy actor decides autonomously, records reasoning.
- `edit_code = 1.0` (always manual): User is prompted for each decision during Strategize.
- `edit_code = 0.0` (always automatic): Strategy actor decides autonomously, records reasoning.
- Intermediate thresholds: Auto-decide only when the confidence score meets or exceeds the threshold; otherwise prompt the user.
The same pattern applies to `auto_decisions_execute` for Execute-phase decisions.
The same pattern applies to `execute_command` for Execute-phase decisions.
### Unified Correction Mechanism
+14 -10
View File
@@ -55,15 +55,19 @@ CleverAgents uses **automation profiles** — named configuration bundles that c
Each automation profile is a set of confidence thresholds plus a composed **safety profile** sub-model (see [ADR-041](ADR-041-safety-profile-extraction.md)):
| Field | Type | Description |
| Field | Type | Description (spec § Automatable Tasks) |
|-------|------|-------------|
| `auto_strategize` | float (0.0-1.0) | Confidence threshold for automatic entry into Strategize after `plan use`. 0.0 = always auto, 1.0 = always manual. |
| `auto_execute` | float (0.0-1.0) | Confidence threshold for automatic transition from Strategize to Execute. |
| `auto_apply` | float (0.0-1.0) | Confidence threshold for automatic Apply after Execute. |
| `auto_decisions_strategize` | float (0.0-1.0) | Threshold for automatic decision-making during Strategize. |
| `auto_decisions_execute` | float (0.0-1.0) | Threshold for automatic decision-making during Execute. |
| `auto_strategy_revision` | float (0.0-1.0) | Threshold for automatic Execute → Strategize reversion. |
| `auto_reversion_from_apply` | float (0.0-1.0) | Threshold for automatic Apply → Strategize reversion. |
| `decompose_task` | float (0.0-1.0) | Automatically enter Strategize after `plan use`. 0.0 = always auto, 1.0 = always manual. |
| `create_tool` | float (0.0-1.0) | Automatically proceed from Strategize to Execute. |
| `select_tool` | float (0.0-1.0) | Automatically proceed from Execute to Apply. |
| `edit_code` | float (0.0-1.0) | Automatically make decisions during Strategize. |
| `execute_command` | float (0.0-1.0) | Automatically make decisions during Execute. |
| `create_file` | float (0.0-1.0) | Automatically attempt to fix validation failures. |
| `delete_content` | float (0.0-1.0) | Automatically revise strategy when Execute hits constraints. |
| `access_network` | float (0.0-1.0) | Automatically revert from Apply (`constrained`) to Strategize. |
| `install_dependency` | float (0.0-1.0) | Automatically spawn and execute child plans. |
| `modify_config` | float (0.0-1.0) | Automatically retry on transient failures. |
| `approve_plan` | float (0.0-1.0) | Automatically restore from checkpoint on failure. |
| `safety` | SafetyProfile | Composed sub-model with hard safety constraints (see below). |
The `safety` field is a `SafetyProfile` sub-model containing:
@@ -90,8 +94,8 @@ The Semantic Escalation system produces confidence scores for each transition. W
| Profile | Intent | Key Settings |
|---------|--------|-------------|
| `manual` | Human controls everything | All thresholds 1.0, `safety.require_sandbox: true`, `safety.require_checkpoints: true` |
| `review` | Auto-strategize, human reviews before execute and apply | `auto_strategize: 0.0`, execute/apply thresholds high |
| `supervised` | Auto through strategize/execute, human approves apply | `auto_apply: 1.0`, others low |
| `review` | Auto-strategize, human reviews before execute and apply | `decompose_task: 0.0`, execute/apply thresholds high |
| `supervised` | Auto through strategize/execute, human approves apply | `select_tool: 1.0`, others low |
| `cautious` | Mostly auto with conservative thresholds | Moderate thresholds (~0.7), `safety.require_sandbox: true` |
| `trusted` | Fully auto for well-tested domains | Low thresholds (~0.3), `safety.require_sandbox: true` |
| `auto` | Fully automatic with safety nets | All thresholds 0.0, `safety.require_sandbox: true`, `safety.require_checkpoints: true` |
@@ -216,7 +216,7 @@ During the Execute phase, the execution actor operates under constraints establi
When `record_decision` is called, the system checks the actor's `confidence_score` against the applicable automation profile threshold before persisting:
1. Actor calls `record_decision` with `confidence_score = 0.72`.
2. System checks the profile: if `auto_decisions_strategize = 0.8` (during Strategize) or `auto_decisions_execute = 0.8` (during Execute), the confidence is below the threshold.
2. System checks the profile: if `edit_code = 0.8` (during Strategize) or `execute_command = 0.8` (during Execute), the confidence is below the threshold.
3. System pauses execution and presents the decision to the user for approval or override.
4. User either approves (decision is persisted as-is), selects an alternative (decision is persisted with the user's choice), or provides custom guidance (decision is persisted with the user's input).
5. If the user overrides the actor's choice, the decision's `chosen_option` reflects the user's selection, and the original actor choice is recorded in `alternatives_considered`.
+3 -3
View File
@@ -59,8 +59,8 @@ When `default_automation_profile` is set, it takes precedence over
The `PlanLifecycleService` uses profile thresholds to decide whether
to auto-progress plans:
- **Strategize → Execute**: auto-progresses when `profile.auto_execute < 1.0`
- **Execute → Apply**: auto-progresses when `profile.auto_apply < 1.0`
- **Strategize → Execute**: auto-progresses when `profile.create_tool < 1.0`
- **Execute → Apply**: auto-progresses when `profile.select_tool < 1.0`
A threshold of `0.0` means fully automatic (no human gate required).
A threshold of `1.0` means human approval is always required.
@@ -69,7 +69,7 @@ A threshold of `1.0` means human approval is always required.
Eight built-in profiles ship with every installation:
| Profile | auto_execute | auto_apply | Behavior |
| Profile | create_tool | select_tool | Behavior |
|---------------|-------------|------------|-------------------------|
| `manual` | 1.0 | 1.0 | Human approves all |
| `review` | 0.0 | 1.0 | Human reviews before apply |
+40 -40
View File
@@ -14,19 +14,19 @@ Each threshold field is a float in the range `[0.0, 1.0]`:
### Threshold Fields
| Field | Category | Description |
| Field | Category | Description (spec § Automatable Tasks) |
|-------|----------|-------------|
| `auto_strategize` | Phase transition | Gate before entering the strategy phase |
| `auto_execute` | Phase transition | Gate before entering the execution phase |
| `auto_apply` | Phase transition | Gate before applying changes |
| `auto_decisions_strategize` | Decision autonomy | Gate for decisions during strategy |
| `auto_decisions_execute` | Decision autonomy | Gate for decisions during execution |
| `auto_validation_fix` | Self-repair | Gate for automatic validation fixes |
| `auto_strategy_revision` | Self-repair | Gate for automatic strategy revision |
| `auto_reversion_from_apply` | Self-repair | Gate for reverting from the apply phase |
| `auto_child_plans` | Child plans | Gate for spawning child plans |
| `auto_retry_transient` | Retry | Gate for retrying transient failures |
| `auto_checkpoint_restore` | Checkpoint | Gate for automatic checkpoint restoration |
| `decompose_task` | Phase transition | Automatically enter Strategize after `plan use` |
| `create_tool` | Phase transition | Automatically proceed from Strategize to Execute |
| `select_tool` | Phase transition | Automatically proceed from Execute to Apply |
| `edit_code` | Decision autonomy | Automatically make decisions during Strategize |
| `execute_command` | Decision autonomy | Automatically make decisions during Execute |
| `create_file` | Self-repair | Automatically attempt to fix validation failures |
| `delete_content` | Self-repair | Automatically revise strategy when Execute hits constraints |
| `access_network` | Self-repair | Automatically revert from Apply (`constrained`) to Strategize |
| `install_dependency` | Execution controls | Automatically spawn and execute child plans |
| `modify_config` | Retry | Automatically retry on transient failures |
| `approve_plan` | Checkpoint | Automatically restore from checkpoint on failure |
### Safety Profile (Composed Sub-Model)
@@ -53,17 +53,17 @@ Eight profiles ship with every CleverAgents installation:
| Flag | manual | review | supervised | cautious | trusted | auto | ci | full-auto |
|------|:---:|:---:|:---:|:---:|:---:|:---:|:---:|:---:|
| auto_strategize | 1.0 | 0.0 | 0.0 | 0.7 | 0.0 | 0.0 | 0.0 | 0.0 |
| auto_execute | 1.0 | 0.0 | 1.0 | 0.7 | 0.0 | 0.0 | 0.0 | 0.0 |
| auto_apply | 1.0 | 1.0 | 1.0 | 1.0 | 1.0 | 1.0 | 0.0 | 0.0 |
| auto_decisions_strategize | 1.0 | 1.0 | 0.0 | 0.6 | 0.0 | 0.0 | 0.0 | 0.0 |
| auto_decisions_execute | 1.0 | 1.0 | 1.0 | 0.8 | 0.0 | 0.0 | 0.0 | 0.0 |
| auto_validation_fix | 1.0 | 1.0 | 1.0 | 0.7 | 0.0 | 0.0 | 0.0 | 0.0 |
| auto_strategy_revision | 1.0 | 1.0 | 1.0 | 0.8 | 1.0 | 0.0 | 0.0 | 0.0 |
| auto_reversion_from_apply | 1.0 | 1.0 | 1.0 | 0.9 | 1.0 | 1.0 | 0.0 | 0.0 |
| auto_child_plans | 1.0 | 0.0 | 1.0 | 0.7 | 0.0 | 0.0 | 0.0 | 0.0 |
| auto_retry_transient | 1.0 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 |
| auto_checkpoint_restore | 1.0 | 1.0 | 1.0 | 0.6 | 1.0 | 0.0 | 0.0 | 0.0 |
| decompose_task | 1.0 | 0.0 | 0.0 | 0.7 | 0.0 | 0.0 | 0.0 | 0.0 |
| create_tool | 1.0 | 0.0 | 1.0 | 0.7 | 0.0 | 0.0 | 0.0 | 0.0 |
| select_tool | 1.0 | 1.0 | 1.0 | 1.0 | 1.0 | 1.0 | 0.0 | 0.0 |
| edit_code | 1.0 | 1.0 | 0.0 | 0.6 | 0.0 | 0.0 | 0.0 | 0.0 |
| execute_command | 1.0 | 1.0 | 1.0 | 0.8 | 0.0 | 0.0 | 0.0 | 0.0 |
| create_file | 1.0 | 1.0 | 1.0 | 0.7 | 0.0 | 0.0 | 0.0 | 0.0 |
| delete_content | 1.0 | 1.0 | 1.0 | 0.8 | 1.0 | 0.0 | 0.0 | 0.0 |
| access_network | 1.0 | 1.0 | 1.0 | 0.9 | 1.0 | 1.0 | 0.0 | 0.0 |
| install_dependency | 1.0 | 0.0 | 1.0 | 0.7 | 0.0 | 0.0 | 0.0 | 0.0 |
| modify_config | 1.0 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 |
| approve_plan | 1.0 | 1.0 | 1.0 | 0.6 | 1.0 | 0.0 | 0.0 | 0.0 |
| **Safety Profile** | | | | | | | | |
| safety.require_sandbox | true | true | true | true | true | true | true | false |
| safety.require_checkpoints | true | true | true | true | true | true | true | false |
@@ -107,17 +107,17 @@ name: acme/strict
description: Strict profile for production deployments
schema_version: "1.0"
auto_strategize: 0.9
auto_execute: 0.9
auto_apply: 1.0
auto_decisions_strategize: 0.8
auto_decisions_execute: 0.9
auto_validation_fix: 0.5
auto_strategy_revision: 0.9
auto_reversion_from_apply: 1.0
auto_child_plans: 0.8
auto_retry_transient: 0.3
auto_checkpoint_restore: 0.7
decompose_task: 0.9
create_tool: 0.9
select_tool: 1.0
edit_code: 0.8
execute_command: 0.9
create_file: 0.5
delete_content: 0.9
access_network: 1.0
install_dependency: 0.8
modify_config: 0.3
approve_plan: 0.7
# Safety profile (composed sub-model)
safety:
@@ -174,9 +174,9 @@ The result of a guard evaluation is a `GuardResult` with three fields:
name: acme/guarded
description: Profile with guard constraints
schema_version: "1.0"
auto_strategize: 0.7
auto_execute: 0.7
auto_apply: 1.0
decompose_task: 0.7
create_tool: 0.7
select_tool: 1.0
# Safety profile (plan-level constraints)
safety:
@@ -376,9 +376,9 @@ a complete audit record for post-mortem analysis.
name: acme/guarded-auto
description: Auto profile with autonomy guardrails
schema_version: "1.0"
auto_strategize: 0.0
auto_execute: 0.0
auto_apply: 1.0
decompose_task: 0.0
create_tool: 0.0
select_tool: 1.0
guards:
max_tool_calls_per_step: 10
+1 -1
View File
@@ -35,7 +35,7 @@ Each error category maps to one or more recovery actions with CLI commands:
## Retry Policy
The retry policy is controlled by the automation profile's
`auto_retry_transient` threshold:
`modify_config` threshold (named per spec § Automatable Tasks):
- **0.0** (auto): Automatic retry for retriable errors
- **1.0** (human): Always escalate to human
+4 -4
View File
@@ -15,14 +15,14 @@ re-planning without discarding accumulated context.
Automatic reversion is gated by the plan's resolved `AutomationProfile`:
| Threshold | Controls |
| Threshold | Controls (see spec § Automatable Tasks for field naming) |
|-----------|----------|
| `auto_reversion_from_apply` | Auto-revert when Apply is constrained. `< 1.0` = automatic, `1.0` = manual only |
| `auto_strategy_revision` | Auto-revert from Execute to Strategize. `< 1.0` = automatic, `1.0` = manual only |
| `access_network` | Auto-revert when Apply is constrained. `< 1.0` = automatic, `1.0` = manual only |
| `delete_content` | Auto-revert from Execute to Strategize. `< 1.0` = automatic, `1.0` = manual only |
Built-in profile defaults:
| Profile | `auto_reversion_from_apply` | `auto_strategy_revision` |
| Profile | `access_network` | `delete_content` |
|---------|---------------------------|------------------------|
| `manual` | 1.0 (never auto) | 1.0 |
| `review` | 1.0 | 1.0 |
+2 -1
View File
@@ -295,7 +295,8 @@ When an `ErrorRecoveryService` is provided to the executor, the
`error_details`.
Retry limits default to 3 and are controlled by the automation
profile's `auto_retry_transient` threshold.
profile's `modify_config` threshold (named per spec § Automatable
Tasks; controls transient-failure retry gating).
Use `agents plan errors <plan_id>` to inspect error decisions,
retry history, and recovery suggestions for a plan.
+60 -26
View File
@@ -5,6 +5,7 @@
type: object
required:
- name
additionalProperties: false
properties:
name:
type: string
@@ -21,79 +22,112 @@ properties:
default: "1.0"
description: "Schema version for forward compatibility"
# Phase-transition thresholds (0.0 = auto, 1.0 = human)
auto_strategize:
# Task-type confidence thresholds (0.0 = auto, 1.0 = human)
decompose_task:
type: number
minimum: 0.0
maximum: 1.0
default: 0.0
description: "Threshold for automatic strategy approval"
auto_execute:
description: "Threshold for automatic task decomposition"
create_tool:
type: number
minimum: 0.0
maximum: 1.0
default: 0.0
description: "Threshold for automatic execution approval"
auto_apply:
description: "Threshold for automatic tool creation"
select_tool:
type: number
minimum: 0.0
maximum: 1.0
default: 0.0
description: "Threshold for automatic apply approval"
description: "Threshold for automatic tool selection"
# Decision-autonomy thresholds
auto_decisions_strategize:
edit_code:
type: number
minimum: 0.0
maximum: 1.0
default: 0.0
description: "Threshold for automatic decisions during strategy"
auto_decisions_execute:
description: "Threshold for automatic code editing"
execute_command:
type: number
minimum: 0.0
maximum: 1.0
default: 0.0
description: "Threshold for automatic decisions during execution"
description: "Threshold for automatic command execution"
# Self-repair thresholds
auto_validation_fix:
create_file:
type: number
minimum: 0.0
maximum: 1.0
default: 0.0
description: "Threshold for automatic validation fix"
auto_strategy_revision:
description: "Threshold for automatic file creation"
delete_content:
type: number
minimum: 0.0
maximum: 1.0
default: 0.0
description: "Threshold for automatic strategy revision"
auto_reversion_from_apply:
description: "Threshold for automatic content deletion"
access_network:
type: number
minimum: 0.0
maximum: 1.0
default: 0.0
description: "Threshold for automatic reversion from apply"
description: "Threshold for automatic network access"
# Child plan and retry thresholds
auto_child_plans:
install_dependency:
type: number
minimum: 0.0
maximum: 1.0
default: 0.0
description: "Threshold for automatic child plan spawning"
auto_retry_transient:
description: "Threshold for automatic dependency installation"
modify_config:
type: number
minimum: 0.0
maximum: 1.0
default: 0.0
description: "Threshold for automatic retry of transient failures"
auto_checkpoint_restore:
description: "Threshold for automatic configuration modification"
approve_plan:
type: number
minimum: 0.0
maximum: 1.0
default: 0.0
description: "Threshold for automatic checkpoint restore"
description: "Threshold for automatic plan approval"
# Optional automation guards (runtime enforcement hooks)
guards:
type: ["object", "null"]
description: "Optional AutomationGuard sub-model with per-invocation runtime constraints"
properties:
max_tool_calls_per_step:
type: ["integer", "null"]
minimum: 0
default: null
description: "Maximum tool invocations per step before requiring approval"
max_total_cost:
type: ["number", "null"]
minimum: 0.0
default: null
description: "Maximum cumulative invocation cost before requiring approval"
tool_allowlist:
type: ["array", "null"]
items:
type: string
default: null
description: "Only these tools may proceed automatically (null = all tools)"
tool_denylist:
type: ["array", "null"]
items:
type: string
default: null
description: "These tools always require approval (null = no denied tools)"
require_approval_for_writes:
type: boolean
default: false
description: "Require approval for write operations"
require_approval_for_apply:
type: boolean
default: false
description: "Require approval before apply phase"
# Safety profile (composed sub-model)
safety:
+289 -285
View File
@@ -12100,7 +12100,7 @@ Rebuild a stopped or failed `devcontainer-instance` resource. Transitions the c
- [x] **Apply** — Changeset is merged into real project resources
!!! note "Phase Reversion"
Both Execute and Apply can revert to Strategize when constraints are too restrictive. See `auto_strategy_revision` and `auto_reversion_from_apply` automation profile flags.
Both Execute and Apply can revert to Strategize when constraints are too restrictive. See `delete_content` and `access_network` automation profile flags.
##### agents plan list
@@ -16733,17 +16733,17 @@ Register a new custom automation profile from a YAML configuration file. The pro
╰──────────────────────────────────────────────────────────────────╯
╭─ Confidence Thresholds ────────────────╮
│ <span style="color: #66cc66; font-weight: 600;">auto_strategize:</span> 0.0 │
│ <span style="color: #66cc66; font-weight: 600;">auto_execute:</span> 0.0 │
│ <span style="color: #ff6666; font-weight: 600;">auto_apply:</span> 1.0 │
│ <span style="color: #66cc66; font-weight: 600;">auto_decisions_strategize:</span> 0.0 │
│ <span style="color: #66cc66; font-weight: 600;">auto_decisions_execute:</span> 0.0 │
│ <span style="color: #66cc66; font-weight: 600;">auto_validation_fix:</span> 0.0 │
│ <span style="color: #ff6666; font-weight: 600;">auto_strategy_revision:</span> 1.0 │
│ <span style="color: #ff6666; font-weight: 600;">auto_reversion_from_apply:</span> 1.0 │
│ <span style="color: #66cc66; font-weight: 600;">auto_child_plans:</span> 0.0 │
│ <span style="color: #66cc66; font-weight: 600;">auto_retry_transient:</span> 0.0 │
│ <span style="color: #66cc66; font-weight: 600;">auto_checkpoint_restore:</span> 0.0 │
│ <span style="color: #66cc66; font-weight: 600;">decompose_task:</span> 0.0 │
│ <span style="color: #66cc66; font-weight: 600;">create_tool:</span> 0.0 │
│ <span style="color: #ff6666; font-weight: 600;">select_tool:</span> 1.0 │
│ <span style="color: #66cc66; font-weight: 600;">edit_code:</span> 0.0 │
│ <span style="color: #66cc66; font-weight: 600;">execute_command:</span> 0.0 │
│ <span style="color: #66cc66; font-weight: 600;">create_file:</span> 0.0 │
│ <span style="color: #ff6666; font-weight: 600;">delete_content:</span> 1.0 │
│ <span style="color: #ff6666; font-weight: 600;">access_network:</span> 1.0 │
│ <span style="color: #66cc66; font-weight: 600;">install_dependency:</span> 0.0 │
│ <span style="color: #66cc66; font-weight: 600;">modify_config:</span> 0.0 │
│ <span style="color: #66cc66; font-weight: 600;">approve_plan:</span> 0.0 │
│ <span style="color: #66cc66; font-weight: 600;">require_sandbox:</span> true │
│ <span style="color: #66cc66; font-weight: 600;">require_checkpoints:</span> true │
│ <span style="color: #ff6666; font-weight: 600;">allow_unsafe_tools:</span> false │
@@ -16763,17 +16763,17 @@ Register a new custom automation profile from a YAML configuration file. The pro
Created: 2026-02-08 14:30
Confidence Thresholds
auto_strategize: 0.0
auto_execute: 0.0
auto_apply: 1.0
auto_decisions_strategize: 0.0
auto_decisions_execute: 0.0
auto_validation_fix: 0.0
auto_strategy_revision: 1.0
auto_reversion_from_apply: 1.0
auto_child_plans: 0.0
auto_retry_transient: 0.0
auto_checkpoint_restore: 0.0
decompose_task: 0.0
create_tool: 0.0
select_tool: 1.0
edit_code: 0.0
execute_command: 0.0
create_file: 0.0
delete_content: 1.0
access_network: 1.0
install_dependency: 0.0
modify_config: 0.0
approve_plan: 0.0
require_sandbox: true
require_checkpoints: true
allow_unsafe_tools: false
@@ -16793,17 +16793,17 @@ Register a new custom automation profile from a YAML configuration file. The pro
"description": "Autonomous execution with mandatory sandbox and manual apply",
"created": "2026-02-08T14:30:00Z",
"thresholds": {
"auto_strategize": 0.0,
"auto_execute": 0.0,
"auto_apply": 1.0,
"auto_decisions_strategize": 0.0,
"auto_decisions_execute": 0.0,
"auto_validation_fix": 0.0,
"auto_strategy_revision": 1.0,
"auto_reversion_from_apply": 1.0,
"auto_child_plans": 0.0,
"auto_retry_transient": 0.0,
"auto_checkpoint_restore": 0.0
"decompose_task": 0.0,
"create_tool": 0.0,
"select_tool": 1.0,
"edit_code": 0.0,
"execute_command": 0.0,
"create_file": 0.0,
"delete_content": 1.0,
"access_network": 1.0,
"install_dependency": 0.0,
"modify_config": 0.0,
"approve_plan": 0.0
},
"flags": {
"require_sandbox": true,
@@ -16827,17 +16827,17 @@ Register a new custom automation profile from a YAML configuration file. The pro
description: "Autonomous execution with mandatory sandbox and manual apply"
created: "2026-02-08T14:30:00Z"
thresholds:
auto_strategize: 0.0
auto_execute: 0.0
auto_apply: 1.0
auto_decisions_strategize: 0.0
auto_decisions_execute: 0.0
auto_validation_fix: 0.0
auto_strategy_revision: 1.0
auto_reversion_from_apply: 1.0
auto_child_plans: 0.0
auto_retry_transient: 0.0
auto_checkpoint_restore: 0.0
decompose_task: 0.0
create_tool: 0.0
select_tool: 1.0
edit_code: 0.0
execute_command: 0.0
create_file: 0.0
delete_content: 1.0
access_network: 1.0
install_dependency: 0.0
modify_config: 0.0
approve_plan: 0.0
flags:
require_sandbox: true
require_checkpoints: true
@@ -16996,15 +16996,15 @@ List all available automation profiles (built-in and custom).
"exit_code": 0,
"data": {
"profiles": [
{ "name": "manual", "source": "built-in", "auto_apply": 1.0, "sandbox": true, "description": "Human-driven (default)" },
{ "name": "review", "source": "built-in", "auto_apply": 1.0, "sandbox": true, "description": "Auto-phase, manual decisions" },
{ "name": "supervised", "source": "built-in", "auto_apply": 1.0, "sandbox": true, "description": "Auto-plan, manual exec" },
{ "name": "cautious", "source": "built-in", "auto_apply": 1.0, "sandbox": true, "description": "Confidence-gated automation" },
{ "name": "trusted", "source": "built-in", "auto_apply": 1.0, "sandbox": true, "description": "Auto-exec, manual apply" },
{ "name": "auto", "source": "built-in", "auto_apply": 1.0, "sandbox": true, "description": "Full auto except apply" },
{ "name": "ci", "source": "built-in", "auto_apply": 0.0, "sandbox": true, "description": "Full auto, safe CI/CD" },
{ "name": "full-auto", "source": "built-in", "auto_apply": 0.0, "sandbox": false, "description": "Complete automation" },
{ "name": "local/careful-auto", "source": "custom", "auto_apply": 0.8, "sandbox": true, "description": "Custom careful profile" }
{ "name": "manual", "source": "built-in", "select_tool": 1.0, "sandbox": true, "description": "Human-driven (default)" },
{ "name": "review", "source": "built-in", "select_tool": 1.0, "sandbox": true, "description": "Auto-phase, manual decisions" },
{ "name": "supervised", "source": "built-in", "select_tool": 1.0, "sandbox": true, "description": "Auto-plan, manual exec" },
{ "name": "cautious", "source": "built-in", "select_tool": 1.0, "sandbox": true, "description": "Confidence-gated automation" },
{ "name": "trusted", "source": "built-in", "select_tool": 1.0, "sandbox": true, "description": "Auto-exec, manual apply" },
{ "name": "auto", "source": "built-in", "select_tool": 1.0, "sandbox": true, "description": "Full auto except apply" },
{ "name": "ci", "source": "built-in", "select_tool": 0.0, "sandbox": true, "description": "Full auto, safe CI/CD" },
{ "name": "full-auto", "source": "built-in", "select_tool": 0.0, "sandbox": false, "description": "Complete automation" },
{ "name": "local/careful-auto", "source": "custom", "select_tool": 0.8, "sandbox": true, "description": "Custom careful profile" }
],
"summary": { "built_in": 8, "custom": 1, "total": 9 }
},
@@ -17023,47 +17023,47 @@ List all available automation profiles (built-in and custom).
profiles:
- name: manual
source: built-in
auto_apply: 1.0
select_tool: 1.0
sandbox: true
description: "Human-driven (default)"
- name: review
source: built-in
auto_apply: 1.0
select_tool: 1.0
sandbox: true
description: "Auto-phase, manual decisions"
- name: supervised
source: built-in
auto_apply: 1.0
select_tool: 1.0
sandbox: true
description: "Auto-plan, manual exec"
- name: cautious
source: built-in
auto_apply: 1.0
select_tool: 1.0
sandbox: true
description: "Confidence-gated automation"
- name: trusted
source: built-in
auto_apply: 1.0
select_tool: 1.0
sandbox: true
description: "Auto-exec, manual apply"
- name: auto
source: built-in
auto_apply: 1.0
select_tool: 1.0
sandbox: true
description: "Full auto except apply"
- name: ci
source: built-in
auto_apply: 0.0
select_tool: 0.0
sandbox: true
description: "Full auto, safe CI/CD"
- name: full-auto
source: built-in
auto_apply: 0.0
select_tool: 0.0
sandbox: false
description: "Complete automation"
- name: local/careful-auto
source: custom
auto_apply: 0.8
select_tool: 0.8
sandbox: true
description: "Custom careful profile"
summary:
@@ -17102,25 +17102,26 @@ Show full details for an automation profile, including all flag values.
╰────────────────────────────────────────────────────────────────╯
╭─ Phase Transitions (thresholds) ─────╮
│ <span style="color: #66cc66; font-weight: 600;">auto_strategize:</span> 0.0 │
│ <span style="color: #66cc66; font-weight: 600;">auto_execute:</span> 0.0 │
│ <span style="color: #ff6666; font-weight: 600;">auto_apply:</span> 1.0 │
│ <span style="color: #66cc66; font-weight: 600;">decompose_task:</span> 0.0 │
│ <span style="color: #66cc66; font-weight: 600;">create_tool:</span> 0.0 │
│ <span style="color: #ff6666; font-weight: 600;">select_tool:</span> 1.0 │
╰──────────────────────────────────────╯
╭─ Decision Automation (thresholds) ───╮
│ <span style="color: #66cc66; font-weight: 600;">auto_decisions_strategize:</span> 0.0 │
│ <span style="color: #66cc66; font-weight: 600;">auto_decisions_execute:</span> 0.0 │
│ <span style="color: #66cc66; font-weight: 600;">edit_code:</span> 0.0 │
│ <span style="color: #66cc66; font-weight: 600;">execute_command:</span> 0.0 │
╰──────────────────────────────────────╯
╭─ Self-Repair (thresholds) ───────────╮
│ <span style="color: #66cc66; font-weight: 600;">auto_validation_fix:</span> 0.0 │
│ <span style="color: #ff6666; font-weight: 600;">auto_strategy_revision:</span> 1.0 │
│ <span style="color: #66cc66; font-weight: 600;">auto_retry_transient:</span> 0.0
│ <span style="color: #ff6666; font-weight: 600;">auto_checkpoint_restore:</span> 1.0 │
│ <span style="color: #66cc66; font-weight: 600;">create_file:</span> 0.0 │
│ <span style="color: #ff6666; font-weight: 600;">delete_content:</span> 1.0 │
│ <span style="color: #ff6666; font-weight: 600;">access_network:</span> 1.0 │
│ <span style="color: #66cc66; font-weight: 600;">modify_config:</span> 0.0
│ <span style="color: #ff6666; font-weight: 600;">approve_plan:</span> 1.0 │
╰──────────────────────────────────────╯
╭─ Execution Controls (thresholds) ────╮
│ <span style="color: #66cc66; font-weight: 600;">auto_child_plans:</span> 0.0 │
│ <span style="color: #66cc66; font-weight: 600;">install_dependency:</span> 0.0 │
│ <span style="color: #66cc66; font-weight: 600;">require_sandbox:</span> true │
│ <span style="color: #66cc66; font-weight: 600;">require_checkpoints:</span> true │
│ <span style="color: #ff6666; font-weight: 600;">allow_unsafe_tools:</span> false │
@@ -17140,22 +17141,23 @@ Show full details for an automation profile, including all flag values.
Description: Auto-exec, manual apply. Day-to-day development
Phase Transitions (thresholds)
auto_strategize: 0.0
auto_execute: 0.0
auto_apply: 1.0
decompose_task: 0.0
create_tool: 0.0
select_tool: 1.0
Decision Automation (thresholds)
auto_decisions_strategize: 0.0
auto_decisions_execute: 0.0
edit_code: 0.0
execute_command: 0.0
Self-Repair (thresholds)
auto_validation_fix: 0.0
auto_strategy_revision: 1.0
auto_retry_transient: 0.0
auto_checkpoint_restore: 1.0
create_file: 0.0
delete_content: 1.0
access_network: 1.0
modify_config: 0.0
approve_plan: 1.0
Execution Controls (thresholds)
auto_child_plans: 0.0
install_dependency: 0.0
require_sandbox: true
require_checkpoints: true
allow_unsafe_tools: false
@@ -17175,22 +17177,23 @@ Show full details for an automation profile, including all flag values.
"source": "built-in",
"description": "Auto-exec, manual apply. Day-to-day development",
"phase_transitions": {
"auto_strategize": 0.0,
"auto_execute": 0.0,
"auto_apply": 1.0
"decompose_task": 0.0,
"create_tool": 0.0,
"select_tool": 1.0
},
"decision_automation": {
"auto_decisions_strategize": 0.0,
"auto_decisions_execute": 0.0
"edit_code": 0.0,
"execute_command": 0.0
},
"self_repair": {
"auto_validation_fix": 0.0,
"auto_strategy_revision": 1.0,
"auto_retry_transient": 0.0,
"auto_checkpoint_restore": 1.0
"create_file": 0.0,
"delete_content": 1.0,
"access_network": 1.0,
"modify_config": 0.0,
"approve_plan": 1.0
},
"execution_controls": {
"auto_child_plans": 0.0,
"install_dependency": 0.0,
"require_sandbox": true,
"require_checkpoints": true,
"allow_unsafe_tools": false
@@ -17212,19 +17215,20 @@ Show full details for an automation profile, including all flag values.
source: built-in
description: "Auto-exec, manual apply. Day-to-day development"
phase_transitions:
auto_strategize: 0.0
auto_execute: 0.0
auto_apply: 1.0
decompose_task: 0.0
create_tool: 0.0
select_tool: 1.0
decision_automation:
auto_decisions_strategize: 0.0
auto_decisions_execute: 0.0
edit_code: 0.0
execute_command: 0.0
self_repair:
auto_validation_fix: 0.0
auto_strategy_revision: 1.0
auto_retry_transient: 0.0
auto_checkpoint_restore: 1.0
create_file: 0.0
delete_content: 1.0
access_network: 1.0
modify_config: 0.0
approve_plan: 1.0
execution_controls:
auto_child_plans: 0.0
install_dependency: 0.0
require_sandbox: true
require_checkpoints: true
allow_unsafe_tools: false
@@ -18227,14 +18231,14 @@ While the normal phase progression is forward (Action → Strategize → Execute
* **Trigger:** During execution, the execution actor discovers that constraints established during Strategize are too restrictive to complete the work. For example, a strategy decision may have mandated an approach that proves infeasible once actual resources are examined, dependencies are resolved, or implementation details are encountered.
* **Behavior:** Rather than overriding or silently violating Strategize-phase decisions, the plan reverts to the Strategize phase so the strategy actor can adjust the decision tree. Execute-phase decisions must always be constrained by Strategize-phase decisions — if those constraints cannot be honored, the correct response is reversion, not violation.
* **After reversion:** The strategy actor receives the execution actor's findings (the reason for reversion, the specific constraints that were too restrictive) and produces an updated decision tree. The plan then re-enters the Execute phase with the revised strategy.
* **Automation:** Controlled by the `auto_strategy_revision` automation profile flag.
* **Automation:** Controlled by the `delete_content` automation profile flag.
##### Apply → Strategize
* **Trigger:** During the Apply phase, the system determines that the changeset cannot be successfully applied within the current strategy's constraints. Examples include: merge conflicts that violate invariants, validation failures at apply time that cannot be resolved within the strategy's scope, or resource state drift that contradicts strategy assumptions.
* **Behavior:** The plan enters the `constrained` terminal state within the Apply phase. From this state, the plan may revert to Strategize either automatically (if the `auto_reversion_from_apply` automation profile flag allows it) or after manual user approval.
* **Behavior:** The plan enters the `constrained` terminal state within the Apply phase. From this state, the plan may revert to Strategize either automatically (if the `access_network` automation profile flag allows it) or after manual user approval.
* **After reversion:** The strategy actor receives the Apply phase's findings (the constraint violations, the specific issues encountered) and produces an updated decision tree. The plan then progresses forward again through Execute and Apply with the revised strategy.
* **Automation:** Controlled by the `auto_reversion_from_apply` automation profile flag (separate from `auto_strategy_revision`, which governs Execute → Strategize reversion).
* **Automation:** Controlled by the `access_network` automation profile flag (separate from `delete_content`, which governs Execute → Strategize reversion).
#### Plan States (Per Phase)
@@ -18505,12 +18509,12 @@ Who makes decisions depends on the plan's **automation profile**:
| Profile Flag | Who Makes Decisions |
|-------------|---------------------|
| `auto_decisions_strategize = 1.0` (always manual) | User is prompted for each decision point during Strategize |
| `auto_decisions_strategize = 0.0` (always automatic) | Strategy actor makes decisions autonomously, records reasoning |
| `auto_decisions_execute = 1.0` (always manual) | User is prompted for each decision point during Execute |
| `auto_decisions_execute = 0.0` (always automatic) | Execution actor makes decisions autonomously |
| `edit_code = 1.0` (always manual) | User is prompted for each decision point during Strategize |
| `edit_code = 0.0` (always automatic) | Strategy actor makes decisions autonomously, records reasoning |
| `execute_command = 1.0` (always manual) | User is prompted for each decision point during Execute |
| `execute_command = 0.0` (always automatic) | Execution actor makes decisions autonomously |
Intermediate thresholds (e.g., `auto_decisions_strategize = 0.7`) cause the system to auto-decide only when the Semantic Escalation confidence score meets or exceeds the threshold; otherwise the user is prompted.
Intermediate thresholds (e.g., `edit_code = 0.7`) cause the system to auto-decide only when the Semantic Escalation confidence score meets or exceeds the threshold; otherwise the user is prompted.
When **automation allows automatic decisions**, the strategy actor uses its best judgment based on context, and records its reasoning in the decision's `rationale` field.
@@ -18662,7 +18666,7 @@ The `record_decision` tool accepts the decision type, question, chosen option, a
!!! warning "Execute-Phase Checkpoint Trigger"
In the Execute phase, `record_decision` is treated as a **write operation** for checkpoint purposes. The system automatically creates a **coordinated checkpoint group** — one checkpoint per modified sandbox resource — at every Execute-phase decision point. This creates a 1:1 mapping between decisions and resource states, enabling fine-grained rollback to any Execute-phase decision (see *Correcting Plans* in the Behavior section).
**Automation profile integration**: When `record_decision` is called, the system checks the confidence score against the applicable threshold (`auto_decisions_strategize` or `auto_decisions_execute`). If confidence is below the threshold, execution pauses and the decision is presented to the user for approval or override.
**Automation profile integration**: When `record_decision` is called, the system checks the confidence score against the applicable threshold (`edit_code` or `execute_command`). If confidence is below the threshold, execution pauses and the decision is presented to the user for approval or override.
##### Decision Record Structure
@@ -19700,7 +19704,7 @@ Apply should perform (configurable) validations before committing:
* **Diff review gate**
* If the `auto_apply` threshold is not met (i.e., confidence < threshold, or threshold is `1.0`) in the automation profile, show:
* If the `select_tool` threshold is not met (i.e., confidence < threshold, or threshold is `1.0`) in the automation profile, show:
* changed files summary,
* full diff,
@@ -19744,7 +19748,7 @@ Apply is the final phase. It does not transition to another phase — instead, t
* plan.phase = `apply`
* plan.state = `constrained`
* the Apply phase has determined that the current strategy's constraints prevent successful application (e.g., merge conflicts that violate invariants, validation failures that cannot be resolved within the strategy's scope, resource state drift that contradicts strategy assumptions)
* depending on the `auto_reversion_from_apply` automation profile flag, this may automatically trigger a reversion to Strategize, or the system may pause for user decision
* depending on the `access_network` automation profile flag, this may automatically trigger a reversion to Strategize, or the system may pause for user decision
* sandbox remains intact pending reversion or user action
**When Apply fails:**
@@ -22485,7 +22489,7 @@ When a **required** validation returns `"passed": false` during Execute:
4. **Retry limit**: The fix-then-revalidate loop runs up to the configured retry limit (default: 3 attempts, configurable per plan or in the automation profile). After the limit is reached, self-fix stops.
5. **Strategy revision**: If the actor determines that the failure cannot be resolved within the current strategy's constraints (e.g., the strategy says "modify only `handler.py`" but the test failure requires changes to `model.py`), it may request a **strategy revision**. This triggers a re-run of the Strategize phase for the affected subtree of the decision tree. Whether this happens automatically or requires user approval depends on the automation profile's `auto_strategy_revision` flag.
5. **Strategy revision**: If the actor determines that the failure cannot be resolved within the current strategy's constraints (e.g., the strategy says "modify only `handler.py`" but the test failure requires changes to `model.py`), it may request a **strategy revision**. This triggers a re-run of the Strategize phase for the affected subtree of the decision tree. Whether this happens automatically or requires user approval depends on the automation profile's `delete_content` flag.
6. **Escalation**: If strategy revision also fails, or if the automation profile requires human approval for strategy changes, the plan pauses and requests user guidance via `agents plan prompt`:
@@ -28326,17 +28330,17 @@ Each automation profile specifies a **confidence threshold** (a floating-point v
| Flag | Type | Description | Behavior |
|------|------|-------------|----------|
| `auto_strategize` | float (0.01.0) | Automatically enter Strategize after `plan use` | When confidence >= threshold, Strategize begins immediately. Below threshold, system pauses after plan creation for user confirmation before entering Strategize. |
| `auto_execute` | float (0.01.0) | Automatically proceed from Strategize to Execute | When confidence >= threshold, Execute begins when Strategize completes. Below threshold, system pauses for user review. |
| `auto_apply` | float (0.01.0) | Automatically proceed from Execute to Apply | When confidence >= threshold, Apply begins when Execute completes. Below threshold, system pauses for user diff review. |
| `auto_decisions_strategize` | float (0.01.0) | Automatically make decisions during Strategize | When confidence >= threshold, the strategy actor makes the decision autonomously. Below threshold, system pauses at the decision point for user input. |
| `auto_decisions_execute` | float (0.01.0) | Automatically make decisions during Execute | When confidence >= threshold, the execution actor makes the decision autonomously. Below threshold, system pauses at the decision point for user input. |
| `auto_validation_fix` | float (0.01.0) | Automatically attempt to fix validation failures | When confidence >= threshold, execution actor self-fixes failing validations. Below threshold, system pauses for user guidance. |
| `auto_strategy_revision` | float (0.01.0) | Automatically revise strategy when Execute hits constraints | When confidence >= threshold, system re-runs Strategize for affected subtree. Below threshold, system pauses and asks user. |
| `auto_reversion_from_apply` | float (0.01.0) | Automatically revert from Apply (`constrained` state) to Strategize | When confidence >= threshold, a `constrained` Apply automatically triggers reversion to Strategize. Below threshold, system pauses and asks user whether to revert or cancel. |
| `auto_child_plans` | float (0.01.0) | Automatically spawn and execute child plans | When confidence >= threshold, child plans are created and executed without pausing. Below threshold, each spawn requires approval. |
| `auto_retry_transient` | float (0.01.0) | Automatically retry on transient failures (network, timeout, rate-limit) | When confidence >= threshold, system retries with backoff. Below threshold, system pauses and asks user. |
| `auto_checkpoint_restore` | float (0.01.0) | Automatically restore from checkpoint on failure | When confidence >= threshold, system rolls back and retries. Below threshold, user decides whether to restore. |
| `decompose_task` | float (0.01.0) | Automatically enter Strategize after `plan use` | When confidence >= threshold, Strategize begins immediately. Below threshold, system pauses after plan creation for user confirmation before entering Strategize. |
| `create_tool` | float (0.01.0) | Automatically proceed from Strategize to Execute | When confidence >= threshold, Execute begins when Strategize completes. Below threshold, system pauses for user review. |
| `select_tool` | float (0.01.0) | Automatically proceed from Execute to Apply | When confidence >= threshold, Apply begins when Execute completes. Below threshold, system pauses for user diff review. |
| `edit_code` | float (0.01.0) | Automatically make decisions during Strategize | When confidence >= threshold, the strategy actor makes the decision autonomously. Below threshold, system pauses at the decision point for user input. |
| `execute_command` | float (0.01.0) | Automatically make decisions during Execute | When confidence >= threshold, the execution actor makes the decision autonomously. Below threshold, system pauses at the decision point for user input. |
| `create_file` | float (0.01.0) | Automatically attempt to fix validation failures | When confidence >= threshold, execution actor self-fixes failing validations. Below threshold, system pauses for user guidance. |
| `delete_content` | float (0.01.0) | Automatically revise strategy when Execute hits constraints | When confidence >= threshold, system re-runs Strategize for affected subtree. Below threshold, system pauses and asks user. |
| `access_network` | float (0.01.0) | Automatically revert from Apply (`constrained` state) to Strategize | When confidence >= threshold, a `constrained` Apply automatically triggers reversion to Strategize. Below threshold, system pauses and asks user whether to revert or cancel. |
| `install_dependency` | float (0.01.0) | Automatically spawn and execute child plans | When confidence >= threshold, child plans are created and executed without pausing. Below threshold, each spawn requires approval. |
| `modify_config` | float (0.01.0) | Automatically retry on transient failures (network, timeout, rate-limit) | When confidence >= threshold, system retries with backoff. Below threshold, system pauses and asks user. |
| `approve_plan` | float (0.01.0) | Automatically restore from checkpoint on failure | When confidence >= threshold, system rolls back and retries. Below threshold, user decides whether to restore. |
#### Safety Profile (Composed Sub-Model)
@@ -28368,17 +28372,17 @@ Threshold values are shown for each flag. A value of **0.0** means always automa
| Flag | `manual` | `review` | `supervised` | `cautious` | `trusted` | `auto` | `ci` | `full-auto` |
|------|:---:|:---:|:---:|:---:|:---:|:---:|:---:|:---:|
| `auto_strategize` | 1.0 | 0.0 | 0.0 | 0.7 | 0.0 | 0.0 | 0.0 | 0.0 |
| `auto_execute` | 1.0 | 0.0 | 1.0 | 0.7 | 0.0 | 0.0 | 0.0 | 0.0 |
| `auto_apply` | 1.0 | 1.0 | 1.0 | 1.0 | 1.0 | 1.0 | 0.0 | 0.0 |
| `auto_decisions_strategize` | 1.0 | 1.0 | 0.0 | 0.6 | 0.0 | 0.0 | 0.0 | 0.0 |
| `auto_decisions_execute` | 1.0 | 1.0 | 1.0 | 0.8 | 0.0 | 0.0 | 0.0 | 0.0 |
| `auto_validation_fix` | 1.0 | 1.0 | 1.0 | 0.7 | 0.0 | 0.0 | 0.0 | 0.0 |
| `auto_strategy_revision` | 1.0 | 1.0 | 1.0 | 0.8 | 1.0 | 0.0 | 0.0 | 0.0 |
| `auto_reversion_from_apply` | 1.0 | 1.0 | 1.0 | 0.9 | 1.0 | 1.0 | 0.0 | 0.0 |
| `auto_child_plans` | 1.0 | 0.0 | 1.0 | 0.7 | 0.0 | 0.0 | 0.0 | 0.0 |
| `auto_retry_transient` | 1.0 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 |
| `auto_checkpoint_restore` | 1.0 | 1.0 | 1.0 | 0.6 | 1.0 | 0.0 | 0.0 | 0.0 |
| `decompose_task` | 1.0 | 0.0 | 0.0 | 0.7 | 0.0 | 0.0 | 0.0 | 0.0 |
| `create_tool` | 1.0 | 0.0 | 1.0 | 0.7 | 0.0 | 0.0 | 0.0 | 0.0 |
| `select_tool` | 1.0 | 1.0 | 1.0 | 1.0 | 1.0 | 1.0 | 0.0 | 0.0 |
| `edit_code` | 1.0 | 1.0 | 0.0 | 0.6 | 0.0 | 0.0 | 0.0 | 0.0 |
| `execute_command` | 1.0 | 1.0 | 1.0 | 0.8 | 0.0 | 0.0 | 0.0 | 0.0 |
| `create_file` | 1.0 | 1.0 | 1.0 | 0.7 | 0.0 | 0.0 | 0.0 | 0.0 |
| `delete_content` | 1.0 | 1.0 | 1.0 | 0.8 | 1.0 | 0.0 | 0.0 | 0.0 |
| `access_network` | 1.0 | 1.0 | 1.0 | 0.9 | 1.0 | 1.0 | 0.0 | 0.0 |
| `install_dependency` | 1.0 | 0.0 | 1.0 | 0.7 | 0.0 | 0.0 | 0.0 | 0.0 |
| `modify_config` | 1.0 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 |
| `approve_plan` | 1.0 | 1.0 | 1.0 | 0.6 | 1.0 | 0.0 | 0.0 | 0.0 |
| **Safety Profile** | | | | | | | | |
| `safety.require_sandbox` | true | true | true | true | true | true | true | false |
| `safety.require_checkpoints` | true | true | true | true | true | true | true | false |
@@ -28430,17 +28434,17 @@ Custom profiles are created via YAML configuration files and registered with `ag
<span style="color: cyan; font-weight: 600;">description</span>: <span style="color: #66cc66;">&quot;Autonomous execution with mandatory sandbox and manual apply&quot;</span>
<span style="opacity: 0.7;"># Confidence thresholds (0.0 = always auto, 1.0 = always manual)</span>
<span style="color: cyan; font-weight: 600;">auto_strategize</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_execute</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_apply</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">auto_decisions_strategize</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_decisions_execute</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_validation_fix</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_strategy_revision</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">auto_reversion_from_apply</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">auto_child_plans</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_retry_transient</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_checkpoint_restore</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">decompose_task</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">create_tool</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">select_tool</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">edit_code</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">execute_command</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">create_file</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">delete_content</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">access_network</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">install_dependency</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">modify_config</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">approve_plan</span>: <span style="color: yellow;">0.0</span>
<span style="opacity: 0.7;"># Safety profile (composed sub-model)</span>
<span style="color: cyan; font-weight: 600;">safety</span>:
@@ -28449,24 +28453,24 @@ Custom profiles are created via YAML configuration files and registered with `ag
<span style="color: cyan; font-weight: 600;">allow_unsafe_tools</span>: <span style="color: magenta; font-weight: 600;">false</span>
</code></pre></div>
A profile with intermediate thresholds provides nuanced control. For example, `auto_decisions_execute: 0.7` means decisions during Execute proceed automatically when confidence >= 0.7, but drop to manual review when confidence is below 0.7:
A profile with intermediate thresholds provides nuanced control. For example, `execute_command: 0.7` means decisions during Execute proceed automatically when confidence >= 0.7, but drop to manual review when confidence is below 0.7:
<div class="highlight"><pre><code>
<span style="opacity: 0.7;"># File: profiles/nuanced-auto.yaml</span>
<span style="color: cyan; font-weight: 600;">name</span>: local/nuanced-auto
<span style="color: cyan; font-weight: 600;">description</span>: <span style="color: #66cc66;">&quot;Nuanced automation with graduated confidence thresholds&quot;</span>
<span style="color: cyan; font-weight: 600;">auto_strategize</span>: <span style="color: yellow;">0.0</span><span style="opacity: 0.7;"> # Always auto-strategize</span>
<span style="color: cyan; font-weight: 600;">auto_execute</span>: <span style="color: yellow;">0.5</span><span style="opacity: 0.7;"> # Auto-execute when confidence >= 0.5</span>
<span style="color: cyan; font-weight: 600;">auto_apply</span>: <span style="color: yellow;">1.0</span><span style="opacity: 0.7;"> # Always require manual apply</span>
<span style="color: cyan; font-weight: 600;">auto_decisions_strategize</span>: <span style="color: yellow;">0.3</span><span style="opacity: 0.7;"> # Low bar for strategy decisions</span>
<span style="color: cyan; font-weight: 600;">auto_decisions_execute</span>: <span style="color: yellow;">0.7</span><span style="opacity: 0.7;"> # Higher bar for execution decisions</span>
<span style="color: cyan; font-weight: 600;">auto_validation_fix</span>: <span style="color: yellow;">0.5</span><span style="opacity: 0.7;"> # Auto-fix when reasonably confident</span>
<span style="color: cyan; font-weight: 600;">auto_strategy_revision</span>: <span style="color: yellow;">0.8</span><span style="opacity: 0.7;"> # High confidence needed for auto-revision</span>
<span style="color: cyan; font-weight: 600;">auto_reversion_from_apply</span>: <span style="color: yellow;">0.9</span><span style="opacity: 0.7;"> # Very high bar for late-stage reversion</span>
<span style="color: cyan; font-weight: 600;">auto_child_plans</span>: <span style="color: yellow;">0.5</span><span style="opacity: 0.7;"> # Auto-spawn when moderately confident</span>
<span style="color: cyan; font-weight: 600;">auto_retry_transient</span>: <span style="color: yellow;">0.0</span><span style="opacity: 0.7;"> # Always auto-retry transient errors</span>
<span style="color: cyan; font-weight: 600;">auto_checkpoint_restore</span>: <span style="color: yellow;">0.6</span><span style="opacity: 0.7;"> # Auto-restore when fairly confident</span>
<span style="color: cyan; font-weight: 600;">decompose_task</span>: <span style="color: yellow;">0.0</span><span style="opacity: 0.7;"> # Always auto-strategize</span>
<span style="color: cyan; font-weight: 600;">create_tool</span>: <span style="color: yellow;">0.5</span><span style="opacity: 0.7;"> # Auto-execute when confidence >= 0.5</span>
<span style="color: cyan; font-weight: 600;">select_tool</span>: <span style="color: yellow;">1.0</span><span style="opacity: 0.7;"> # Always require manual apply</span>
<span style="color: cyan; font-weight: 600;">edit_code</span>: <span style="color: yellow;">0.3</span><span style="opacity: 0.7;"> # Low bar for strategy decisions</span>
<span style="color: cyan; font-weight: 600;">execute_command</span>: <span style="color: yellow;">0.7</span><span style="opacity: 0.7;"> # Higher bar for execution decisions</span>
<span style="color: cyan; font-weight: 600;">create_file</span>: <span style="color: yellow;">0.5</span><span style="opacity: 0.7;"> # Auto-fix when reasonably confident</span>
<span style="color: cyan; font-weight: 600;">delete_content</span>: <span style="color: yellow;">0.8</span><span style="opacity: 0.7;"> # High confidence needed for auto-revision</span>
<span style="color: cyan; font-weight: 600;">access_network</span>: <span style="color: yellow;">0.9</span><span style="opacity: 0.7;"> # Very high bar for late-stage reversion</span>
<span style="color: cyan; font-weight: 600;">install_dependency</span>: <span style="color: yellow;">0.5</span><span style="opacity: 0.7;"> # Auto-spawn when moderately confident</span>
<span style="color: cyan; font-weight: 600;">modify_config</span>: <span style="color: yellow;">0.0</span><span style="opacity: 0.7;"> # Always auto-retry transient errors</span>
<span style="color: cyan; font-weight: 600;">approve_plan</span>: <span style="color: yellow;">0.6</span><span style="opacity: 0.7;"> # Auto-restore when fairly confident</span>
<span style="opacity: 0.7;"># Safety profile (composed sub-model)</span>
<span style="color: cyan; font-weight: 600;">safety</span>:
@@ -28497,7 +28501,7 @@ The confidence score is computed from multiple factors:
}
confidence = self.compute_confidence(factors) <span style="opacity: 0.7;"># Returns 0.01.0</span>
threshold = profile.get_threshold(decision.flag) <span style="opacity: 0.7;"># e.g., auto_decisions_execute</span>
threshold = profile.get_threshold(decision.flag) <span style="opacity: 0.7;"># e.g., execute_command</span>
<span style="color: magenta; font-weight: 600;">if</span> confidence &gt;= threshold:
<span style="opacity: 0.7;"># Confidence meets or exceeds the profile threshold — proceed</span>
@@ -28507,7 +28511,7 @@ The confidence score is computed from multiple factors:
<span style="color: magenta; font-weight: 600;">return</span> RequestHumanGuidance(decision, confidence, threshold, factors)
</code></pre></div>
**How thresholds and confidence interact**: A profile with `auto_decisions_execute: 0.7` means the system will make execution decisions automatically when confidence >= 0.7, but will pause for human input when confidence < 0.7. This is more nuanced than a binary on/off: a profile can set a high bar (0.9) for risky operations while being permissive (0.2) for low-risk ones.
**How thresholds and confidence interact**: A profile with `execute_command: 0.7` means the system will make execution decisions automatically when confidence >= 0.7, but will pause for human input when confidence < 0.7. This is more nuanced than a binary on/off: a profile can set a high bar (0.9) for risky operations while being permissive (0.2) for low-risk ones.
**Special cases**: A threshold of **0.0** means "always automatic" — even zero confidence passes the threshold. A threshold of **1.0** means "always manual" — no confidence level (which tops out below 1.0 in practice) is high enough to pass. This means the old boolean behavior is a strict subset: `true` maps to `0.0` and `false` maps to `1.0`.
@@ -35535,67 +35539,67 @@ The following is the formal [JSON Schema](https://json-schema.org/) definition f
<span style="color: cyan; font-weight: 600;">&quot;type&quot;</span>: <span style="color: #66cc66;">&quot;string&quot;</span>,
<span style="color: cyan; font-weight: 600;">&quot;description&quot;</span>: <span style="color: #66cc66;">&quot;Human-readable description of the profile&#x27;s purpose and behavior.&quot;</span>
},
<span style="color: cyan; font-weight: 600;">&quot;auto_strategize&quot;</span>: {
<span style="color: cyan; font-weight: 600;">&quot;decompose_task&quot;</span>: {
<span style="color: cyan; font-weight: 600;">&quot;type&quot;</span>: <span style="color: #66cc66;">&quot;number&quot;</span>,
<span style="color: cyan; font-weight: 600;">&quot;minimum&quot;</span>: <span style="color: magenta; font-weight: 600;">0.0</span>,
<span style="color: cyan; font-weight: 600;">&quot;maximum&quot;</span>: <span style="color: magenta; font-weight: 600;">1.0</span>,
<span style="color: cyan; font-weight: 600;">&quot;description&quot;</span>: <span style="color: #66cc66;">&quot;Confidence threshold (0.0-1.0) for automatically transitioning from Action to Strategize. 0.0 = always automatic, 1.0 = always manual.&quot;</span>
},
<span style="color: cyan; font-weight: 600;">&quot;auto_execute&quot;</span>: {
<span style="color: cyan; font-weight: 600;">&quot;create_tool&quot;</span>: {
<span style="color: cyan; font-weight: 600;">&quot;type&quot;</span>: <span style="color: #66cc66;">&quot;number&quot;</span>,
<span style="color: cyan; font-weight: 600;">&quot;minimum&quot;</span>: <span style="color: magenta; font-weight: 600;">0.0</span>,
<span style="color: cyan; font-weight: 600;">&quot;maximum&quot;</span>: <span style="color: magenta; font-weight: 600;">1.0</span>,
<span style="color: cyan; font-weight: 600;">&quot;description&quot;</span>: <span style="color: #66cc66;">&quot;Confidence threshold (0.0-1.0) for automatically transitioning from Strategize to Execute. 0.0 = always automatic, 1.0 = always manual.&quot;</span>
},
<span style="color: cyan; font-weight: 600;">&quot;auto_apply&quot;</span>: {
<span style="color: cyan; font-weight: 600;">&quot;select_tool&quot;</span>: {
<span style="color: cyan; font-weight: 600;">&quot;type&quot;</span>: <span style="color: #66cc66;">&quot;number&quot;</span>,
<span style="color: cyan; font-weight: 600;">&quot;minimum&quot;</span>: <span style="color: magenta; font-weight: 600;">0.0</span>,
<span style="color: cyan; font-weight: 600;">&quot;maximum&quot;</span>: <span style="color: magenta; font-weight: 600;">1.0</span>,
<span style="color: cyan; font-weight: 600;">&quot;description&quot;</span>: <span style="color: #66cc66;">&quot;Confidence threshold (0.0-1.0) for automatically applying changes after execution completes. 0.0 = always automatic, 1.0 = always manual.&quot;</span>
},
<span style="color: cyan; font-weight: 600;">&quot;auto_decisions_strategize&quot;</span>: {
<span style="color: cyan; font-weight: 600;">&quot;edit_code&quot;</span>: {
<span style="color: cyan; font-weight: 600;">&quot;type&quot;</span>: <span style="color: #66cc66;">&quot;number&quot;</span>,
<span style="color: cyan; font-weight: 600;">&quot;minimum&quot;</span>: <span style="color: magenta; font-weight: 600;">0.0</span>,
<span style="color: cyan; font-weight: 600;">&quot;maximum&quot;</span>: <span style="color: magenta; font-weight: 600;">1.0</span>,
<span style="color: cyan; font-weight: 600;">&quot;description&quot;</span>: <span style="color: #66cc66;">&quot;Confidence threshold (0.0-1.0) for autonomously making decisions during Strategize. 0.0 = always automatic, 1.0 = always manual.&quot;</span>
},
<span style="color: cyan; font-weight: 600;">&quot;auto_decisions_execute&quot;</span>: {
<span style="color: cyan; font-weight: 600;">&quot;execute_command&quot;</span>: {
<span style="color: cyan; font-weight: 600;">&quot;type&quot;</span>: <span style="color: #66cc66;">&quot;number&quot;</span>,
<span style="color: cyan; font-weight: 600;">&quot;minimum&quot;</span>: <span style="color: magenta; font-weight: 600;">0.0</span>,
<span style="color: cyan; font-weight: 600;">&quot;maximum&quot;</span>: <span style="color: magenta; font-weight: 600;">1.0</span>,
<span style="color: cyan; font-weight: 600;">&quot;description&quot;</span>: <span style="color: #66cc66;">&quot;Confidence threshold (0.0-1.0) for autonomously making decisions during Execute. 0.0 = always automatic, 1.0 = always manual.&quot;</span>
},
<span style="color: cyan; font-weight: 600;">&quot;auto_validation_fix&quot;</span>: {
<span style="color: cyan; font-weight: 600;">&quot;create_file&quot;</span>: {
<span style="color: cyan; font-weight: 600;">&quot;type&quot;</span>: <span style="color: #66cc66;">&quot;number&quot;</span>,
<span style="color: cyan; font-weight: 600;">&quot;minimum&quot;</span>: <span style="color: magenta; font-weight: 600;">0.0</span>,
<span style="color: cyan; font-weight: 600;">&quot;maximum&quot;</span>: <span style="color: magenta; font-weight: 600;">1.0</span>,
<span style="color: cyan; font-weight: 600;">&quot;description&quot;</span>: <span style="color: #66cc66;">&quot;Confidence threshold (0.0-1.0) for automatically attempting to fix validation failures. 0.0 = always automatic, 1.0 = always manual.&quot;</span>
},
<span style="color: cyan; font-weight: 600;">&quot;auto_strategy_revision&quot;</span>: {
<span style="color: cyan; font-weight: 600;">&quot;delete_content&quot;</span>: {
<span style="color: cyan; font-weight: 600;">&quot;type&quot;</span>: <span style="color: #66cc66;">&quot;number&quot;</span>,
<span style="color: cyan; font-weight: 600;">&quot;minimum&quot;</span>: <span style="color: magenta; font-weight: 600;">0.0</span>,
<span style="color: cyan; font-weight: 600;">&quot;maximum&quot;</span>: <span style="color: magenta; font-weight: 600;">1.0</span>,
<span style="color: cyan; font-weight: 600;">&quot;description&quot;</span>: <span style="color: #66cc66;">&quot;Confidence threshold (0.0-1.0) for automatically revising the strategy when execution reveals issues. 0.0 = always automatic, 1.0 = always manual.&quot;</span>
},
<span style="color: cyan; font-weight: 600;">&quot;auto_reversion_from_apply&quot;</span>: {
<span style="color: cyan; font-weight: 600;">&quot;access_network&quot;</span>: {
<span style="color: cyan; font-weight: 600;">&quot;type&quot;</span>: <span style="color: #66cc66;">&quot;number&quot;</span>,
<span style="color: cyan; font-weight: 600;">&quot;minimum&quot;</span>: <span style="color: magenta; font-weight: 600;">0.0</span>,
<span style="color: cyan; font-weight: 600;">&quot;maximum&quot;</span>: <span style="color: magenta; font-weight: 600;">1.0</span>,
<span style="color: cyan; font-weight: 600;">&quot;description&quot;</span>: <span style="color: #66cc66;">&quot;Confidence threshold (0.0-1.0) for automatically reverting from a constrained Apply phase to Strategize. 0.0 = always automatic, 1.0 = always manual.&quot;</span>
},
<span style="color: cyan; font-weight: 600;">&quot;auto_retry_transient&quot;</span>: {
<span style="color: cyan; font-weight: 600;">&quot;modify_config&quot;</span>: {
<span style="color: cyan; font-weight: 600;">&quot;type&quot;</span>: <span style="color: #66cc66;">&quot;number&quot;</span>,
<span style="color: cyan; font-weight: 600;">&quot;minimum&quot;</span>: <span style="color: magenta; font-weight: 600;">0.0</span>,
<span style="color: cyan; font-weight: 600;">&quot;maximum&quot;</span>: <span style="color: magenta; font-weight: 600;">1.0</span>,
<span style="color: cyan; font-weight: 600;">&quot;description&quot;</span>: <span style="color: #66cc66;">&quot;Confidence threshold (0.0-1.0) for automatically retrying operations that fail due to transient errors. 0.0 = always automatic, 1.0 = always manual.&quot;</span>
},
<span style="color: cyan; font-weight: 600;">&quot;auto_checkpoint_restore&quot;</span>: {
<span style="color: cyan; font-weight: 600;">&quot;approve_plan&quot;</span>: {
<span style="color: cyan; font-weight: 600;">&quot;type&quot;</span>: <span style="color: #66cc66;">&quot;number&quot;</span>,
<span style="color: cyan; font-weight: 600;">&quot;minimum&quot;</span>: <span style="color: magenta; font-weight: 600;">0.0</span>,
<span style="color: cyan; font-weight: 600;">&quot;maximum&quot;</span>: <span style="color: magenta; font-weight: 600;">1.0</span>,
<span style="color: cyan; font-weight: 600;">&quot;description&quot;</span>: <span style="color: #66cc66;">&quot;Confidence threshold (0.0-1.0) for automatically restoring from the most recent checkpoint on failure. 0.0 = always automatic, 1.0 = always manual.&quot;</span>
},
<span style="color: cyan; font-weight: 600;">&quot;auto_child_plans&quot;</span>: {
<span style="color: cyan; font-weight: 600;">&quot;install_dependency&quot;</span>: {
<span style="color: cyan; font-weight: 600;">&quot;type&quot;</span>: <span style="color: #66cc66;">&quot;number&quot;</span>,
<span style="color: cyan; font-weight: 600;">&quot;minimum&quot;</span>: <span style="color: magenta; font-weight: 600;">0.0</span>,
<span style="color: cyan; font-weight: 600;">&quot;maximum&quot;</span>: <span style="color: magenta; font-weight: 600;">1.0</span>,
@@ -35617,17 +35621,17 @@ The following is the formal [JSON Schema](https://json-schema.org/) definition f
<span style="color: cyan; font-weight: 600;">&quot;required&quot;</span>: [
<span style="color: #66cc66;">&quot;name&quot;</span>,
<span style="color: #66cc66;">&quot;description&quot;</span>,
<span style="color: #66cc66;">&quot;auto_strategize&quot;</span>,
<span style="color: #66cc66;">&quot;auto_execute&quot;</span>,
<span style="color: #66cc66;">&quot;auto_apply&quot;</span>,
<span style="color: #66cc66;">&quot;auto_decisions_strategize&quot;</span>,
<span style="color: #66cc66;">&quot;auto_decisions_execute&quot;</span>,
<span style="color: #66cc66;">&quot;auto_validation_fix&quot;</span>,
<span style="color: #66cc66;">&quot;auto_strategy_revision&quot;</span>,
<span style="color: #66cc66;">&quot;auto_reversion_from_apply&quot;</span>,
<span style="color: #66cc66;">&quot;auto_retry_transient&quot;</span>,
<span style="color: #66cc66;">&quot;auto_checkpoint_restore&quot;</span>,
<span style="color: #66cc66;">&quot;auto_child_plans&quot;</span>,
<span style="color: #66cc66;">&quot;decompose_task&quot;</span>,
<span style="color: #66cc66;">&quot;create_tool&quot;</span>,
<span style="color: #66cc66;">&quot;select_tool&quot;</span>,
<span style="color: #66cc66;">&quot;edit_code&quot;</span>,
<span style="color: #66cc66;">&quot;execute_command&quot;</span>,
<span style="color: #66cc66;">&quot;create_file&quot;</span>,
<span style="color: #66cc66;">&quot;delete_content&quot;</span>,
<span style="color: #66cc66;">&quot;access_network&quot;</span>,
<span style="color: #66cc66;">&quot;modify_config&quot;</span>,
<span style="color: #66cc66;">&quot;approve_plan&quot;</span>,
<span style="color: #66cc66;">&quot;install_dependency&quot;</span>,
<span style="color: #66cc66;">&quot;require_sandbox&quot;</span>,
<span style="color: #66cc66;">&quot;require_checkpoints&quot;</span>,
<span style="color: #66cc66;">&quot;allow_unsafe_tools&quot;</span>
@@ -35648,25 +35652,25 @@ The following annotated YAML provides an easier-to-read overview of the same sch
<span style="opacity: 0.7;"># ─── Phase Transition Thresholds ────────────────────────────────────</span>
<span style="opacity: 0.7;"># Confidence thresholds controlling phase transitions.</span>
<span style="opacity: 0.7;"># 0.0 = always automatic, 1.0 = always manual.</span>
<span style="color: cyan; font-weight: 600;">auto_strategize</span>: <span style="color: #66cc66;">&lt;float: 0.01.0&gt;</span><span style="opacity: 0.7;"> # Confidence threshold for Action → Strategize (required, 0.0=auto, 1.0=manual)</span>
<span style="color: cyan; font-weight: 600;">auto_execute</span>: <span style="color: #66cc66;">&lt;float: 0.01.0&gt;</span><span style="opacity: 0.7;"> # Confidence threshold for Strategize → Execute (required, 0.0=auto, 1.0=manual)</span>
<span style="color: cyan; font-weight: 600;">auto_apply</span>: <span style="color: #66cc66;">&lt;float: 0.01.0&gt;</span><span style="opacity: 0.7;"> # Confidence threshold for Execute → Apply (required, 0.0=auto, 1.0=manual)</span>
<span style="color: cyan; font-weight: 600;">decompose_task</span>: <span style="color: #66cc66;">&lt;float: 0.01.0&gt;</span><span style="opacity: 0.7;"> # Confidence threshold for Action → Strategize (required, 0.0=auto, 1.0=manual)</span>
<span style="color: cyan; font-weight: 600;">create_tool</span>: <span style="color: #66cc66;">&lt;float: 0.01.0&gt;</span><span style="opacity: 0.7;"> # Confidence threshold for Strategize → Execute (required, 0.0=auto, 1.0=manual)</span>
<span style="color: cyan; font-weight: 600;">select_tool</span>: <span style="color: #66cc66;">&lt;float: 0.01.0&gt;</span><span style="opacity: 0.7;"> # Confidence threshold for Execute → Apply (required, 0.0=auto, 1.0=manual)</span>
<span style="opacity: 0.7;"># ─── Decision Thresholds ────────────────────────────────────────────</span>
<span style="opacity: 0.7;"># Confidence thresholds controlling decisions within each phase.</span>
<span style="opacity: 0.7;"># 0.0 = always automatic, 1.0 = always manual.</span>
<span style="color: cyan; font-weight: 600;">auto_decisions_strategize</span>: <span style="color: #66cc66;">&lt;float: 0.01.0&gt;</span><span style="opacity: 0.7;"> # Confidence threshold for decisions during Strategize (required, 0.0=auto, 1.0=manual)</span>
<span style="color: cyan; font-weight: 600;">auto_decisions_execute</span>: <span style="color: #66cc66;">&lt;float: 0.01.0&gt;</span><span style="opacity: 0.7;"> # Confidence threshold for decisions during Execute (required, 0.0=auto, 1.0=manual)</span>
<span style="color: cyan; font-weight: 600;">edit_code</span>: <span style="color: #66cc66;">&lt;float: 0.01.0&gt;</span><span style="opacity: 0.7;"> # Confidence threshold for decisions during Strategize (required, 0.0=auto, 1.0=manual)</span>
<span style="color: cyan; font-weight: 600;">execute_command</span>: <span style="color: #66cc66;">&lt;float: 0.01.0&gt;</span><span style="opacity: 0.7;"> # Confidence threshold for decisions during Execute (required, 0.0=auto, 1.0=manual)</span>
<span style="opacity: 0.7;"># ─── Self-Repair Thresholds ─────────────────────────────────────────</span>
<span style="color: cyan; font-weight: 600;">auto_validation_fix</span>: <span style="color: #66cc66;">&lt;float: 0.01.0&gt;</span><span style="opacity: 0.7;"> # Confidence threshold for auto-fixing validation failures (required, 0.0=auto, 1.0=manual)</span>
<span style="color: cyan; font-weight: 600;">auto_strategy_revision</span>: <span style="color: #66cc66;">&lt;float: 0.01.0&gt;</span><span style="opacity: 0.7;"> # Confidence threshold for auto-revising strategy when Execute hits constraints (required, 0.0=auto, 1.0=manual)</span>
<span style="color: cyan; font-weight: 600;">auto_reversion_from_apply</span>: <span style="color: #66cc66;">&lt;float: 0.01.0&gt;</span><span style="opacity: 0.7;"> # Confidence threshold for auto-reverting from constrained Apply to Strategize (required, 0.0=auto, 1.0=manual)</span>
<span style="color: cyan; font-weight: 600;">auto_retry_transient</span>: <span style="color: #66cc66;">&lt;float: 0.01.0&gt;</span><span style="opacity: 0.7;"> # Confidence threshold for auto-retrying transient errors (required, 0.0=auto, 1.0=manual)</span>
<span style="color: cyan; font-weight: 600;">auto_checkpoint_restore</span>: <span style="color: #66cc66;">&lt;float: 0.01.0&gt;</span><span style="opacity: 0.7;"> # Confidence threshold for auto-restoring from checkpoints (required, 0.0=auto, 1.0=manual)</span>
<span style="color: cyan; font-weight: 600;">create_file</span>: <span style="color: #66cc66;">&lt;float: 0.01.0&gt;</span><span style="opacity: 0.7;"> # Confidence threshold for auto-fixing validation failures (required, 0.0=auto, 1.0=manual)</span>
<span style="color: cyan; font-weight: 600;">delete_content</span>: <span style="color: #66cc66;">&lt;float: 0.01.0&gt;</span><span style="opacity: 0.7;"> # Confidence threshold for auto-revising strategy when Execute hits constraints (required, 0.0=auto, 1.0=manual)</span>
<span style="color: cyan; font-weight: 600;">access_network</span>: <span style="color: #66cc66;">&lt;float: 0.01.0&gt;</span><span style="opacity: 0.7;"> # Confidence threshold for auto-reverting from constrained Apply to Strategize (required, 0.0=auto, 1.0=manual)</span>
<span style="color: cyan; font-weight: 600;">modify_config</span>: <span style="color: #66cc66;">&lt;float: 0.01.0&gt;</span><span style="opacity: 0.7;"> # Confidence threshold for auto-retrying transient errors (required, 0.0=auto, 1.0=manual)</span>
<span style="color: cyan; font-weight: 600;">approve_plan</span>: <span style="color: #66cc66;">&lt;float: 0.01.0&gt;</span><span style="opacity: 0.7;"> # Confidence threshold for auto-restoring from checkpoints (required, 0.0=auto, 1.0=manual)</span>
<span style="opacity: 0.7;"># ─── Execution Control Thresholds ──────────────────────────────────</span>
<span style="color: cyan; font-weight: 600;">auto_child_plans</span>: <span style="color: #66cc66;">&lt;float: 0.01.0&gt;</span><span style="opacity: 0.7;"> # Confidence threshold for auto-spawning child plans (required, 0.0=auto, 1.0=manual)</span>
<span style="color: cyan; font-weight: 600;">install_dependency</span>: <span style="color: #66cc66;">&lt;float: 0.01.0&gt;</span><span style="opacity: 0.7;"> # Confidence threshold for auto-spawning child plans (required, 0.0=auto, 1.0=manual)</span>
<span style="opacity: 0.7;"># ─── Safety Requirements ────────────────────────────────────────────</span>
<span style="color: cyan; font-weight: 600;">require_sandbox</span>: <span style="color: #66cc66;">&lt;boolean&gt;</span><span style="opacity: 0.7;"> # Require sandbox for all write operations (required)</span>
@@ -35687,32 +35691,32 @@ The following annotated YAML provides an easier-to-read overview of the same sch
| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `auto_strategize` | number (0.01.0) | Yes | Confidence threshold for transitioning from Action to Strategize. When computed confidence >= threshold, Strategize begins automatically. 0.0 = always automatic, 1.0 = always manual. |
| `auto_execute` | number (0.01.0) | Yes | Confidence threshold for transitioning from Strategize to Execute. When computed confidence >= threshold, Execute begins automatically. 0.0 = always automatic, 1.0 = always manual. |
| `auto_apply` | number (0.01.0) | Yes | Confidence threshold for transitioning from Execute to Apply. When computed confidence >= threshold, Apply begins automatically. 0.0 = always automatic, 1.0 = always manual. **A threshold of 0.0 means changes are committed without human review.** |
| `decompose_task` | number (0.01.0) | Yes | Confidence threshold for transitioning from Action to Strategize. When computed confidence >= threshold, Strategize begins automatically. 0.0 = always automatic, 1.0 = always manual. |
| `create_tool` | number (0.01.0) | Yes | Confidence threshold for transitioning from Strategize to Execute. When computed confidence >= threshold, Execute begins automatically. 0.0 = always automatic, 1.0 = always manual. |
| `select_tool` | number (0.01.0) | Yes | Confidence threshold for transitioning from Execute to Apply. When computed confidence >= threshold, Apply begins automatically. 0.0 = always automatic, 1.0 = always manual. **A threshold of 0.0 means changes are committed without human review.** |
**Decision Automation Thresholds**
| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `auto_decisions_strategize` | number (0.01.0) | Yes | Confidence threshold for autonomous decision-making during Strategize. When computed confidence >= threshold, the strategy actor decides autonomously. 0.0 = always automatic, 1.0 = always manual. |
| `auto_decisions_execute` | number (0.01.0) | Yes | Confidence threshold for autonomous decision-making during Execute. When computed confidence >= threshold, the execution actor decides autonomously. 0.0 = always automatic, 1.0 = always manual. |
| `edit_code` | number (0.01.0) | Yes | Confidence threshold for autonomous decision-making during Strategize. When computed confidence >= threshold, the strategy actor decides autonomously. 0.0 = always automatic, 1.0 = always manual. |
| `execute_command` | number (0.01.0) | Yes | Confidence threshold for autonomous decision-making during Execute. When computed confidence >= threshold, the execution actor decides autonomously. 0.0 = always automatic, 1.0 = always manual. |
**Self-Repair Thresholds**
| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `auto_validation_fix` | number (0.01.0) | Yes | Confidence threshold for automatically fixing validation failures (e.g., failing tests, lint errors). When computed confidence >= threshold, fix is attempted automatically. 0.0 = always automatic, 1.0 = always manual. |
| `auto_strategy_revision` | number (0.01.0) | Yes | Confidence threshold for automatically revising the strategy when execution reveals issues. When computed confidence >= threshold, revision proceeds automatically. 0.0 = always automatic, 1.0 = always manual. |
| `auto_reversion_from_apply` | number (0.01.0) | Yes | Confidence threshold for automatically reverting from a `constrained` Apply phase to Strategize. When computed confidence >= threshold, reversion proceeds automatically. 0.0 = always automatic, 1.0 = always manual. |
| `auto_retry_transient` | number (0.01.0) | Yes | Confidence threshold for automatically retrying operations that fail due to transient errors (network timeouts, rate limits). When computed confidence >= threshold, retry proceeds automatically. 0.0 = always automatic, 1.0 = always manual. |
| `auto_checkpoint_restore` | number (0.01.0) | Yes | Confidence threshold for automatically restoring from the most recent checkpoint on failure. When computed confidence >= threshold, restore proceeds automatically. 0.0 = always automatic, 1.0 = always manual. |
| `create_file` | number (0.01.0) | Yes | Confidence threshold for automatically fixing validation failures (e.g., failing tests, lint errors). When computed confidence >= threshold, fix is attempted automatically. 0.0 = always automatic, 1.0 = always manual. |
| `delete_content` | number (0.01.0) | Yes | Confidence threshold for automatically revising the strategy when execution reveals issues. When computed confidence >= threshold, revision proceeds automatically. 0.0 = always automatic, 1.0 = always manual. |
| `access_network` | number (0.01.0) | Yes | Confidence threshold for automatically reverting from a `constrained` Apply phase to Strategize. When computed confidence >= threshold, reversion proceeds automatically. 0.0 = always automatic, 1.0 = always manual. |
| `modify_config` | number (0.01.0) | Yes | Confidence threshold for automatically retrying operations that fail due to transient errors (network timeouts, rate limits). When computed confidence >= threshold, retry proceeds automatically. 0.0 = always automatic, 1.0 = always manual. |
| `approve_plan` | number (0.01.0) | Yes | Confidence threshold for automatically restoring from the most recent checkpoint on failure. When computed confidence >= threshold, restore proceeds automatically. 0.0 = always automatic, 1.0 = always manual. |
**Execution Control Thresholds**
| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `auto_child_plans` | number (0.01.0) | Yes | Confidence threshold for automatically spawning child plans decided during Strategize. When computed confidence >= threshold, child plans spawn automatically during Execute. 0.0 = always automatic, 1.0 = always manual. |
| `install_dependency` | number (0.01.0) | Yes | Confidence threshold for automatically spawning child plans decided during Strategize. When computed confidence >= threshold, child plans spawn automatically during Execute. 0.0 = always automatic, 1.0 = always manual. |
**Safety Flags**
@@ -35728,7 +35732,7 @@ The following annotated YAML provides an easier-to-read overview of the same sch
|-----------------|----------|----------|--------------|------------|-----------|--------|------|-------------|
| `auto_strat` | 1.0 | 0.0 | 0.0 | 0.7 | 0.0 | 0.0 | 0.0 | 0.0 |
| `auto_exec` | 1.0 | 0.0 | 1.0 | 0.7 | 0.0 | 0.0 | 0.0 | 0.0 |
| `auto_apply` | 1.0 | 1.0 | 1.0 | 1.0 | 1.0 | 1.0 | 0.0 | 0.0 |
| `select_tool` | 1.0 | 1.0 | 1.0 | 1.0 | 1.0 | 1.0 | 0.0 | 0.0 |
| `auto_dec_strat` | 1.0 | 1.0 | 0.0 | 0.6 | 0.0 | 0.0 | 0.0 | 0.0 |
| `auto_dec_exec` | 1.0 | 1.0 | 1.0 | 0.8 | 0.0 | 0.0 | 0.0 | 0.0 |
| `auto_val_fix` | 1.0 | 1.0 | 1.0 | 0.7 | 0.0 | 0.0 | 0.0 | 0.0 |
@@ -35751,27 +35755,27 @@ A profile for autonomous execution with mandatory sandboxing and manual apply:
<span style="color: cyan; font-weight: 600;">name</span>: <span style="color: #66cc66;">local/careful-auto</span>
<span style="color: cyan; font-weight: 600;">description</span>: <span style="color: #66cc66;">&quot;Autonomous execution with mandatory sandbox and manual apply&quot;</span>
<span style="color: cyan; font-weight: 600;">auto_strategize</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_execute</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_apply</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">decompose_task</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">create_tool</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">select_tool</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">auto_decisions_strategize</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_decisions_execute</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">edit_code</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">execute_command</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_validation_fix</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_strategy_revision</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">auto_reversion_from_apply</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">auto_retry_transient</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_checkpoint_restore</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">create_file</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">delete_content</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">access_network</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">modify_config</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">approve_plan</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_child_plans</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">install_dependency</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">require_sandbox</span>: <span style="color: magenta; font-weight: 600;">true</span>
<span style="color: cyan; font-weight: 600;">require_checkpoints</span>: <span style="color: magenta; font-weight: 600;">true</span>
<span style="color: cyan; font-weight: 600;">allow_unsafe_tools</span>: <span style="color: magenta; font-weight: 600;">false</span>
</code></pre></div>
This is essentially the `auto` built-in profile but with `auto_checkpoint_restore` set to 0.0 (always automatic) for more aggressive self-repair.
This is essentially the `auto` built-in profile but with `approve_plan` set to 0.0 (always automatic) for more aggressive self-repair.
---
@@ -35786,20 +35790,20 @@ A profile designed for automated CI/CD pipelines where everything runs autonomou
<span style="color: cyan; font-weight: 600;">name</span>: <span style="color: #66cc66;">local/ci-pipeline</span>
<span style="color: cyan; font-weight: 600;">description</span>: <span style="color: #66cc66;">&quot;Full automation for CI/CD pipelines. All phases automated, sandbox required.&quot;</span>
<span style="color: cyan; font-weight: 600;">auto_strategize</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_execute</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_apply</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">decompose_task</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">create_tool</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">select_tool</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_decisions_strategize</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_decisions_execute</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">edit_code</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">execute_command</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_validation_fix</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_strategy_revision</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_reversion_from_apply</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_retry_transient</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_checkpoint_restore</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">create_file</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">delete_content</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">access_network</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">modify_config</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">approve_plan</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_child_plans</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">install_dependency</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">require_sandbox</span>: <span style="color: magenta; font-weight: 600;">true</span>
<span style="color: cyan; font-weight: 600;">require_checkpoints</span>: <span style="color: magenta; font-weight: 600;">true</span>
@@ -35821,20 +35825,20 @@ A profile for regulated environments where every decision must be reviewed:
<span style="color: cyan; font-weight: 600;">name</span>: <span style="color: #66cc66;">local/review-heavy</span>
<span style="color: cyan; font-weight: 600;">description</span>: <span style="color: #66cc66;">&quot;Maximum human oversight. Every decision and phase requires approval.&quot;</span>
<span style="color: cyan; font-weight: 600;">auto_strategize</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_execute</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">auto_apply</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">decompose_task</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">create_tool</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">select_tool</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">auto_decisions_strategize</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">auto_decisions_execute</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">edit_code</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">execute_command</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">auto_validation_fix</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">auto_strategy_revision</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">auto_reversion_from_apply</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">auto_retry_transient</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">auto_checkpoint_restore</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">create_file</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">delete_content</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">access_network</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">modify_config</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">approve_plan</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">auto_child_plans</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">install_dependency</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">require_sandbox</span>: <span style="color: magenta; font-weight: 600;">true</span>
<span style="color: cyan; font-weight: 600;">require_checkpoints</span>: <span style="color: magenta; font-weight: 600;">true</span>
@@ -35856,20 +35860,20 @@ A fast-iteration profile for local development where safety is relaxed:
<span style="color: cyan; font-weight: 600;">name</span>: <span style="color: #66cc66;">local/dev-sandbox</span>
<span style="color: cyan; font-weight: 600;">description</span>: <span style="color: #66cc66;">&quot;Fast iteration for local development. Relaxed safety, auto execution.&quot;</span>
<span style="color: cyan; font-weight: 600;">auto_strategize</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_execute</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_apply</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">decompose_task</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">create_tool</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">select_tool</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">auto_decisions_strategize</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_decisions_execute</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">edit_code</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">execute_command</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_validation_fix</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_strategy_revision</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_reversion_from_apply</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">auto_retry_transient</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_checkpoint_restore</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">create_file</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">delete_content</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">access_network</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">modify_config</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">approve_plan</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_child_plans</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">install_dependency</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">require_sandbox</span>: <span style="color: magenta; font-weight: 600;">false</span>
<span style="color: cyan; font-weight: 600;">require_checkpoints</span>: <span style="color: magenta; font-weight: 600;">false</span>
@@ -35895,20 +35899,20 @@ A profile for production deployments combining autonomous execution with maximum
and checkpoint. Apply requires manual approval. Strategy
revision is enabled to adapt to deployment issues.
<span style="color: cyan; font-weight: 600;">auto_strategize</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_execute</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_apply</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">decompose_task</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">create_tool</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">select_tool</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">auto_decisions_strategize</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_decisions_execute</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">edit_code</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">execute_command</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_validation_fix</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_strategy_revision</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_reversion_from_apply</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">auto_retry_transient</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_checkpoint_restore</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">create_file</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">delete_content</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">access_network</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">modify_config</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">approve_plan</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_child_plans</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">install_dependency</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">require_sandbox</span>: <span style="color: magenta; font-weight: 600;">true</span>
<span style="color: cyan; font-weight: 600;">require_checkpoints</span>: <span style="color: magenta; font-weight: 600;">true</span>
@@ -36450,7 +36454,7 @@ Because the automation profile is `manual`, the plan stops and waits after creat
<span style="color: #66cc66; font-weight: 600;">✓ OK</span> Strategize complete — awaiting manual approval
</code></pre></div>
The strategy actor has read the codebase, identified the relevant files, and produced decisions. Since `auto_decisions_strategize` is 1.0 (manual), the plan pauses for review:
The strategy actor has read the codebase, identified the relevant files, and produced decisions. Since `edit_code` is 1.0 (manual), the plan pauses for review:
<div class="highlight"><pre><code>
<span style="opacity: 0.7;"># Review the decision tree</span>
@@ -41266,17 +41270,17 @@ Create `profiles/db-cautious.yaml`:
<span style="color: cyan; font-weight: 600;">name</span>: local/db-cautious
<span style="color: cyan; font-weight: 600;">description</span>: <span style="color: #66cc66;">"Auto for most tasks, manual for database and security decisions"</span>
<span style="color: cyan; font-weight: 600;">auto_strategize</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_execute</span>: <span style="color: yellow;">0.3</span>
<span style="color: cyan; font-weight: 600;">auto_apply</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">auto_decisions_strategize</span>: <span style="color: yellow;">0.4</span>
<span style="color: cyan; font-weight: 600;">auto_decisions_execute</span>: <span style="color: yellow;">0.6</span>
<span style="color: cyan; font-weight: 600;">auto_validation_fix</span>: <span style="color: yellow;">0.5</span>
<span style="color: cyan; font-weight: 600;">auto_strategy_revision</span>: <span style="color: yellow;">0.8</span>
<span style="color: cyan; font-weight: 600;">auto_reversion_from_apply</span>: <span style="color: yellow;">0.9</span>
<span style="color: cyan; font-weight: 600;">auto_child_plans</span>: <span style="color: yellow;">0.3</span>
<span style="color: cyan; font-weight: 600;">auto_retry_transient</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">auto_checkpoint_restore</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">decompose_task</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">create_tool</span>: <span style="color: yellow;">0.3</span>
<span style="color: cyan; font-weight: 600;">select_tool</span>: <span style="color: yellow;">1.0</span>
<span style="color: cyan; font-weight: 600;">edit_code</span>: <span style="color: yellow;">0.4</span>
<span style="color: cyan; font-weight: 600;">execute_command</span>: <span style="color: yellow;">0.6</span>
<span style="color: cyan; font-weight: 600;">create_file</span>: <span style="color: yellow;">0.5</span>
<span style="color: cyan; font-weight: 600;">delete_content</span>: <span style="color: yellow;">0.8</span>
<span style="color: cyan; font-weight: 600;">access_network</span>: <span style="color: yellow;">0.9</span>
<span style="color: cyan; font-weight: 600;">install_dependency</span>: <span style="color: yellow;">0.3</span>
<span style="color: cyan; font-weight: 600;">modify_config</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">approve_plan</span>: <span style="color: yellow;">0.0</span>
<span style="color: cyan; font-weight: 600;">require_sandbox</span>: <span style="color: yellow;">true</span>
<span style="color: cyan; font-weight: 600;">require_checkpoints</span>: <span style="color: yellow;">true</span>
@@ -41294,16 +41298,16 @@ Create `profiles/db-cautious.yaml`:
╰───────────────────────────────────────────────────────────────────────────╯
╭─ Confidence Thresholds ────────────────╮
│ <span style="color: #66cc66; font-weight: 600;">auto_strategize:</span> 0.0 │
│ <span style="color: #66cc66; font-weight: 600;">auto_execute:</span> 0.3 │
│ <span style="color: #ff6666; font-weight: 600;">auto_apply:</span> 1.0 │
│ <span style="color: #66cc66; font-weight: 600;">auto_decisions_strategize:</span> 0.4 │
│ <span style="color: #66cc66; font-weight: 600;">auto_decisions_execute:</span> 0.6 │
│ <span style="color: #66cc66; font-weight: 600;">auto_validation_fix:</span> 0.5 │
│ <span style="color: #66cc66; font-weight: 600;">auto_strategy_revision:</span> 0.8 │
│ <span style="color: #66cc66; font-weight: 600;">auto_child_plans:</span> 0.3 │
│ <span style="color: #66cc66; font-weight: 600;">auto_retry_transient:</span> 0.0 │
│ <span style="color: #66cc66; font-weight: 600;">auto_checkpoint_restore:</span> 0.0 │
│ <span style="color: #66cc66; font-weight: 600;">decompose_task:</span> 0.0 │
│ <span style="color: #66cc66; font-weight: 600;">create_tool:</span> 0.3 │
│ <span style="color: #ff6666; font-weight: 600;">select_tool:</span> 1.0 │
│ <span style="color: #66cc66; font-weight: 600;">edit_code:</span> 0.4 │
│ <span style="color: #66cc66; font-weight: 600;">execute_command:</span> 0.6 │
│ <span style="color: #66cc66; font-weight: 600;">create_file:</span> 0.5 │
│ <span style="color: #66cc66; font-weight: 600;">delete_content:</span> 0.8 │
│ <span style="color: #66cc66; font-weight: 600;">install_dependency:</span> 0.3 │
│ <span style="color: #66cc66; font-weight: 600;">modify_config:</span> 0.0 │
│ <span style="color: #66cc66; font-weight: 600;">approve_plan:</span> 0.0 │
│ <span style="color: #66cc66; font-weight: 600;">require_sandbox:</span> true │
│ <span style="color: #66cc66; font-weight: 600;">require_checkpoints:</span> true │
│ <span style="color: #ff6666; font-weight: 600;">allow_unsafe_tools:</span> false │
+19 -18
View File
@@ -1,29 +1,30 @@
# Built-in profile: auto
# Fully automatic except reversion.
# Everything proceeds without human gates except reversion from apply.
# Fully automatic except apply.
# All thresholds set to 0.0 except select_tool (Apply gate) and
# access_network (Apply-to-Strategize reversion gate), both at 1.0.
name: auto
description: Fully automatic except reversion
description: Fully automatic except apply
schema_version: "1.0"
# Phase-transition thresholds
auto_strategize: 0.0
auto_execute: 0.0
auto_apply: 1.0
# Task-type confidence thresholds
decompose_task: 0.0
create_tool: 0.0
select_tool: 1.0
# Decision-autonomy thresholds
auto_decisions_strategize: 0.0
auto_decisions_execute: 0.0
# Task-type confidence thresholds (continued)
edit_code: 0.0
execute_command: 0.0
# Self-repair thresholds
auto_validation_fix: 0.0
auto_strategy_revision: 0.0
auto_reversion_from_apply: 1.0
# Task-type confidence thresholds (continued)
create_file: 0.0
delete_content: 0.0
access_network: 1.0
# Child plan and retry thresholds
auto_child_plans: 0.0
auto_retry_transient: 0.0
auto_checkpoint_restore: 0.0
# Task-type confidence thresholds (continued)
install_dependency: 0.0
modify_config: 0.0
approve_plan: 0.0
# Safety requirements
safety:
+15 -15
View File
@@ -7,24 +7,24 @@ name: cautious
description: Probabilistic gates on most actions
schema_version: "1.0"
# Phase-transition thresholds
auto_strategize: 0.7
auto_execute: 0.7
auto_apply: 1.0
# Task-type confidence thresholds
decompose_task: 0.7
create_tool: 0.7
select_tool: 1.0
# Decision-autonomy thresholds
auto_decisions_strategize: 0.6
auto_decisions_execute: 0.8
# Task-type confidence thresholds (continued)
edit_code: 0.6
execute_command: 0.8
# Self-repair thresholds
auto_validation_fix: 0.7
auto_strategy_revision: 0.8
auto_reversion_from_apply: 0.9
# Task-type confidence thresholds (continued)
create_file: 0.7
delete_content: 0.8
access_network: 0.9
# Child plan and retry thresholds
auto_child_plans: 0.7
auto_retry_transient: 0.0
auto_checkpoint_restore: 0.6
# Task-type confidence thresholds (continued)
install_dependency: 0.7
modify_config: 0.0
approve_plan: 0.6
# Safety requirements
safety:
+15 -15
View File
@@ -6,24 +6,24 @@ name: ci
description: Designed for CI pipelines
schema_version: "1.0"
# Phase-transition thresholds
auto_strategize: 0.0
auto_execute: 0.0
auto_apply: 0.0
# Task-type confidence thresholds
decompose_task: 0.0
create_tool: 0.0
select_tool: 0.0
# Decision-autonomy thresholds
auto_decisions_strategize: 0.0
auto_decisions_execute: 0.0
# Task-type confidence thresholds (continued)
edit_code: 0.0
execute_command: 0.0
# Self-repair thresholds
auto_validation_fix: 0.0
auto_strategy_revision: 0.0
auto_reversion_from_apply: 0.0
# Task-type confidence thresholds (continued)
create_file: 0.0
delete_content: 0.0
access_network: 0.0
# Child plan and retry thresholds
auto_child_plans: 0.0
auto_retry_transient: 0.0
auto_checkpoint_restore: 0.0
# Task-type confidence thresholds (continued)
install_dependency: 0.0
modify_config: 0.0
approve_plan: 0.0
# Safety requirements
safety:
+15 -15
View File
@@ -6,24 +6,24 @@ name: custom/cautious
description: Cautious profile with guard constraints
schema_version: "1.0"
# Phase-transition thresholds
auto_strategize: 0.7
auto_execute: 0.7
auto_apply: 1.0
# Task-type confidence thresholds
decompose_task: 0.7
create_tool: 0.7
select_tool: 1.0
# Decision-autonomy thresholds
auto_decisions_strategize: 0.6
auto_decisions_execute: 0.8
# Task-type confidence thresholds (continued)
edit_code: 0.6
execute_command: 0.8
# Self-repair thresholds
auto_validation_fix: 0.7
auto_strategy_revision: 0.8
auto_reversion_from_apply: 0.9
# Task-type confidence thresholds (continued)
create_file: 0.7
delete_content: 0.8
access_network: 0.9
# Child plan and retry thresholds
auto_child_plans: 0.7
auto_retry_transient: 0.0
auto_checkpoint_restore: 0.6
# Task-type confidence thresholds (continued)
install_dependency: 0.7
modify_config: 0.0
approve_plan: 0.6
# Safety requirements
safety:
+15 -15
View File
@@ -6,24 +6,24 @@ name: full-auto
description: No gates, no sandbox, no checkpoints
schema_version: "1.0"
# Phase-transition thresholds
auto_strategize: 0.0
auto_execute: 0.0
auto_apply: 0.0
# Task-type confidence thresholds
decompose_task: 0.0
create_tool: 0.0
select_tool: 0.0
# Decision-autonomy thresholds
auto_decisions_strategize: 0.0
auto_decisions_execute: 0.0
# Task-type confidence thresholds (continued)
edit_code: 0.0
execute_command: 0.0
# Self-repair thresholds
auto_validation_fix: 0.0
auto_strategy_revision: 0.0
auto_reversion_from_apply: 0.0
# Task-type confidence thresholds (continued)
create_file: 0.0
delete_content: 0.0
access_network: 0.0
# Child plan and retry thresholds
auto_child_plans: 0.0
auto_retry_transient: 0.0
auto_checkpoint_restore: 0.0
# Task-type confidence thresholds (continued)
install_dependency: 0.0
modify_config: 0.0
approve_plan: 0.0
# Safety requirements
safety:
+15 -15
View File
@@ -6,24 +6,24 @@ name: manual
description: Human approves every action
schema_version: "1.0"
# Phase-transition thresholds
auto_strategize: 1.0
auto_execute: 1.0
auto_apply: 1.0
# Task-type confidence thresholds
decompose_task: 1.0
create_tool: 1.0
select_tool: 1.0
# Decision-autonomy thresholds
auto_decisions_strategize: 1.0
auto_decisions_execute: 1.0
# Task-type confidence thresholds (continued)
edit_code: 1.0
execute_command: 1.0
# Self-repair thresholds
auto_validation_fix: 1.0
auto_strategy_revision: 1.0
auto_reversion_from_apply: 1.0
# Task-type confidence thresholds (continued)
create_file: 1.0
delete_content: 1.0
access_network: 1.0
# Child plan and retry thresholds
auto_child_plans: 1.0
auto_retry_transient: 1.0
auto_checkpoint_restore: 1.0
# Task-type confidence thresholds (continued)
install_dependency: 1.0
modify_config: 1.0
approve_plan: 1.0
# Safety requirements
safety:
+15 -15
View File
@@ -6,24 +6,24 @@ name: review
description: Human reviews before apply
schema_version: "1.0"
# Phase-transition thresholds
auto_strategize: 0.0
auto_execute: 0.0
auto_apply: 1.0
# Task-type confidence thresholds
decompose_task: 0.0
create_tool: 0.0
select_tool: 1.0
# Decision-autonomy thresholds
auto_decisions_strategize: 1.0
auto_decisions_execute: 1.0
# Task-type confidence thresholds (continued)
edit_code: 1.0
execute_command: 1.0
# Self-repair thresholds
auto_validation_fix: 1.0
auto_strategy_revision: 1.0
auto_reversion_from_apply: 1.0
# Task-type confidence thresholds (continued)
create_file: 1.0
delete_content: 1.0
access_network: 1.0
# Child plan and retry thresholds
auto_child_plans: 0.0
auto_retry_transient: 0.0
auto_checkpoint_restore: 1.0
# Task-type confidence thresholds (continued)
install_dependency: 0.0
modify_config: 0.0
approve_plan: 1.0
# Safety requirements
safety:
+15 -15
View File
@@ -6,24 +6,24 @@ name: supervised
description: Human reviews strategy and execution
schema_version: "1.0"
# Phase-transition thresholds
auto_strategize: 0.0
auto_execute: 1.0
auto_apply: 1.0
# Task-type confidence thresholds
decompose_task: 0.0
create_tool: 1.0
select_tool: 1.0
# Decision-autonomy thresholds
auto_decisions_strategize: 0.0
auto_decisions_execute: 1.0
# Task-type confidence thresholds (continued)
edit_code: 0.0
execute_command: 1.0
# Self-repair thresholds
auto_validation_fix: 1.0
auto_strategy_revision: 1.0
auto_reversion_from_apply: 1.0
# Task-type confidence thresholds (continued)
create_file: 1.0
delete_content: 1.0
access_network: 1.0
# Child plan and retry thresholds
auto_child_plans: 1.0
auto_retry_transient: 0.0
auto_checkpoint_restore: 1.0
# Task-type confidence thresholds (continued)
install_dependency: 1.0
modify_config: 0.0
approve_plan: 1.0
# Safety requirements
safety:
+15 -15
View File
@@ -6,24 +6,24 @@ name: trusted
description: Auto for most, human for apply and revert
schema_version: "1.0"
# Phase-transition thresholds
auto_strategize: 0.0
auto_execute: 0.0
auto_apply: 1.0
# Task-type confidence thresholds
decompose_task: 0.0
create_tool: 0.0
select_tool: 1.0
# Decision-autonomy thresholds
auto_decisions_strategize: 0.0
auto_decisions_execute: 0.0
# Task-type confidence thresholds (continued)
edit_code: 0.0
execute_command: 0.0
# Self-repair thresholds
auto_validation_fix: 0.0
auto_strategy_revision: 1.0
auto_reversion_from_apply: 1.0
# Task-type confidence thresholds (continued)
create_file: 0.0
delete_content: 1.0
access_network: 1.0
# Child plan and retry thresholds
auto_child_plans: 0.0
auto_retry_transient: 0.0
auto_checkpoint_restore: 1.0
# Task-type confidence thresholds (continued)
install_dependency: 0.0
modify_config: 0.0
approve_plan: 1.0
# Safety requirements
safety:
+8 -2
View File
@@ -46,6 +46,12 @@ Feature: Automation Profile CLI commands
When I run automation-profile add with --config pointing to the invalid threshold YAML file
Then the automation-profile command should abort
Scenario: Add profile with legacy threshold keys fails
Given an automation profile config YAML file with legacy threshold keys
When I run automation-profile add with --config pointing to the legacy threshold YAML file
Then the automation-profile command should abort
And the automation-profile output should contain "auto_strategize"
Scenario: Add profile cannot overwrite built-in
Given an automation profile config YAML file with built-in name "manual"
When I run automation-profile add with --config pointing to the built-in name YAML file
@@ -84,7 +90,7 @@ Feature: Automation Profile CLI commands
When I run automation-profile list with --format json
Then the automation-profile list should succeed
And the automation-profile json output should contain "name"
And the automation-profile json output should contain "auto_strategize"
And the automation-profile json output should contain "decompose_task"
Scenario: List profiles with no matches
When I run automation-profile list with namespace filter "nonexistent"
@@ -106,7 +112,7 @@ Feature: Automation Profile CLI commands
When I run automation-profile show "manual" with --format yaml
Then the automation-profile show should succeed
And the automation-profile yaml output should contain "name: manual"
And the automation-profile yaml output should contain "auto_strategize"
And the automation-profile yaml output should contain "decompose_task"
Scenario: Show profile with --format json
When I run automation-profile show "manual" with --format json
@@ -14,6 +14,10 @@ Feature: Automation Profile CLI coverage boost
When I call threshold summary on a built-in profile
Then the threshold summary should contain strategize execute and apply values
Scenario: Guarded profile config passes docs schema and model
When I validate a guarded profile config against docs schema and model
Then the guarded profile config should pass schema and model validation
Scenario: Add profile with non-dict YAML content aborts
Given a YAML file containing a list instead of a dict
When I run automation-profile add with that non-dict YAML file
@@ -41,89 +41,89 @@ Feature: Consolidated Automation Profile
# ============================================================
Scenario: Profile accepts threshold of 0.0
When I create a profile with auto_strategize 0.0
When I create a profile with decompose_task 0.0
Then the profile model should be created
And the profile auto_strategize should be 0.0
And the profile decompose_task should be 0.0
Scenario: Profile accepts threshold of 0.5
When I create a profile with auto_strategize 0.5
When I create a profile with decompose_task 0.5
Then the profile model should be created
And the profile auto_strategize should be 0.5
And the profile decompose_task should be 0.5
Scenario: Profile accepts threshold of 1.0
When I create a profile with auto_strategize 1.0
When I create a profile with decompose_task 1.0
Then the profile model should be created
And the profile auto_strategize should be 1.0
And the profile decompose_task should be 1.0
# ---- Profile validation: invalid thresholds ----
Scenario: Profile rejects threshold below 0.0
When I try to create a profile with auto_strategize -0.1
When I try to create a profile with decompose_task -0.1
Then a profile validation error should be raised
And the profile error should mention "greater than or equal"
Scenario: Profile rejects threshold above 1.0
When I try to create a profile with auto_strategize 1.1
When I try to create a profile with decompose_task 1.1
Then a profile validation error should be raised
And the profile error should mention "less than or equal"
Scenario: Profile rejects auto_execute below 0.0
When I try to create a profile with auto_execute -0.5
Scenario: Profile rejects create_tool below 0.0
When I try to create a profile with create_tool -0.5
Then a profile validation error should be raised
Scenario: Profile rejects auto_execute above 1.0
When I try to create a profile with auto_execute 2.0
Scenario: Profile rejects create_tool above 1.0
When I try to create a profile with create_tool 2.0
Then a profile validation error should be raised
Scenario: Profile rejects auto_apply below 0.0
When I try to create a profile with auto_apply -0.01
Scenario: Profile rejects select_tool below 0.0
When I try to create a profile with select_tool -0.01
Then a profile validation error should be raised
Scenario: Profile rejects auto_decisions_strategize above 1.0
When I try to create a profile with auto_decisions_strategize 1.5
Scenario: Profile rejects edit_code above 1.0
When I try to create a profile with edit_code 1.5
Then a profile validation error should be raised
Scenario: Profile rejects auto_decisions_execute below 0.0
When I try to create a profile with auto_decisions_execute -1.0
Scenario: Profile rejects execute_command below 0.0
When I try to create a profile with execute_command -1.0
Then a profile validation error should be raised
Scenario: Profile rejects auto_validation_fix above 1.0
When I try to create a profile with auto_validation_fix 9.9
Scenario: Profile rejects create_file above 1.0
When I try to create a profile with create_file 9.9
Then a profile validation error should be raised
Scenario: Profile rejects auto_strategy_revision below 0.0
When I try to create a profile with auto_strategy_revision -0.001
Scenario: Profile rejects delete_content below 0.0
When I try to create a profile with delete_content -0.001
Then a profile validation error should be raised
Scenario: Profile rejects auto_reversion_from_apply above 1.0
When I try to create a profile with auto_reversion_from_apply 1.01
Scenario: Profile rejects access_network above 1.0
When I try to create a profile with access_network 1.01
Then a profile validation error should be raised
Scenario: Profile rejects auto_child_plans below 0.0
When I try to create a profile with auto_child_plans -0.5
Scenario: Profile rejects install_dependency below 0.0
When I try to create a profile with install_dependency -0.5
Then a profile validation error should be raised
Scenario: Profile rejects auto_retry_transient above 1.0
When I try to create a profile with auto_retry_transient 100.0
Scenario: Profile rejects modify_config above 1.0
When I try to create a profile with modify_config 100.0
Then a profile validation error should be raised
Scenario: Profile rejects auto_checkpoint_restore below 0.0
When I try to create a profile with auto_checkpoint_restore -0.1
Scenario: Profile rejects approve_plan below 0.0
When I try to create a profile with approve_plan -0.1
Then a profile validation error should be raised
# ---- Built-in profiles load correctly ----
@@ -132,9 +132,9 @@ Feature: Consolidated Automation Profile
Scenario: Built-in manual profile loads with expected values
When I load the built-in profile "manual"
Then the profile model should be created
And the profile auto_strategize should be 1.0
And the profile auto_execute should be 1.0
And the profile auto_apply should be 1.0
And the profile decompose_task should be 1.0
And the profile create_tool should be 1.0
And the profile select_tool should be 1.0
And the profile safety require_sandbox should be true
And the profile safety require_checkpoints should be true
And the profile safety allow_unsafe_tools should be false
@@ -143,59 +143,59 @@ Feature: Consolidated Automation Profile
Scenario: Built-in review profile loads with expected values
When I load the built-in profile "review"
Then the profile model should be created
And the profile auto_strategize should be 0.0
And the profile auto_execute should be 0.0
And the profile auto_apply should be 1.0
And the profile auto_child_plans should be 0.0
And the profile decompose_task should be 0.0
And the profile create_tool should be 0.0
And the profile select_tool should be 1.0
And the profile install_dependency should be 0.0
Scenario: Built-in supervised profile loads with expected values
When I load the built-in profile "supervised"
Then the profile model should be created
And the profile auto_strategize should be 0.0
And the profile auto_execute should be 1.0
And the profile auto_decisions_strategize should be 0.0
And the profile auto_child_plans should be 1.0
And the profile decompose_task should be 0.0
And the profile create_tool should be 1.0
And the profile edit_code should be 0.0
And the profile install_dependency should be 1.0
Scenario: Built-in cautious profile loads with expected values
When I load the built-in profile "cautious"
Then the profile model should be created
And the profile auto_strategize should be 0.7
And the profile auto_execute should be 0.7
And the profile auto_decisions_strategize should be 0.6
And the profile auto_decisions_execute should be 0.8
And the profile auto_validation_fix should be 0.7
And the profile auto_strategy_revision should be 0.8
And the profile auto_reversion_from_apply should be 0.9
And the profile auto_child_plans should be 0.7
And the profile auto_checkpoint_restore should be 0.6
And the profile decompose_task should be 0.7
And the profile create_tool should be 0.7
And the profile edit_code should be 0.6
And the profile execute_command should be 0.8
And the profile create_file should be 0.7
And the profile delete_content should be 0.8
And the profile access_network should be 0.9
And the profile install_dependency should be 0.7
And the profile approve_plan should be 0.6
Scenario: Built-in trusted profile loads with expected values
When I load the built-in profile "trusted"
Then the profile model should be created
And the profile auto_strategize should be 0.0
And the profile auto_execute should be 0.0
And the profile auto_apply should be 1.0
And the profile auto_strategy_revision should be 1.0
And the profile auto_reversion_from_apply should be 1.0
And the profile decompose_task should be 0.0
And the profile create_tool should be 0.0
And the profile select_tool should be 1.0
And the profile delete_content should be 1.0
And the profile access_network should be 1.0
Scenario: Built-in auto profile loads with expected values
When I load the built-in profile "auto"
Then the profile model should be created
And the profile auto_strategize should be 0.0
And the profile auto_apply should be 1.0
And the profile auto_reversion_from_apply should be 1.0
And the profile auto_strategy_revision should be 0.0
And the profile decompose_task should be 0.0
And the profile select_tool should be 1.0
And the profile access_network should be 1.0
And the profile delete_content should be 0.0
Scenario: Built-in ci profile loads with expected values
When I load the built-in profile "ci"
Then the profile model should be created
And the profile auto_strategize should be 0.0
And the profile auto_apply should be 0.0
And the profile decompose_task should be 0.0
And the profile select_tool should be 0.0
And the profile safety require_sandbox should be true
And the profile safety allow_unsafe_tools should be false
@@ -203,8 +203,8 @@ Feature: Consolidated Automation Profile
Scenario: Built-in full-auto profile loads with expected values
When I load the built-in profile "full-auto"
Then the profile model should be created
And the profile auto_strategize should be 0.0
And the profile auto_apply should be 0.0
And the profile decompose_task should be 0.0
And the profile select_tool should be 0.0
And the profile safety require_sandbox should be false
And the profile safety require_checkpoints should be false
And the profile safety allow_unsafe_tools should be true
@@ -227,10 +227,10 @@ Feature: Consolidated Automation Profile
Scenario: Custom profile from YAML config loads correctly
When I load a profile from config with name "acme/strict" and auto_apply 0.8
When I load a profile from config with name "acme/strict" and select_tool 0.8
Then the profile model should be created
And the profile name should be "acme/strict"
And the profile auto_apply should be 0.8
And the profile select_tool should be 0.8
Scenario: Profile from config missing name raises error
@@ -323,36 +323,36 @@ Feature: Consolidated Automation Profile
Scenario: Assigning invalid threshold raises error
When I create a profile with name "assign-test"
And I try to assign auto_strategize 1.5 on the profile
And I try to assign decompose_task 1.5 on the profile
Then a profile validation error should be raised
# ---- Built-in profile retry and checkpoint values ----
Scenario: Manual profile has auto_retry_transient 1.0
Scenario: Manual profile has modify_config 1.0
When I load the built-in profile "manual"
Then the profile auto_retry_transient should be 1.0
And the profile auto_checkpoint_restore should be 1.0
Then the profile modify_config should be 1.0
And the profile approve_plan should be 1.0
Scenario: Review profile has auto_retry_transient 0.0
Scenario: Review profile has modify_config 0.0
When I load the built-in profile "review"
Then the profile auto_retry_transient should be 0.0
And the profile auto_checkpoint_restore should be 1.0
Then the profile modify_config should be 0.0
And the profile approve_plan should be 1.0
Scenario: Cautious profile has auto_retry_transient 0.0
Scenario: Cautious profile has modify_config 0.0
When I load the built-in profile "cautious"
Then the profile auto_retry_transient should be 0.0
Then the profile modify_config should be 0.0
# ---- Model dump and round-trip ----
Scenario: Profile model_dump produces valid dict
When I create a profile and dump it with auto_apply 0.5
When I create a profile and dump it with select_tool 0.5
Then the profile model dump should have key "name"
And the profile model dump should have key "auto_apply"
And the profile model dump auto_apply should be 0.5
And the profile model dump should have key "select_tool"
And the profile model dump select_tool should be 0.5
# ============================================================
@@ -535,7 +535,7 @@ Feature: Consolidated Automation Profile
Given an automation profile service with global default "manual"
When I get profile "auto"
Then the retrieved profile name should be "auto"
And the retrieved profile auto_apply should be 1.0
And the retrieved profile select_tool should be 1.0
# ---- Profile threshold checks ----
@@ -543,17 +543,17 @@ Feature: Consolidated Automation Profile
Scenario: Manual profile has all thresholds at 1.0
Given an automation profile service with global default "manual"
When I get profile "manual"
Then the retrieved profile auto_strategize should be 1.0
And the retrieved profile auto_execute should be 1.0
And the retrieved profile auto_apply should be 1.0
Then the retrieved profile decompose_task should be 1.0
And the retrieved profile create_tool should be 1.0
And the retrieved profile select_tool should be 1.0
Scenario: Full-auto profile has all thresholds at 0.0
Given an automation profile service with global default "manual"
When I get profile "full-auto"
Then the retrieved profile auto_strategize should be 0.0
And the retrieved profile auto_execute should be 0.0
And the retrieved profile auto_apply should be 0.0
Then the retrieved profile decompose_task should be 0.0
And the retrieved profile create_tool should be 0.0
And the retrieved profile select_tool should be 0.0
# ============================================================
+9 -9
View File
@@ -756,9 +756,9 @@ Feature: Consolidated Misc
Given a m6 smoke test runner
And a m6 smoke A2A local facade
When I m6 smoke load built-in profile "manual"
Then the m6 smoke profile auto_strategize should be 1.0
And the m6 smoke profile auto_execute should be 1.0
And the m6 smoke profile auto_apply should be 1.0
Then the m6 smoke profile decompose_task should be 1.0
And the m6 smoke profile create_tool should be 1.0
And the m6 smoke profile select_tool should be 1.0
And the m6 smoke profile require_sandbox should be true
@@ -766,9 +766,9 @@ Feature: Consolidated Misc
Given a m6 smoke test runner
And a m6 smoke A2A local facade
When I m6 smoke load built-in profile "full-auto"
Then the m6 smoke profile auto_strategize should be 0.0
And the m6 smoke profile auto_execute should be 0.0
And the m6 smoke profile auto_apply should be 0.0
Then the m6 smoke profile decompose_task should be 0.0
And the m6 smoke profile create_tool should be 0.0
And the m6 smoke profile select_tool should be 0.0
And the m6 smoke profile require_sandbox should be false
And the m6 smoke profile allow_unsafe_tools should be true
@@ -778,9 +778,9 @@ Feature: Consolidated Misc
Scenario: M6 smoke create custom namespaced profile
Given a m6 smoke test runner
And a m6 smoke A2A local facade
When I m6 smoke create a profile named "acme/strict" with auto_apply 1.0
When I m6 smoke create a profile named "acme/strict" with select_tool 1.0
Then the m6 smoke created profile name should be "acme/strict"
And the m6 smoke created profile auto_apply should be 1.0
And the m6 smoke created profile select_tool should be 1.0
Scenario: M6 smoke profile name validation rejects invalid
@@ -793,7 +793,7 @@ Feature: Consolidated Misc
Scenario: M6 smoke profile threshold validation rejects out of range
Given a m6 smoke test runner
And a m6 smoke A2A local facade
When I m6 smoke create a profile with auto_strategize 1.5
When I m6 smoke create a profile with decompose_task 1.5
Then the m6 smoke creation should raise ValueError
+17 -17
View File
@@ -5,17 +5,17 @@
"name": "builtin_profiles",
"expected_names": ["manual", "review", "supervised", "cautious", "trusted", "auto", "ci", "full-auto"],
"manual_thresholds": {
"auto_strategize": 1.0,
"auto_execute": 1.0,
"auto_apply": 1.0,
"decompose_task": 1.0,
"create_tool": 1.0,
"select_tool": 1.0,
"require_sandbox": true,
"require_checkpoints": true,
"allow_unsafe_tools": false
},
"full_auto_thresholds": {
"auto_strategize": 0.0,
"auto_execute": 0.0,
"auto_apply": 0.0,
"decompose_task": 0.0,
"create_tool": 0.0,
"select_tool": 0.0,
"require_sandbox": false,
"require_checkpoints": false,
"allow_unsafe_tools": true
@@ -27,17 +27,17 @@
"name": "acme/strict",
"description": "Strict profile for ACME Corp",
"schema_version": "1.0",
"auto_strategize": 1.0,
"auto_execute": 1.0,
"auto_apply": 1.0,
"auto_decisions_strategize": 1.0,
"auto_decisions_execute": 1.0,
"auto_validation_fix": 1.0,
"auto_strategy_revision": 1.0,
"auto_reversion_from_apply": 1.0,
"auto_child_plans": 1.0,
"auto_retry_transient": 1.0,
"auto_checkpoint_restore": 1.0,
"decompose_task": 1.0,
"create_tool": 1.0,
"select_tool": 1.0,
"edit_code": 1.0,
"execute_command": 1.0,
"create_file": 1.0,
"delete_content": 1.0,
"access_network": 1.0,
"install_dependency": 1.0,
"modify_config": 1.0,
"approve_plan": 1.0,
"require_sandbox": true,
"require_checkpoints": true,
"allow_unsafe_tools": false
+12 -12
View File
@@ -6,9 +6,9 @@
"profile": {
"name": "test-denylist",
"description": "Profile with tool denylist guard",
"auto_strategize": 0.0,
"auto_execute": 0.0,
"auto_apply": 1.0,
"decompose_task": 0.0,
"create_tool": 0.0,
"select_tool": 1.0,
"guards": {
"tool_denylist": ["rm_rf", "drop_database", "format_disk"],
"require_approval_for_writes": false,
@@ -26,9 +26,9 @@
"profile": {
"name": "test-allowlist",
"description": "Profile with tool allowlist guard",
"auto_strategize": 0.0,
"auto_execute": 0.0,
"auto_apply": 1.0,
"decompose_task": 0.0,
"create_tool": 0.0,
"select_tool": 1.0,
"guards": {
"tool_allowlist": ["read_file", "list_dir", "search"],
"require_approval_for_writes": false,
@@ -46,9 +46,9 @@
"profile": {
"name": "test-budget",
"description": "Profile with cost budget guard",
"auto_strategize": 0.0,
"auto_execute": 0.0,
"auto_apply": 1.0,
"decompose_task": 0.0,
"create_tool": 0.0,
"select_tool": 1.0,
"guards": {
"max_total_cost": 10.0,
"max_tool_calls_per_step": 5
@@ -65,9 +65,9 @@
"profile": {
"name": "test-write-approval",
"description": "Profile requiring write approval",
"auto_strategize": 0.0,
"auto_execute": 0.0,
"auto_apply": 1.0,
"decompose_task": 0.0,
"create_tool": 0.0,
"select_tool": 1.0,
"guards": {
"require_approval_for_writes": true,
"require_approval_for_apply": true
+45 -45
View File
@@ -36,8 +36,8 @@ Feature: Semantic Escalation with Confidence Scoring
Scenario Outline: Threshold comparison for built-in profile <profile_name>
Given the automation profile "<profile_name>"
When I evaluate escalation for operation "auto_execute" with confidence factors past_success_rate 0.85 codebase_familiarity 0.9 risk_assessment 0.1 invariant_complexity 0.1
Then the escalation decision should match the "<profile_name>" profile threshold for "auto_execute"
When I evaluate escalation for operation "create_tool" with confidence factors past_success_rate 0.85 codebase_familiarity 0.9 risk_assessment 0.1 invariant_complexity 0.1
Then the escalation decision should match the "<profile_name>" profile threshold for "create_tool"
Examples:
| profile_name |
@@ -51,82 +51,82 @@ Feature: Semantic Escalation with Confidence Scoring
| full-auto |
Scenario: Threshold 0.0 always proceeds automatically
Given a profile with auto_execute threshold 0.0
When I evaluate escalation for operation "auto_execute" with confidence factors past_success_rate 0.0 codebase_familiarity 0.0 risk_assessment 1.0 invariant_complexity 1.0
Given a profile with create_tool threshold 0.0
When I evaluate escalation for operation "create_tool" with confidence factors past_success_rate 0.0 codebase_familiarity 0.0 risk_assessment 1.0 invariant_complexity 1.0
Then the escalation decision proceed should be true
Scenario: Threshold 1.0 escalates with realistic confidence
Given a profile with auto_execute threshold 1.0
When I evaluate escalation for operation "auto_execute" with confidence factors past_success_rate 0.95 codebase_familiarity 0.95 risk_assessment 0.05 invariant_complexity 0.05
Given a profile with create_tool threshold 1.0
When I evaluate escalation for operation "create_tool" with confidence factors past_success_rate 0.95 codebase_familiarity 0.95 risk_assessment 0.05 invariant_complexity 0.05
Then the escalation decision proceed should be false
Scenario: Exactly at threshold proceeds
Given a profile with auto_execute threshold 0.5
When I evaluate escalation for operation "auto_execute" with confidence factors past_success_rate 0.5 codebase_familiarity 0.5 risk_assessment 0.5 invariant_complexity 0.5
Given a profile with create_tool threshold 0.5
When I evaluate escalation for operation "create_tool" with confidence factors past_success_rate 0.5 codebase_familiarity 0.5 risk_assessment 0.5 invariant_complexity 0.5
Then the escalation decision proceed should be true
Scenario: Just below threshold escalates
Given a profile with auto_execute threshold 0.51
When I evaluate escalation for operation "auto_execute" with confidence factors past_success_rate 0.5 codebase_familiarity 0.5 risk_assessment 0.5 invariant_complexity 0.5
Given a profile with create_tool threshold 0.51
When I evaluate escalation for operation "create_tool" with confidence factors past_success_rate 0.5 codebase_familiarity 0.5 risk_assessment 0.5 invariant_complexity 0.5
Then the escalation decision proceed should be false
# ---- Historical success tracking ----
Scenario: Historical success rate starts at neutral
Then the historical success rate for "auto_execute" should be 0.5
Then the historical success rate for "create_tool" should be 0.5
Scenario: Recording successes increases success rate
When I record 8 successes and 2 failures for "auto_execute"
Then the historical success rate for "auto_execute" should be 0.8
When I record 8 successes and 2 failures for "create_tool"
Then the historical success rate for "create_tool" should be 0.8
Scenario: Recording all failures gives zero success rate
When I record 0 successes and 5 failures for "auto_execute"
Then the historical success rate for "auto_execute" should be 0.0
When I record 0 successes and 5 failures for "create_tool"
Then the historical success rate for "create_tool" should be 0.0
Scenario: Recording all successes gives perfect success rate
When I record 10 successes and 0 failures for "auto_execute"
Then the historical success rate for "auto_execute" should be 1.0
When I record 10 successes and 0 failures for "create_tool"
Then the historical success rate for "create_tool" should be 1.0
Scenario: Success rate evolves with new outcomes
When I record 5 successes and 5 failures for "auto_execute"
Then the historical success rate for "auto_execute" should be 0.5
When I record 5 additional successes for "auto_execute"
Then the historical success rate for "auto_execute" should be approximately 0.667
When I record 5 successes and 5 failures for "create_tool"
Then the historical success rate for "create_tool" should be 0.5
When I record 5 additional successes for "create_tool"
Then the historical success rate for "create_tool" should be approximately 0.667
Scenario: Clearing history resets to neutral
When I record 10 successes and 0 failures for "auto_execute"
And I clear history for "auto_execute"
Then the historical success rate for "auto_execute" should be 0.5
When I record 10 successes and 0 failures for "create_tool"
And I clear history for "create_tool"
Then the historical success rate for "create_tool" should be 0.5
Scenario: History count tracks recorded outcomes
When I record 3 successes and 2 failures for "auto_execute"
Then the history count for "auto_execute" should be 5
When I record 3 successes and 2 failures for "create_tool"
Then the history count for "create_tool" should be 5
# ---- Escalation explanation generation ----
Scenario: Proceeding decision includes explanation
Given a profile with auto_execute threshold 0.3
When I evaluate escalation for operation "auto_execute" with confidence factors past_success_rate 0.9 codebase_familiarity 0.9 risk_assessment 0.1 invariant_complexity 0.1
Given a profile with create_tool threshold 0.3
When I evaluate escalation for operation "create_tool" with confidence factors past_success_rate 0.9 codebase_familiarity 0.9 risk_assessment 0.1 invariant_complexity 0.1
Then the escalation explanation should contain "Proceeding automatically"
And the escalation explanation should contain "auto_execute"
And the escalation explanation should contain "create_tool"
Scenario: Escalating decision includes explanation
Given a profile with auto_execute threshold 0.99
When I evaluate escalation for operation "auto_execute" with confidence factors past_success_rate 0.5 codebase_familiarity 0.5 risk_assessment 0.5 invariant_complexity 0.5
Given a profile with create_tool threshold 0.99
When I evaluate escalation for operation "create_tool" with confidence factors past_success_rate 0.5 codebase_familiarity 0.5 risk_assessment 0.5 invariant_complexity 0.5
Then the escalation explanation should contain "Escalating to user"
And the escalation explanation should contain "auto_execute"
And the escalation explanation should contain "create_tool"
# ---- Edge cases ----
Scenario: Zero confidence with zero threshold proceeds
Given a profile with auto_execute threshold 0.0
When I evaluate escalation for operation "auto_execute" with confidence factors past_success_rate 0.0 codebase_familiarity 0.0 risk_assessment 1.0 invariant_complexity 1.0
Given a profile with create_tool threshold 0.0
When I evaluate escalation for operation "create_tool" with confidence factors past_success_rate 0.0 codebase_familiarity 0.0 risk_assessment 1.0 invariant_complexity 1.0
Then the escalation decision proceed should be true
And the confidence should be 0.0
Scenario: Perfect confidence with threshold below 1.0 proceeds
Given a profile with auto_execute threshold 0.99
When I evaluate escalation for operation "auto_execute" with confidence factors past_success_rate 1.0 codebase_familiarity 1.0 risk_assessment 0.0 invariant_complexity 0.0
Given a profile with create_tool threshold 0.99
When I evaluate escalation for operation "create_tool" with confidence factors past_success_rate 1.0 codebase_familiarity 1.0 risk_assessment 0.0 invariant_complexity 0.0
Then the escalation decision proceed should be true
And the confidence should be 1.0
@@ -160,9 +160,9 @@ Feature: Semantic Escalation with Confidence Scoring
# ---- EscalationDecision model ----
Scenario: EscalationDecision captures all fields
Given a profile with auto_execute threshold 0.5
When I evaluate escalation for operation "auto_execute" with confidence factors past_success_rate 0.8 codebase_familiarity 0.7 risk_assessment 0.2 invariant_complexity 0.3
Then the escalation decision should have operation_type "auto_execute"
Given a profile with create_tool threshold 0.5
When I evaluate escalation for operation "create_tool" with confidence factors past_success_rate 0.8 codebase_familiarity 0.7 risk_assessment 0.2 invariant_complexity 0.3
Then the escalation decision should have operation_type "create_tool"
And the escalation decision should have 4 factors
And the escalation decision threshold should be 0.5
@@ -197,18 +197,18 @@ Feature: Semantic Escalation with Confidence Scoring
Then a weight validation error should be raised
Scenario: Clearing all history resets everything
When I record 5 successes and 0 failures for "auto_execute"
And I record 5 successes and 0 failures for "auto_apply"
When I record 5 successes and 0 failures for "create_tool"
And I record 5 successes and 0 failures for "select_tool"
And I clear all history
Then the historical success rate for "auto_execute" should be 0.5
And the historical success rate for "auto_apply" should be 0.5
Then the historical success rate for "create_tool" should be 0.5
And the historical success rate for "select_tool" should be 0.5
Scenario: Weights property returns current weights
Then the controller weights should have 4 entries
Scenario: History eviction at max capacity
When I record max history outcomes for "auto_execute"
Then the history count for "auto_execute" should be 10000
When I record max history outcomes for "create_tool"
Then the history count for "create_tool" should be 10000
Scenario: Controller rejects extra weight keys
When I try to create a controller with extra weight keys
@@ -72,9 +72,9 @@ def _make_guarded_profile(
name=name,
description=description,
schema_version="1.0",
auto_strategize=0.5,
auto_execute=0.4,
auto_apply=0.3,
decompose_task=0.5,
create_tool=0.4,
select_tool=0.3,
guards=guards,
)
@@ -314,9 +314,9 @@ def step_guarded_yaml_config(context: Context, name: str) -> None:
name: {name}
description: Guarded profile for testing
schema_version: "1.0"
auto_strategize: 0.5
auto_execute: 0.4
auto_apply: 0.3
decompose_task: 0.5
create_tool: 0.4
select_tool: 0.3
guards:
max_tool_calls_per_step: 8
max_total_cost: 200.0
@@ -5,8 +5,11 @@ from __future__ import annotations
import os
import tempfile
import warnings
from pathlib import Path
from unittest.mock import patch
import jsonschema
import yaml
from behave import given, then, when
from behave.runner import Context
from typer.testing import CliRunner
@@ -59,9 +62,9 @@ def _make_profile(
name=name,
description=description,
schema_version="1.0",
auto_strategize=0.8,
auto_execute=0.7,
auto_apply=0.6,
decompose_task=0.8,
create_tool=0.7,
select_tool=0.6,
)
@@ -115,9 +118,57 @@ def step_call_threshold_summary(context: Context) -> None:
@then("the threshold summary should contain strategize execute and apply values")
def step_assert_threshold_summary(context: Context) -> None:
result = context.threshold_result
assert "strategize=" in result
assert "execute=" in result
assert "apply=" in result
assert "decompose_task=" in result
assert "create_tool=" in result
assert "select_tool=" in result
@when("I validate a guarded profile config against docs schema and model")
def step_validate_guarded_profile_schema_and_model(context: Context) -> None:
schema_path = Path("docs/schema/automation_profile.schema.yaml")
with open(schema_path) as fh:
schema = yaml.safe_load(fh)
config = {
"name": "acme/guarded",
"guards": {
"max_tool_calls_per_step": 5,
"max_total_cost": 25.0,
"tool_allowlist": ["read_file"],
"tool_denylist": ["shell_exec"],
"require_approval_for_writes": True,
"require_approval_for_apply": True,
},
}
context.guarded_profile_schema_error = None
context.guarded_profile_model_error = None
context.guarded_profile_model = None
try:
jsonschema.validate(instance=config, schema=schema)
except jsonschema.ValidationError as exc:
context.guarded_profile_schema_error = exc
try:
context.guarded_profile_model = AutomationProfile.from_config(config)
except Exception as exc: # pragma: no cover - assertion reports details
context.guarded_profile_model_error = exc
@then("the guarded profile config should pass schema and model validation")
def step_guarded_profile_schema_and_model_ok(context: Context) -> None:
assert context.guarded_profile_schema_error is None, (
"Expected docs schema validation to pass, got: "
f"{context.guarded_profile_schema_error}"
)
assert context.guarded_profile_model_error is None, (
"Expected AutomationProfile.from_config validation to pass, got: "
f"{context.guarded_profile_model_error}"
)
assert context.guarded_profile_model is not None
assert context.guarded_profile_model.guards is not None
assert context.guarded_profile_model.guards.max_tool_calls_per_step == 5
@given("a YAML file containing a list instead of a dict")
+73 -24
View File
@@ -53,17 +53,17 @@ _VALID_YAML = """\
name: acme/strict
description: Strict review for production
schema_version: "1.0"
auto_strategize: 1.0
auto_execute: 1.0
auto_apply: 1.0
auto_decisions_strategize: 1.0
auto_decisions_execute: 1.0
auto_validation_fix: 1.0
auto_strategy_revision: 1.0
auto_reversion_from_apply: 1.0
auto_child_plans: 1.0
auto_retry_transient: 1.0
auto_checkpoint_restore: 1.0
decompose_task: 1.0
create_tool: 1.0
select_tool: 1.0
edit_code: 1.0
execute_command: 1.0
create_file: 1.0
delete_content: 1.0
access_network: 1.0
install_dependency: 1.0
modify_config: 1.0
approve_plan: 1.0
safety:
require_sandbox: true
require_checkpoints: true
@@ -80,7 +80,24 @@ _INVALID_THRESHOLD_YAML = """\
name: acme/bad-threshold
description: Bad threshold
schema_version: "1.0"
auto_strategize: 2.0
decompose_task: 2.0
"""
_LEGACY_THRESHOLD_YAML = """\
name: acme/legacy-thresholds
description: Uses pre-rename threshold keys
schema_version: "1.0"
auto_strategize: 1.0
auto_execute: 1.0
auto_apply: 1.0
auto_decisions_strategize: 1.0
auto_decisions_execute: 1.0
auto_validation_fix: 1.0
auto_strategy_revision: 1.0
auto_reversion_from_apply: 1.0
auto_child_plans: 1.0
auto_retry_transient: 1.0
auto_checkpoint_restore: 1.0
"""
_INVALID_YAML_CONTENT = """\
@@ -98,17 +115,17 @@ def _make_custom_profile(
name=name,
description=description,
schema_version="1.0",
auto_strategize=1.0,
auto_execute=1.0,
auto_apply=1.0,
auto_decisions_strategize=1.0,
auto_decisions_execute=1.0,
auto_validation_fix=1.0,
auto_strategy_revision=1.0,
auto_reversion_from_apply=1.0,
auto_child_plans=1.0,
auto_retry_transient=1.0,
auto_checkpoint_restore=1.0,
decompose_task=1.0,
create_tool=1.0,
select_tool=1.0,
edit_code=1.0,
execute_command=1.0,
create_file=1.0,
delete_content=1.0,
access_network=1.0,
install_dependency=1.0,
modify_config=1.0,
approve_plan=1.0,
safety=SafetyProfile(
require_sandbox=True,
require_checkpoints=True,
@@ -137,6 +154,11 @@ def step_automation_profile_cli_runner(context: Context) -> None:
"""Set up the CLI runner for testing."""
context.runner = CliRunner()
context.result = None
# Widen the virtual terminal so Rich does not truncate profile names
# in the table output. The wider column headers introduced by the
# task-type field rename (e.g. "Create Tool") need extra room.
prev_columns = os.environ.get("COLUMNS")
os.environ["COLUMNS"] = "200"
# Create an in-memory service and patch _get_service for this scenario
context._ap_service = _create_in_memory_profile_service()
context._ap_patcher = patch(
@@ -148,6 +170,14 @@ def step_automation_profile_cli_runner(context: Context) -> None:
context._cleanup_handlers = []
context._cleanup_handlers.append(context._ap_patcher.stop)
def _restore_columns() -> None:
if prev_columns is None:
os.environ.pop("COLUMNS", None)
else:
os.environ["COLUMNS"] = prev_columns
context._cleanup_handlers.append(_restore_columns)
@given("a valid automation profile config YAML file")
def step_valid_profile_config(context: Context) -> None:
@@ -182,6 +212,14 @@ def step_invalid_threshold_config(context: Context) -> None:
)
@given("an automation profile config YAML file with legacy threshold keys")
def step_legacy_threshold_config(context: Context) -> None:
"""Write a profile config with legacy pre-rename threshold keys."""
context.legacy_threshold_yaml_path = _write_temp_yaml(
context, _LEGACY_THRESHOLD_YAML
)
@given('an automation profile config YAML file with built-in name "{name}"')
def step_builtin_name_config(context: Context, name: str) -> None:
"""Write a profile config with a built-in name to a temp file."""
@@ -189,7 +227,7 @@ def step_builtin_name_config(context: Context, name: str) -> None:
name: {name}
description: Attempt to overwrite built-in
schema_version: "1.0"
auto_strategize: 0.5
decompose_task: 0.5
"""
context.builtin_name_yaml_path = _write_temp_yaml(context, yaml_content)
@@ -276,6 +314,17 @@ def step_run_add_invalid_threshold(context: Context) -> None:
)
@when(
"I run automation-profile add with --config pointing to the legacy threshold "
"YAML file"
)
def step_run_add_legacy_threshold(context: Context) -> None:
"""Run the add command with legacy threshold keys."""
context.result = context.runner.invoke(
profile_app, ["add", "--config", context.legacy_threshold_yaml_path]
)
@when(
"I run automation-profile add with --config pointing to the built-in name YAML file"
)
@@ -181,11 +181,11 @@ def step_then_validation_error_mentions(context: Context, text: str) -> None:
assert text in err, f"Expected '{text}' in error, got: {err}"
@then("the resolved profile should have auto_apply {expected:g}")
def step_then_resolved_auto_apply(context: Context, expected: float) -> None:
"""Check resolved profile auto_apply."""
actual = context.resolved_profile.auto_apply
assert actual == expected, f"Expected auto_apply {expected}, got {actual}"
@then("the resolved profile should have select_tool {expected:g}")
def step_then_resolved_select_tool(context: Context, expected: float) -> None:
"""Check resolved profile select_tool."""
actual = context.resolved_profile.select_tool
assert actual == expected, f"Expected select_tool {expected}, got {actual}"
@then('the profile list should include "{name}"')
@@ -209,22 +209,22 @@ def step_then_retrieved_name(context: Context, expected: str) -> None:
assert actual == expected, f"Expected '{expected}', got '{actual}'"
@then("the retrieved profile auto_apply should be {expected:g}")
def step_then_retrieved_auto_apply(context: Context, expected: float) -> None:
"""Check retrieved profile auto_apply."""
actual = context.retrieved_profile.auto_apply
@then("the retrieved profile select_tool should be {expected:g}")
def step_then_retrieved_select_tool(context: Context, expected: float) -> None:
"""Check retrieved profile select_tool."""
actual = context.retrieved_profile.select_tool
assert actual == expected, f"Expected {expected}, got {actual}"
@then("the retrieved profile auto_strategize should be {expected:g}")
def step_then_retrieved_auto_strategize(context: Context, expected: float) -> None:
"""Check retrieved profile auto_strategize."""
actual = context.retrieved_profile.auto_strategize
@then("the retrieved profile decompose_task should be {expected:g}")
def step_then_retrieved_decompose_task(context: Context, expected: float) -> None:
"""Check retrieved profile decompose_task."""
actual = context.retrieved_profile.decompose_task
assert actual == expected, f"Expected {expected}, got {actual}"
@then("the retrieved profile auto_execute should be {expected:g}")
def step_then_retrieved_auto_execute(context: Context, expected: float) -> None:
"""Check retrieved profile auto_execute."""
actual = context.retrieved_profile.auto_execute
@then("the retrieved profile create_tool should be {expected:g}")
def step_then_retrieved_create_tool(context: Context, expected: float) -> None:
"""Check retrieved profile create_tool."""
actual = context.retrieved_profile.create_tool
assert actual == expected, f"Expected {expected}, got {actual}"
+91 -91
View File
@@ -31,130 +31,130 @@ def _make_profile(**overrides: Any) -> AutomationProfile:
# ---------------------------------------------------------------------------
@when("I create a profile with auto_strategize {value:g}")
def step_create_profile_auto_strategize(context: Context, value: float) -> None:
"""Create a profile with a specific auto_strategize."""
context.profile_model = _make_profile(auto_strategize=value)
@when("I create a profile with decompose_task {value:g}")
def step_create_profile_decompose_task(context: Context, value: float) -> None:
"""Create a profile with a specific decompose_task."""
context.profile_model = _make_profile(decompose_task=value)
context.profile_error = None
@when("I try to create a profile with auto_strategize {value:g}")
def step_try_create_profile_auto_strategize(context: Context, value: float) -> None:
"""Try creating a profile with invalid auto_strategize."""
@when("I try to create a profile with decompose_task {value:g}")
def step_try_create_profile_decompose_task(context: Context, value: float) -> None:
"""Try creating a profile with invalid decompose_task."""
context.profile_error = None
context.profile_model = None
try:
context.profile_model = _make_profile(auto_strategize=value)
context.profile_model = _make_profile(decompose_task=value)
except ValidationError as e:
context.profile_error = e
@when("I try to create a profile with auto_execute {value:g}")
def step_try_create_profile_auto_execute(context: Context, value: float) -> None:
"""Try creating a profile with invalid auto_execute."""
@when("I try to create a profile with create_tool {value:g}")
def step_try_create_profile_create_tool(context: Context, value: float) -> None:
"""Try creating a profile with invalid create_tool."""
context.profile_error = None
context.profile_model = None
try:
context.profile_model = _make_profile(auto_execute=value)
context.profile_model = _make_profile(create_tool=value)
except ValidationError as e:
context.profile_error = e
@when("I try to create a profile with auto_apply {value:g}")
def step_try_create_profile_auto_apply(context: Context, value: float) -> None:
"""Try creating with invalid auto_apply."""
@when("I try to create a profile with select_tool {value:g}")
def step_try_create_profile_select_tool(context: Context, value: float) -> None:
"""Try creating with invalid select_tool."""
context.profile_error = None
context.profile_model = None
try:
context.profile_model = _make_profile(auto_apply=value)
context.profile_model = _make_profile(select_tool=value)
except ValidationError as e:
context.profile_error = e
@when("I try to create a profile with auto_decisions_strategize {value:g}")
@when("I try to create a profile with edit_code {value:g}")
def step_try_create_profile_auto_dec_strat(context: Context, value: float) -> None:
"""Try creating with invalid auto_decisions_strategize."""
"""Try creating with invalid edit_code."""
context.profile_error = None
context.profile_model = None
try:
context.profile_model = _make_profile(auto_decisions_strategize=value)
context.profile_model = _make_profile(edit_code=value)
except ValidationError as e:
context.profile_error = e
@when("I try to create a profile with auto_decisions_execute {value:g}")
@when("I try to create a profile with execute_command {value:g}")
def step_try_create_profile_auto_dec_exec(context: Context, value: float) -> None:
"""Try creating with invalid auto_decisions_execute."""
"""Try creating with invalid execute_command."""
context.profile_error = None
context.profile_model = None
try:
context.profile_model = _make_profile(auto_decisions_execute=value)
context.profile_model = _make_profile(execute_command=value)
except ValidationError as e:
context.profile_error = e
@when("I try to create a profile with auto_validation_fix {value:g}")
@when("I try to create a profile with create_file {value:g}")
def step_try_create_profile_auto_val_fix(context: Context, value: float) -> None:
"""Try creating with invalid auto_validation_fix."""
"""Try creating with invalid create_file."""
context.profile_error = None
context.profile_model = None
try:
context.profile_model = _make_profile(auto_validation_fix=value)
context.profile_model = _make_profile(create_file=value)
except ValidationError as e:
context.profile_error = e
@when("I try to create a profile with auto_strategy_revision {value:g}")
@when("I try to create a profile with delete_content {value:g}")
def step_try_create_profile_auto_strat_rev(context: Context, value: float) -> None:
"""Try creating with invalid auto_strategy_revision."""
"""Try creating with invalid delete_content."""
context.profile_error = None
context.profile_model = None
try:
context.profile_model = _make_profile(auto_strategy_revision=value)
context.profile_model = _make_profile(delete_content=value)
except ValidationError as e:
context.profile_error = e
@when("I try to create a profile with auto_reversion_from_apply {value:g}")
@when("I try to create a profile with access_network {value:g}")
def step_try_create_profile_auto_rev_apply(context: Context, value: float) -> None:
"""Try creating with invalid auto_reversion_from_apply."""
"""Try creating with invalid access_network."""
context.profile_error = None
context.profile_model = None
try:
context.profile_model = _make_profile(auto_reversion_from_apply=value)
context.profile_model = _make_profile(access_network=value)
except ValidationError as e:
context.profile_error = e
@when("I try to create a profile with auto_child_plans {value:g}")
@when("I try to create a profile with install_dependency {value:g}")
def step_try_create_profile_auto_child(context: Context, value: float) -> None:
"""Try creating with invalid auto_child_plans."""
"""Try creating with invalid install_dependency."""
context.profile_error = None
context.profile_model = None
try:
context.profile_model = _make_profile(auto_child_plans=value)
context.profile_model = _make_profile(install_dependency=value)
except ValidationError as e:
context.profile_error = e
@when("I try to create a profile with auto_retry_transient {value:g}")
@when("I try to create a profile with modify_config {value:g}")
def step_try_create_profile_auto_retry(context: Context, value: float) -> None:
"""Try creating with invalid auto_retry_transient."""
"""Try creating with invalid modify_config."""
context.profile_error = None
context.profile_model = None
try:
context.profile_model = _make_profile(auto_retry_transient=value)
context.profile_model = _make_profile(modify_config=value)
except ValidationError as e:
context.profile_error = e
@when("I try to create a profile with auto_checkpoint_restore {value:g}")
@when("I try to create a profile with approve_plan {value:g}")
def step_try_create_profile_auto_ckpt(context: Context, value: float) -> None:
"""Try creating with invalid auto_checkpoint_restore."""
"""Try creating with invalid approve_plan."""
context.profile_error = None
context.profile_model = None
try:
context.profile_model = _make_profile(auto_checkpoint_restore=value)
context.profile_model = _make_profile(approve_plan=value)
except ValidationError as e:
context.profile_error = e
@@ -170,80 +170,80 @@ def step_check_profile_created(context: Context) -> None:
assert context.profile_model is not None, "Profile should be created"
@then("the profile auto_strategize should be {expected:g}")
def step_check_auto_strategize(context: Context, expected: float) -> None:
"""Check auto_strategize value."""
actual = context.profile_model.auto_strategize
assert actual == expected, f"Expected auto_strategize {expected}, got {actual}"
@then("the profile decompose_task should be {expected:g}")
def step_check_decompose_task(context: Context, expected: float) -> None:
"""Check decompose_task value."""
actual = context.profile_model.decompose_task
assert actual == expected, f"Expected decompose_task {expected}, got {actual}"
@then("the profile auto_execute should be {expected:g}")
def step_check_auto_execute(context: Context, expected: float) -> None:
"""Check auto_execute value."""
actual = context.profile_model.auto_execute
assert actual == expected, f"Expected auto_execute {expected}, got {actual}"
@then("the profile create_tool should be {expected:g}")
def step_check_create_tool(context: Context, expected: float) -> None:
"""Check create_tool value."""
actual = context.profile_model.create_tool
assert actual == expected, f"Expected create_tool {expected}, got {actual}"
@then("the profile auto_apply should be {expected:g}")
def step_check_auto_apply(context: Context, expected: float) -> None:
"""Check auto_apply value."""
actual = context.profile_model.auto_apply
assert actual == expected, f"Expected auto_apply {expected}, got {actual}"
@then("the profile select_tool should be {expected:g}")
def step_check_select_tool(context: Context, expected: float) -> None:
"""Check select_tool value."""
actual = context.profile_model.select_tool
assert actual == expected, f"Expected select_tool {expected}, got {actual}"
@then("the profile auto_decisions_strategize should be {expected:g}")
@then("the profile edit_code should be {expected:g}")
def step_check_auto_dec_strat(context: Context, expected: float) -> None:
"""Check auto_decisions_strategize value."""
actual = context.profile_model.auto_decisions_strategize
"""Check edit_code value."""
actual = context.profile_model.edit_code
assert actual == expected, f"Expected {expected}, got {actual}"
@then("the profile auto_decisions_execute should be {expected:g}")
@then("the profile execute_command should be {expected:g}")
def step_check_auto_dec_exec(context: Context, expected: float) -> None:
"""Check auto_decisions_execute value."""
actual = context.profile_model.auto_decisions_execute
"""Check execute_command value."""
actual = context.profile_model.execute_command
assert actual == expected, f"Expected {expected}, got {actual}"
@then("the profile auto_validation_fix should be {expected:g}")
@then("the profile create_file should be {expected:g}")
def step_check_auto_val_fix(context: Context, expected: float) -> None:
"""Check auto_validation_fix value."""
actual = context.profile_model.auto_validation_fix
"""Check create_file value."""
actual = context.profile_model.create_file
assert actual == expected, f"Expected {expected}, got {actual}"
@then("the profile auto_strategy_revision should be {expected:g}")
@then("the profile delete_content should be {expected:g}")
def step_check_auto_strat_rev(context: Context, expected: float) -> None:
"""Check auto_strategy_revision value."""
actual = context.profile_model.auto_strategy_revision
"""Check delete_content value."""
actual = context.profile_model.delete_content
assert actual == expected, f"Expected {expected}, got {actual}"
@then("the profile auto_reversion_from_apply should be {expected:g}")
@then("the profile access_network should be {expected:g}")
def step_check_auto_rev_apply(context: Context, expected: float) -> None:
"""Check auto_reversion_from_apply value."""
actual = context.profile_model.auto_reversion_from_apply
"""Check access_network value."""
actual = context.profile_model.access_network
assert actual == expected, f"Expected {expected}, got {actual}"
@then("the profile auto_child_plans should be {expected:g}")
@then("the profile install_dependency should be {expected:g}")
def step_check_auto_child(context: Context, expected: float) -> None:
"""Check auto_child_plans value."""
actual = context.profile_model.auto_child_plans
"""Check install_dependency value."""
actual = context.profile_model.install_dependency
assert actual == expected, f"Expected {expected}, got {actual}"
@then("the profile auto_retry_transient should be {expected:g}")
@then("the profile modify_config should be {expected:g}")
def step_check_auto_retry(context: Context, expected: float) -> None:
"""Check auto_retry_transient value."""
actual = context.profile_model.auto_retry_transient
"""Check modify_config value."""
actual = context.profile_model.modify_config
assert actual == expected, f"Expected {expected}, got {actual}"
@then("the profile auto_checkpoint_restore should be {expected:g}")
@then("the profile approve_plan should be {expected:g}")
def step_check_auto_ckpt(context: Context, expected: float) -> None:
"""Check auto_checkpoint_restore value."""
actual = context.profile_model.auto_checkpoint_restore
"""Check approve_plan value."""
actual = context.profile_model.approve_plan
assert actual == expected, f"Expected {expected}, got {actual}"
@@ -327,13 +327,13 @@ def step_check_builtin_exists(context: Context, name: str) -> None:
# ---------------------------------------------------------------------------
@when('I load a profile from config with name "{name}" and auto_apply {value:g}')
@when('I load a profile from config with name "{name}" and select_tool {value:g}')
def step_load_profile_from_config(context: Context, name: str, value: float) -> None:
"""Load a profile from config dict."""
config = {
"name": name,
"description": "Custom profile",
"auto_apply": value,
"select_tool": value,
}
context.profile_model = AutomationProfile.from_config(config)
context.profile_error = None
@@ -490,12 +490,12 @@ def step_create_profile_with_desc(context: Context, desc: str) -> None:
# ---------------------------------------------------------------------------
@when("I try to assign auto_strategize {value:g} on the profile")
@when("I try to assign decompose_task {value:g} on the profile")
def step_try_assign_threshold(context: Context, value: float) -> None:
"""Try to assign an invalid threshold on existing profile."""
context.profile_error = None
try:
context.profile_model.auto_strategize = value
context.profile_model.decompose_task = value
except ValidationError as e:
context.profile_error = e
@@ -505,10 +505,10 @@ def step_try_assign_threshold(context: Context, value: float) -> None:
# ---------------------------------------------------------------------------
@when("I create a profile and dump it with auto_apply {value:g}")
def step_create_profile_with_auto_apply(context: Context, value: float) -> None:
@when("I create a profile and dump it with select_tool {value:g}")
def step_create_profile_with_select_tool(context: Context, value: float) -> None:
"""Create a profile and store model dump."""
context.profile_model = AutomationProfile(name="dump-test", auto_apply=value)
context.profile_model = AutomationProfile(name="dump-test", select_tool=value)
context.profile_dump = context.profile_model.model_dump()
context.profile_error = None
@@ -521,8 +521,8 @@ def step_check_dump_key(context: Context, key: str) -> None:
)
@then("the profile model dump auto_apply should be {expected:g}")
def step_check_dump_auto_apply(context: Context, expected: float) -> None:
"""Check auto_apply in model dump."""
actual = context.profile_dump["auto_apply"]
assert actual == expected, f"Expected auto_apply {expected}, got {actual}"
@then("the profile model dump select_tool should be {expected:g}")
def step_check_dump_select_tool(context: Context, expected: float) -> None:
"""Check select_tool in model dump."""
actual = context.profile_dump["select_tool"]
assert actual == expected, f"Expected select_tool {expected}, got {actual}"
+19 -19
View File
@@ -105,28 +105,28 @@ def step_m6_smoke_load_builtin(context: Context, name: str) -> None:
context.m6_profile = BUILTIN_PROFILES[name]
@then("the m6 smoke profile auto_strategize should be {value:g}")
def step_m6_smoke_profile_auto_strategize(
@then("the m6 smoke profile decompose_task should be {value:g}")
def step_m6_smoke_profile_decompose_task(
context: Context,
value: float,
) -> None:
assert context.m6_profile.auto_strategize == value
assert context.m6_profile.decompose_task == value
@then("the m6 smoke profile auto_execute should be {value:g}")
def step_m6_smoke_profile_auto_execute(
@then("the m6 smoke profile create_tool should be {value:g}")
def step_m6_smoke_profile_create_tool(
context: Context,
value: float,
) -> None:
assert context.m6_profile.auto_execute == value
assert context.m6_profile.create_tool == value
@then("the m6 smoke profile auto_apply should be {value:g}")
def step_m6_smoke_profile_auto_apply(
@then("the m6 smoke profile select_tool should be {value:g}")
def step_m6_smoke_profile_select_tool(
context: Context,
value: float,
) -> None:
assert context.m6_profile.auto_apply == value
assert context.m6_profile.select_tool == value
@then("the m6 smoke profile require_sandbox should be true")
@@ -149,13 +149,13 @@ def step_m6_smoke_profile_unsafe_true(context: Context) -> None:
# -----------------------------------------------------------------------
@when('I m6 smoke create a profile named "{name}" with auto_apply {value:g}')
@when('I m6 smoke create a profile named "{name}" with select_tool {value:g}')
def step_m6_smoke_create_profile(
context: Context,
name: str,
value: float,
) -> None:
context.m6_profile = AutomationProfile(name=name, auto_apply=value)
context.m6_profile = AutomationProfile(name=name, select_tool=value)
@then('the m6 smoke created profile name should be "{name}"')
@@ -163,9 +163,9 @@ def step_m6_smoke_created_name(context: Context, name: str) -> None:
assert context.m6_profile.name == name
@then("the m6 smoke created profile auto_apply should be {value:g}")
def step_m6_smoke_created_auto_apply(context: Context, value: float) -> None:
assert context.m6_profile.auto_apply == value
@then("the m6 smoke created profile select_tool should be {value:g}")
def step_m6_smoke_created_select_tool(context: Context, value: float) -> None:
assert context.m6_profile.select_tool == value
@when('I m6 smoke create a profile with invalid name "{name}"')
@@ -182,10 +182,10 @@ def step_m6_smoke_error_value(context: Context) -> None:
assert isinstance(context.m6_error, (ValueError,))
@when("I m6 smoke create a profile with auto_strategize {value:g}")
@when("I m6 smoke create a profile with decompose_task {value:g}")
def step_m6_smoke_invalid_threshold(context: Context, value: float) -> None:
try:
AutomationProfile(name="test-bad-threshold", auto_strategize=value)
AutomationProfile(name="test-bad-threshold", decompose_task=value)
context.m6_error = None
except ValueError as exc:
context.m6_error = exc
@@ -196,9 +196,9 @@ def step_m6_smoke_yaml_file(context: Context) -> None:
config = {
"name": "test-yaml-profile",
"description": "A profile loaded from YAML",
"auto_strategize": 0.5,
"auto_execute": 0.5,
"auto_apply": 1.0,
"decompose_task": 0.5,
"create_tool": 0.5,
"select_tool": 1.0,
}
with tempfile.NamedTemporaryFile(
mode="w",
@@ -290,9 +290,9 @@ def step_plan_in_apply_constrained_max_reversions(context: Context) -> None:
@given("the plan uses a profile that permits auto-reversion from apply")
def step_set_profile_permitting_reversion(context: Context) -> None:
"""Set an automation profile that allows auto-reversion from apply
(auto_reversion_from_apply < 1.0)."""
(access_network < 1.0 permits automatic reversion)."""
context.plan.automation_profile = AutomationProfileRef(
profile_name="ci", # ci profile has auto_reversion_from_apply=0.0
profile_name="ci", # ci: access_network=0.0 (auto-revert from Apply permitted)
provenance=AutomationProfileProvenance.PLAN,
)
@@ -373,9 +373,9 @@ def step_plan_in_execute_max_reversions(context: Context) -> None:
@given("the plan uses a profile that permits auto-reversion from execute")
def step_set_profile_permitting_execute_reversion(context: Context) -> None:
"""Set an automation profile that allows auto-reversion from execute
(auto_strategy_revision < 1.0)."""
(delete_content < 1.0 permits strategy revision)."""
context.plan.automation_profile = AutomationProfileRef(
profile_name="ci", # ci profile has auto_strategy_revision=0.0
profile_name="ci", # ci: delete_content=0.0 (strategy revision permitted)
provenance=AutomationProfileProvenance.PLAN,
)
@@ -102,7 +102,7 @@ def step_r2_plan_strategize_complete(context: Context) -> None:
context.r2_plan = context.r2_service.get_plan(plan.identity.plan_id)
# If auto_progress already executed, the plan may be in EXECUTE.
# For testing execute_plan explicitly, we need the plan in STRATEGIZE/COMPLETE.
# The manual profile (default) has auto_execute=1.0 so auto_progress won't fire.
# The manual profile (default) has create_tool=1.0 so auto_progress won't fire.
context.r2_ctx.reset_mock()
@@ -188,17 +188,17 @@ def _make_fake_automation_profile() -> SimpleNamespace:
name="local/test-profile",
description="A test profile",
schema_version="1.0",
auto_strategize=0.0,
auto_execute=0.0,
auto_apply=0.0,
auto_decisions_strategize=0.0,
auto_decisions_execute=0.0,
auto_validation_fix=0.0,
auto_strategy_revision=0.0,
auto_reversion_from_apply=0.0,
auto_child_plans=0.0,
auto_retry_transient=0.0,
auto_checkpoint_restore=0.0,
decompose_task=0.0,
create_tool=0.0,
select_tool=0.0,
edit_code=0.0,
execute_command=0.0,
create_file=0.0,
delete_content=0.0,
access_network=0.0,
install_dependency=0.0,
modify_config=0.0,
approve_plan=0.0,
safety=SimpleNamespace(
require_sandbox=True,
require_checkpoints=True,
@@ -120,17 +120,17 @@ def _make_automation_profile(
name=name,
description=description,
schema_version=schema_version,
auto_strategize=0.0,
auto_execute=0.0,
auto_apply=0.0,
auto_decisions_strategize=0.0,
auto_decisions_execute=0.0,
auto_validation_fix=0.0,
auto_strategy_revision=0.0,
auto_reversion_from_apply=0.0,
auto_child_plans=0.0,
auto_retry_transient=0.0,
auto_checkpoint_restore=0.0,
decompose_task=0.0,
create_tool=0.0,
select_tool=0.0,
edit_code=0.0,
execute_command=0.0,
create_file=0.0,
delete_content=0.0,
access_network=0.0,
install_dependency=0.0,
modify_config=0.0,
approve_plan=0.0,
safety=SafetyProfile(**safety_defaults),
)
defaults.update(overrides)
@@ -1407,17 +1407,17 @@ def step_given_ap_full_fields(context, name):
name,
description="full fields profile",
schema_version="2.0",
auto_strategize=0.1,
auto_execute=0.2,
auto_apply=0.3,
auto_decisions_strategize=0.4,
auto_decisions_execute=0.5,
auto_validation_fix=0.6,
auto_strategy_revision=0.7,
auto_reversion_from_apply=0.8,
auto_child_plans=0.9,
auto_retry_transient=0.15,
auto_checkpoint_restore=0.25,
decompose_task=0.1,
create_tool=0.2,
select_tool=0.3,
edit_code=0.4,
execute_command=0.5,
create_file=0.6,
delete_content=0.7,
access_network=0.8,
install_dependency=0.9,
modify_config=0.15,
approve_plan=0.25,
require_sandbox=False,
require_checkpoints=False,
allow_unsafe_tools=True,
@@ -1434,21 +1434,17 @@ def step_then_ap_all_fields(context):
assert result.name == orig.name
assert result.description == orig.description
assert result.schema_version == orig.schema_version
assert abs(result.auto_strategize - orig.auto_strategize) < 0.001
assert abs(result.auto_execute - orig.auto_execute) < 0.001
assert abs(result.auto_apply - orig.auto_apply) < 0.001
assert (
abs(result.auto_decisions_strategize - orig.auto_decisions_strategize) < 0.001
)
assert abs(result.auto_decisions_execute - orig.auto_decisions_execute) < 0.001
assert abs(result.auto_validation_fix - orig.auto_validation_fix) < 0.001
assert abs(result.auto_strategy_revision - orig.auto_strategy_revision) < 0.001
assert (
abs(result.auto_reversion_from_apply - orig.auto_reversion_from_apply) < 0.001
)
assert abs(result.auto_child_plans - orig.auto_child_plans) < 0.001
assert abs(result.auto_retry_transient - orig.auto_retry_transient) < 0.001
assert abs(result.auto_checkpoint_restore - orig.auto_checkpoint_restore) < 0.001
assert abs(result.decompose_task - orig.decompose_task) < 0.001
assert abs(result.create_tool - orig.create_tool) < 0.001
assert abs(result.select_tool - orig.select_tool) < 0.001
assert abs(result.edit_code - orig.edit_code) < 0.001
assert abs(result.execute_command - orig.execute_command) < 0.001
assert abs(result.create_file - orig.create_file) < 0.001
assert abs(result.delete_content - orig.delete_content) < 0.001
assert abs(result.access_network - orig.access_network) < 0.001
assert abs(result.install_dependency - orig.install_dependency) < 0.001
assert abs(result.modify_config - orig.modify_config) < 0.001
assert abs(result.approve_plan - orig.approve_plan) < 0.001
assert result.safety.require_sandbox == orig.safety.require_sandbox
assert result.safety.require_checkpoints == orig.safety.require_checkpoints
assert result.safety.allow_unsafe_tools == orig.safety.allow_unsafe_tools
@@ -1464,8 +1460,8 @@ def step_given_ap_specific_fields(context, name):
profile = _make_automation_profile(
name,
description="original",
auto_strategize=0.1,
auto_execute=0.2,
decompose_task=0.1,
create_tool=0.2,
require_sandbox=True,
allow_unsafe_tools=False,
)
@@ -1479,17 +1475,17 @@ def step_when_ap_update_fields(context, name):
profile = _make_automation_profile(
name,
description="updated roundtrip",
auto_strategize=0.9,
auto_execute=0.8,
auto_apply=0.7,
auto_decisions_strategize=0.6,
auto_decisions_execute=0.5,
auto_validation_fix=0.4,
auto_strategy_revision=0.3,
auto_reversion_from_apply=0.2,
auto_child_plans=0.1,
auto_retry_transient=0.05,
auto_checkpoint_restore=0.15,
decompose_task=0.9,
create_tool=0.8,
select_tool=0.7,
edit_code=0.6,
execute_command=0.5,
create_file=0.4,
delete_content=0.3,
access_network=0.2,
install_dependency=0.1,
modify_config=0.05,
approve_plan=0.15,
require_sandbox=False,
require_checkpoints=False,
allow_unsafe_tools=True,
@@ -1504,9 +1500,17 @@ def step_then_ap_new_values(context, name):
expected = context._ucl_ap_updated_vals
assert result is not None, f"Profile '{name}' was None"
assert result.description == expected.description
assert abs(result.auto_strategize - expected.auto_strategize) < 0.001
assert abs(result.auto_execute - expected.auto_execute) < 0.001
assert abs(result.auto_apply - expected.auto_apply) < 0.001
assert abs(result.decompose_task - expected.decompose_task) < 0.001
assert abs(result.create_tool - expected.create_tool) < 0.001
assert abs(result.select_tool - expected.select_tool) < 0.001
assert abs(result.edit_code - expected.edit_code) < 0.001
assert abs(result.execute_command - expected.execute_command) < 0.001
assert abs(result.create_file - expected.create_file) < 0.001
assert abs(result.delete_content - expected.delete_content) < 0.001
assert abs(result.access_network - expected.access_network) < 0.001
assert abs(result.install_dependency - expected.install_dependency) < 0.001
assert abs(result.modify_config - expected.modify_config) < 0.001
assert abs(result.approve_plan - expected.approve_plan) < 0.001
assert result.safety.require_sandbox == expected.safety.require_sandbox
assert result.safety.require_checkpoints == expected.safety.require_checkpoints
assert result.safety.allow_unsafe_tools == expected.safety.allow_unsafe_tools
+5 -5
View File
@@ -90,15 +90,15 @@ def step_given_profile(context: Context, profile_name: str) -> None:
context.profile = BUILTIN_PROFILES[profile_name]
@given("a profile with auto_execute threshold {threshold:g}")
@given("a profile with create_tool threshold {threshold:g}")
def step_given_custom_threshold_profile(
context: Context,
threshold: float,
) -> None:
"""Create a minimal profile with a specific auto_execute threshold."""
"""Create a minimal profile with a specific create_tool threshold."""
context.profile = AutomationProfile(
name="test-profile",
auto_execute=threshold,
create_tool=threshold,
)
@@ -426,7 +426,7 @@ def step_call_proceed_none_operation(context: Context) -> None:
def step_call_proceed_none_factors(context: Context) -> None:
"""Call should_proceed_automatically with None factors."""
try:
op = OperationContext(operation_type="auto_execute")
op = OperationContext(operation_type="create_tool")
profile = AutomationProfile(name="test")
context.controller.should_proceed_automatically(
op,
@@ -442,7 +442,7 @@ def step_call_proceed_none_factors(context: Context) -> None:
def step_call_proceed_none_profile(context: Context) -> None:
"""Call should_proceed_automatically with None profile."""
try:
op = OperationContext(operation_type="auto_execute")
op = OperationContext(operation_type="create_tool")
factors = ConfidenceFactors()
context.controller.should_proceed_automatically(
op,
@@ -92,13 +92,13 @@ def step_plan_prompt_echoes_empty_guidance(context: Context) -> None:
# ---------------------------------------------------------------------------
@given("the cautious auto_decisions_strategize threshold should be {threshold:g}")
@given("the cautious edit_code threshold should be {threshold:g}")
def step_verify_cautious_threshold(context: Context, threshold: float) -> None:
"""Verify the cautious profile auto_decisions_strategize threshold."""
"""Verify the cautious profile edit_code threshold."""
profile = BUILTIN_PROFILES["cautious"]
actual = profile.auto_decisions_strategize
actual = profile.edit_code
assert abs(actual - threshold) < 1e-6, (
f"Expected cautious auto_decisions_strategize={threshold}, got {actual}"
f"Expected cautious edit_code={threshold}, got {actual}"
)
+7 -7
View File
@@ -37,29 +37,29 @@ Feature: WF03 plan prompt and confidence-threshold pausing verification
Scenario: Cautious profile pauses on low-confidence strategy decision
Given a default autonomy controller
And the automation profile "cautious"
And the cautious auto_decisions_strategize threshold should be 0.6
When I evaluate escalation for operation "auto_decisions_strategize" with confidence factors past_success_rate 0.4 codebase_familiarity 0.5 risk_assessment 0.6 invariant_complexity 0.5
And the cautious edit_code threshold should be 0.6
When I evaluate escalation for operation "edit_code" with confidence factors past_success_rate 0.4 codebase_familiarity 0.5 risk_assessment 0.6 invariant_complexity 0.5
Then the escalation decision proceed should be false
And the escalation confidence should be below the cautious threshold 0.6
Scenario: Cautious profile proceeds on high-confidence strategy decision
Given a default autonomy controller
And the automation profile "cautious"
When I evaluate escalation for operation "auto_decisions_strategize" with confidence factors past_success_rate 0.9 codebase_familiarity 0.8 risk_assessment 0.1 invariant_complexity 0.1
When I evaluate escalation for operation "edit_code" with confidence factors past_success_rate 0.9 codebase_familiarity 0.8 risk_assessment 0.1 invariant_complexity 0.1
Then the escalation decision proceed should be true
And the escalation confidence should be at or above the cautious threshold 0.6
Scenario: Cautious profile pauses when confidence equals 0.55 for strategy decisions
Given a default autonomy controller
And the automation profile "cautious"
When I evaluate escalation for operation "auto_decisions_strategize" with factors producing confidence 0.55
When I evaluate escalation for operation "edit_code" with factors producing confidence 0.55
Then the escalation decision proceed should be false
And the decision explanation should mention threshold
Scenario: Cautious profile proceeds when confidence equals 0.6 exactly for strategy decisions
Given a default autonomy controller
And the automation profile "cautious"
When I evaluate escalation for operation "auto_decisions_strategize" with factors producing confidence 0.6
When I evaluate escalation for operation "edit_code" with factors producing confidence 0.6
Then the escalation decision proceed should be true
# --------------------------------------------------------------------------
@@ -72,12 +72,12 @@ Feature: WF03 plan prompt and confidence-threshold pausing verification
Scenario: WF03 full pause-and-resume flow with cautious profile
Given a default autonomy controller
And the automation profile "cautious"
And a decision seeded with confidence 0.55 for operation "auto_decisions_strategize"
And a decision seeded with confidence 0.55 for operation "edit_code"
When I check whether the system should proceed automatically
Then the escalation decision proceed should be false
And the decision explanation should mention escalation to user
When I provide plan prompt guidance "Use separate models/ directory" for the paused plan
Then the guidance should be recorded as a user intervention
And the guidance response plan id should match the paused decision context
When I re-evaluate with corrected confidence 0.85 for operation "auto_decisions_strategize"
When I re-evaluate with corrected confidence 0.85 for operation "edit_code"
Then the escalation decision proceed should be true
+9 -9
View File
@@ -93,8 +93,8 @@ Guard Enforcement Assertions
# Verify automation-profile-specific fields appear in combined output
${combined}= Set Variable ${plan_use.stdout} ${plan_use.stderr}
${combined_lower}= Evaluate ($combined).lower()
${has_profile}= Evaluate 'automation_profile' in $combined_lower or 'automation-profile' in $combined_lower or 'require_sandbox' in $combined_lower or 'auto_strategize' in $combined_lower or 'auto_execute' in $combined_lower or 'safety_profile' in $combined_lower or '"${expected_profile}"' in $combined_lower
Should Be True ${has_profile} Plan output should reference automation profile fields (automation_profile, require_sandbox, auto_strategize, etc.)
${has_profile}= Evaluate 'automation_profile' in $combined_lower or 'automation-profile' in $combined_lower or 'require_sandbox' in $combined_lower or 'decompose_task' in $combined_lower or 'create_tool' in $combined_lower or 'safety_profile' in $combined_lower or '"${expected_profile}"' in $combined_lower
Should Be True ${has_profile} Plan output should reference automation profile fields (automation_profile, require_sandbox, decompose_task, etc.)
Full Flow Apply Step
[Documentation] Attempt lifecycle-apply after execute succeeds and verify state transition.
@@ -167,9 +167,9 @@ M6 E2E Automation Profile Show
Should Not Be Empty ${result.stdout}
Output Should Contain ${result} manual
# Threshold fields should be present
Output Should Contain ${result} auto_strategize
Output Should Contain ${result} auto_execute
Output Should Contain ${result} auto_apply
Output Should Contain ${result} decompose_task
Output Should Contain ${result} create_tool
Output Should Contain ${result} select_tool
M6 E2E Config Automation Profile
[Documentation] Set and get the automation profile configuration key.
@@ -220,9 +220,9 @@ M6 E2E Guard Enforcement Denylist Budget Limits
... name: ${guard_profile_name}
... description: E2E test profile with denylist budget and tool-call limits
... schema_version: "1.0"
... auto_strategize: 0.5
... auto_execute: 0.5
... auto_apply: 1.0
... decompose_task: 0.5
... create_tool: 0.5
... select_tool: 1.0
... safety:
... ${SPACE}${SPACE}require_sandbox: true
... ${SPACE}${SPACE}require_checkpoints: true
@@ -382,7 +382,7 @@ M6 E2E Hierarchical Decomposition Via Plan Tree
[Teardown] Run CleverAgents Command config set core.automation-profile manual expected_rc=None
Skip If No LLM Keys
${proj_name}= Setup Plan Test Resources tree
# Create plan with full-auto profile (enables auto_child_plans for decomposition)
# Create plan with full-auto profile (enables install_dependency for decomposition)
${plan_use}= Run CleverAgents Command plan use local/code-review ${proj_name} --automation-profile full-auto --format json expected_rc=None timeout=180s
# P0-2: Fail (not Skip) when API keys are present but plan use fails.
Should Be Equal As Integers ${plan_use.rc} 0
+3 -3
View File
@@ -130,6 +130,6 @@ WF14 E2E Supervised Profile Verification
${result}= Run CleverAgents Command automation-profile show supervised
Output Should Contain ${result} supervised
# Verify supervised-specific threshold fields are present in the output
Output Should Contain ${result} auto_strategize
Output Should Contain ${result} auto_execute
Output Should Contain ${result} auto_apply
Output Should Contain ${result} decompose_task
Output Should Contain ${result} execute_command
Output Should Contain ${result} approve_plan
+14 -14
View File
@@ -32,9 +32,9 @@ def _test_profile(name: str) -> None:
profile = get_builtin_profile(name)
assert isinstance(profile, AutomationProfile)
assert profile.name == name
assert 0.0 <= profile.auto_strategize <= 1.0
assert 0.0 <= profile.auto_execute <= 1.0
assert 0.0 <= profile.auto_apply <= 1.0
assert 0.0 <= profile.decompose_task <= 1.0
assert 0.0 <= profile.create_tool <= 1.0
assert 0.0 <= profile.select_tool <= 1.0
print(
f"profile-{name}-ok "
f"(sandbox={profile.safety.require_sandbox}, "
@@ -49,17 +49,17 @@ def _test_summary() -> None:
for name in _PROFILE_NAMES:
profile = get_builtin_profile(name)
thresholds = [
profile.auto_strategize,
profile.auto_execute,
profile.auto_apply,
profile.auto_decisions_strategize,
profile.auto_decisions_execute,
profile.auto_validation_fix,
profile.auto_strategy_revision,
profile.auto_reversion_from_apply,
profile.auto_child_plans,
profile.auto_retry_transient,
profile.auto_checkpoint_restore,
profile.decompose_task,
profile.create_tool,
profile.select_tool,
profile.edit_code,
profile.execute_command,
profile.create_file,
profile.delete_content,
profile.access_network,
profile.install_dependency,
profile.modify_config,
profile.approve_plan,
]
avg = sum(thresholds) / len(thresholds)
print(
+11 -11
View File
@@ -53,17 +53,17 @@ _VALID_YAML = """\
name: acme/robot-test
description: Robot test profile
schema_version: "1.0"
auto_strategize: 0.8
auto_execute: 0.7
auto_apply: 1.0
auto_decisions_strategize: 0.6
auto_decisions_execute: 0.8
auto_validation_fix: 0.7
auto_strategy_revision: 0.8
auto_reversion_from_apply: 0.9
auto_child_plans: 0.7
auto_retry_transient: 0.0
auto_checkpoint_restore: 0.6
decompose_task: 0.8
create_tool: 0.7
select_tool: 1.0
edit_code: 0.6
execute_command: 0.8
create_file: 0.7
delete_content: 0.8
access_network: 0.9
install_dependency: 0.7
modify_config: 0.0
approve_plan: 0.6
safety:
require_sandbox: true
require_checkpoints: true
+1 -1
View File
@@ -304,7 +304,7 @@ def _automation_review_before_apply() -> None:
plan_id = plan.identity.plan_id
# Set "auto" profile (review-before-apply equivalent):
# auto_execute=0.0, auto_apply=1.0 → advances after strategize but pauses at apply
# create_tool=0.0, select_tool=1.0 → advances after strategize but pauses at apply
plan.automation_profile = AutomationProfileRef(
profile_name="auto",
provenance=AutomationProfileProvenance.PLAN,
+17 -17
View File
@@ -52,14 +52,14 @@ def _test_confidence_low() -> None:
def _test_threshold_proceed() -> None:
"""Proceed when confidence >= threshold."""
ctrl = AutonomyController()
profile = AutomationProfile(name="test", auto_execute=0.5)
profile = AutomationProfile(name="test", create_tool=0.5)
factors = ConfidenceFactors(
past_success_rate=0.9,
codebase_familiarity=0.9,
risk_assessment=0.1,
invariant_complexity=0.1,
)
op = OperationContext(operation_type="auto_execute")
op = OperationContext(operation_type="create_tool")
decision = ctrl.should_proceed_automatically(op, factors, profile)
assert decision.proceed is True, f"Expected proceed=True, got {decision.proceed}"
assert decision.confidence >= 0.5
@@ -69,14 +69,14 @@ def _test_threshold_proceed() -> None:
def _test_threshold_escalate() -> None:
"""Escalate when confidence < threshold."""
ctrl = AutonomyController()
profile = AutomationProfile(name="test", auto_execute=0.99)
profile = AutomationProfile(name="test", create_tool=0.99)
factors = ConfidenceFactors(
past_success_rate=0.3,
codebase_familiarity=0.3,
risk_assessment=0.7,
invariant_complexity=0.7,
)
op = OperationContext(operation_type="auto_execute")
op = OperationContext(operation_type="create_tool")
decision = ctrl.should_proceed_automatically(op, factors, profile)
assert decision.proceed is False, f"Expected proceed=False, got {decision.proceed}"
print("threshold-escalate-ok")
@@ -85,20 +85,20 @@ def _test_threshold_escalate() -> None:
def _test_history_tracking() -> None:
"""Success rate updates after recording outcomes."""
ctrl = AutonomyController()
assert abs(ctrl.get_historical_success_rate("auto_execute") - 0.5) < 1e-6
assert abs(ctrl.get_historical_success_rate("create_tool") - 0.5) < 1e-6
for _ in range(8):
ctrl.record_outcome(
HistoricalOutcome(operation_type="auto_execute", succeeded=True)
HistoricalOutcome(operation_type="create_tool", succeeded=True)
)
for _ in range(2):
ctrl.record_outcome(
HistoricalOutcome(operation_type="auto_execute", succeeded=False)
HistoricalOutcome(operation_type="create_tool", succeeded=False)
)
rate = ctrl.get_historical_success_rate("auto_execute")
rate = ctrl.get_historical_success_rate("create_tool")
assert abs(rate - 0.8) < 1e-6, f"Expected 0.8, got {rate}"
assert ctrl.get_history_count("auto_execute") == 10
assert ctrl.get_history_count("create_tool") == 10
print("history-tracking-ok")
@@ -112,7 +112,7 @@ def _test_profile_manual() -> None:
risk_assessment=0.05,
invariant_complexity=0.05,
)
op = OperationContext(operation_type="auto_execute")
op = OperationContext(operation_type="create_tool")
decision = ctrl.should_proceed_automatically(op, factors, profile)
assert decision.proceed is False
print("profile-manual-ok")
@@ -128,7 +128,7 @@ def _test_profile_fullauto() -> None:
risk_assessment=1.0,
invariant_complexity=1.0,
)
op = OperationContext(operation_type="auto_execute")
op = OperationContext(operation_type="create_tool")
decision = ctrl.should_proceed_automatically(op, factors, profile)
assert decision.proceed is True
print("profile-fullauto-ok")
@@ -146,7 +146,7 @@ def _test_profile_cautious() -> None:
risk_assessment=0.05,
invariant_complexity=0.05,
)
op = OperationContext(operation_type="auto_execute")
op = OperationContext(operation_type="create_tool")
high_decision = ctrl.should_proceed_automatically(
op,
high_factors,
@@ -173,17 +173,17 @@ def _test_profile_cautious() -> None:
def _test_decision_fields() -> None:
"""Decision model includes all required fields."""
ctrl = AutonomyController()
profile = AutomationProfile(name="test", auto_execute=0.5)
profile = AutomationProfile(name="test", create_tool=0.5)
factors = ConfidenceFactors(
past_success_rate=0.8,
codebase_familiarity=0.7,
risk_assessment=0.2,
invariant_complexity=0.3,
)
op = OperationContext(operation_type="auto_execute")
op = OperationContext(operation_type="create_tool")
decision = ctrl.should_proceed_automatically(op, factors, profile)
assert decision.operation_type == "auto_execute"
assert decision.operation_type == "create_tool"
assert len(decision.factors) == 4
assert "past_success_rate" in decision.factors
assert abs(decision.threshold - 0.5) < 1e-6
@@ -195,14 +195,14 @@ def _test_decision_fields() -> None:
def _test_zero_threshold() -> None:
"""Threshold 0.0 means always automatic, even zero confidence."""
ctrl = AutonomyController()
profile = AutomationProfile(name="test", auto_execute=0.0)
profile = AutomationProfile(name="test", create_tool=0.0)
factors = ConfidenceFactors(
past_success_rate=0.0,
codebase_familiarity=0.0,
risk_assessment=1.0,
invariant_complexity=1.0,
)
op = OperationContext(operation_type="auto_execute")
op = OperationContext(operation_type="create_tool")
decision = ctrl.should_proceed_automatically(op, factors, profile)
assert decision.proceed is True
assert abs(decision.confidence - 0.0) < 1e-6
+6 -6
View File
@@ -106,21 +106,21 @@ def wf03_plan_prompt_facade() -> None:
def wf03_confidence_threshold_pausing() -> None:
"""Verify cautious profile pauses on low-confidence decisions.
The cautious profile has auto_decisions_strategize=0.6.
The cautious profile has edit_code=0.6.
With confidence 0.55, the system should NOT proceed (proceed=False).
"""
controller = AutonomyController()
profile = BUILTIN_PROFILES["cautious"]
# Verify the cautious threshold value
threshold = profile.auto_decisions_strategize
threshold = profile.edit_code
if abs(threshold - 0.6) > 1e-6:
_fail(f"Expected cautious auto_decisions_strategize=0.6, got {threshold}")
_fail(f"Expected cautious edit_code=0.6, got {threshold}")
# Produce confidence 0.55 (below threshold 0.6)
factors = _factors_for_confidence(0.55)
operation = OperationContext(
operation_type="auto_decisions_strategize",
operation_type="edit_code",
)
decision = controller.should_proceed_automatically(
operation=operation, factors=factors, profile=profile
@@ -166,7 +166,7 @@ def wf03_confidence_threshold_proceeds() -> None:
# Produce confidence 0.85 (above threshold 0.6)
factors = _factors_for_confidence(0.85)
operation = OperationContext(
operation_type="auto_decisions_strategize",
operation_type="edit_code",
)
decision = controller.should_proceed_automatically(
operation=operation, factors=factors, profile=profile
@@ -226,7 +226,7 @@ def wf03_pause_and_resume() -> None:
factors = _factors_for_confidence(0.55)
operation = OperationContext(
operation_type="auto_decisions_strategize",
operation_type="edit_code",
)
decision = controller.should_proceed_automatically(
operation=operation, factors=factors, profile=profile
+1 -1
View File
@@ -37,7 +37,7 @@ WF03 Plan Prompt Via Facade
WF03 Confidence Threshold Pausing
[Documentation] Verify that the cautious profile pauses execution when
... a strategy decision has confidence below the threshold
... (0.6 for ``auto_decisions_strategize``). Seeds factors
... (0.6 for ``edit_code``). Seeds factors
... producing confidence 0.55 and asserts ``proceed=False``.
[Tags] confidence cautious threshold
${result}= Run Process ${PYTHON} ${HELPER} confidence-threshold-pausing cwd=${WORKSPACE} timeout=120s on_timeout=kill
@@ -307,9 +307,16 @@ class AutonomyController:
Falls back to 1.0 (always manual) if the operation type
is not a recognised threshold field.
The ``operation_type`` uses spec-defined **task-type** names
(e.g. ``create_tool``, ``access_network``) rather than the
old phase-transition names (e.g. ``auto_execute``,
``auto_reversion_from_apply``). See the mapping table in
``automation_profile.py`` and ``_LEGACY_FIELD_MAP`` for the
full old-to-new correspondence.
Args:
profile: The automation profile.
operation_type: The flag name (e.g. ``auto_execute``).
operation_type: The flag name (e.g. ``create_tool``).
Returns:
The threshold float in [0.0, 1.0].
@@ -1530,9 +1530,18 @@ class PlanLifecycleService:
on the relevant phase means the transition is fully
automatic. A threshold of ``1.0`` requires human approval.
Task-type threshold fields used as phase-transition gates
(per specification, Section "Automation Profiles"):
* ``create_tool`` Strategize Execute
* ``select_tool`` Execute Apply
* ``access_network`` auto-revert from Apply
* ``delete_content`` auto-revert from Execute (strategy revision)
Returns True when:
- Strategize/COMPLETE and profile.auto_execute < 1.0
- Execute/COMPLETE and profile.auto_apply < 1.0
- Strategize/COMPLETE and ``create_tool < 1.0``
- Execute/COMPLETE and ``select_tool < 1.0``
Returns False otherwise.
"""
@@ -1545,7 +1554,7 @@ class PlanLifecycleService:
if (
plan.phase == PlanPhase.STRATEGIZE
and plan.processing_state == ProcessingState.COMPLETE
and profile.auto_execute < 1.0
and profile.create_tool < 1.0
):
return True
@@ -1553,7 +1562,7 @@ class PlanLifecycleService:
return bool(
plan.phase == PlanPhase.EXECUTE
and plan.processing_state == ProcessingState.COMPLETE
and profile.auto_apply < 1.0
and profile.select_tool < 1.0
)
def _complete_apply_if_queued(self, plan_id: str) -> Plan:
@@ -1644,7 +1653,7 @@ class PlanLifecycleService:
# complete it immediately when auto-progressing. This
# ensures ``plan execute`` drives the plan to terminal
# ``applied`` state when the automation profile permits
# (spec §Automation Profiles: auto_apply < 1.0).
# (spec §Automation Profiles: select_tool < 1.0).
return self._complete_apply_if_queued(plan_id)
return plan
@@ -1655,9 +1664,9 @@ class PlanLifecycleService:
When the plan's automation profile permits, this method advances
the plan synchronously through Strategize Execute Apply:
* ``auto_strategize < 1.0`` start + complete Strategize
* ``auto_execute < 1.0`` start + complete Execute
* ``auto_apply < 1.0`` start + complete Apply
* ``decompose_task < 1.0`` start + complete Strategize
* ``create_tool < 1.0`` start + complete Execute
* ``select_tool < 1.0`` start + complete Apply
Each completion step calls :meth:`auto_progress` internally,
which transitions the plan to the next phase when appropriate.
@@ -1683,10 +1692,11 @@ class PlanLifecycleService:
profile = self._resolve_profile_for_plan(plan)
# --- Strategize phase: QUEUED → PROCESSING → COMPLETE -----------
# (decompose_task threshold gates the Strategize phase start)
if (
plan.phase == PlanPhase.STRATEGIZE
and plan.state == ProcessingState.QUEUED
and profile.auto_strategize < 1.0
and profile.decompose_task < 1.0
):
self._logger.info(
"Auto-running strategize phase",
@@ -1699,10 +1709,11 @@ class PlanLifecycleService:
plan = self.get_plan(plan_id)
# --- Execute phase: QUEUED → PROCESSING → COMPLETE --------------
# (create_tool threshold gates the Execute phase start)
if (
plan.phase == PlanPhase.EXECUTE
and plan.state == ProcessingState.QUEUED
and profile.auto_execute < 1.0
and profile.create_tool < 1.0
):
self._logger.info(
"Auto-running execute phase",
@@ -1715,10 +1726,11 @@ class PlanLifecycleService:
plan = self.get_plan(plan_id)
# --- Apply phase: QUEUED → PROCESSING → APPLIED (terminal) ------
# (select_tool threshold gates the Apply phase start)
if (
plan.phase == PlanPhase.APPLY
and plan.state == ProcessingState.QUEUED
and profile.auto_apply < 1.0
and profile.select_tool < 1.0
):
self._logger.info(
"Auto-running apply phase",
@@ -1871,7 +1883,8 @@ class PlanLifecycleService:
"""Attempt automatic reversion from a constrained Apply phase.
Called after ``constrain_apply`` when the automation profile
permits automatic reversion (``auto_reversion_from_apply < 1.0``).
permits automatic reversion. The ``access_network`` task-type
threshold controls this gate (``access_network < 1.0``).
Args:
plan_id: The plan ULID.
@@ -1889,11 +1902,12 @@ class PlanLifecycleService:
return plan
profile = self._resolve_profile_for_plan(plan)
if profile.auto_reversion_from_apply >= 1.0:
if profile.access_network >= 1.0:
self._logger.info(
"Auto-reversion blocked by profile threshold",
plan_id=plan_id,
threshold=profile.auto_reversion_from_apply,
threshold_field="access_network",
threshold=profile.access_network,
)
return plan
@@ -1922,7 +1936,8 @@ class PlanLifecycleService:
"""Attempt automatic reversion from Execute to Strategize.
Called when validation failures block apply and the automation
profile permits reversion.
profile permits reversion. The ``delete_content`` task-type
threshold controls this gate (strategy revision).
Args:
plan_id: The plan ULID.
@@ -1937,11 +1952,12 @@ class PlanLifecycleService:
return plan
profile = self._resolve_profile_for_plan(plan)
if profile.auto_strategy_revision >= 1.0:
if profile.delete_content >= 1.0:
self._logger.info(
"Execute-to-Strategize reversion blocked by profile threshold",
plan_id=plan_id,
threshold=profile.auto_strategy_revision,
threshold_field="delete_content",
threshold=profile.delete_content,
)
return plan
@@ -83,8 +83,10 @@ def _guards_dict(guards: AutomationGuard | None) -> dict[str, object] | None:
def _profile_spec_dict(profile: AutomationProfile) -> dict[str, object]:
"""Return profile data as a dict suitable for CLI output.
Keys match the AutomationProfile field names for consistency
with the YAML config format.
Structure matches the specification's JSON output format for
``automation-profile show`` with thresholds grouped into four
semantic categories: phase_transitions, decision_automation,
self_repair, and execution_controls.
"""
source = "built-in" if profile.name in BUILTIN_PROFILES else "custom"
result: dict[str, object] = {
@@ -92,26 +94,27 @@ def _profile_spec_dict(profile: AutomationProfile) -> dict[str, object]:
"description": profile.description,
"source": source,
"schema_version": profile.schema_version,
"auto_strategize": profile.auto_strategize,
"auto_execute": profile.auto_execute,
"auto_apply": profile.auto_apply,
"auto_decisions_strategize": profile.auto_decisions_strategize,
"auto_decisions_execute": profile.auto_decisions_execute,
"auto_validation_fix": profile.auto_validation_fix,
"auto_strategy_revision": profile.auto_strategy_revision,
"auto_reversion_from_apply": profile.auto_reversion_from_apply,
"auto_child_plans": profile.auto_child_plans,
"auto_retry_transient": profile.auto_retry_transient,
"auto_checkpoint_restore": profile.auto_checkpoint_restore,
"safety": {
"phase_transitions": {
"decompose_task": profile.decompose_task,
"create_tool": profile.create_tool,
"select_tool": profile.select_tool,
},
"decision_automation": {
"edit_code": profile.edit_code,
"execute_command": profile.execute_command,
},
"self_repair": {
"create_file": profile.create_file,
"delete_content": profile.delete_content,
"access_network": profile.access_network,
"modify_config": profile.modify_config,
"approve_plan": profile.approve_plan,
},
"execution_controls": {
"install_dependency": profile.install_dependency,
"require_sandbox": profile.safety.require_sandbox,
"require_checkpoints": profile.safety.require_checkpoints,
"require_human_approval": profile.safety.require_human_approval,
"allow_unsafe_tools": profile.safety.allow_unsafe_tools,
"max_cost_per_plan": profile.safety.max_cost_per_plan,
"max_retries_per_step": profile.safety.max_retries_per_step,
"max_total_cost": profile.safety.max_total_cost,
"allowed_skill_categories": (profile.safety.allowed_skill_categories),
},
"guards": _guards_dict(profile.guards),
}
@@ -121,9 +124,9 @@ def _profile_spec_dict(profile: AutomationProfile) -> dict[str, object]:
def _threshold_summary(profile: AutomationProfile) -> str:
"""Return a compact summary of key thresholds."""
return (
f"strategize={profile.auto_strategize:.1f} "
f"execute={profile.auto_execute:.1f} "
f"apply={profile.auto_apply:.1f}"
f"decompose_task={profile.decompose_task:.1f} "
f"create_tool={profile.create_tool:.1f} "
f"select_tool={profile.select_tool:.1f}"
)
@@ -145,31 +148,24 @@ def _print_profile(
f"[bold]Description:[/bold] {profile.description}\n"
f"[bold]Source:[/bold] {source}\n"
f"[bold]Schema Version:[/bold] {profile.schema_version}\n"
f"\n[bold]Phase-Transition Thresholds:[/bold]\n"
f" auto_strategize: {profile.auto_strategize}\n"
f" auto_execute: {profile.auto_execute}\n"
f" auto_apply: {profile.auto_apply}\n"
f"\n[bold]Decision-Autonomy Thresholds:[/bold]\n"
f" auto_decisions_strategize: {profile.auto_decisions_strategize}\n"
f" auto_decisions_execute: {profile.auto_decisions_execute}\n"
f"\n[bold]Self-Repair Thresholds:[/bold]\n"
f" auto_validation_fix: {profile.auto_validation_fix}\n"
f" auto_strategy_revision: {profile.auto_strategy_revision}\n"
f" auto_reversion_from_apply: {profile.auto_reversion_from_apply}\n"
f"\n[bold]Child Plan & Retry Thresholds:[/bold]\n"
f" auto_child_plans: {profile.auto_child_plans}\n"
f" auto_retry_transient: {profile.auto_retry_transient}\n"
f" auto_checkpoint_restore: {profile.auto_checkpoint_restore}\n"
f"\n[bold]Safety Profile (Composed Sub-Model):[/bold]\n"
f"\n[bold]Phase Transitions (thresholds):[/bold]\n"
f" decompose_task: {profile.decompose_task}\n"
f" create_tool: {profile.create_tool}\n"
f" select_tool: {profile.select_tool}\n"
f"\n[bold]Decision Automation (thresholds):[/bold]\n"
f" edit_code: {profile.edit_code}\n"
f" execute_command: {profile.execute_command}\n"
f"\n[bold]Self-Repair (thresholds):[/bold]\n"
f" create_file: {profile.create_file}\n"
f" delete_content: {profile.delete_content}\n"
f" access_network: {profile.access_network}\n"
f" modify_config: {profile.modify_config}\n"
f" approve_plan: {profile.approve_plan}\n"
f"\n[bold]Execution Controls (thresholds):[/bold]\n"
f" install_dependency: {profile.install_dependency}\n"
f" require_sandbox: {profile.safety.require_sandbox}\n"
f" require_checkpoints: {profile.safety.require_checkpoints}\n"
f" require_human_approval: {profile.safety.require_human_approval}\n"
f" allow_unsafe_tools: {profile.safety.allow_unsafe_tools}\n"
f" max_cost_per_plan: {profile.safety.max_cost_per_plan}\n"
f" max_retries_per_step: {profile.safety.max_retries_per_step}\n"
f" max_total_cost: {profile.safety.max_total_cost}\n"
f" allowed_skill_categories: "
f"{profile.safety.allowed_skill_categories}"
f" allow_unsafe_tools: {profile.safety.allow_unsafe_tools}"
)
if profile.guards is not None:
@@ -407,9 +403,9 @@ def list_profiles(
table.add_column("Name", style="cyan")
table.add_column("Source", style="blue")
table.add_column("Description", style="dim")
table.add_column("Strategize", justify="right")
table.add_column("Execute", justify="right")
table.add_column("Apply", justify="right")
table.add_column("Decompose", justify="right")
table.add_column("Create Tool", justify="right")
table.add_column("Select Tool", justify="right")
table.add_column("Sandbox", justify="center")
for profile in profiles:
@@ -419,9 +415,9 @@ def list_profiles(
source,
profile.description[:40]
+ ("..." if len(profile.description) > 40 else ""),
f"{profile.auto_strategize:.1f}",
f"{profile.auto_execute:.1f}",
f"{profile.auto_apply:.1f}",
f"{profile.decompose_task:.1f}",
f"{profile.create_tool:.1f}",
f"{profile.select_tool:.1f}",
"yes" if profile.safety.require_sandbox else "no",
)
+1 -1
View File
@@ -1927,7 +1927,7 @@ def execute_plan(
# If the plan is still in Strategize/queued, run the strategize
# phase inline before transitioning to Execute. This implements
# the auto_strategize behaviour described in the specification:
# the decompose_task behaviour described in the specification:
# "When confidence >= threshold, Strategize begins immediately."
if current_plan.phase == PlanPhase.STRATEGIZE and current_plan.state in (
ProcessingState.QUEUED,
@@ -6,6 +6,44 @@ Each threshold is a float in [0.0, 1.0]: 0.0 = automatic,
with every installation. Custom profiles use ``namespace/name``.
Based on ``docs/specification.md`` Section "Automation Profiles".
Field Name Mapping
------------------
The specification defines 11 threshold fields using **task-type**
semantics (what the operation *does*) rather than
**phase-transition** semantics (which lifecycle phase it gates).
The mapping between old and new names is:
Old (phase-transition) -> New (spec task-type)
``auto_strategize`` -> ``decompose_task``
Enter Strategize after plan use.
``auto_execute`` -> ``create_tool``
Strategize -> Execute transition.
``auto_apply`` -> ``select_tool``
Execute -> Apply transition.
``auto_decisions_strategize`` -> ``edit_code``
Decisions during Strategize.
``auto_decisions_execute`` -> ``execute_command``
Decisions during Execute.
``auto_validation_fix`` -> ``create_file``
Auto-fix validation failures.
``auto_strategy_revision`` -> ``delete_content``
Revise strategy from Execute constraints.
``auto_reversion_from_apply`` -> ``access_network``
Revert from Apply to Strategize.
``auto_child_plans`` -> ``install_dependency``
Spawn and execute child plans.
``auto_retry_transient`` -> ``modify_config``
Retry on transient failures.
``auto_checkpoint_restore`` -> ``approve_plan``
Restore from checkpoint on failure.
The ``_LEGACY_FIELD_MAP`` dict below encodes this mapping for
runtime detection of old field names in user-supplied YAML
configs. See also
``PlanLifecycleService.should_auto_progress()`` for how the
task-type names map back to phase-transition gates at runtime.
"""
from __future__ import annotations
@@ -15,7 +53,7 @@ from pathlib import Path
from typing import Any, ClassVar
import yaml
from pydantic import BaseModel, ConfigDict, Field, field_validator
from pydantic import BaseModel, ConfigDict, Field, field_validator, model_validator
from cleveragents.domain.models.core.automation_guard import (
AutomationGuard,
@@ -33,6 +71,24 @@ from cleveragents.domain.models.core.safety_profile import (
_BARE_NAME = re.compile(r"^[a-zA-Z0-9_-]+$")
_NAMESPACED_NAME = re.compile(r"^[a-zA-Z0-9_-]+/[a-zA-Z0-9_-]+$")
# Mapping from legacy (pre-rename) field names to the current
# spec-defined task-type names. Used by the ``@model_validator`` to
# produce an actionable error when users supply YAML configs with
# the old phase-transition field names.
_LEGACY_FIELD_MAP: dict[str, str] = {
"auto_strategize": "decompose_task",
"auto_execute": "create_tool",
"auto_apply": "select_tool",
"auto_decisions_strategize": "edit_code",
"auto_decisions_execute": "execute_command",
"auto_validation_fix": "create_file",
"auto_strategy_revision": "delete_content",
"auto_reversion_from_apply": "access_network",
"auto_child_plans": "install_dependency",
"auto_retry_transient": "modify_config",
"auto_checkpoint_restore": "approve_plan",
}
# ---------------------------------------------------------------------------
# AutomationProfile
@@ -69,82 +125,76 @@ class AutomationProfile(BaseModel):
description="Schema version for forward compatibility",
)
# -- Phase-transition thresholds (0.0 = auto, 1.0 = human) ------------
# -- Task-type confidence thresholds (0.0 = auto, 1.0 = human) ---------
auto_strategize: float = Field(
decompose_task: float = Field(
0.0,
ge=0.0,
le=1.0,
description="Threshold for automatic strategy approval",
description="Threshold for automatic task decomposition",
)
auto_execute: float = Field(
create_tool: float = Field(
0.0,
ge=0.0,
le=1.0,
description="Threshold for automatic execution approval",
description="Threshold for automatic tool creation",
)
auto_apply: float = Field(
select_tool: float = Field(
0.0,
ge=0.0,
le=1.0,
description="Threshold for automatic apply approval",
description="Threshold for automatic tool selection",
)
# -- Decision-autonomy thresholds --------------------------------------
auto_decisions_strategize: float = Field(
edit_code: float = Field(
0.0,
ge=0.0,
le=1.0,
description=("Threshold for automatic decisions during strategy"),
description="Threshold for automatic code editing",
)
auto_decisions_execute: float = Field(
execute_command: float = Field(
0.0,
ge=0.0,
le=1.0,
description=("Threshold for automatic decisions during execution"),
description="Threshold for automatic command execution",
)
# -- Self-repair thresholds --------------------------------------------
auto_validation_fix: float = Field(
create_file: float = Field(
0.0,
ge=0.0,
le=1.0,
description="Threshold for automatic validation fix",
description="Threshold for automatic file creation",
)
auto_strategy_revision: float = Field(
delete_content: float = Field(
0.0,
ge=0.0,
le=1.0,
description="Threshold for automatic strategy revision",
description="Threshold for automatic content deletion",
)
auto_reversion_from_apply: float = Field(
access_network: float = Field(
0.0,
ge=0.0,
le=1.0,
description=("Threshold for automatic reversion from apply"),
description="Threshold for automatic network access",
)
# -- Child plan and retry thresholds -----------------------------------
auto_child_plans: float = Field(
install_dependency: float = Field(
0.0,
ge=0.0,
le=1.0,
description="Threshold for automatic child plan spawning",
description="Threshold for automatic dependency installation",
)
auto_retry_transient: float = Field(
modify_config: float = Field(
0.0,
ge=0.0,
le=1.0,
description=("Threshold for automatic retry of transient failures"),
description="Threshold for automatic configuration modification",
)
auto_checkpoint_restore: float = Field(
approve_plan: float = Field(
0.0,
ge=0.0,
le=1.0,
description="Threshold for automatic checkpoint restore",
description="Threshold for automatic plan approval",
)
# -- Safety profile (composed sub-model) --------------------------------
@@ -182,31 +232,31 @@ class AutomationProfile(BaseModel):
# -- Threshold field validation ----------------------------------------
_THRESHOLD_FIELDS: ClassVar[list[str]] = [
"auto_strategize",
"auto_execute",
"auto_apply",
"auto_decisions_strategize",
"auto_decisions_execute",
"auto_validation_fix",
"auto_strategy_revision",
"auto_reversion_from_apply",
"auto_child_plans",
"auto_retry_transient",
"auto_checkpoint_restore",
"decompose_task",
"create_tool",
"select_tool",
"edit_code",
"execute_command",
"create_file",
"delete_content",
"access_network",
"install_dependency",
"modify_config",
"approve_plan",
]
@field_validator(
"auto_strategize",
"auto_execute",
"auto_apply",
"auto_decisions_strategize",
"auto_decisions_execute",
"auto_validation_fix",
"auto_strategy_revision",
"auto_reversion_from_apply",
"auto_child_plans",
"auto_retry_transient",
"auto_checkpoint_restore",
"decompose_task",
"create_tool",
"select_tool",
"edit_code",
"execute_command",
"create_file",
"delete_content",
"access_network",
"install_dependency",
"modify_config",
"approve_plan",
)
@classmethod
def validate_threshold(cls: type[AutomationProfile], v: float) -> float:
@@ -310,9 +360,37 @@ class AutomationProfile(BaseModel):
raise ValueError("Profile YAML must contain a mapping (dict)")
return cls.from_config(config)
# -- Legacy field detection ----------------------------------------------
@model_validator(mode="before")
@classmethod
def reject_legacy_field_names(
cls: type[AutomationProfile],
data: Any,
) -> Any:
"""Detect legacy phase-transition field names and raise a clear error.
After the rename to spec-defined task-type semantics, YAML
configs using the old ``auto_*`` keys are rejected with an
actionable message that lists the required renames.
"""
if not isinstance(data, dict):
return data
found: list[str] = [k for k in data if k in _LEGACY_FIELD_MAP]
if found:
lines = [f" '{old}' -> '{_LEGACY_FIELD_MAP[old]}'" for old in found]
raise ValueError(
"Automation profile contains legacy field names that were "
"renamed to spec-defined task-type semantics. Please update "
"your YAML config:\n" + "\n".join(lines)
)
return data
model_config = ConfigDict(
str_strip_whitespace=True,
validate_assignment=True,
extra="forbid",
)
@@ -325,17 +403,17 @@ BUILTIN_PROFILES: dict[str, AutomationProfile] = {
name="manual",
description="Human approves every action",
schema_version="1.0",
auto_strategize=1.0,
auto_execute=1.0,
auto_apply=1.0,
auto_decisions_strategize=1.0,
auto_decisions_execute=1.0,
auto_validation_fix=1.0,
auto_strategy_revision=1.0,
auto_reversion_from_apply=1.0,
auto_child_plans=1.0,
auto_retry_transient=1.0,
auto_checkpoint_restore=1.0,
decompose_task=1.0,
create_tool=1.0,
select_tool=1.0,
edit_code=1.0,
execute_command=1.0,
create_file=1.0,
delete_content=1.0,
access_network=1.0,
install_dependency=1.0,
modify_config=1.0,
approve_plan=1.0,
safety=SafetyProfile(
require_sandbox=True,
require_checkpoints=True,
@@ -348,17 +426,17 @@ BUILTIN_PROFILES: dict[str, AutomationProfile] = {
name="review",
description="Human reviews before apply",
schema_version="1.0",
auto_strategize=0.0,
auto_execute=0.0,
auto_apply=1.0,
auto_decisions_strategize=1.0,
auto_decisions_execute=1.0,
auto_validation_fix=1.0,
auto_strategy_revision=1.0,
auto_reversion_from_apply=1.0,
auto_child_plans=0.0,
auto_retry_transient=0.0,
auto_checkpoint_restore=1.0,
decompose_task=0.0,
create_tool=0.0,
select_tool=1.0,
edit_code=1.0,
execute_command=1.0,
create_file=1.0,
delete_content=1.0,
access_network=1.0,
install_dependency=0.0,
modify_config=0.0,
approve_plan=1.0,
safety=SafetyProfile(
require_sandbox=True,
require_checkpoints=True,
@@ -371,17 +449,17 @@ BUILTIN_PROFILES: dict[str, AutomationProfile] = {
name="supervised",
description=("Human reviews strategy and execution"),
schema_version="1.0",
auto_strategize=0.0,
auto_execute=1.0,
auto_apply=1.0,
auto_decisions_strategize=0.0,
auto_decisions_execute=1.0,
auto_validation_fix=1.0,
auto_strategy_revision=1.0,
auto_reversion_from_apply=1.0,
auto_child_plans=1.0,
auto_retry_transient=0.0,
auto_checkpoint_restore=1.0,
decompose_task=0.0,
create_tool=1.0,
select_tool=1.0,
edit_code=0.0,
execute_command=1.0,
create_file=1.0,
delete_content=1.0,
access_network=1.0,
install_dependency=1.0,
modify_config=0.0,
approve_plan=1.0,
safety=SafetyProfile(
require_sandbox=True,
require_checkpoints=True,
@@ -394,17 +472,17 @@ BUILTIN_PROFILES: dict[str, AutomationProfile] = {
name="cautious",
description=("Probabilistic gates on most actions"),
schema_version="1.0",
auto_strategize=0.7,
auto_execute=0.7,
auto_apply=1.0,
auto_decisions_strategize=0.6,
auto_decisions_execute=0.8,
auto_validation_fix=0.7,
auto_strategy_revision=0.8,
auto_reversion_from_apply=0.9,
auto_child_plans=0.7,
auto_retry_transient=0.0,
auto_checkpoint_restore=0.6,
decompose_task=0.7,
create_tool=0.7,
select_tool=1.0,
edit_code=0.6,
execute_command=0.8,
create_file=0.7,
delete_content=0.8,
access_network=0.9,
install_dependency=0.7,
modify_config=0.0,
approve_plan=0.6,
safety=SafetyProfile(
require_sandbox=True,
require_checkpoints=True,
@@ -417,17 +495,17 @@ BUILTIN_PROFILES: dict[str, AutomationProfile] = {
name="trusted",
description=("Auto for most, human for apply and revert"),
schema_version="1.0",
auto_strategize=0.0,
auto_execute=0.0,
auto_apply=1.0,
auto_decisions_strategize=0.0,
auto_decisions_execute=0.0,
auto_validation_fix=0.0,
auto_strategy_revision=1.0,
auto_reversion_from_apply=1.0,
auto_child_plans=0.0,
auto_retry_transient=0.0,
auto_checkpoint_restore=1.0,
decompose_task=0.0,
create_tool=0.0,
select_tool=1.0,
edit_code=0.0,
execute_command=0.0,
create_file=0.0,
delete_content=1.0,
access_network=1.0,
install_dependency=0.0,
modify_config=0.0,
approve_plan=1.0,
safety=SafetyProfile(
require_sandbox=True,
require_checkpoints=True,
@@ -438,19 +516,19 @@ BUILTIN_PROFILES: dict[str, AutomationProfile] = {
),
"auto": AutomationProfile(
name="auto",
description="Fully automatic except reversion",
description="Fully automatic except apply",
schema_version="1.0",
auto_strategize=0.0,
auto_execute=0.0,
auto_apply=1.0,
auto_decisions_strategize=0.0,
auto_decisions_execute=0.0,
auto_validation_fix=0.0,
auto_strategy_revision=0.0,
auto_reversion_from_apply=1.0,
auto_child_plans=0.0,
auto_retry_transient=0.0,
auto_checkpoint_restore=0.0,
decompose_task=0.0,
create_tool=0.0,
select_tool=1.0,
edit_code=0.0,
execute_command=0.0,
create_file=0.0,
delete_content=0.0,
access_network=1.0,
install_dependency=0.0,
modify_config=0.0,
approve_plan=0.0,
safety=SafetyProfile(
require_sandbox=True,
require_checkpoints=True,
@@ -463,17 +541,17 @@ BUILTIN_PROFILES: dict[str, AutomationProfile] = {
name="ci",
description="Designed for CI pipelines",
schema_version="1.0",
auto_strategize=0.0,
auto_execute=0.0,
auto_apply=0.0,
auto_decisions_strategize=0.0,
auto_decisions_execute=0.0,
auto_validation_fix=0.0,
auto_strategy_revision=0.0,
auto_reversion_from_apply=0.0,
auto_child_plans=0.0,
auto_retry_transient=0.0,
auto_checkpoint_restore=0.0,
decompose_task=0.0,
create_tool=0.0,
select_tool=0.0,
edit_code=0.0,
execute_command=0.0,
create_file=0.0,
delete_content=0.0,
access_network=0.0,
install_dependency=0.0,
modify_config=0.0,
approve_plan=0.0,
safety=SafetyProfile(
require_sandbox=True,
require_checkpoints=True,
@@ -486,17 +564,17 @@ BUILTIN_PROFILES: dict[str, AutomationProfile] = {
name="full-auto",
description=("No gates, no sandbox, no checkpoints"),
schema_version="1.0",
auto_strategize=0.0,
auto_execute=0.0,
auto_apply=0.0,
auto_decisions_strategize=0.0,
auto_decisions_execute=0.0,
auto_validation_fix=0.0,
auto_strategy_revision=0.0,
auto_reversion_from_apply=0.0,
auto_child_plans=0.0,
auto_retry_transient=0.0,
auto_checkpoint_restore=0.0,
decompose_task=0.0,
create_tool=0.0,
select_tool=0.0,
edit_code=0.0,
execute_command=0.0,
create_file=0.0,
delete_content=0.0,
access_network=0.0,
install_dependency=0.0,
modify_config=0.0,
approve_plan=0.0,
safety=SafetyProfile(
require_sandbox=False,
require_checkpoints=False,
@@ -89,7 +89,7 @@ class OperationContext(BaseModel):
Attributes:
operation_type: Type/name of the operation (e.g. the
automation profile flag like ``auto_execute``).
automation profile flag like ``create_tool``).
project_id: Identifier of the project being operated on.
file_count: Number of files affected by the operation.
test_coverage: Test coverage ratio for affected code.
@@ -99,7 +99,7 @@ class OperationContext(BaseModel):
operation_type: str = Field(
...,
min_length=1,
description="Automation profile flag name (e.g. 'auto_execute')",
description="Automation profile flag name (e.g. 'create_tool')",
)
project_id: str = Field(
default="",
@@ -2131,24 +2131,18 @@ class AutomationProfileModel(Base): # type: ignore[misc]
description = Column(Text, nullable=True)
schema_version = Column(Text, nullable=False, server_default="1.0")
# Phase-transition thresholds
auto_strategize = Column(Float, nullable=False, default=0.0)
auto_execute = Column(Float, nullable=False, default=0.0)
auto_apply = Column(Float, nullable=False, default=0.0)
# Decision-autonomy thresholds
auto_decisions_strategize = Column(Float, nullable=False, default=0.0)
auto_decisions_execute = Column(Float, nullable=False, default=0.0)
# Self-repair thresholds
auto_validation_fix = Column(Float, nullable=False, default=0.0)
auto_strategy_revision = Column(Float, nullable=False, default=0.0)
auto_reversion_from_apply = Column(Float, nullable=False, default=0.0)
# Child plan and retry thresholds
auto_child_plans = Column(Float, nullable=False, default=0.0)
auto_retry_transient = Column(Float, nullable=False, default=0.0)
auto_checkpoint_restore = Column(Float, nullable=False, default=0.0)
# Task-type confidence thresholds
decompose_task = Column(Float, nullable=False, default=0.0)
create_tool = Column(Float, nullable=False, default=0.0)
select_tool = Column(Float, nullable=False, default=0.0)
edit_code = Column(Float, nullable=False, default=0.0)
execute_command = Column(Float, nullable=False, default=0.0)
create_file = Column(Float, nullable=False, default=0.0)
delete_content = Column(Float, nullable=False, default=0.0)
access_network = Column(Float, nullable=False, default=0.0)
install_dependency = Column(Float, nullable=False, default=0.0)
modify_config = Column(Float, nullable=False, default=0.0)
approve_plan = Column(Float, nullable=False, default=0.0)
# Safety requirements (legacy scalar columns kept for queries)
require_sandbox = Column(Boolean, nullable=False, default=True)
@@ -4526,17 +4526,17 @@ class AutomationProfileRepository:
name=cast(str, row.name),
description=cast(str, row.description) or "",
schema_version=cast(str, row.schema_version),
auto_strategize=float(cast(float, row.auto_strategize)),
auto_execute=float(cast(float, row.auto_execute)),
auto_apply=float(cast(float, row.auto_apply)),
auto_decisions_strategize=float(cast(float, row.auto_decisions_strategize)),
auto_decisions_execute=float(cast(float, row.auto_decisions_execute)),
auto_validation_fix=float(cast(float, row.auto_validation_fix)),
auto_strategy_revision=float(cast(float, row.auto_strategy_revision)),
auto_reversion_from_apply=float(cast(float, row.auto_reversion_from_apply)),
auto_child_plans=float(cast(float, row.auto_child_plans)),
auto_retry_transient=float(cast(float, row.auto_retry_transient)),
auto_checkpoint_restore=float(cast(float, row.auto_checkpoint_restore)),
decompose_task=float(cast(float, row.decompose_task)),
create_tool=float(cast(float, row.create_tool)),
select_tool=float(cast(float, row.select_tool)),
edit_code=float(cast(float, row.edit_code)),
execute_command=float(cast(float, row.execute_command)),
create_file=float(cast(float, row.create_file)),
delete_content=float(cast(float, row.delete_content)),
access_network=float(cast(float, row.access_network)),
install_dependency=float(cast(float, row.install_dependency)),
modify_config=float(cast(float, row.modify_config)),
approve_plan=float(cast(float, row.approve_plan)),
safety=safety,
guards=guards,
)
@@ -4560,17 +4560,17 @@ class AutomationProfileRepository:
name=profile.name,
description=profile.description,
schema_version=profile.schema_version,
auto_strategize=profile.auto_strategize,
auto_execute=profile.auto_execute,
auto_apply=profile.auto_apply,
auto_decisions_strategize=(profile.auto_decisions_strategize),
auto_decisions_execute=(profile.auto_decisions_execute),
auto_validation_fix=profile.auto_validation_fix,
auto_strategy_revision=(profile.auto_strategy_revision),
auto_reversion_from_apply=(profile.auto_reversion_from_apply),
auto_child_plans=profile.auto_child_plans,
auto_retry_transient=(profile.auto_retry_transient),
auto_checkpoint_restore=(profile.auto_checkpoint_restore),
decompose_task=profile.decompose_task,
create_tool=profile.create_tool,
select_tool=profile.select_tool,
edit_code=(profile.edit_code),
execute_command=(profile.execute_command),
create_file=profile.create_file,
delete_content=(profile.delete_content),
access_network=(profile.access_network),
install_dependency=profile.install_dependency,
modify_config=(profile.modify_config),
approve_plan=(profile.approve_plan),
require_sandbox=profile.safety.require_sandbox,
require_checkpoints=profile.safety.require_checkpoints,
allow_unsafe_tools=profile.safety.allow_unsafe_tools,
@@ -4591,38 +4591,38 @@ class AutomationProfileRepository:
row.schema_version = ( # type: ignore[assignment]
profile.schema_version
)
row.auto_strategize = ( # type: ignore[assignment]
profile.auto_strategize
row.decompose_task = ( # type: ignore[assignment]
profile.decompose_task
)
row.auto_execute = ( # type: ignore[assignment]
profile.auto_execute
row.create_tool = ( # type: ignore[assignment]
profile.create_tool
)
row.auto_apply = ( # type: ignore[assignment]
profile.auto_apply
row.select_tool = ( # type: ignore[assignment]
profile.select_tool
)
row.auto_decisions_strategize = ( # type: ignore[assignment]
profile.auto_decisions_strategize
row.edit_code = ( # type: ignore[assignment]
profile.edit_code
)
row.auto_decisions_execute = ( # type: ignore[assignment]
profile.auto_decisions_execute
row.execute_command = ( # type: ignore[assignment]
profile.execute_command
)
row.auto_validation_fix = ( # type: ignore[assignment]
profile.auto_validation_fix
row.create_file = ( # type: ignore[assignment]
profile.create_file
)
row.auto_strategy_revision = ( # type: ignore[assignment]
profile.auto_strategy_revision
row.delete_content = ( # type: ignore[assignment]
profile.delete_content
)
row.auto_reversion_from_apply = ( # type: ignore[assignment]
profile.auto_reversion_from_apply
row.access_network = ( # type: ignore[assignment]
profile.access_network
)
row.auto_child_plans = ( # type: ignore[assignment]
profile.auto_child_plans
row.install_dependency = ( # type: ignore[assignment]
profile.install_dependency
)
row.auto_retry_transient = ( # type: ignore[assignment]
profile.auto_retry_transient
row.modify_config = ( # type: ignore[assignment]
profile.modify_config
)
row.auto_checkpoint_restore = ( # type: ignore[assignment]
profile.auto_checkpoint_restore
row.approve_plan = ( # type: ignore[assignment]
profile.approve_plan
)
row.require_sandbox = ( # type: ignore[assignment]
profile.safety.require_sandbox