UAT: top-level acms/ module duplicates domain/models/acms/ — UKO vocabulary data should live in the domain layer #4139

Open
opened 2026-04-06 10:39:05 +00:00 by freemo · 0 comments
Owner

Metadata

  • Branch: refactor/acms-uko-move-to-domain-layer
  • Commit Message: refactor(acms): move top-level acms/uko/ vocabulary data into domain/models/acms/
  • Milestone: (none — see backlog note below)
  • Parent Epic: #396

Bug Report

Feature Area: Code Organization and Module Structure
Tested by: UAT tester instance uat-tester-code-org-001
Severity: Medium (Clean Architecture structural violation)

What Was Tested

Checked the top-level module structure of src/cleveragents/ for modules that violate clean architecture layer placement.

Expected Behavior (from CONTRIBUTING.md)

CONTRIBUTING.md line 402 states: "Clean Architecture: Separate concerns, maintain clear boundaries between layers."

Domain models and vocabulary data should live in the domain/ layer. There should not be a separate top-level acms/ module that duplicates the domain/models/acms/ module's purpose.

Actual Behavior

There are two separate ACMS-related modules at different levels:

  1. src/cleveragents/acms/ — top-level module containing UKO vocabulary data (layer 3 language-specific vocabularies, detail level maps)
  2. src/cleveragents/domain/models/acms/ — domain layer module containing ACMS models (analyzers, strategies, tiers, etc.)

The top-level acms/ module is outside the clean architecture layers (domain/application/infrastructure/presentation) and contains domain-level vocabulary data that arguably belongs in domain/models/acms/.

Evidence

$ ls src/cleveragents/acms/
__init__.py  uko/

$ ls src/cleveragents/acms/uko/
__init__.py  detail_level_maps.py  layer3_java.py  layer3_py.py  layer3_rs.py  layer3_ts.py
vocabularies.py  vocabulary.py  vocabulary_registry.py

$ ls src/cleveragents/domain/models/acms/
__init__.py  analyzers.py  backends.py  crp.py  detail_level.py  ...

The top-level acms/ module is only imported by one file:

$ grep -rn "from cleveragents.acms import" src/cleveragents/ --include="*.py"
application/services/acms_skeleton_compressor.py:10:from cleveragents.acms import (...)

Steps to Reproduce

ls src/cleveragents/acms/
ls src/cleveragents/domain/models/acms/
grep -rn "from cleveragents.acms import" src/cleveragents/ --include="*.py"

Impact

  • Confusing module structure — developers must look in two places for ACMS-related code
  • The top-level acms/ module sits outside the clean architecture layers, making it unclear which layer it belongs to
  • Violates the principle of having a single, clear location for domain vocabulary data

Suggested Fix

Move src/cleveragents/acms/uko/ to src/cleveragents/domain/models/acms/uko/ and update the single import in acms_skeleton_compressor.py accordingly. This consolidates all ACMS-related domain data in the domain layer.

Code Location

src/cleveragents/acms/ (top-level module)
src/cleveragents/domain/models/acms/ (domain layer module)


Subtasks

  • Move src/cleveragents/acms/uko/ to src/cleveragents/domain/models/acms/uko/
  • Update __init__.py exports in domain/models/acms/ to expose the relocated UKO symbols
  • Update the single import in application/services/acms_skeleton_compressor.py from cleveragents.acms to cleveragents.domain.models.acms
  • Remove the now-empty top-level src/cleveragents/acms/ module and its __init__.py
  • Search for any other references to cleveragents.acms across the codebase and update them
  • Tests (Behave): Verify all existing ACMS unit test scenarios still pass after the move
  • Tests (Robot): Verify integration tests referencing ACMS context pipeline still pass
  • Verify coverage >= 97% via nox -s coverage_report
  • Run nox (all default sessions), fix any errors

Definition of Done

This issue is complete when:

  • All subtasks above are completed and checked off.
  • The top-level src/cleveragents/acms/ module no longer exists; all UKO vocabulary data lives under src/cleveragents/domain/models/acms/uko/.
  • A Git commit is created where the first line of the commit message matches the Commit Message in Metadata exactly, followed by a blank line, then additional lines providing relevant details about the implementation.
  • The commit is pushed to the remote on the branch matching the Branch in Metadata exactly.
  • The commit is submitted as a pull request to master, reviewed, and merged before this issue is marked done.
  • All nox stages pass.
  • Coverage >= 97%.

Backlog note: This issue was discovered during autonomous operation
on milestone v3.4.0. It does not block milestone completion and has been
placed in the backlog for human review and future milestone assignment.


Automated by CleverAgents Bot
Supervisor: UAT Testing | Agent: ca-new-issue-creator

