Commit Graph

1334 Commits

Author SHA1 Message Date
freemo 3c741d926d docs: add v3.7.0 release documentation and TUI reference
CI / lint (pull_request) Successful in 21s
CI / quality (pull_request) Successful in 32s
CI / build (pull_request) Successful in 21s
CI / security (pull_request) Successful in 56s
CI / helm (pull_request) Successful in 28s
CI / typecheck (pull_request) Successful in 3m58s
CI / unit_tests (pull_request) Successful in 6m14s
CI / docker (pull_request) Successful in 1m30s
CI / coverage (pull_request) Successful in 13m6s
CI / e2e_tests (pull_request) Successful in 17m6s
CI / integration_tests (pull_request) Successful in 21m48s
CI / status-check (pull_request) Successful in 1s
CI / benchmark-publish (pull_request) Has been skipped
CI / benchmark-regression (pull_request) Successful in 55m13s
- CHANGELOG.md: add v3.7.0 release section documenting TUI milestone (M8)
  with Added/Changed/Fixed/Security categories covering all major changes
  from the Unreleased section relevant to this release
- README.md: add Feature Overview table, TUI quick-start guide with
  keybinding reference, and first-plan walkthrough; fix clone URL
- docs/reference/tui.md: new TUI reference covering installation, launch,
  keybindings, input modes (@-references, /commands, !-shell), slash
  command catalog (67 commands / 14 groups), widget inventory, and
  source locations
- docs/reference/tui_persona.md: new persona system reference covering
  Persona schema, PersonaRegistry, PersonaState, slash commands, and
  default persona behaviour
2026-04-02 08:08:31 +00:00
freemo 0db70b9514 build: further expanded opencode agents for better parallelism and better isolation between agents environments
CI / benchmark-publish (push) Waiting to run
CI / lint (push) Failing after 2s
CI / security (push) Failing after 2s
CI / quality (push) Failing after 2s
CI / unit_tests (push) Failing after 2s
CI / integration_tests (push) Failing after 1s
CI / e2e_tests (push) Failing after 1s
CI / helm (push) Failing after 2s
CI / build (push) Successful in 15s
CI / typecheck (push) Successful in 4m1s
CI / coverage (push) Has been skipped
CI / benchmark-regression (push) Waiting to run
CI / docker (push) Has been skipped
CI / status-check (push) Failing after 1s
2026-04-02 03:55:43 -04:00
freemo c937abdc09 build: Fixed opencode agents so they dont accidentally delete PR body
CI / benchmark-publish (push) Waiting to run
CI / lint (push) Failing after 1s
CI / typecheck (push) Failing after 1s
CI / coverage (push) Has been skipped
CI / benchmark-regression (push) Waiting to run
CI / security (push) Failing after 1s
CI / quality (push) Failing after 2s
CI / unit_tests (push) Failing after 2s
CI / docker (push) Has been skipped
CI / integration_tests (push) Failing after 2s
CI / e2e_tests (push) Failing after 2s
CI / build (push) Failing after 1s
CI / helm (push) Failing after 2s
CI / status-check (push) Failing after 1s
2026-04-02 03:09:55 -04:00
freemo ec83213294 build: Modified opencode agents to be more aggressive in being parallel 2026-04-02 03:06:32 -04:00
freemo d344989387 build: submited opencode agent files
CI / benchmark-publish (push) Waiting to run
CI / typecheck (push) Successful in 52s
CI / quality (push) Successful in 1m0s
CI / e2e_tests (push) Failing after 5s
CI / build (push) Failing after 4s
CI / security (push) Successful in 1m14s
CI / helm (push) Successful in 21s
CI / lint (push) Successful in 3m21s
CI / benchmark-regression (push) Waiting to run
CI / unit_tests (push) Successful in 5m50s
CI / docker (push) Successful in 1m21s
CI / coverage (push) Successful in 12m9s
CI / integration_tests (push) Successful in 24m55s
CI / status-check (push) Failing after 1s
2026-04-02 02:07:23 -04:00
freemo ce026cafc2 Merge pull request 'fix(cleanup): remove ghost acp/ package and orphaned .pyc files' (#1256) from fix/m7-remove-acp-ghost-package into master
CI / lint (push) Successful in 3m20s
CI / build (push) Successful in 17s
CI / quality (push) Successful in 3m43s
CI / helm (push) Successful in 21s
CI / typecheck (push) Successful in 4m8s
CI / security (push) Successful in 4m11s
CI / unit_tests (push) Successful in 6m2s
CI / docker (push) Successful in 1m28s
CI / coverage (push) Successful in 12m51s
CI / e2e_tests (push) Successful in 18m50s
CI / integration_tests (push) Successful in 21m38s
CI / status-check (push) Successful in 1s
CI / benchmark-publish (push) Successful in 28m30s
CI / benchmark-regression (push) Has been skipped
2026-04-02 04:16:22 +00:00
brent.edwards f653c58ebd fix(cleanup): remove ghost acp/ package and orphaned .pyc files
CI / benchmark-publish (pull_request) Has been skipped
CI / build (pull_request) Successful in 21s
CI / helm (pull_request) Successful in 23s
CI / lint (pull_request) Successful in 3m20s
CI / quality (pull_request) Successful in 3m43s
CI / typecheck (pull_request) Successful in 3m58s
CI / security (pull_request) Successful in 4m8s
CI / unit_tests (pull_request) Successful in 5m48s
CI / docker (pull_request) Successful in 11s
CI / coverage (pull_request) Successful in 13m1s
CI / e2e_tests (pull_request) Successful in 19m50s
CI / integration_tests (pull_request) Successful in 22m2s
CI / status-check (pull_request) Successful in 1s
CI / benchmark-regression (pull_request) Successful in 55m19s
The ACP module was properly renamed to A2A in commit ec0b7631 (closing #688),
but the deprecated src/cleveragents/acp/ path was not explicitly excluded from
version control. While __pycache__/ and *.py[cod] are already gitignored
globally, add an explicit .gitignore entry for the deprecated acp/ package path
to prevent accidental re-introduction and document the deprecation per ADR-047.

Verification performed:
- Confirmed src/cleveragents/acp/ does not exist in git (only __pycache__
  artifacts remain on developer machines as untracked build artifacts)
- Confirmed zero tracked .pyc files across the entire repository
- Confirmed zero imports referencing cleveragents.acp in source, test, and
  configuration files
- Confirmed no orphaned .pyc files exist without corresponding .py sources
- All nox sessions pass (coverage: 98.7%)

ISSUES CLOSED: #947
2026-04-02 02:43:54 +00:00
CoreRasurae b21e0fedea test(bdd): add direct test for _fast_init_or_upgrade early-return behavior
CI / benchmark-publish (pull_request) Has been skipped
CI / build (pull_request) Successful in 21s
CI / helm (pull_request) Successful in 24s
CI / typecheck (pull_request) Successful in 50s
CI / security (pull_request) Successful in 1m10s
CI / lint (pull_request) Successful in 3m20s
CI / quality (pull_request) Successful in 3m45s
CI / unit_tests (pull_request) Successful in 5m53s
CI / docker (pull_request) Successful in 1m32s
CI / coverage (pull_request) Successful in 12m27s
CI / e2e_tests (pull_request) Successful in 19m48s
CI / integration_tests (pull_request) Successful in 22m24s
CI / status-check (pull_request) Successful in 1s
CI / build (push) Successful in 16s
CI / helm (push) Successful in 22s
CI / lint (push) Successful in 3m17s
CI / quality (push) Successful in 3m39s
CI / typecheck (push) Successful in 3m53s
CI / security (push) Successful in 4m4s
CI / unit_tests (push) Successful in 9m13s
CI / docker (push) Successful in 20s
CI / coverage (push) Successful in 12m20s
CI / e2e_tests (push) Successful in 19m18s
CI / integration_tests (push) Successful in 24m36s
CI / status-check (push) Successful in 2s
CI / benchmark-regression (push) Has been skipped
CI / benchmark-regression (pull_request) Successful in 55m5s
CI / benchmark-publish (push) Successful in 28m26s
Add 8 BDD scenarios in features/fast_init_upgrade.feature that directly
exercise the _fast_init_or_upgrade closure installed by
_install_template_db_patch in features/environment.py.

Scenarios cover all code paths:
- Non-empty DB with matching prefix → early return (original NOT invoked)
- Non-existent DB with matching prefix → template copied (original NOT invoked)
- Existing empty DB with matching prefix → template copied (original NOT invoked)
- Non-matching prefix → delegates to original init_or_upgrade
- In-memory SQLite → delegates to original init_or_upgrade
- Non-SQLite URL → delegates to original init_or_upgrade
- Bare sqlite:// URL → delegates to original init_or_upgrade
- Delegation forwards runner instance and keyword arguments correctly

Test infrastructure:
- features/mocks/fast_init_test_helpers.py provides a context manager
  (patch_original_init_or_upgrade) that replaces the _original_init_or_upgrade
  reference inside the closure via cell_contents manipulation, enabling
  precise call-tracking without recreating the function under test.
- All scenarios tagged @mock_only to skip unnecessary DB setup.
- Cleanup registered via context._cleanup_handlers for temp file removal.
- Works in both sequential and parallel execution modes.

Review fix round:
- Added bare sqlite:// URL scenario covering the second branch of the
  in-memory disjunction (L1).
- Added scenario verifying runner instance and keyword argument forwarding
  through the delegation path (L2, L3).
- Replaced hardcoded test credentials with clearly synthetic pattern (I4).
- Fixed CHANGELOG wording that incorrectly claimed mktemp replacement (L5).

ISSUES CLOSED: #733
2026-04-01 23:52:20 +01:00
brent.edwards 054891d247 feat(tui): implement help panel (F1) with context-sensitive help
CI / build (push) Successful in 19s
CI / helm (push) Successful in 23s
CI / quality (push) Successful in 34s
CI / lint (push) Successful in 3m18s
CI / typecheck (push) Successful in 3m54s
CI / benchmark-regression (push) Has been skipped
CI / security (push) Successful in 4m6s
CI / unit_tests (push) Successful in 8m55s
CI / docker (push) Successful in 1m45s
CI / coverage (push) Successful in 12m44s
CI / e2e_tests (push) Successful in 19m24s
CI / integration_tests (push) Successful in 21m12s
CI / status-check (push) Successful in 1s
CI / benchmark-publish (push) Successful in 28m28s
Auto-merge when checks pass.
2026-04-01 22:16:11 +00:00
brent.edwards 0ae733d01f feat(tui): implement help panel (F1) with context-sensitive help
CI / benchmark-publish (pull_request) Has been skipped
CI / build (pull_request) Successful in 18s
CI / helm (pull_request) Successful in 23s
CI / lint (pull_request) Successful in 3m20s
CI / quality (pull_request) Successful in 3m44s
CI / typecheck (pull_request) Successful in 3m58s
CI / security (pull_request) Successful in 4m10s
CI / unit_tests (pull_request) Successful in 9m2s
CI / docker (pull_request) Successful in 1m30s
CI / coverage (pull_request) Successful in 9m3s
CI / e2e_tests (pull_request) Successful in 22m5s
CI / integration_tests (pull_request) Successful in 24m37s
CI / status-check (pull_request) Successful in 2s
CI / benchmark-regression (pull_request) Successful in 55m59s
Add a dedicated TUI help overlay toggled by F1 and resolve its content from the current prompt mode for main-screen, slash-command, reference, and shell contexts.

Extend Behave and Robot coverage for the new help-panel widget, app wiring, context switching, and toggle behavior.

ISSUES CLOSED: #1013
2026-04-01 21:51:14 +00:00
hamza.khyari 49058c3a72 Merge pull request 'feat(resource): implement ResourceHandler content_hash method' (#1066) from feature/resource-handler-content-hash into master
CI / quality (push) Successful in 46s
CI / typecheck (push) Successful in 51s
CI / build (push) Successful in 24s
CI / helm (push) Successful in 27s
CI / lint (push) Successful in 3m20s
CI / benchmark-regression (push) Has been skipped
CI / security (push) Successful in 4m7s
CI / unit_tests (push) Successful in 9m20s
CI / docker (push) Successful in 1m50s
CI / e2e_tests (push) Successful in 15m40s
CI / coverage (push) Successful in 12m41s
CI / integration_tests (push) Successful in 21m39s
CI / status-check (push) Successful in 3s
CI / benchmark-publish (push) Successful in 28m32s
Reviewed-on: #1066
Reviewed-by: Jeffrey Phillips Freeman <jeffrey.freeman@cleverthis.com>
2026-04-01 13:41:51 +00:00
hamza.khyari 18b9d61e35 feat(resource): implement ResourceHandler content_hash method
CI / build (pull_request) Successful in 20s
CI / lint (pull_request) Successful in 30s
CI / quality (pull_request) Successful in 42s
CI / helm (pull_request) Successful in 26s
CI / security (pull_request) Successful in 1m9s
CI / typecheck (pull_request) Successful in 3m59s
CI / benchmark-publish (pull_request) Has been skipped
CI / coverage (pull_request) Successful in 9m25s
CI / e2e_tests (pull_request) Successful in 17m19s
CI / integration_tests (pull_request) Successful in 21m10s
CI / unit_tests (pull_request) Successful in 6m0s
CI / docker (pull_request) Successful in 2m22s
CI / status-check (pull_request) Successful in 1s
CI / benchmark-regression (pull_request) Successful in 54m57s
Add content_hash(resource, *, algorithm='sha256') -> str to the
ResourceHandler protocol and all handler implementations:

- Protocol: new content_hash method on ResourceHandler (protocol.py)
- BaseResourceHandler: default impl hashes file content or directory
  entry names; returns EMPTY_CONTENT_HASH sentinel for missing
  resources
- GitCheckoutHandler: hashes git rev-parse HEAD through the requested
  algorithm for consistent digest format
- FsDirectoryHandler: recursive walk hashing sorted relative paths
  and file contents (content-only, ignores metadata)
- DevcontainerHandler: hashes devcontainer.json config file
- DatabaseResourceHandler: hashes connection string; for SQLite
  file-based DBs, hashes the database file content
- _DefaultHandler: delegates to BaseResourceHandler

EMPTY_CONTENT_HASH sentinel is the SHA-256 of empty input
(e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855).

Hash algorithm is configurable via the algorithm parameter (default
sha256, accepts any hashlib.new()-compatible name).

Behave tests (10 scenarios): sentinel for missing/nonexistent,
determinism, different content produces different hash, fs-directory
recursive hash with change detection, git-checkout hash, configurable
algorithm (sha256 vs sha512), protocol compliance for all 4 handlers.

ISSUES CLOSED: #837
2026-04-01 13:02:24 +00:00
brent.edwards 2fdac4b4c9 feat(tui): enumerate full slash command set (60+ commands, 14 groups)
CI / lint (push) Successful in 3m20s
CI / build (push) Successful in 14s
CI / helm (push) Successful in 22s
CI / quality (push) Successful in 3m43s
CI / typecheck (push) Successful in 3m55s
CI / security (push) Successful in 4m6s
CI / unit_tests (push) Successful in 9m14s
CI / docker (push) Successful in 1m38s
CI / e2e_tests (push) Successful in 15m28s
CI / coverage (push) Successful in 12m20s
CI / integration_tests (push) Successful in 24m24s
CI / status-check (push) Successful in 1s
CI / benchmark-regression (push) Has been skipped
CI / benchmark-publish (push) Successful in 28m17s
Auto-merge after checks succeed
2026-04-01 09:49:05 +00:00
brent.edwards dc1359fc07 feat(tui): enumerate full slash command set (60+ commands, 14 groups)
CI / benchmark-publish (pull_request) Has been skipped
CI / build (pull_request) Successful in 17s
CI / helm (pull_request) Successful in 22s
CI / lint (pull_request) Successful in 3m19s
CI / quality (pull_request) Successful in 3m46s
CI / typecheck (pull_request) Successful in 3m56s
CI / security (pull_request) Successful in 4m8s
CI / unit_tests (pull_request) Successful in 9m14s
CI / docker (pull_request) Successful in 1m19s
CI / coverage (pull_request) Successful in 9m24s
CI / e2e_tests (pull_request) Successful in 17m12s
CI / integration_tests (pull_request) Successful in 25m32s
CI / status-check (pull_request) Successful in 1s
CI / benchmark-regression (pull_request) Successful in 54m48s
Add a specification-aligned slash command catalog and wire it into TUI overlay initialization so command discovery reflects the complete command surface. Cover command and group cardinality plus representative command presence in Behave tests.

ISSUES CLOSED: #1002
2026-04-01 09:23:21 +00:00
aditya b579178b67 Merge pull request 'feat(acms): implement DepthReductionCompressor for skeleton compression' (#1170) from feat/depth-reduction-compressor into master
CI / typecheck (push) Successful in 46s
CI / build (push) Successful in 17s
CI / security (push) Successful in 1m3s
CI / helm (push) Successful in 21s
CI / lint (push) Successful in 3m20s
CI / quality (push) Successful in 3m42s
CI / unit_tests (push) Successful in 5m48s
CI / docker (push) Successful in 1m31s
CI / coverage (push) Successful in 9m10s
CI / e2e_tests (push) Successful in 21m16s
CI / integration_tests (push) Successful in 24m5s
CI / status-check (push) Successful in 1s
CI / benchmark-publish (push) Successful in 28m17s
CI / benchmark-regression (push) Has been skipped
Reviewed-on: #1170
Reviewed-by: Jeffrey Phillips Freeman <jeffrey.freeman@cleverthis.com>
2026-04-01 06:38:11 +00:00
aditya 137d040c4d feat(acms): implement DepthReductionCompressor for skeleton compression
CI / benchmark-publish (pull_request) Has been skipped
CI / build (pull_request) Successful in 18s
CI / helm (pull_request) Successful in 22s
CI / quality (pull_request) Successful in 56s
CI / lint (pull_request) Successful in 3m21s
CI / typecheck (pull_request) Successful in 4m0s
CI / security (pull_request) Successful in 4m19s
CI / unit_tests (pull_request) Successful in 9m32s
CI / docker (pull_request) Successful in 1m22s
CI / coverage (pull_request) Successful in 12m27s
CI / e2e_tests (pull_request) Successful in 20m3s
CI / integration_tests (pull_request) Successful in 21m20s
CI / status-check (pull_request) Successful in 1s
CI / benchmark-regression (pull_request) Successful in 54m56s
Add a production skeleton compressor that re-renders inherited fragments to overview depths via the UKO detail-level map chain, fits the result within the configured skeleton budget, and wires the pipeline default to the new compressor.

Address prior review feedback by extracting the render visitors into a dedicated module, restoring projected metadata to native runtime types, constraining builtin component resolution with an allowlist, and keeping child-context inheritance compatible with CRP context fragments for the Robot integration path.

Reproduced the Forgejo lint job in a clean python:3.13-slim container with the CI commands All checks passed! and 1740 files already formatted; both passed, so the earlier lint failure appears to have been transient runner behavior rather than a source-level defect.

ISSUES CLOSED: #919
2026-04-01 06:16:41 +00:00
brent.edwards 34dcf5226f feat(autonomy): automation profile resolution precedence correct (#1196)
CI / build (push) Successful in 18s
CI / helm (push) Successful in 38s
CI / lint (push) Successful in 3m19s
CI / quality (push) Successful in 3m42s
CI / typecheck (push) Successful in 3m56s
CI / security (push) Successful in 4m7s
CI / unit_tests (push) Failing after 5m43s
CI / docker (push) Has been skipped
CI / coverage (push) Successful in 12m28s
CI / e2e_tests (push) Successful in 20m5s
CI / integration_tests (push) Failing after 39m29s
CI / status-check (push) Failing after 8m55s
CI / benchmark-regression (push) Has been skipped
CI / benchmark-publish (push) Successful in 28m30s
## Summary
- Fix automation profile resolution precedence at plan-creation time to follow plan > action > project > global.
- Narrow exception handling in `_resolve_plan_profile_ref` to catch only `(KeyError, ValueError, OSError)` with warning-level structured logging, replacing bare `except Exception:` per CONTRIBUTING.md §Exception Propagation.
- Fix TDD feature file tag/title inconsistency: align to `@tdd_bug @tdd_bug_1076` / "TDD Bug #1076" referencing the original bug ticket.
- Add BDD scenarios for plan-level profile override and config service error fallback.
- Harden lifecycle and Robot/Behave test paths for auto-progression and parallel CI stability (including pre-seeded DB initialization for `tdd_plan_explain_plan_id` helper).
- Update Robot helper timing/session patterns to reduce false negatives in long-running integration/E2E validations.

## Approach
The automation profile resolution is implemented in `PlanLifecycleService._resolve_plan_profile_ref`, which evaluates the four-level precedence chain (plan > action > project > global) at `use_action()` time. The resolved profile is stored as an `AutomationProfileRef` on the Plan with provenance tracking. The `ConfigService` is used for project-scoped and global config lookups, with narrowed exception handling that logs warnings on failure and falls back to the settings default.

## Validation
- `nox -s lint` 
- `nox -s typecheck` 
- `nox -s unit_tests` 
- `nox -s coverage_report`  (97%)

## Review Fix Round (Review #2963)
1. **Bare `except Exception:` → narrowed to `(KeyError, ValueError, OSError)` with warning logging** — addresses CONTRIBUTING.md §Exception Propagation violation
2. **Tag inconsistency fixed** — `@tdd_bug @tdd_bug_1076` with title "TDD Bug #1076"
3. **Added 2 new BDD scenarios** — plan-level override and config error fallback
4. **Rebased onto latest master** (532ea100)

Closes #854

Reviewed-on: #1196
Co-authored-by: Brent Edwards <brent.edwards@cleverthis.com>
Co-committed-by: Brent Edwards <brent.edwards@cleverthis.com>
2026-04-01 04:27:09 +00:00
brent.edwards 81c141716b test(integration): workflow example 2 — automated test generation for a module (trusted profile) (#1176)
CI / build (push) Successful in 22s
CI / helm (push) Successful in 22s
CI / lint (push) Successful in 3m20s
CI / quality (push) Successful in 3m46s
CI / typecheck (push) Successful in 3m56s
CI / security (push) Successful in 4m11s
CI / unit_tests (push) Successful in 8m55s
CI / docker (push) Successful in 1m35s
CI / coverage (push) Successful in 12m29s
CI / e2e_tests (push) Successful in 18m50s
CI / integration_tests (push) Successful in 24m10s
CI / status-check (push) Successful in 1s
CI / benchmark-publish (push) Has been cancelled
CI / benchmark-regression (push) Has been cancelled
## Summary
- Refactors WF02 integration helper into focused modules to satisfy maintainability guidelines and keep command responsibilities isolated.
- Moves WF02 artifact assertions onto lifecycle-produced change artifacts and verifies user-facing `plan artifacts` flow with mocked providers.
- Reworks WF02 coverage-gate assertions to run through validation registration/attachment/execution lifecycle and apply-gate outcomes.

## What changed in this fix round (cycle-6)
- **CI must-fix — trusted profile lifecycle integration failure:**
  - Fixed failing integration test `WF02 Trusted Profile Auto Runs Strategize And Execute` caused by legacy AutomationProfile fields that no longer exist.
  - Updated WF02 trusted-profile assertions from removed legacy fields (`auto_strategize`, `auto_execute`, `auto_apply`) to current spec-aligned fields (`decompose_task`, `create_tool`, `select_tool`).
  - Key module: `robot/wf02_test_generation_commands.py` (`wf02_trusted_lifecycle`).

## Prior fix rounds retained
- **P1 must-fix — validation payload assertions strengthened:**
  - Added explicit assertions for validation payload correctness in both failing and passing branches.
  - Assertions now verify:
    - validation identity (`local/auth-coverage` on `local/api-service-repo`)
    - required-mode semantics (`mode=required`, required pass/fail counters, `all_required_passed`)
    - `passed` boolean for each branch
    - measured-vs-target semantics (`measured_coverage` compared against `target`).
  - Key module: `robot/wf02_test_generation_validation.py`.

- **P2 should-fix — artifact membership assertions tightened:**
  - Artifact assertions now enforce exact expected membership and count instead of permissive subset checks.
  - Persisted changeset assertions were aligned to the same strict set/count checks.
  - Key module: `robot/wf02_test_generation_artifacts.py`.

- **P2 should-fix — removed unused helper:**
  - Deleted unused `_bind_changeset_to_plan` helper to eliminate dead code.
  - Key module: `robot/wf02_test_generation_artifacts.py`.

- **P2 should-fix — concrete typing:**
  - Replaced `_setup_validation_db` return type from `tuple[Any, Any]` to concrete typed return (`Callable[[], _NoCloseSession]`, `Session`).
  - Key module: `robot/wf02_test_generation_validation.py`.

## Quality gates
- `nox -e lint` 
- `nox -e typecheck` 
- `nox -e unit_tests` 
- `nox -e integration_tests` 
- `nox -e e2e_tests` 
- `nox -e coverage_report`  (coverage: **98.74%**)

## Scope / limitations
- No deferred items identified in cycle-6.

Closes #766

Reviewed-on: #1176
Reviewed-by: Jeffrey Phillips Freeman <jeffrey.freeman@cleverthis.com>
Co-authored-by: Brent Edwards <brent.edwards@cleverthis.com>
Co-committed-by: Brent Edwards <brent.edwards@cleverthis.com>
2026-04-01 03:30:00 +00:00
brent.edwards a8d91b94a7 feat(autonomy): guard enforcement works (denylist, budget caps, tool call limits) (#1204)
CI / build (push) Successful in 16s
CI / helm (push) Successful in 22s
CI / lint (push) Successful in 39s
CI / quality (push) Successful in 3m43s
CI / typecheck (push) Successful in 3m57s
CI / benchmark-regression (push) Has been skipped
CI / security (push) Successful in 4m8s
CI / unit_tests (push) Successful in 9m13s
CI / docker (push) Successful in 1m34s
CI / e2e_tests (push) Successful in 15m20s
CI / coverage (push) Successful in 12m28s
CI / integration_tests (push) Successful in 21m12s
CI / status-check (push) Successful in 1s
CI / benchmark-publish (push) Successful in 28m30s
## Summary
- Enforced autonomy guard behavior for denylist/allowlist checks, budget caps, tool-call limits, and write/apply approval gates.
- Added scope-aware guard evaluation (plan vs subplan) using `GuardScope(StrEnum)` for type-safe scope handling.
- Extracted remediation guidance strings as module-level constants (`REMEDIATION_DENYLIST`, `REMEDIATION_ALLOWLIST`, etc.) for consistency and testability.
- Added Behave coverage to validate guard remediation messaging and subplan-scoped tool-call limit behavior.

## Review Fix Round (v2)
Addressed review #2910 by @freemo:
1. **Reverted `resource_dag.robot`** — Unrelated Robot SQLite/cycle-detection changes removed from this commit; will be submitted as a separate PR.
2. **`scope` parameter → `GuardScope` enum** — Created `GuardScope(StrEnum)` in `automation_guard.py` with `PLAN` and `SUBPLAN` members. Updated `check_guard()` signature and all call sites.
3. **Removed redundant `scope_label`** — Now uses `scope.value` directly.
4. **Extracted remediation constants** — Guidance strings moved to module-level constants in `automation_guard.py`.

## Validation
- `nox -s lint` — passed
- `nox -s typecheck` — passed (0 errors, 0 warnings)
- `nox -s unit_tests` — passed (508 features, 12989 scenarios, 0 failures)
- `nox -s coverage_report` — passed (97% coverage)
- Rebased onto latest `master` (532ea100)

Closes #853

Reviewed-on: #1204
Co-authored-by: Brent Edwards <brent.edwards@cleverthis.com>
Co-committed-by: Brent Edwards <brent.edwards@cleverthis.com>
2026-04-01 01:46:37 +00:00
brent.edwards 91cc0b1446 test: add TDD bug-capture test for #1025 — plan correct auto-resolve (#1172)
CI / quality (push) Successful in 36s
CI / build (push) Successful in 20s
CI / helm (push) Successful in 22s
CI / lint (push) Successful in 3m21s
CI / typecheck (push) Successful in 3m57s
CI / benchmark-regression (push) Has been skipped
CI / security (push) Successful in 4m7s
CI / unit_tests (push) Successful in 9m18s
CI / docker (push) Successful in 1m18s
CI / coverage (push) Successful in 12m28s
CI / e2e_tests (push) Failing after 19m0s
CI / integration_tests (push) Successful in 24m45s
CI / status-check (push) Failing after 1s
CI / benchmark-publish (push) Successful in 28m39s
## Summary
- add Behave `@tdd_expected_fail` bug-capture scenarios for `plan correct` auto-resolve without `--plan`
- add shared mock fixtures and Robot integration coverage for isolated-container divergence reproducing bug #1025
- add ASV benchmark coverage for active-plan filtering and document the new TDD capture in changelog

## Testing
- nox -s unit_tests -- features/tdd_plan_correct_auto_resolve.feature
- nox -s integration_tests -- --include tdd_bug_1025
- nox -s lint
- nox -s typecheck
- nox -s coverage_report
- nox

Closes #1035

Reviewed-on: #1172
Reviewed-by: Jeffrey Phillips Freeman <jeffrey.freeman@cleverthis.com>
Co-authored-by: Brent Edwards <brent.edwards@cleverthis.com>
Co-committed-by: Brent Edwards <brent.edwards@cleverthis.com>
2026-04-01 00:40:46 +00:00
brent.edwards 01b6eb1804 feat(autonomy): parallel execution scales to 10+ concurrent subplans (#1201)
CI / build (push) Successful in 17s
CI / helm (push) Successful in 22s
CI / lint (push) Successful in 28s
CI / typecheck (push) Successful in 47s
CI / benchmark-regression (push) Has been skipped
CI / quality (push) Successful in 3m49s
CI / security (push) Successful in 4m11s
CI / unit_tests (push) Successful in 9m19s
CI / docker (push) Successful in 1m22s
CI / coverage (push) Successful in 12m35s
CI / e2e_tests (push) Successful in 16m17s
CI / integration_tests (push) Successful in 25m5s
CI / status-check (push) Successful in 2s
CI / benchmark-publish (push) Successful in 28m31s
## Summary

Add M6 parallel-scaling coverage for 10+ concurrent subplans:

- **15-subplan parallel scenario** with explicit peak-concurrency bound checks (`max_parallel=10`) and thread-safe concurrency tracking via `_build_executor()`.
- **Deep hierarchical decomposition** coverage (4+ levels) with adjusted leaf condition that only stops early when hitting `max_depth` or when the workset is trivially small (`min_files_per_subplan`).
- **Non-progress guard** in `_build_hierarchy` to prevent pathological recursion when clustering cannot meaningfully split the file set.
- **Small-project regression test** (< 50 files) verifying decomposition depth does not increase unexpectedly with the relaxed leaf condition.
- **ASV benchmark** for 15-subplan parallel execution with `max_parallel=10` to track scaling behavior.

### Removed from this PR

The `_build_hierarchy` child-linkage correctness fix (returning `node_id` from recursive calls instead of using `nodes[-1].node_id`) has been **removed** per review feedback — it is a separate bug fix and will be submitted as an independent issue/PR per CONTRIBUTING.md §Atomic Commits.

## Approach

- **Concurrency tracking:** The `_build_executor()` closure in step definitions detects `context.concurrency_counter` / `context.concurrency_lock` and performs thread-safe peak tracking in a try/finally block.
- **Leaf condition:** Replaced the `max_files_per_subplan` / `max_tokens_per_subplan` leaf check with a `min_files_per_subplan` check to allow deeper decomposition for large projects. Added a non-progress guard so clustering that cannot split the file set terminates immediately rather than recursing to `max_depth`.
- **Deterministic IDs:** `_ids_for_count()` preserves legacy fixed IDs for the first 5 subplans and generates additional deterministic IDs for scale scenarios.

## Validation

### Passing
- `nox -s lint` — all checks passed
- `nox -s typecheck` — 0 errors, 0 warnings
- `nox -s unit_tests` — 12,988 scenarios passed, 0 failed
- `nox -s coverage_report` — 97% (passes `--fail-under=97`)

Closes #855

Reviewed-on: #1201
Co-authored-by: Brent E. Edwards <brent.edwards@cleverthis.com>
Co-committed-by: Brent E. Edwards <brent.edwards@cleverthis.com>
2026-03-31 23:57:39 +00:00
freemo 31472b5413 test(coverage): add Behave scenarios for 39 under-covered modules
CI / benchmark-publish (pull_request) Has been skipped
CI / build (pull_request) Successful in 21s
CI / helm (pull_request) Successful in 22s
CI / lint (pull_request) Successful in 3m20s
CI / quality (pull_request) Successful in 3m43s
CI / typecheck (pull_request) Successful in 3m58s
CI / security (pull_request) Successful in 4m8s
CI / integration_tests (pull_request) Successful in 9m33s
CI / unit_tests (pull_request) Successful in 10m12s
CI / docker (pull_request) Successful in 1m28s
CI / coverage (pull_request) Successful in 12m18s
CI / e2e_tests (pull_request) Successful in 19m51s
CI / status-check (pull_request) Successful in 1s
CI / build (push) Successful in 15s
CI / helm (push) Successful in 22s
CI / lint (push) Successful in 3m18s
CI / quality (push) Successful in 3m41s
CI / typecheck (push) Successful in 3m57s
CI / benchmark-regression (push) Has been skipped
CI / security (push) Successful in 4m10s
CI / unit_tests (push) Failing after 6m58s
CI / docker (push) Has been skipped
CI / integration_tests (push) Successful in 9m15s
CI / coverage (push) Successful in 12m26s
CI / e2e_tests (push) Successful in 23m11s
CI / status-check (push) Failing after 1s
CI / benchmark-publish (push) Successful in 28m31s
CI / benchmark-regression (pull_request) Successful in 54m53s
Add Behave feature/step pairs that exercise uncovered branches across handlers, LSP, CLI, and service layers to reach the coverage gate.

ISSUES CLOSED: #1232
2026-03-31 21:47:12 +00:00
brent.edwards eed455d9f9 fix(devcontainer): Dockerfile build fails when .dockerignore excludes .git/ (#1234)
CI / build (push) Successful in 24s
CI / helm (push) Successful in 25s
CI / lint (push) Successful in 3m21s
CI / quality (push) Successful in 3m46s
CI / typecheck (push) Successful in 4m1s
CI / benchmark-regression (push) Has been skipped
CI / security (push) Successful in 4m14s
CI / integration_tests (push) Successful in 8m55s
CI / unit_tests (push) Successful in 9m54s
CI / docker (push) Successful in 1m33s
CI / coverage (push) Successful in 12m33s
CI / e2e_tests (push) Successful in 19m38s
CI / status-check (push) Successful in 1s
CI / benchmark-publish (push) Successful in 28m27s
## Summary

Fixes the Docker build failure at step 30/30:
```
fatal: not a git repository (or any of the parent directories): .git
```

## Root Cause

`.dockerignore` excludes `.git/`, so `COPY . $APP_DIR` never copies the `.git` directory into the image. However, the final `RUN` step unconditionally runs `git clean -xdf`, which requires a git repository to exist.

## Fix

Wrapped `git clean -xdf` and `rm -rf .git` in a conditional that checks for `.git` directory existence first, falling through silently when absent:

```dockerfile
([ -d .git ] && git clean -xdf && rm -rf .git || true)
```

This makes the Dockerfile work correctly whether `.git` is present (e.g., if `.dockerignore` is modified) or absent (current behavior).

## Quality Gates

| Gate | Result |
|------|--------|
| lint | Pass |
| typecheck | Pass (0 errors) |
| pre-commit hooks | Pass |

(Dockerfile-only change — no Python code modified, so unit/integration tests are unaffected.)

Closes #1233

Reviewed-on: #1234
Reviewed-by: Luis Mendes <luis.mendes@cleverthis.com>
Co-authored-by: Brent E. Edwards <brent.edwards@cleverthis.com>
Co-committed-by: Brent E. Edwards <brent.edwards@cleverthis.com>
2026-03-31 21:14:46 +00:00
hamza.khyari dd3b0286e5 Merge pull request 'feat(resource): implement 6-level execution environment precedence chain' (#1065) from feature/m5-exec-env-precedence into master
CI / build (push) Successful in 19s
CI / helm (push) Successful in 22s
CI / quality (push) Successful in 56s
CI / security (push) Successful in 1m1s
CI / lint (push) Successful in 3m19s
CI / typecheck (push) Successful in 3m55s
CI / benchmark-regression (push) Has been skipped
CI / integration_tests (push) Successful in 7m6s
CI / unit_tests (push) Successful in 7m42s
CI / docker (push) Successful in 1m31s
CI / coverage (push) Successful in 11m54s
CI / e2e_tests (push) Successful in 18m22s
CI / status-check (push) Successful in 14s
CI / benchmark-publish (push) Successful in 28m31s
Reviewed-on: #1065
Reviewed-by: Jeffrey Phillips Freeman <jeffrey.freeman@cleverthis.com>
2026-03-31 16:22:46 +00:00
hamza.khyari 5e96b4bf80 feat(resource): implement 6-level execution environment precedence chain
CI / build (pull_request) Successful in 16s
CI / helm (pull_request) Successful in 21s
CI / lint (pull_request) Successful in 3m18s
CI / quality (pull_request) Successful in 3m47s
CI / typecheck (pull_request) Successful in 3m57s
CI / security (pull_request) Successful in 4m6s
CI / benchmark-publish (pull_request) Has been skipped
CI / integration_tests (pull_request) Successful in 7m6s
CI / unit_tests (pull_request) Successful in 7m18s
CI / docker (pull_request) Successful in 1m19s
CI / coverage (pull_request) Successful in 11m49s
CI / e2e_tests (pull_request) Successful in 20m44s
CI / status-check (pull_request) Successful in 1s
CI / benchmark-regression (pull_request) Successful in 55m9s
Implement the spec's 6-level execution environment precedence chain
(spec lines 19324-19386):

1. Plan override (priority=override) — always wins
2. Project override (priority=override) — wins over devcontainer
3. Nearest-ancestor devcontainer — auto-discovered
4. Plan fallback (priority=fallback) — defers to devcontainer
5. Project fallback (priority=fallback) — defers to closer scopes
6. Host default — final fallback

- New resolve_with_precedence() API on ExecutionEnvironmentResolver
- Added execution_env_priority field to ContextConfig (project model)
- has_devcontainer() helper for devcontainer-instance detection
- Legacy 4-level resolve() preserved for backward compatibility
- _parse_priority() defaults missing priority to FALLBACK
- 13 new Behave scenarios testing all 6 levels + edge cases
- Updated CHANGELOG

ISSUES CLOSED: #877
2026-03-31 16:01:58 +00:00
hamza.khyari d27fb6d1f0 Merge pull request 'fix(cli): honour project-level execution-env-priority in resolution' (#1136) from bugfix/m8-exec-env-precedence-level2 into master
CI / build (push) Successful in 20s
CI / helm (push) Successful in 23s
CI / lint (push) Successful in 28s
CI / quality (push) Successful in 47s
CI / typecheck (push) Successful in 47s
CI / security (push) Successful in 4m9s
CI / integration_tests (push) Successful in 6m24s
CI / unit_tests (push) Successful in 6m33s
CI / docker (push) Successful in 1m22s
CI / coverage (push) Successful in 8m58s
CI / e2e_tests (push) Successful in 21m6s
CI / status-check (push) Successful in 2s
CI / benchmark-regression (push) Has been skipped
CI / benchmark-publish (push) Successful in 28m30s
Reviewed-on: #1136
2026-03-31 11:53:08 +00:00
hamza.khyari cd9cb9e889 fix(cli): honour project-level execution-env-priority in resolution
CI / build (pull_request) Successful in 15s
CI / helm (pull_request) Successful in 22s
CI / lint (pull_request) Successful in 3m19s
CI / quality (pull_request) Successful in 3m54s
CI / typecheck (pull_request) Successful in 3m57s
CI / security (pull_request) Successful in 4m27s
CI / integration_tests (pull_request) Successful in 7m1s
CI / unit_tests (pull_request) Successful in 7m44s
CI / docker (pull_request) Successful in 1m31s
CI / coverage (pull_request) Successful in 12m18s
CI / e2e_tests (pull_request) Successful in 21m52s
CI / status-check (pull_request) Successful in 1s
CI / benchmark-publish (pull_request) Has been skipped
CI / benchmark-regression (pull_request) Successful in 54m34s
Thread plan_env and project_env through the tool execution chain so
the ExecutionEnvironmentResolver receives project-level execution
environment values stored in ContextConfig.execution_environment.

The resolver's precedence logic (tool > plan > project > default) was
already correct, but callers never passed project_env — tools always
fell through to the global HOST default, ignoring project-level
overrides entirely.

Changes:
- PlanExecutionContext: add plan_env and project_env fields + properties
- ToolCallRouter: accept plan_env/project_env in constructor, pass to
  runner.execute() in route() and route_streaming()
- ToolCallingRuntime: accept plan_env/project_env, pass to
  runner.execute() in the direct-runner fallback path
- Update monkey-patched execute stubs in tool_router_steps.py to accept
  explicit plan_env/project_env keyword arguments
- Add 4 BDD scenarios proving plan_env/project_env reach the resolver
  via ToolCallRouter (project-only, plan-only, both, neither)

Dependency: requires PR #1135 to be merged first (adds CLI flag and
persistence for project-level execution-env-priority).

Closes #1080

ISSUES CLOSED: #1080
2026-03-31 11:31:00 +00:00
hamza.khyari 44e5eb9a94 Merge pull request 'test(integration): workflow example 5 — database schema migration with safety nets (review profile)' (#1042) from test/int-wf05-db-migration into master
CI / benchmark-publish (push) Waiting to run
CI / build (push) Successful in 17s
CI / helm (push) Successful in 21s
CI / lint (push) Successful in 3m19s
CI / quality (push) Successful in 3m41s
CI / typecheck (push) Successful in 3m56s
CI / benchmark-regression (push) Waiting to run
CI / security (push) Successful in 5m15s
CI / integration_tests (push) Successful in 7m13s
CI / unit_tests (push) Successful in 7m17s
CI / docker (push) Successful in 1m31s
CI / coverage (push) Successful in 12m10s
CI / e2e_tests (push) Successful in 21m51s
CI / status-check (push) Successful in 1s
Reviewed-on: #1042
2026-03-31 11:26:27 +00:00
hamza.khyari 3f66221938 test(integration): workflow example 5 — database schema migration with safety nets (review profile)
CI / build (pull_request) Successful in 25s
CI / helm (pull_request) Successful in 29s
CI / lint (pull_request) Successful in 3m47s
CI / typecheck (pull_request) Successful in 4m20s
CI / quality (pull_request) Successful in 4m23s
CI / security (pull_request) Successful in 4m49s
CI / integration_tests (pull_request) Successful in 7m27s
CI / unit_tests (pull_request) Successful in 8m11s
CI / docker (pull_request) Successful in 1m31s
CI / coverage (pull_request) Successful in 12m17s
CI / e2e_tests (pull_request) Successful in 22m57s
CI / status-check (pull_request) Successful in 1s
CI / benchmark-publish (pull_request) Has been skipped
CI / benchmark-regression (pull_request) Successful in 54m40s
Robot Framework integration test suite for Specification Workflow Example 5:
Database Schema Migration with Safety Nets.  Exercises the review automation
profile with custom resource types, custom skills with database tools,
phased child plan execution, checkpointing, and rollback.

- 7 test cases covering: custom resource type registration, review profile
  behavior, custom skill with 3 database tools, action creation with
  review profile, checkpoint/rollback via managers, 5-phase sequential
  SubplanService.spawn with fail-fast, and plan lifecycle through
  strategize-to-execute
- Uses mocked LLM providers (CLEVERAGENTS_TESTING_USE_MOCK_AI=true)
- All Run Process calls have timeout=60s on_timeout=kill
- Fix environment-dependent test failures: mock shutil.disk_usage in
  disk space and diagnostics --check Behave steps so tests pass
  regardless of CI runner disk space; Robot diagnostics test tolerates
  disk-space errors

ISSUES CLOSED: #769
2026-03-31 11:03:20 +00:00
freemo 532ea100e3 Docs: updated spec with --image tag
CI / lint (push) Successful in 19s
CI / quality (push) Successful in 3m46s
CI / typecheck (push) Successful in 3m59s
CI / benchmark-regression (push) Has been skipped
CI / security (push) Successful in 4m10s
CI / build (push) Successful in 13m16s
CI / helm (push) Successful in 13m46s
CI / coverage (push) Successful in 12m5s
CI / unit_tests (push) Successful in 22m50s
CI / integration_tests (push) Successful in 23m8s
CI / docker (push) Successful in 1m20s
CI / benchmark-publish (push) Successful in 28m26s
CI / e2e_tests (push) Successful in 33m26s
CI / status-check (push) Successful in 1s
2026-03-30 22:12:17 -04:00
freemo 8f104fab88 Docs: daily update to timeline 2026-03-30 22:12:17 -04:00
brent.edwards 84b0c10dbf fix(cli): plan correct active-plan resolution in isolated environments (#1184)
CI / build (push) Successful in 20s
CI / helm (push) Successful in 22s
CI / lint (push) Successful in 3m20s
CI / quality (push) Successful in 3m45s
CI / typecheck (push) Successful in 3m57s
CI / benchmark-regression (push) Has been skipped
CI / security (push) Successful in 4m9s
CI / integration_tests (push) Successful in 6m27s
CI / unit_tests (push) Successful in 6m27s
CI / docker (push) Successful in 1m19s
CI / coverage (push) Successful in 8m54s
CI / e2e_tests (push) Successful in 22m50s
CI / status-check (push) Successful in 1s
CI / benchmark-publish (push) Has been cancelled
## Summary
- tighten `plan correct` active-plan fallback so it only runs for isolated `CLEVERAGENTS_HOME` mismatch cases and never when explicit DB env overrides are configured
- narrow fallback exception handling in `_resolve_active_plan_id()` to expected DB/path/service failures; unexpected errors now surface instead of being silently swallowed
- add BDD regression coverage for both safeguards in `features/consolidated_plan_misc.feature` + `features/steps/plan_cli_legacy_r2_steps.py`

## Validation
- `nox -e lint`: PASS
- `nox -e typecheck`: PASS
- `nox -e unit_tests`: PASS
- `nox -e integration_tests`: FAIL in current branch baseline (29 failing Robot integration tests in this environment)
- `nox -e e2e_tests`: FAIL in current branch baseline (45 failing E2E tests in this environment)
- `nox -e coverage_report`: PASS (97%)

Closes #1025

Reviewed-on: #1184
Reviewed-by: Jeffrey Phillips Freeman <jeffrey.freeman@cleverthis.com>
Co-authored-by: Brent E. Edwards <brent.edwards@cleverthis.com>
Co-committed-by: Brent E. Edwards <brent.edwards@cleverthis.com>
2026-03-31 01:49:16 +00:00
CoreRasurae a4a6b061a6 fix(db): align v3_plans schema with specification DDL
CI / benchmark-publish (pull_request) Has been skipped
CI / build (pull_request) Successful in 18s
CI / lint (pull_request) Successful in 20s
CI / helm (pull_request) Successful in 22s
CI / typecheck (pull_request) Successful in 51s
CI / quality (pull_request) Successful in 3m45s
CI / integration_tests (pull_request) Successful in 3m59s
CI / security (pull_request) Successful in 4m8s
CI / unit_tests (pull_request) Successful in 5m44s
CI / docker (pull_request) Successful in 1m32s
CI / coverage (pull_request) Successful in 11m50s
CI / e2e_tests (pull_request) Successful in 20m28s
CI / status-check (pull_request) Successful in 1s
CI / lint (push) Successful in 17s
CI / build (push) Successful in 18s
CI / helm (push) Successful in 22s
CI / quality (push) Successful in 31s
CI / typecheck (push) Successful in 1m1s
CI / benchmark-regression (push) Has been skipped
CI / unit_tests (push) Successful in 3m57s
CI / security (push) Successful in 4m3s
CI / docker (push) Successful in 1m21s
CI / integration_tests (push) Successful in 7m11s
CI / coverage (push) Successful in 11m56s
CI / e2e_tests (push) Successful in 20m56s
CI / status-check (push) Successful in 1s
CI / benchmark-publish (push) Successful in 28m22s
CI / benchmark-regression (pull_request) Successful in 55m20s
Aligned v3_plans table with specification DDL:

1. Added effective_profile_snapshot column (TEXT NOT NULL) for
   storing frozen JSON snapshot of automation profile at plan
   creation time.  Added Pydantic field_validator ensuring the
   value is well-formed JSON.  Validator catches RecursionError
   for deeply nested JSON, consistent with automation_profile
   deserialization hardening.  Validator error message uses
   length-only to avoid potential information disclosure.
   Documented that the default "{}" exists for backward
   compatibility; new plans should explicitly set the snapshot.

2. Made root_plan_id NOT NULL — root plans self-reference their
   own plan_id, child plans reference the root ancestor.  Added
   explicit ondelete="RESTRICT" FK policy for consistency with
   other FKs in the model.  Documented known FK policy drift
   between ORM model (RESTRICT) and migrated databases (retained
   SET NULL) in the migration; data integrity is preserved by
   the NOT NULL constraint regardless.  Moved root_plan_id
   self-reference resolution into a PlanIdentity model_validator
   so the domain model is consistent with the DB NOT NULL
   constraint before and after persistence (previously the
   resolution only happened in from_domain(), creating an
   asymmetry where root_plan_id was None in-memory but non-null
   after round-tripping through the database).

3. Made automation_profile NOT NULL with default "balanced".

4. Documented intentional deviation: phase default is "action"
   (code) vs "strategize" (spec) because the Action phase was
   added as a pre-Strategize setup step.

5. Created Alembic migration with backfill logic for existing
   rows.  Root-ancestor backfill uses level-by-level propagation
   with a parent-readiness guard to correctly resolve plans at
   arbitrary hierarchy depth (3+ levels).  Added safety bound
   (max 100 iterations) with logged error on exhaustion to guard
   against cycles in parent_plan_id.  Merged batch_alter_table
   operations to avoid redundant full-table copies in SQLite
   batch mode.  Migration backfill also handles empty-string
   automation_profile values.  Documented downgrade limitation
   (backfill is not reversible).  Orphan-row fallback now logs
   affected row count at WARNING level.  Migration cycle-detection
   now logs affected plan_id values before the orphan fallback
   overwrites them.  All migration SQL uses sa.text() for
   consistency with SQLAlchemy best practices.

6. Hardened automation_profile deserialization in to_domain() to
   catch ValueError (invalid StrEnum provenance), Pydantic
   ValidationError, and RecursionError (deeply nested JSON) in
   addition to JSONDecodeError and KeyError, preventing
   unreadable plans from corrupted DB rows.  Applied the same
   defensive deserialization pattern to effective_profile_snapshot
   in to_domain(): corrupted JSON falls back to '{}' with a
   WARNING log instead of crashing the read path.  Added TypeError
   to the effective_profile_snapshot exception list in to_domain()
   for consistency with the Pydantic validator.  Logging of
   unparseable values uses length only to avoid potential
   information disclosure.

7. Used explicit None check (is not None) instead of truthiness
   for root_plan_id resolution in from_domain(), for
   effective_profile_snapshot in to_domain(), and in
   _serialize_automation_profile() for consistency.

8. Documented intentional column naming conventions vs spec DDL
   (e.g. automation_profile vs automation_profile_name, *_actor
   vs *_actor_name, processing_state vs state, v3_plans vs
   plans).  Documented the semantic difference: automation_profile
   stores either a bare name or structured JSON with provenance,
   whereas the spec automation_profile_name stores a plain name.

9. Fixed benchmark plan constructors
   (plan_phase_migration_bench.py) that were missing the now-
   required root_plan_id and effective_profile_snapshot fields.

10. Replaced defensive getattr() with direct attribute access for
    effective_profile_snapshot in from_domain() and update(),
    since the field is now defined on the Plan domain model.

11. Fixed Any type annotation in test helper _make_plan() to use
    AutomationProfileRef | None for proper type safety.

12. Added BDD scenarios for PlanIdentity self-reference
    resolution, NULL effective_profile_snapshot constraint
    enforcement, valid-JSON-missing-profile_name-key
    deserialization, invalid-JSON and empty-string snapshot
    rejection by Pydantic validator, and corrupted
    effective_profile_snapshot DB fallback in to_domain().

13. Extracted default automation profile name to a module-level
    constant (DEFAULT_AUTOMATION_PROFILE) to reduce sentinel
    duplication across models.py and repositories.py.

14. Centralised automation-profile serialisation into
    LifecyclePlanModel._serialize_automation_profile() to
    eliminate duplication between from_domain() and
    LifecyclePlanRepository.update().

15. Fixed to_domain() root_plan_id type cast from str | None
    to str, reflecting the NOT NULL column constraint.

16. Added PlanIdentity model_validator that resolves None
    root_plan_id to plan_id at domain construction time, ensuring
    the domain model honours the spec DDL NOT NULL constraint
    regardless of persistence state.  Simplified from_domain()
    root resolution accordingly.

ISSUES CLOSED: #921
2026-03-30 23:40:36 +01:00
freemo 7b3fcaf466 feat(config): implement three-scope config resolution with local config file support
CI / benchmark-publish (pull_request) Has been skipped
CI / build (pull_request) Successful in 19s
CI / helm (pull_request) Successful in 20s
CI / lint (pull_request) Successful in 3m19s
CI / quality (pull_request) Successful in 3m49s
CI / typecheck (pull_request) Successful in 3m57s
CI / integration_tests (pull_request) Successful in 3m57s
CI / security (pull_request) Successful in 4m6s
CI / unit_tests (pull_request) Successful in 7m19s
CI / docker (pull_request) Successful in 1m18s
CI / coverage (pull_request) Successful in 11m53s
CI / e2e_tests (pull_request) Successful in 21m25s
CI / status-check (pull_request) Successful in 1s
CI / build (push) Successful in 18s
CI / helm (push) Successful in 22s
CI / lint (push) Successful in 3m16s
CI / quality (push) Successful in 3m41s
CI / integration_tests (push) Successful in 3m48s
CI / typecheck (push) Successful in 3m54s
CI / unit_tests (push) Successful in 3m54s
CI / security (push) Successful in 4m4s
CI / docker (push) Successful in 1m19s
CI / benchmark-regression (push) Has been skipped
CI / e2e_tests (push) Successful in 14m58s
CI / coverage (push) Successful in 11m55s
CI / status-check (push) Successful in 1s
CI / benchmark-publish (push) Successful in 28m23s
CI / benchmark-regression (pull_request) Successful in 54m47s
Implement three-scope configuration resolution (local > project > global)
with deep merge. Add ConfigScope enum, project-root discovery, and
config.local.toml file support.

Changes:
- Add LOCAL to ConfigLevel enum and new ConfigScope enum (GLOBAL, PROJECT, LOCAL)
- Implement discover_project_root() walking up from CWD for cleveragents.toml/.cleveragents
- Implement config.local.toml file loading in ConfigService
- Implement three-scope deep merge via _deep_merge() helper
- Add read_project_config(), read_local_config(), read_merged_config() methods
- Add write_scoped_config() for writing to any scope file
- Update set_value() to accept optional scope parameter
- Update resolve() with six-level precedence chain (CLI > env > local > project > global > default)
- Update CLI config set with --scope flag (global/project/local)
- Add config.local.toml to .gitignore and DEFAULT_IGNORE_PATTERNS
- Add Behave BDD scenarios for three-scope resolution, deep merge, and project-root discovery

ISSUES CLOSED: #937
2026-03-30 21:48:01 +00:00
freemo 38e05ac45a feat(correction): wire checkpoint rollback into correction service revert flow
CI / benchmark-publish (pull_request) Has been skipped
CI / lint (pull_request) Successful in 18s
CI / build (pull_request) Successful in 20s
CI / helm (pull_request) Successful in 22s
CI / typecheck (pull_request) Successful in 1m0s
CI / quality (pull_request) Successful in 3m41s
CI / integration_tests (pull_request) Successful in 3m51s
CI / security (pull_request) Successful in 4m3s
CI / unit_tests (pull_request) Successful in 4m11s
CI / docker (pull_request) Successful in 1m31s
CI / coverage (pull_request) Successful in 11m48s
CI / e2e_tests (pull_request) Successful in 21m45s
CI / status-check (pull_request) Successful in 1s
CI / build (push) Successful in 17s
CI / helm (push) Successful in 21s
CI / quality (push) Successful in 3m48s
CI / integration_tests (push) Successful in 3m58s
CI / typecheck (push) Successful in 3m58s
CI / security (push) Successful in 4m6s
CI / unit_tests (push) Successful in 7m16s
CI / lint (push) Successful in 8m14s
CI / benchmark-regression (push) Has been skipped
CI / docker (push) Successful in 1m36s
CI / e2e_tests (push) Successful in 18m9s
CI / coverage (push) Successful in 12m13s
CI / status-check (push) Successful in 1s
CI / benchmark-publish (push) Successful in 28m11s
CI / benchmark-regression (pull_request) Successful in 54m54s
Implement the full correction-checkpoint rollback pipeline:

- Workspace snapshots: CheckpointService.create_workspace_snapshot()
  creates diff-based checkpoints before decision execution, storing
  only changed file paths in metadata.extra["diff_paths"]

- CorrectionService.revert_decisions(): new high-level entry point
  that creates a correction, computes impact, invokes checkpoint
  rollback, and archives artifacts in a single call

- Physical artifact archival: CheckpointService.archive_artifacts()
  moves files to .cleveragents/archived_artifacts/ instead of just
  flagging metadata. CorrectionService._archive_decision_artifacts()
  delegates to this during revert execution

- Selective rollback: CheckpointService.selective_rollback() wraps
  rollback_to_checkpoint with atomic semantics — captures HEAD before
  rollback and recovers on failure

- Diff-based storage: _compute_diff_snapshot() computes changed paths
  between checkpoints via git diff; snapshots store diff manifest and
  SHA-256 hash in metadata

- CLI: plan rollback now accepts --to-checkpoint <id> in addition to
  the positional checkpoint_id argument; uses selective_rollback for
  atomic execution

- DI wiring: Container now injects checkpoint_service into
  CorrectionService; CLI correct command uses container-provided
  service instead of ad-hoc instance (fixes bug #986)

- Checkpoint model: pre_decision added to allowed checkpoint_type
  values

- TDD: Removed @tdd_expected_fail from wiring test feature since the
  DI bug is now fixed

ISSUES CLOSED: #943
2026-03-30 17:06:49 -04:00
freemo afe6b849fe feat(cli): implement missing output element types and handles
CI / benchmark-publish (pull_request) Has been skipped
CI / build (pull_request) Successful in 19s
CI / helm (pull_request) Successful in 21s
CI / lint (pull_request) Successful in 3m19s
CI / quality (pull_request) Successful in 3m52s
CI / typecheck (pull_request) Successful in 3m56s
CI / security (pull_request) Successful in 4m5s
CI / integration_tests (pull_request) Successful in 7m2s
CI / unit_tests (pull_request) Successful in 11m51s
CI / docker (pull_request) Successful in 1m31s
CI / coverage (pull_request) Successful in 11m50s
CI / e2e_tests (pull_request) Successful in 16m31s
CI / status-check (pull_request) Successful in 1s
CI / build (push) Successful in 17s
CI / helm (push) Successful in 21s
CI / lint (push) Successful in 24s
CI / quality (push) Successful in 3m41s
CI / integration_tests (push) Successful in 3m46s
CI / typecheck (push) Successful in 3m55s
CI / security (push) Successful in 4m6s
CI / unit_tests (push) Successful in 7m14s
CI / docker (push) Successful in 1m32s
CI / benchmark-regression (push) Has been skipped
CI / coverage (push) Successful in 11m46s
CI / e2e_tests (push) Successful in 18m1s
CI / status-check (push) Successful in 1s
CI / benchmark-publish (push) Successful in 28m19s
CI / benchmark-regression (pull_request) Successful in 54m43s
Implement LiveMaterializationStrategy as the third materialization
strategy type (alongside sequential_buffer and accumulate) per spec
§26456-26492.  The live strategy renders element updates in-place at
~15 fps by tracking a dirty-element set and coalescing updates into
frame redraws.

RichMaterializer now extends LiveMaterializationStrategy instead of
_BaseBufferStrategy, enabling supports_incremental_updates=True.
Element rendering still delegates to the colour renderer for visual
formatting, maintaining backward compatibility.

Changes:
- Add _LiveMaterializationStrategy class with frame-rate throttling,
  dirty-element tracking, and per-frame composition in declaration
  order
- Update RichMaterializer to extend _LiveMaterializationStrategy
- Export LiveMaterializationStrategy from materializers.py and
  __init__.py
- Update SD-2 and SD-7 documentation in __init__.py
- Add vulture whitelist entry for LiveMaterializationStrategy
- Add 5 Behave scenarios covering live strategy rendering, incremental
  update support, dirty-element coalescing, all-element-type rendering,
  and frame rate validation
- Add step definitions for the new scenarios

ISSUES CLOSED: #903
2026-03-30 19:52:51 +00:00
freemo 297823c291 feat(cli): add actor context remove, export, and import commands
CI / benchmark-publish (pull_request) Has been skipped
CI / build (pull_request) Successful in 18s
CI / helm (pull_request) Successful in 21s
CI / lint (pull_request) Successful in 3m18s
CI / quality (pull_request) Successful in 3m42s
CI / typecheck (pull_request) Successful in 3m55s
CI / security (pull_request) Successful in 4m5s
CI / integration_tests (pull_request) Successful in 9m12s
CI / unit_tests (pull_request) Successful in 9m32s
CI / docker (pull_request) Successful in 1m33s
CI / coverage (pull_request) Successful in 11m51s
CI / e2e_tests (pull_request) Successful in 16m26s
CI / status-check (pull_request) Successful in 1s
CI / build (push) Successful in 13s
CI / helm (push) Successful in 22s
CI / lint (push) Successful in 3m17s
CI / quality (push) Successful in 3m41s
CI / typecheck (push) Successful in 3m53s
CI / benchmark-regression (push) Has been skipped
CI / security (push) Successful in 4m4s
CI / integration_tests (push) Successful in 10m44s
CI / unit_tests (push) Successful in 12m37s
CI / docker (push) Failing after 47s
CI / coverage (push) Successful in 11m53s
CI / e2e_tests (push) Has been cancelled
CI / benchmark-publish (push) Has been cancelled
CI / status-check (push) Has been cancelled
CI / benchmark-regression (pull_request) Successful in 54m46s
Implement three new actor context subcommands as specified in the v3
CLI specification:

- `agents actor context remove [--yes|-y] (--all|-a|<NAME>)`:
  Remove a named context or all contexts with interactive confirmation.
  Supports --all for bulk removal and --yes to skip prompts.

- `agents actor context export (--output|-o) <FILE> <NAME>`:
  Export a named context to JSON or YAML (detected from file extension).
  Includes sha256 integrity checksum in output metadata.

- `agents actor context import [--update] (--input|-i) <FILE> [<NAME>]`:
  Import a context from JSON or YAML. Name is inferred from file metadata
  if omitted. Refuses to overwrite existing contexts unless --update is
  specified.

All commands:
- Support 6 output formats (json, yaml, plain, table, rich, color) via
  the shared format_output framework
- Use ContextManager for persistence (messages, metadata, state,
  global_context)
- Follow existing error handling patterns (typer.Exit for user errors)
- Are wired as `agents actor context` subcommand group via add_typer

New files:
- src/cleveragents/cli/commands/actor_context.py (command module)
- features/actor_context_cmds.feature (Behave BDD scenarios)
- features/steps/actor_context_cmds_steps.py (BDD step definitions)
- robot/actor_context_export_import.robot (Robot integration test)

ISSUES CLOSED: #869
2026-03-30 19:35:23 +00:00
freemo a9465c4865 fix(cli): derive actor name from config file instead of positional argument
CI / benchmark-publish (pull_request) Has been skipped
CI / build (pull_request) Successful in 18s
CI / helm (pull_request) Successful in 22s
CI / typecheck (pull_request) Successful in 50s
CI / lint (pull_request) Successful in 3m19s
CI / quality (pull_request) Successful in 3m53s
CI / security (pull_request) Successful in 4m12s
CI / integration_tests (pull_request) Successful in 7m10s
CI / unit_tests (pull_request) Successful in 7m27s
CI / docker (pull_request) Successful in 1m30s
CI / coverage (pull_request) Successful in 11m54s
CI / e2e_tests (pull_request) Successful in 19m37s
CI / status-check (pull_request) Successful in 1s
CI / build (push) Successful in 15s
CI / helm (push) Successful in 23s
CI / security (push) Successful in 57s
CI / lint (push) Successful in 3m18s
CI / quality (push) Successful in 3m39s
CI / typecheck (push) Successful in 3m52s
CI / integration_tests (push) Successful in 8m48s
CI / unit_tests (push) Successful in 9m38s
CI / docker (push) Successful in 1m18s
CI / coverage (push) Successful in 11m48s
CI / e2e_tests (push) Successful in 20m13s
CI / status-check (push) Successful in 1s
CI / benchmark-publish (push) Successful in 28m20s
CI / benchmark-regression (push) Has been skipped
CI / benchmark-regression (pull_request) Successful in 54m52s
Remove the <NAME> positional argument from `actor add` command. The actor
name is now derived from the `name` field inside the config YAML file, per
the specification: `agents actor add (--config|-c) <FILE> [--update]`.
Updated all BDD and integration tests to pass name via config file.

ISSUES CLOSED: #914
2026-03-30 18:27:59 +00:00
freemo 1c1f477208 fix(cli): align output envelope with specification structure
CI / benchmark-publish (pull_request) Has been skipped
CI / build (pull_request) Successful in 22s
CI / helm (pull_request) Successful in 34s
CI / lint (pull_request) Successful in 3m19s
CI / quality (pull_request) Successful in 3m41s
CI / typecheck (pull_request) Successful in 3m55s
CI / integration_tests (pull_request) Successful in 3m58s
CI / security (pull_request) Successful in 4m5s
CI / unit_tests (pull_request) Successful in 7m30s
CI / docker (pull_request) Successful in 1m31s
CI / coverage (pull_request) Successful in 8m49s
CI / e2e_tests (pull_request) Successful in 17m42s
CI / status-check (pull_request) Successful in 1s
CI / build (push) Successful in 15s
CI / helm (push) Successful in 23s
CI / lint (push) Successful in 3m18s
CI / typecheck (push) Successful in 3m57s
CI / quality (push) Successful in 3m57s
CI / benchmark-regression (push) Has been skipped
CI / security (push) Successful in 4m24s
CI / integration_tests (push) Successful in 6m58s
CI / unit_tests (push) Successful in 7m27s
CI / docker (push) Successful in 1m18s
CI / coverage (push) Successful in 12m17s
CI / e2e_tests (push) Successful in 19m39s
CI / status-check (push) Successful in 1s
CI / benchmark-publish (push) Successful in 28m4s
CI / benchmark-regression (pull_request) Successful in 54m48s
Align the structured output envelope (JSON/YAML modes) with the specification:
add `status` field, rename `elements` to `data`, rename `metadata` to
`messages`, and fix the fallback chain to include the table step
(rich→table→color→plain).

ISSUES CLOSED: #884
2026-03-30 17:48:48 +00:00
freemo 4eddbcf489 fix(cli): add --depth-gradient flag to project context set
CI / benchmark-publish (pull_request) Has been skipped
CI / build (pull_request) Successful in 22s
CI / helm (pull_request) Successful in 25s
CI / lint (pull_request) Successful in 3m45s
CI / quality (pull_request) Successful in 4m5s
CI / typecheck (pull_request) Successful in 4m22s
CI / security (pull_request) Successful in 4m31s
CI / integration_tests (pull_request) Successful in 7m27s
CI / unit_tests (pull_request) Successful in 7m55s
CI / docker (pull_request) Successful in 1m30s
CI / coverage (pull_request) Successful in 12m1s
CI / e2e_tests (pull_request) Successful in 22m32s
CI / status-check (pull_request) Successful in 12s
CI / build (push) Successful in 25s
CI / quality (push) Successful in 39s
CI / helm (push) Successful in 41s
CI / lint (push) Successful in 3m36s
CI / typecheck (push) Successful in 3m52s
CI / benchmark-regression (push) Has been skipped
CI / security (push) Successful in 4m3s
CI / unit_tests (push) Successful in 4m12s
CI / docker (push) Successful in 1m32s
CI / integration_tests (push) Successful in 7m3s
CI / coverage (push) Successful in 11m52s
CI / e2e_tests (push) Successful in 20m56s
CI / status-check (push) Successful in 1s
CI / benchmark-publish (push) Successful in 28m22s
CI / benchmark-regression (pull_request) Successful in 55m2s
Add the missing --depth-gradient repeatable flag to `project context set`
per specification. The flag accepts HOP:INT_OR_NAME format to control
context detail depth degradation with graph distance. Parsing validates
hop as integer and value as integer or recognized detail level name.

ISSUES CLOSED: #889
2026-03-30 17:12:20 +00:00
hamza.khyari cbcb873e17 Merge pull request 'fix(cli): implement --execution-env-priority on project context set' (#1135) from bugfix/m8-project-exec-env-priority into master
CI / lint (push) Successful in 19s
CI / build (push) Successful in 19s
CI / helm (push) Successful in 22s
CI / typecheck (push) Successful in 1m4s
CI / security (push) Successful in 1m5s
CI / benchmark-regression (push) Has been skipped
CI / quality (push) Successful in 3m47s
CI / integration_tests (push) Successful in 6m57s
CI / unit_tests (push) Successful in 7m20s
CI / docker (push) Successful in 1m39s
CI / coverage (push) Successful in 8m44s
CI / e2e_tests (push) Successful in 17m56s
CI / status-check (push) Successful in 1s
CI / benchmark-publish (push) Successful in 28m56s
Reviewed-on: #1135
2026-03-30 14:53:55 +00:00
hamza.khyari 49015c6bee fix(cli): implement --execution-env-priority on project context set
CI / benchmark-publish (pull_request) Has been skipped
CI / build (pull_request) Successful in 18s
CI / helm (pull_request) Successful in 23s
CI / lint (pull_request) Successful in 3m19s
CI / quality (pull_request) Successful in 3m43s
CI / typecheck (pull_request) Successful in 3m57s
CI / security (pull_request) Successful in 4m6s
CI / integration_tests (pull_request) Successful in 7m5s
CI / unit_tests (pull_request) Successful in 7m10s
CI / docker (pull_request) Successful in 1m18s
CI / coverage (pull_request) Successful in 11m47s
CI / e2e_tests (pull_request) Successful in 20m22s
CI / status-check (pull_request) Successful in 2s
CI / benchmark-regression (pull_request) Successful in 1h0m10s
Add --execution-env-priority flag to 'project context set' command,
enabling project-level execution environment priority per spec WF17.

- Add execution_env_priority field to ContextConfig domain model
- Validate flag value against ExecutionEnvPriority enum (fallback/override)
- Persist in context_policy_json, preserving existing execution_environment
- Display in 'project context show' Execution Environment section
- Merge with existing blob to avoid overwriting previously set fields

Tests: 9 Behave scenarios, 26 steps.

ISSUES CLOSED: #1079
2026-03-30 14:33:28 +00:00
hamza.khyari 40e0cb9860 Merge pull request 'feat(resource): add container infrastructure resource types' (#1045) from feature/container-resource-types into master
CI / build (push) Successful in 16s
CI / helm (push) Successful in 21s
CI / lint (push) Successful in 20s
CI / quality (push) Successful in 3m43s
CI / typecheck (push) Successful in 4m5s
CI / benchmark-regression (push) Has been skipped
CI / security (push) Successful in 4m11s
CI / unit_tests (push) Successful in 4m21s
CI / docker (push) Successful in 1m30s
CI / integration_tests (push) Successful in 7m29s
CI / coverage (push) Successful in 8m42s
CI / e2e_tests (push) Successful in 19m32s
CI / status-check (push) Successful in 1s
CI / benchmark-publish (push) Successful in 30m4s
Reviewed-on: #1045
2026-03-30 14:06:24 +00:00
hamza.khyari 2370e19da8 feat(resource): add container infrastructure resource types
CI / benchmark-publish (pull_request) Has been skipped
CI / build (pull_request) Successful in 21s
CI / lint (pull_request) Successful in 27s
CI / helm (pull_request) Successful in 31s
CI / typecheck (pull_request) Successful in 1m9s
CI / quality (pull_request) Successful in 3m43s
CI / security (pull_request) Successful in 4m6s
CI / integration_tests (pull_request) Successful in 6m12s
CI / unit_tests (pull_request) Successful in 7m14s
CI / docker (pull_request) Successful in 2m7s
CI / coverage (pull_request) Successful in 11m52s
CI / e2e_tests (pull_request) Successful in 21m28s
CI / status-check (pull_request) Successful in 1s
CI / benchmark-regression (pull_request) Successful in 56m15s
Add 7 container infrastructure resource types per ADR-039:
container-runtime, container-image, container-mount, container-exec-env,
container-port, container-volume, container-network.

- YAML configs under examples/resource-types/
- Bootstrap registration via _resource_registry_container.py
- Updated container-instance parent_types (container-runtime, container-image)
  and child_types (container-mount, container-exec-env, container-port)
- container-runtime is top-level with auto-discovery rules (scan_depth: 1)
- container-mount/exec-env/port inherit snapshot sandbox from instance
- container-volume is user-addable with snapshot sandbox
- container-network is read-only, no sandbox
- Handler references are forward declarations (ADR-039)
- 33 Behave BDD scenarios, 4 Robot integration tests
- Updated BUILTIN_NAMES, service docstring, CHANGELOG

ISSUES CLOSED: #831
2026-03-30 13:44:54 +00:00
aditya f03e510a11 Merge pull request 'feat(acms): integrate FAISS into ACMS vector backend protocol' (#1165) from feature/m6-faiss-acms-backend into master
CI / build (push) Successful in 18s
CI / helm (push) Successful in 20s
CI / quality (push) Successful in 41s
CI / security (push) Successful in 1m17s
CI / lint (push) Successful in 3m23s
CI / typecheck (push) Successful in 3m55s
CI / benchmark-regression (push) Has been skipped
CI / integration_tests (push) Successful in 7m34s
CI / unit_tests (push) Successful in 7m49s
CI / docker (push) Successful in 1m18s
CI / coverage (push) Successful in 12m10s
CI / e2e_tests (push) Successful in 19m11s
CI / status-check (push) Successful in 2s
CI / benchmark-publish (push) Has been cancelled
Reviewed-on: #1165
Reviewed-by: Jeffrey Phillips Freeman <jeffrey.freeman@cleverthis.com>
2026-03-30 13:40:25 +00:00
aditya eff446f5e8 feat(acms): integrate FAISS into ACMS vector backend protocol
CI / benchmark-publish (pull_request) Has been skipped
CI / build (pull_request) Successful in 19s
CI / helm (pull_request) Successful in 21s
CI / lint (pull_request) Successful in 26s
CI / typecheck (pull_request) Successful in 50s
CI / quality (pull_request) Successful in 3m44s
CI / integration_tests (pull_request) Successful in 3m58s
CI / unit_tests (pull_request) Successful in 4m5s
CI / security (pull_request) Successful in 4m6s
CI / docker (pull_request) Successful in 1m18s
CI / coverage (pull_request) Successful in 14m17s
CI / e2e_tests (pull_request) Successful in 21m13s
CI / status-check (pull_request) Successful in 1s
CI / benchmark-regression (pull_request) Successful in 58m23s
Add FAISS-backed ACMS read and write adapters on top of the shared VectorStoreService, wire them through the DI container, and cover indexing, scoped search, removal, and benchmark behavior with Behave and ASV.

Address review feedback by keeping the commit scoped to the FAISS backend work and replacing the loose vector-store cache typing with explicit FAISS store protocols instead of Any.

ISSUES CLOSED: #871
2026-03-30 13:19:08 +00:00
CoreRasurae 007af498b8 refactor(autonomy): rename automation profile task flags to spec names
CI / benchmark-publish (pull_request) Has been skipped
CI / build (pull_request) Successful in 17s
CI / helm (pull_request) Successful in 33s
CI / lint (pull_request) Successful in 3m42s
CI / security (pull_request) Successful in 4m8s
CI / quality (pull_request) Successful in 4m9s
CI / typecheck (pull_request) Successful in 4m20s
CI / integration_tests (pull_request) Successful in 7m2s
CI / unit_tests (pull_request) Successful in 7m55s
CI / docker (pull_request) Successful in 1m19s
CI / coverage (pull_request) Successful in 8m46s
CI / e2e_tests (pull_request) Successful in 16m1s
CI / status-check (pull_request) Successful in 1s
CI / build (push) Successful in 17s
CI / helm (push) Successful in 22s
CI / quality (push) Successful in 31s
CI / lint (push) Successful in 3m28s
CI / typecheck (push) Successful in 3m54s
CI / benchmark-regression (push) Has been skipped
CI / security (push) Successful in 4m5s
CI / integration_tests (push) Successful in 6m13s
CI / unit_tests (push) Successful in 6m28s
CI / docker (push) Successful in 1m34s
CI / coverage (push) Successful in 12m5s
CI / e2e_tests (push) Successful in 18m47s
CI / status-check (push) Successful in 1s
CI / benchmark-publish (push) Successful in 28m0s
CI / benchmark-regression (pull_request) Successful in 59m48s
Renamed all 11 task-type confidence threshold fields in AutomationProfile
from phase-transition semantics to spec-defined task-type semantics.
Updated all 8 built-in profiles, CLI formatting, YAML schema, services,
and all Behave/Robot tests referencing the old field names.

Post-review fixes:
- Fixed 24 stale old field names in M6 fixture files
  (automation_profiles.json, autonomy_guardrails.json)
- Added model_validator(mode='before') to detect legacy field names
  and raise actionable ValueError with rename mapping
- Added semantic bridge comments in PlanLifecycleService mapping
  task-type thresholds to phase-transition gates
- Added threshold_field to structured log messages for observability
- Restored categorised CLI automation-profile show output to match
  spec (Phase Transitions / Decision Automation / Self-Repair /
  Execution Controls) instead of flat list
- Added missing access_network field to spec show output examples
  (Rich, Plain, JSON, YAML variants)
- Aligned ADR-017 profile fields table to all 11 fields with
  descriptions matching spec Automatable Tasks table
- Aligned automation_profiles.md threshold descriptions with spec
- Added spec section references in phase_reversion.md, error_recovery.md,
  and plan_execute.md for field naming context
- Extended repository roundtrip test to assert all 11 threshold fields
- Fixed benchmark _make_profile() 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 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 (line 16703, line 28406)
- Improved bridge comments in test steps with semantic context for
  threshold-to-gate mappings

ISSUES CLOSED: #902
2026-03-30 13:18:07 +01:00
hamza.khyari 452a2f35b0 Merge pull request 'feat(lsp): add missing LspServerConfig model fields' (#1064) from feature/lsp-config-fields into master
CI / lint (push) Successful in 21s
CI / build (push) Successful in 23s
CI / helm (push) Successful in 24s
CI / typecheck (push) Successful in 48s
CI / quality (push) Successful in 3m43s
CI / security (push) Successful in 4m8s
CI / integration_tests (push) Successful in 6m6s
CI / unit_tests (push) Successful in 6m22s
CI / benchmark-regression (push) Has been skipped
CI / docker (push) Successful in 1m35s
CI / coverage (push) Successful in 8m55s
CI / benchmark-publish (push) Has been cancelled
CI / status-check (push) Has been cancelled
CI / e2e_tests (push) Has been cancelled
Reviewed-on: #1064
Reviewed-by: Jeffrey Phillips Freeman <jeffrey.freeman@cleverthis.com>
2026-03-30 12:07:28 +00:00
hamza.khyari c97ec273a9 feat(lsp): add missing LspServerConfig model fields
CI / build (pull_request) Successful in 21s
CI / helm (pull_request) Successful in 23s
CI / lint (pull_request) Successful in 26s
CI / quality (pull_request) Successful in 56s
CI / typecheck (pull_request) Successful in 1m2s
CI / security (pull_request) Successful in 1m7s
CI / integration_tests (pull_request) Successful in 5m51s
CI / unit_tests (pull_request) Successful in 7m29s
CI / docker (pull_request) Successful in 2m13s
CI / coverage (pull_request) Successful in 8m50s
CI / benchmark-publish (pull_request) Has been skipped
CI / e2e_tests (pull_request) Successful in 15m34s
CI / status-check (pull_request) Successful in 2s
CI / benchmark-regression (pull_request) Successful in 59m14s
Add specification-required fields to LspServerConfig:

- description: str (max_length=1000, default='')
- transport: LspTransport enum (stdio/tcp/pipe, default=stdio)
- initialization: dict[str, Any] (LSP initializationOptions, default={})
- workspace_settings: dict[str, Any] (workspace/didChangeConfiguration, default={})

All fields have defaults for backward compatibility with existing
configs. LspTransport enum exported from lsp package.

Tests: 17 Behave scenarios, 5 Robot integration tests.
Existing LSP tests: 250/250 pass unchanged.

ISSUES CLOSED: #835
2026-03-30 11:51:27 +00:00
freemo 9cace15d6e test(e2e): workflow example 18 — container with remote repo clone (trusted profile)
CI / benchmark-publish (pull_request) Has been skipped
CI / lint (pull_request) Successful in 20s
CI / typecheck (pull_request) Successful in 47s
CI / quality (pull_request) Successful in 48s
CI / build (pull_request) Successful in 15s
CI / helm (pull_request) Successful in 22s
CI / security (pull_request) Successful in 4m18s
CI / integration_tests (pull_request) Successful in 6m19s
CI / unit_tests (pull_request) Successful in 6m39s
CI / docker (pull_request) Successful in 1m32s
CI / coverage (pull_request) Successful in 12m6s
CI / e2e_tests (pull_request) Successful in 19m6s
CI / status-check (pull_request) Successful in 2s
CI / quality (push) Successful in 45s
CI / build (push) Successful in 17s
CI / helm (push) Successful in 23s
CI / lint (push) Successful in 3m16s
CI / integration_tests (push) Successful in 3m50s
CI / typecheck (push) Successful in 3m54s
CI / security (push) Successful in 4m4s
CI / unit_tests (push) Successful in 8m31s
CI / docker (push) Successful in 1m22s
CI / coverage (push) Successful in 12m12s
CI / benchmark-regression (push) Has been skipped
CI / e2e_tests (push) Successful in 21m14s
CI / status-check (push) Successful in 2s
CI / benchmark-publish (push) Has been cancelled
CI / benchmark-regression (pull_request) Successful in 59m1s
E2E test for Specification Workflow Example 18: Container with Remote
Repo Clone using the trusted automation profile.  Exercises the full
container-instance workflow per the spec:

- Registers a container-instance resource with --clone-into flag (new
  CLI flag added to resource add for REPO_URL:CONTAINER_PATH).
- Two-step project creation: project create + project link-resource.
- Dynamic LLM actor selection (Anthropic/OpenAI) matching available
  API keys.
- Plan use with --execution-environment container,
  --execution-env-priority fallback, and --automation-profile trusted.
- Full plan lifecycle: strategize, execute, diff, apply, status.
- Positive assertions: non-empty output, plan ID presence, terminal
  state verification, container/clone evidence logging.
- Negative assertions: Traceback and INTERNAL error checks.
- ULID regex uses Crockford base32 character set.
- Unique suffix for resource/project names (parallel CI safe).
- Skip If No LLM Keys guard for graceful degradation.
- CHANGELOG.md updated.

ISSUES CLOSED: #764
2026-03-30 19:17:41 +08:00