Split aman.py into focused CLI and runtime modules
Break the old god module into flat siblings for CLI parsing, run lifecycle, daemon state, shared processing helpers, benchmark tooling, and maintainer-only model sync so changes stop sharing one giant import graph. Keep aman as a thin shim over aman_cli, move sync-default-model behind the hidden aman-maint entrypoint plus Make wrappers, and update packaging metadata plus maintainer docs to reflect the new surface. Retarget the tests to the new seams with dedicated runtime, run, benchmark, maintainer, and entrypoint suites, and verify with python3 -m unittest discover -s tests -p "test_*.py", python3 -m py_compile src/*.py tests/*.py, PYTHONPATH=src python3 -m aman --help, PYTHONPATH=src python3 -m aman version, and PYTHONPATH=src python3 -m aman_maint --help.
This commit is contained in:
parent
721248ca26
commit
4d0081d1d0
18 changed files with 2838 additions and 2427 deletions
11
AGENTS.md
11
AGENTS.md
|
|
@ -2,9 +2,14 @@
|
|||
|
||||
## Project Structure & Module Organization
|
||||
|
||||
- `src/aman.py` is the primary entrypoint (X11 STT daemon).
|
||||
- `src/aman.py` is the thin console/module entrypoint shim.
|
||||
- `src/aman_cli.py` owns the main end-user CLI parser and dispatch.
|
||||
- `src/aman_run.py` owns foreground runtime startup, tray wiring, and settings flow.
|
||||
- `src/aman_runtime.py` owns the daemon lifecycle and runtime state machine.
|
||||
- `src/aman_benchmarks.py` owns `bench`, `eval-models`, and heuristic dataset tooling.
|
||||
- `src/aman_model_sync.py` and `src/aman_maint.py` own maintainer-only model promotion flows.
|
||||
- `src/recorder.py` handles audio capture using PortAudio via `sounddevice`.
|
||||
- `src/aman.py` owns Whisper setup and transcription.
|
||||
- `src/aman_processing.py` owns shared Whisper/editor pipeline helpers.
|
||||
- `src/aiprocess.py` runs the in-process Llama-3.2-3B cleanup.
|
||||
- `src/desktop_x11.py` encapsulates X11 hotkeys, tray, and injection.
|
||||
- `src/desktop_wayland.py` scaffolds Wayland support (exits with a message).
|
||||
|
|
@ -13,7 +18,7 @@
|
|||
|
||||
- Install deps (X11): `uv sync`.
|
||||
- Install deps (Wayland scaffold): `uv sync --extra wayland`.
|
||||
- Run daemon: `uv run python3 src/aman.py --config ~/.config/aman/config.json`.
|
||||
- Run daemon: `uv run aman run --config ~/.config/aman/config.json`.
|
||||
|
||||
System packages (example names):
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue