Install
openclaw skills install @sdk-team/alibabacloud-agentloop-datasetOperate Alibaba Cloud AgentLoop Dataset resources with aliyun CLI and the AgentLoop API version 2026-05-20. Use when requests concern AgentLoop datasets, data rows, Dataset schemas, embedding fields, semantic search, ExecuteQuery, AgentSpace data, 数据集, 数据写入, 数据查询, 语义检索, or ask to create/list/get/update AgentLoop datasets, append structured rows, run read-only SQL or SearchExpr queries, inspect query results, or debug aliyun agentloop Dataset commands.
openclaw skills install @sdk-team/alibabacloud-agentloop-datasetOperate the public AgentLoop Dataset surface through aliyun agentloop:
execute-query.Do not expose or operate service deployment, database, cache, or other internal implementation details. Do not manage AgentSpaces unless the user separately requests that scope.
Treat commands and parameters exposed by the installed public AgentLoop CLI plugin as the external capability boundary. Do not expose a capability found only in backend development code until it appears in the published CLI help or public API contract.
Require Aliyun CLI 3.3.3 or later.
aliyun version
Require the AgentLoop plugin 0.7.1 or later. This version exposes all Dataset commands used by this skill, including add-dataset-data and the extended execute-query parameters.
aliyun plugin show --name agentloop
If the AgentLoop plugin is missing or older than 0.7.1, install it through the configured Aliyun CLI plugin source, then verify it before continuing:
aliyun plugin install --names agentloop
aliyun plugin show --name agentloop
Use the plugin ID agentloop for installation; successful output identifies the installed package as aliyun-cli-agentloop. If the Aliyun CLI itself is missing or below 3.3.3, stop and ask the user to upgrade the CLI through their organization-approved process outside this session. Do not download or install CLI binaries from this Skill.
Use an existing Aliyun CLI profile, Alibaba Cloud environment credentials, STS, OAuth, or an instance RAM role.
Security rules:
aliyun configure set with literal credential values.aliyun configure list to check whether a usable identity and region are configured.aliyun configure list
If no valid identity is available, stop and ask the user to configure credentials outside this session. Do not continue to a Dataset request.
Dataset operations use the six concrete RAM actions listed in references/ram-policies.md and support Dataset resource ARNs. Do not use a wildcard action pattern in a policy.
On any permission failure:
references/ram-policies.md.ram-permission-diagnose is installed, invoke it. Otherwise show the missing action and the least-privilege policy template.Confirm user-customizable values before executing a cloud request. Reuse explicit values already supplied by the user; do not ask again.
| Parameter | Required for | Rule |
|---|---|---|
--region | All operations when the configured region is not explicitly accepted | Dataset and AgentSpace must be in this region. |
--agent-space | All commands | Confirm the exact AgentSpace name. |
--dataset-name | All Dataset commands in this skill | Use 4-63 ASCII characters matching ^[a-z][a-z0-9]*(?:_[a-z0-9]+)*$; do not use uppercase letters, hyphens, spaces, or leading, trailing, or consecutive underscores. |
--description | Optional create/update description | Keep the UTF-8 encoded value at 255 bytes or fewer. |
--schema | Create; optional update | Confirm field names, types, Chinese tokenization, JSON keys, and embedding use. The only supported public embedding model value is agentloop-embedding-v4. |
--data-array | Structured writes | Confirm the rows or the source from which they are constructed. |
--query | execute-query | This Skill permits only read-only SELECT or SearchExpr query text. The public API accepts one raw query string and exposes no bind-parameter option; the default query-text cap is 10 MiB. |
--from, --to | Optional SELECT time window | Use non-negative Unix seconds over __time__; to is exclusive and, when both are non-zero, from must be less than to. |
--offset, --length | Optional SELECT result window | Use non-negative integers only for SELECT; length cannot exceed the configured SELECT maximum, which defaults to 100,000. |
--max-output-length | Optional SELECT truncation | 0 or omitted returns full values. |
--biz-version | Optional SELECT against an existing snapshot | This CLI flag serializes to the request-body field version; confirm the exact version and omit it for current data. |
--client-token | Optional create/update/write idempotency | Generate one non-secret UUID and reuse it for retries of the same logical request. |
Generate one session ID before the first AgentLoop API request in a skill session. Generate it once, require exactly 32 lowercase hexadecimal characters, and reuse it for the entire session:
SESSION_ID="$(openssl rand -hex 16)"
USER_AGENT="AlibabaCloud-Agent-Skills/alibabacloud-agentloop-dataset/${SESSION_ID}"
The canonical CLI template is:
--user-agent "AlibabaCloud-Agent-Skills/alibabacloud-agentloop-dataset/{session-id}"
Observability rules:
--user-agent "${USER_AGENT}" to every aliyun agentloop invocation, including dry runs, retries, mutations, and verification calls. Command examples omit this repeated global flag for readability; add it before execution.Execute the workflow:
references/dataset-management.mdreferences/data-operations.mdreferences/query-syntax.md--cli-dry-run first and inspect the serialized URL, query parameters, and body.references/verification-method.md.text, long, double, and json field types.chn for text tokenization. It has no useful effect on non-text fields.embedding only on text or json fields. When present, its value must be exactly agentloop-embedding-v4; do not use an internal backend model name or invent another alias.jsonKeys only under a top-level json field. Each indexed child uses type and optional chn; do not add child embedding or another jsonKeys level unless current CLI help explicitly exposes those fields.lower_snake_case to simplify SQL and case-insensitive structured writes.id, __time__, __dataset_seq, __effective_seq, or __expired_seq.Prefer add-dataset-data for row appends. It avoids SQL quoting errors and validates values against the Dataset schema.
dataArray must be non-empty and every entry must be an object.null.text values must be strings, long values integers, double values finite numbers, and json values valid JSON.id to generate one. If supplied, it must be a UUID string.__time__ to use the current time. If supplied, it must be a non-null, non-negative Unix timestamp in seconds.__dataset_seq.add-dataset-data.--type SQL; it is the only supported statement type.execute-query only for read-only SELECT or SearchExpr queries. Never send INSERT, UPDATE, DELETE, DDL, or multiple statements through this command.execute-query contract carries raw query text and has no bind-parameter field. Do not compose SQL from untrusted text; use add-dataset-data for user-provided values whenever it can express the write.agentloop:ExecuteQuery RAM action is not statement-level read-only. This Skill's SELECT-only boundary is an instruction, not a service-side control.execute-query body within the default 100 MiB cap and the query text within the default 10 MiB cap.LIMIT and --length.columns with each rows entry by position; the response is row-based, not an array of objects.semantic_distance(field, 'query', 'l2') with an explicit distance type. The field must have embedding enabled.similarity() thresholds in [0, 1] and topk() values as integers from 1 through 100,000.add-dataset-data for writes.All public Dataset CLI commands, parameters, and help checks are in references/related-commands.md.
| Wrong | Right | Reason |
|---|---|---|
aliyun cms ... dataset ... | aliyun agentloop ... | This skill uses the AgentLoop 2026-05-20 public API. |
--type sql without checking | --type SQL | The service currently requires SQL. |
| Create with an empty schema | Supply at least one typed field | Empty schemas are rejected. |
| Update an existing field type | Add a new top-level field or update description | Schema evolution is add-only. |
Put JSON in a text field | Declare/use a json field | Structured writes validate field types. |
Expect response.data | Zip columns with each entry in rows | Query responses are row-based. |
Use execute-query for a data mutation | Use add-dataset-data for row appends | This Skill permits execute-query only for read-only queries. |
semantic_distance(field, 'q') | semantic_distance(field, 'q', 'l2') | Current Dataset execution requires an explicit distance type. |
--version v1 | --biz-version v1 | Global --version selects the OpenAPI version; the Dataset snapshot selector is --biz-version. |
| Reuse a new client token on retry | Reuse the original token for the same logical request | Idempotency depends on a stable token. |
| File | Use |
|---|---|
references/dataset-management.md | Create, list, get, update, and schema construction. |
references/data-operations.md | Structured row append and typed values. |
references/query-syntax.md | Read-only SQL, SearchExpr, semantic retrieval, windows, and response shape. |
references/related-commands.md | Supported command and parameter inventory. |
references/verification-method.md | Dry-run and post-operation verification. |
references/ram-policies.md | RAM actions, resource ARN, and policy examples. |