pan3793 commented on code in PR #7431:
URL: https://github.com/apache/kyuubi/pull/7431#discussion_r3298383922


##########
docs/quick_start/quick_start_with_data_agent.md:
##########
@@ -0,0 +1,211 @@
+<!--
+- Licensed to the Apache Software Foundation (ASF) under one or more
+- contributor license agreements.  See the NOTICE file distributed with
+- this work for additional information regarding copyright ownership.
+- The ASF licenses this file to You under the Apache License, Version 2.0
+- (the "License"); you may not use this file except in compliance with
+- the License.  You may obtain a copy of the License at
+-
+-   http://www.apache.org/licenses/LICENSE-2.0
+-
+- Unless required by applicable law or agreed to in writing, software
+- distributed under the License is distributed on an "AS IS" BASIS,
+- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+- See the License for the specific language governing permissions and
+- limitations under the License.
+-->
+
+# Data Agent Engine
+
+The Data Agent engine lets users explore and query data with natural language. 
It is a Kyuubi engine type (`DATA_AGENT`) that runs an LLM-driven 
[ReAct](https://arxiv.org/abs/2210.03629) agent. The agent reasons about the 
user's request, calls a small set of SQL tools against a JDBC-accessible 
backend (Spark, Trino, MySQL, SQLite, ...), and streams its responses to the 
bundled web UI.
+
+This page covers how to configure the engine, how the web UI behaves at 
runtime, the approval / risk model that gates SQL tool execution, and a few 
deployment notes worth knowing.
+
+## At a glance
+
+- **Engine type**: `DATA_AGENT`, share level follows 
`kyuubi.engine.share.level` like every other engine
+- **LLM provider**: any OpenAI-compatible chat-completion endpoint (OpenAI, 
Azure OpenAI, vLLM, llama.cpp, or any other provider that exposes the OpenAI 
chat-completion API)
+- **Datasource**: any JDBC URL the engine can reach. When unset, defaults to 
ZooKeeper service discovery for ZK-HA deployments, or 
`jdbc:hive2://localhost:<thrift-port>/default` otherwise
+- **Tools** (built in): `run_select_query` (low-risk, read-only) and 
`run_mutation_query` (high-risk, mutating). Per-dialect prompt templates ship 
for Spark / Trino / MySQL / SQLite / Generic
+- **Interface**: the bundled Kyuubi web UI. Pick **Data Agent** from the left 
navigation after logging in
+
+## Quick start
+
+### 1. Configure the LLM provider
+
+Add the following to `$KYUUBI_HOME/conf/kyuubi-defaults.conf`:
+
+```
+kyuubi.engine.data.agent.provider OPENAI_COMPATIBLE
+
+# OpenAI-compatible endpoint and credentials
+kyuubi.engine.data.agent.openai.endpoint https://api.openai.com/v1
+kyuubi.engine.data.agent.openai.api.key   sk-xxxxxxxxxxxxxxxxxxxxxxxx
+kyuubi.engine.data.agent.model            gpt-4o-mini
+```
+
+Substitute the endpoint, API key, and model ID for whichever OpenAI-compatible 
provider you use.
+
+### 2. Restart Kyuubi and open the UI
+
+```
+$KYUUBI_HOME/bin/kyuubi restart
+```
+
+Open `http://<kyuubi-host>:10099/ui` in a browser (the port comes from 
`kyuubi.frontend.rest.bind.port`, default `10099`). Pick **Data Agent** in the 
left navigation.
+
+### 3. Ask a question

Review Comment:
   is there a known dataset and question set that can be used for a demo? for 
example, kyuubi provides Spark TPC-H connector, which could provide the TPC-H 
dataset on the fly, is it suitable for the demo purpose?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to