3.5 KiB
3.5 KiB
MODIFIED Requirements
Requirement: Cloud Console displays a task's full LLM interaction history
Cloud Console SHALL provide a view, for a given task, listing each persisted planner decision in step order, including its full prompt, resulting decision, and — when available — the AI's rationale (pre-tool text reflection), thinking (extended thinking block), action purpose, and expected outcome, sourced from the Cloud Control Plane's persisted planner-decision log.
Scenario: Task has persisted planner decisions with rationale
- WHEN an operator opens the LLM interaction history view for a task that has one or more persisted planner decisions with non-null rationale
- THEN Cloud Console shows each decision in step order with its prompt, resulting tool call, and rationale text
Scenario: Task has persisted planner decisions with thinking
- WHEN an operator opens the LLM interaction history view for a task whose planner decisions include a non-null thinking field
- THEN Cloud Console shows the thinking content alongside the prompt and tool call for that step
Scenario: Task has persisted planner decisions without rationale or thinking
- WHEN an operator opens the LLM interaction history view for a task whose decisions have null rationale and null thinking
- THEN Cloud Console shows each decision without those fields, without error or placeholder text
Scenario: Task's Host used direct-to-provider transport
- WHEN an operator opens the LLM interaction history view for a task whose Host used direct-to-provider transport
- THEN Cloud Console indicates that no LLM interaction history is available because the Host does not report it, rather than showing an empty history with no explanation
Requirement: Cloud Control Plane persists rationale and thinking in the planner decision log
The Cloud Control Plane's planner-decision log SHALL store the AI's rationale, thinking, action purpose, and expected outcome fields alongside the existing prompt and tool-call fields for each persisted decision. These fields SHALL be nullable for backward compatibility; absence of a legacy or non-AI value SHALL NOT prevent a decision record from being stored or queried.
Scenario: Decision record includes rationale
- WHEN the Host Agent reports a planner decision with a non-null rationale
- THEN the persisted
planner_decision_logrow stores that rationale text in therationalecolumn
Scenario: Decision record includes thinking
- WHEN the Host Agent reports a planner decision with a non-null thinking block
- THEN the persisted
planner_decision_logrow stores that thinking text in thethinkingcolumn
Scenario: Decision record has no rationale or thinking
- WHEN the Host Agent reports a planner decision with null rationale and null thinking (e.g., cloud-proxy transport where these are not surfaced)
- THEN the persisted row stores NULL for both columns without error
Scenario: Decision record includes reusable action metadata
- WHEN the Host reports a device-action planner decision with a purpose and expected outcome
- THEN the persisted row stores both values separately from the executable tool arguments and the task API returns them to authorized readers
Scenario: Existing decision records without rationale or thinking remain readable
- WHEN the system queries a
planner_decision_logrow created before this migration - THEN both
rationaleandthinkingread as NULL, and the row is returned normally