atlasbot: favor factual fallback in fast mode
This commit is contained in:
parent
dda943ce16
commit
436e56c5de
@ -16,7 +16,7 @@ spec:
|
|||||||
labels:
|
labels:
|
||||||
app: atlasbot
|
app: atlasbot
|
||||||
annotations:
|
annotations:
|
||||||
checksum/atlasbot-configmap: manual-atlasbot-97
|
checksum/atlasbot-configmap: manual-atlasbot-98
|
||||||
vault.hashicorp.com/agent-inject: "true"
|
vault.hashicorp.com/agent-inject: "true"
|
||||||
vault.hashicorp.com/role: "comms"
|
vault.hashicorp.com/role: "comms"
|
||||||
vault.hashicorp.com/agent-inject-secret-turn-secret: "kv/data/atlas/comms/turn-shared-secret"
|
vault.hashicorp.com/agent-inject-secret-turn-secret: "kv/data/atlas/comms/turn-shared-secret"
|
||||||
|
|||||||
@ -2948,6 +2948,7 @@ def _open_ended_system() -> str:
|
|||||||
"Do not mention fact IDs or internal labels (e.g., F1/F2) in your response. "
|
"Do not mention fact IDs or internal labels (e.g., F1/F2) in your response. "
|
||||||
"When the fact pack includes hottest_cpu/ram/net/io lines, use them to answer hottest/busiest node questions. "
|
"When the fact pack includes hottest_cpu/ram/net/io lines, use them to answer hottest/busiest node questions. "
|
||||||
"When the fact pack includes postgres_hottest_db, use it for questions about the busiest database. "
|
"When the fact pack includes postgres_hottest_db, use it for questions about the busiest database. "
|
||||||
|
"Do not convert counts into percentages or claim 100% unless a fact explicitly states a percentage. "
|
||||||
"Do not invent numbers or facts. "
|
"Do not invent numbers or facts. "
|
||||||
"End with lines: Confidence, Relevance (0-100), Satisfaction (0-100), HallucinationRisk (low|medium|high)."
|
"End with lines: Confidence, Relevance (0-100), Satisfaction (0-100), HallucinationRisk (low|medium|high)."
|
||||||
)
|
)
|
||||||
@ -4007,6 +4008,10 @@ def _open_ended_fast(
|
|||||||
selected_pack = _fact_pack_text(selected_lines, selected_meta)
|
selected_pack = _fact_pack_text(selected_lines, selected_meta)
|
||||||
if _needs_full_fact_pack(prompt) or not selected_lines:
|
if _needs_full_fact_pack(prompt) or not selected_lines:
|
||||||
selected_pack = fact_pack
|
selected_pack = fact_pack
|
||||||
|
if not subjective and _needs_full_fact_pack(prompt):
|
||||||
|
fallback = _fallback_fact_answer(prompt, fact_pack)
|
||||||
|
if fallback:
|
||||||
|
return _ensure_scores(fallback)
|
||||||
if state:
|
if state:
|
||||||
state.total_steps = _open_ended_total_steps("fast")
|
state.total_steps = _open_ended_total_steps("fast")
|
||||||
return _open_ended_fast_single(
|
return _open_ended_fast_single(
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user