Skip to content

Data Exploration — Dataset Discovery and Structure Inspection

This page is mainly for Skill authors, delivery teams, and Agent maintainers. Business users usually don't need to look up dataset codes themselves — the Agent does this "scouting" step first.


What this step is for

When an Agent receives a business question, it typically needs to answer three things first:

  1. Which business objects actually exist in this system?
  2. Which dataset does the object I need correspond to?
  3. Which fields does that dataset have, and which of them can be used for filtering?

dataset list and dataset detail exist for exactly this.


When you need it

  • First time taking over a business system
  • You don't know which table holds objects like "customers", "orders", or "tickets"
  • You need to confirm field names so the keys in --params are correct
  • You want the Agent to understand the data structure before querying or writing

If you already know the dataset code, skip this step and go straight to data filter, data getOne, data aggregate, or the write commands.


Prerequisites

Before using dataset discovery commands, two things must be in place:

  • You are logged in with an AccessKey
  • The current app is resolved (for example, via app use or --appcode)

In other words, the runtime CLI runs in AccessKey mode — not the old cookie mode.


Listing datasets

Bash
# 列出当前应用下的全部数据集
lovrabet dataset list

# 按名称模糊搜索
lovrabet dataset list --name order

# 按 code 精确过滤
lovrabet dataset list --code a1b2c3d4e5f6a7b8c9d0e1f2a3b4c5d6

Think of this as "see which business objects exist in this system". A common pattern is to start from a business keyword, for example:

Bash
lovrabet dataset list --name 客户
lovrabet dataset list --name 订单
lovrabet dataset list --name 工单

Inspecting dataset details

Bash
lovrabet dataset detail --code a1b2c3d4e5f6a7b8c9d0e1f2a3b4c5d6

In the output, the parts worth focusing on are:

  • name: the dataset name
  • code: the code the data commands will use
  • table: the underlying table name
  • fields: the field list
  • operations: which standard operations are supported

For an Agent, fields is the critical part — field names must be exact when assembling --params later.


How this chains into the next steps

The most common flow:

  1. Use dataset list to find the likely business object
  2. Use dataset detail to inspect the field structure
  3. Move on to data filter / data aggregate / data create / data update

For example:

  • The business question is "find unshipped orders"
  • The Agent first discovers the order dataset
  • Then confirms whether fields like payStatus, deliveryStatus, and warehouseName exist
  • Finally runs the filtering and aggregation

About dataset codes

A dataset code is a 32-character hex string. The safest approach is always:

  1. Find it in the dataset list output
  2. Copy it into the follow-up command

Never type it by hand, never guess.


Advice for business users

Business users don't need to say "look up the dataset code for me". More natural phrasing:

  • Show me where the customer data lives
  • Check whether orders have a warehouse field
  • Help me get a picture of what ticket objects look like in this system

Hand these to the Agent, and under the hood it will almost always run dataset list / dataset detail first.

基于飞书知识库同步生成,内容以飞书源文档为准