atlasbot: answer hardware mix queries

This commit is contained in:
Brad Stein 2026-01-27 19:06:44 -03:00
parent ea8eda2c73
commit 9bf822ec36
2 changed files with 6 additions and 1 deletions

View File

@ -16,7 +16,7 @@ spec:
labels:
app: atlasbot
annotations:
checksum/atlasbot-configmap: manual-atlasbot-63
checksum/atlasbot-configmap: manual-atlasbot-64
vault.hashicorp.com/agent-inject: "true"
vault.hashicorp.com/role: "comms"
vault.hashicorp.com/agent-inject-secret-turn-secret: "kv/data/atlas/comms/turn-shared-secret"

View File

@ -1292,6 +1292,11 @@ def structured_answer(
if not op and entity == "node":
op = "list" if (include_hw or exclude_hw or nodes_in_query) else "count"
if entity == "node" and ("hardware mix" in q or "architecture" in q):
hw_line = _hardware_mix_line(inventory)
if hw_line:
return _format_confidence(hw_line, "high")
if op == "top" and metric is None:
metric = "cpu"