refactor(ai_client,gui_2): merge vendor_state split: VendorMetric -> ai_client, get_vendor_state (renamed _get_vendor_state_metrics) -> gui_2; git rm src/vendor_state.py

Per spec FR2 + Phase 2.2 + architecture feedback (data != view):
  - VendorMetric (data) -> src/ai_client.py (alongside VendorCapabilities; all vendor data)
  - get_vendor_state -> renamed to _get_vendor_state_metrics in src/gui_2.py
    (it's a view-helper that builds the metrics for render_vendor_state's table)
  - render_vendor_state in gui_2.py now calls _get_vendor_state_metrics directly

Tests:
- tests/test_vendor_state.py: imports get_vendor_state from src.gui_2, VendorMetric from src.ai_client
This commit is contained in:
ed
2026-06-26 07:10:06 -04:00
parent 81d8bce419
commit d9cd7c557b
4 changed files with 81 additions and 84 deletions
+10
View File
@@ -3537,3 +3537,13 @@ register(VendorCapabilities(vendor='deepseek', model='deepseek-v3', conte
register(VendorCapabilities(vendor='deepseek', model='deepseek-reasoner', context_window=32768, cost_input_per_mtok=0.55, cost_output_per_mtok=2.19, reasoning=True, structured_output=True))
register(VendorCapabilities(vendor='deepseek', model='deepseek-r1', context_window=32768, cost_input_per_mtok=0.55, cost_output_per_mtok=2.19, reasoning=True, structured_output=True))
#endregion: Vendor Capabilities
#region: Vendor State (moved from src/vendor_state.py)
@dataclass(frozen=True)
class VendorMetric:
key: str
label: str
value: str
state: str
tooltip: str
#endregion: Vendor State