## Metadata - **Branch**: `refactor/acms-uko-move-to-domain-layer` - **Commit Message**: `refactor(acms): move top-level acms/uko/ vocabulary data into domain/models/acms/` - **Milestone**: *(none — see backlog note below)* - **Parent Epic**: #396 --- ## Bug Report **Feature Area:** Code Organization and Module Structure **Tested by:** UAT tester instance uat-tester-code-org-001 **Severity:** Medium (Clean Architecture structural violation) ### What Was Tested Checked the top-level module structure of `src/cleveragents/` for modules that violate clean architecture layer placement. ### Expected Behavior (from CONTRIBUTING.md) CONTRIBUTING.md line 402 states: *"Clean Architecture: Separate concerns, maintain clear boundaries between layers."* Domain models and vocabulary data should live in the `domain/` layer. There should not be a separate top-level `acms/` module that duplicates the `domain/models/acms/` module's purpose. ### Actual Behavior There are **two separate ACMS-related modules** at different levels: 1. `src/cleveragents/acms/` — top-level module containing UKO vocabulary data (layer 3 language-specific vocabularies, detail level maps) 2. `src/cleveragents/domain/models/acms/` — domain layer module containing ACMS models (analyzers, strategies, tiers, etc.) The top-level `acms/` module is outside the clean architecture layers (domain/application/infrastructure/presentation) and contains domain-level vocabulary data that arguably belongs in `domain/models/acms/`. ### Evidence ``` $ ls src/cleveragents/acms/ __init__.py uko/ $ ls src/cleveragents/acms/uko/ __init__.py detail_level_maps.py layer3_java.py layer3_py.py layer3_rs.py layer3_ts.py vocabularies.py vocabulary.py vocabulary_registry.py $ ls src/cleveragents/domain/models/acms/ __init__.py analyzers.py backends.py crp.py detail_level.py ... ``` The top-level `acms/` module is only imported by one file: ``` $ grep -rn "from cleveragents.acms import" src/cleveragents/ --include="*.py" application/services/acms_skeleton_compressor.py:10:from cleveragents.acms import (...) ``` ### Steps to Reproduce ```bash ls src/cleveragents/acms/ ls src/cleveragents/domain/models/acms/ grep -rn "from cleveragents.acms import" src/cleveragents/ --include="*.py" ``` ### Impact - Confusing module structure — developers must look in two places for ACMS-related code - The top-level `acms/` module sits outside the clean architecture layers, making it unclear which layer it belongs to - Violates the principle of having a single, clear location for domain vocabulary data ### Suggested Fix Move `src/cleveragents/acms/uko/` to `src/cleveragents/domain/models/acms/uko/` and update the single import in `acms_skeleton_compressor.py` accordingly. This consolidates all ACMS-related domain data in the domain layer. ### Code Location `src/cleveragents/acms/` (top-level module) `src/cleveragents/domain/models/acms/` (domain layer module) --- ## Subtasks - [ ] Move `src/cleveragents/acms/uko/` to `src/cleveragents/domain/models/acms/uko/` - [ ] Update `__init__.py` exports in `domain/models/acms/` to expose the relocated UKO symbols - [ ] Update the single import in `application/services/acms_skeleton_compressor.py` from `cleveragents.acms` to `cleveragents.domain.models.acms` - [ ] Remove the now-empty top-level `src/cleveragents/acms/` module and its `__init__.py` - [ ] Search for any other references to `cleveragents.acms` across the codebase and update them - [ ] Tests (Behave): Verify all existing ACMS unit test scenarios still pass after the move - [ ] Tests (Robot): Verify integration tests referencing ACMS context pipeline still pass - [ ] Verify coverage >= 97% via `nox -s coverage_report` - [ ] Run `nox` (all default sessions), fix any errors ## Definition of Done This issue is complete when: - All subtasks above are completed and checked off. - The top-level `src/cleveragents/acms/` module no longer exists; all UKO vocabulary data lives under `src/cleveragents/domain/models/acms/uko/`. - A Git commit is created where the **first line** of the commit message matches the Commit Message in Metadata exactly, followed by a blank line, then additional lines providing relevant details about the implementation. - The commit is pushed to the remote on the branch matching the **Branch** in Metadata exactly. - The commit is submitted as a **pull request** to `master`, reviewed, and **merged** before this issue is marked done. - All nox stages pass. - Coverage >= 97%. --- > **Backlog note:** This issue was discovered during autonomous operation > on milestone v3.4.0. It does not block milestone completion and has been > placed in the backlog for human review and future milestone assignment. --- **Automated by CleverAgents Bot** Supervisor: UAT Testing | Agent: ca-new-issue-creator
freemo added this to the v3.4.0 milestone 2026-04-06 18:07:13 +00:00
freemo removed this from the v3.4.0 milestone 2026-04-06 20:41:34 +00:00
HAL9000 added this to the v3.5.0 milestone 2026-04-09 03:10:39 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Blocks
#396 Epic: ACMS Context Pipeline
cleveragents/cleveragents-core
Reference
cleveragents/cleveragents-core#4139
No description provided.