Skip to content

CLI-006: CLI/Core Separation for Reuse

This Reference preserves the recorded requirement contract. The front matter states its lifecycle status; this editorial notice does not change that status. An ACTIVE contract is not a historical implementation or qualification result. The statement, rationale, identifiers, and traceability below keep their recorded meaning. The original file is available at source revision 6d35d245f11a.

Statement

The CLI shall separate thin CLI layer (src/aptl/cli/) from domain logic (src/aptl/core/). Core modules shall have no dependency on Typer, Rich, or terminal I/O, enabling reuse by the web UI backend and direct scripting.

Rationale

The future FastAPI web backend needs to import the same logic without CLI framework dependencies.

Traceability

  • CONSTRAINS → ADR docs/adrs/adr-007-python-cli-control-plane.md (ADR-007: Python CLI Control Plane)