-
Notifications
You must be signed in to change notification settings - Fork 0
Custom Skills and Tools
GIS Data Agent v14.5 — 基于 Google ADK 的 AI 地理空间平台 仓库:https://github.com/zhouning/gisdataagent
自定义技能让您无需编写代码即可为 AI 代理添加新的行为和专业知识。每个自定义技能在运行时会动态构建一个 ADK LlmAgent 实例。
- 打开右侧数据面板 → Capabilities(能力) 标签页
- 点击 "+Skill" 按钮
- 填写技能定义:
| 字段 | 说明 | 示例 |
|---|---|---|
| 名称 | 技能唯一标识 | wetland-assessment |
| 指令 (Instruction) | 技能的提示词/行为定义 | 你是一个湿地评估专家,擅长... |
| 工具集选择 | 技能可用的工具集 |
ExplorationToolset, AnalysisToolset
|
| 触发关键词 | 自动触发技能的关键词 |
湿地, wetland, 生态
|
| 模型层级 | 使用的 LLM 层级 |
flash(快速)或 pro(高质量) |
当用户消息包含触发关键词时,系统从数据库加载技能定义,动态构建 LlmAgent,并使用指定的工具集和指令执行任务。
- 版本控制:每次修改自动保存版本,可回滚到历史版本
- 评分系统:用户可对技能评分,高分技能获得更高推荐优先级
- 克隆:一键复制现有技能作为新技能的起点
- 审批流程:共享技能需通过管理员审批
- 用户隔离:每个用户的技能独立,可选择共享给团队
用户自定义工具允许通过声明式 JSON 定义创建新工具,无需编写 Python 代码。工具在运行时被包装为 ADK FunctionTool。
调用外部 REST API:
{
"type": "http_call",
"method": "GET",
"url": "https://api.example.com/data/{city}",
"headers": {"Authorization": "Bearer {{API_KEY}}"},
"params": {"format": "geojson"}
}执行预定义的数据库查询:
{
"type": "sql_query",
"query": "SELECT * FROM land_parcels WHERE area_ha > {min_area}",
"connection": "default"
}对上传文件执行预定义的转换操作:
{
"type": "file_transform",
"operation": "reproject",
"target_crs": "EPSG:4326"
}将多个工具串联执行:
{
"type": "chain",
"steps": [
{"tool": "my_http_tool", "params": {"city": "{input}"}},
{"tool": "my_transform_tool", "params": {"data": "{prev_result}"}}
]
}- 数据面板 → Capabilities 标签页 → 点击 "+Tool"
- 选择模板类型,填写 JSON 定义
- 保存后,工具立即可用于所有代理
可视化 DAG(有向无环图)编辑器,基于 ReactFlow 构建,支持将多个管道和自定义技能组合为复杂工作流。
| 节点类型 | 说明 |
|---|---|
| DataInput | 数据输入节点——指定输入文件或数据源 |
| Pipeline | 管道节点——内置的三大管道 (Optimization/Governance/General) |
| Skill Agent | 技能代理节点——引用自定义技能 |
| Output | 输出节点——保存或展示结果 |
- 顺序执行:节点按连接顺序依次运行
- 并行分支:DAG 拓扑排序支持同层级节点并行执行
- Cron 调度:设置定时触发(如每天凌晨2点执行数据治理)
- Webhook 触发:通过 HTTP Webhook 外部触发工作流
- 节点重试:每个节点可单独配置重试次数和间隔
- 数据面板 → Workflows(工作流) 标签页
- 拖拽添加节点,拉线连接
- 配置每个节点参数
- 保存 → 手动运行或设置触发器
预配置的工具集+技能组合,提供开箱即用的专业能力:
- 一键安装完整的领域解决方案
- 包含配套的工具集选择和技能指令
- 通过 Capabilities 标签页的 Bundles 区域管理
GIS Data Agent v14.5 — AI geospatial platform on Google ADK Repository: https://github.com/zhouning/gisdataagent
Custom Skills let you add new behaviors and domain expertise to AI agents without writing code. Each custom skill dynamically builds an ADK LlmAgent instance at runtime.
- Open the right-side Data Panel → Capabilities tab
- Click the "+Skill" button
- Fill in the skill definition:
| Field | Description | Example |
|---|---|---|
| Name | Unique skill identifier | wetland-assessment |
| Instruction | Prompt / behavior definition | You are a wetland assessment expert who... |
| Toolset selection | Available toolsets for the skill |
ExplorationToolset, AnalysisToolset
|
| Trigger keywords | Keywords that auto-trigger the skill |
wetland, ecology, habitat
|
| Model tier | LLM tier to use |
flash (fast) or pro (high quality) |
When a user message contains trigger keywords, the system loads the skill definition from the database, dynamically builds an LlmAgent, and executes the task using the specified toolsets and instructions.
- Versioning: Every edit auto-saves a version; rollback to any historical version
- Rating system: Users can rate skills; higher-rated skills get higher recommendation priority
- Cloning: One-click copy of existing skills as a starting point for new ones
- Approval workflow: Shared skills require admin approval
- User isolation: Each user's skills are independent, with optional team sharing
User-Defined Tools allow you to create new tools via declarative JSON definitions without writing Python code. Tools are wrapped as ADK FunctionTool instances at runtime.
Call an external REST API:
{
"type": "http_call",
"method": "GET",
"url": "https://api.example.com/data/{city}",
"headers": {"Authorization": "Bearer {{API_KEY}}"},
"params": {"format": "geojson"}
}Execute a predefined database query:
{
"type": "sql_query",
"query": "SELECT * FROM land_parcels WHERE area_ha > {min_area}",
"connection": "default"
}Perform predefined transformations on uploaded files:
{
"type": "file_transform",
"operation": "reproject",
"target_crs": "EPSG:4326"
}Chain multiple tools together:
{
"type": "chain",
"steps": [
{"tool": "my_http_tool", "params": {"city": "{input}"}},
{"tool": "my_transform_tool", "params": {"data": "{prev_result}"}}
]
}- Data Panel → Capabilities tab → click "+Tool"
- Choose template type, fill in the JSON definition
- Once saved, the tool is immediately available to all agents
A visual DAG (Directed Acyclic Graph) editor built on ReactFlow. Compose multiple pipelines and custom skills into complex workflows.
| Node Type | Description |
|---|---|
| DataInput | Data input node — specify input files or data sources |
| Pipeline | Pipeline node — the three built-in pipelines (Optimization/Governance/General) |
| Skill Agent | Skill agent node — reference a custom skill |
| Output | Output node — save or display results |
- Sequential: Nodes run in connection order
- Parallel branches: DAG topological sort enables same-level nodes to run in parallel
- Cron scheduling: Set timed triggers (e.g., run governance audit daily at 2 AM)
- Webhook triggers: Trigger workflows externally via HTTP webhook
- Node retry: Each node can individually configure retry count and interval
- Data Panel → Workflows tab
- Drag to add nodes, draw connections
- Configure each node's parameters
- Save → run manually or set up triggers
Pre-configured toolset + skill combinations providing ready-to-use domain capabilities:
- One-click install of complete domain solutions
- Includes paired toolset selections and skill instructions
- Managed through the Bundles section in the Capabilities tab
GIS Data Agent v14.5 · Built on Google ADK · GitHub · Report Issue
快速开始 Getting Started
核心概念 Core Concepts
使用指南 User Guide
架构与运维 Architecture & Ops
参考 Reference