Tag genie ask requests with databricks_cli source and disable viz#5988
Tag genie ask requests with databricks_cli source and disable viz#5988yansonggao-db wants to merge 1 commit into
Conversation
|
@lennartkats-db this is the CLI side of the Genie-One-in-CLI work — |
ab82edf to
f64d9e2
Compare
`databricks experimental genie ask` now sends a `source: "databricks_cli"` field on the OneChat /responses request so the backend can attribute CLI traffic distinctly (vs webapp/Slack/MCP), and sends `enable_viz: false` because the CLI renders in a terminal that cannot display charts. - GenieRequest gains Source (string) and EnableViz (*bool, so false serializes past omitempty) fields. - BuildRequest sets both unconditionally; neither is user-configurable. - Updates the wire-format test and adds a test pinning both fields.
f64d9e2 to
72a1f44
Compare
|
An authorized user can trigger integration tests manually by following the instructions below: Trigger: Inputs:
Checks will be approved automatically on success. |
Changes
databricks experimental genie asknow sets two fields on the OneChat/responsesrequest it already sends:source: "databricks_cli"— so the backend attributes CLI-originated Genie traffic distinctly from webapp/Slack/MCP.enable_viz: false— the CLI renders in a terminal that can't display charts, so it tells the agent to skip visualization tools.Neither is user-configurable;
BuildRequestsets both unconditionally.EnableVizis a*boolsofalseserializes pastomitempty(a plainfalsewould be dropped, letting the backend default viz on).Why
Backend traffic attribution: OneChat buckets conversations by
source, and CLI traffic currently arrives untagged (bucketed as UNSPECIFIED). The matching backend enum + parsing already landed in the Databricks monorepo. Disabling viz avoids the agent emitting chart/plot items the terminal can't render.Tests
go test ./experimental/genie/...passes. UpdatedTestBuildRequest_WireFormatto pin the new fields and addedTestBuildRequest_TagsSourceAndDisablesVizassertingsourceandenable_viz:falseare always on the wire.