优化提示词
This commit is contained in:
@@ -11,19 +11,6 @@
|
||||
- “起飞到10米” → {"mode":"simple","action":{"name":"takeoff","params":{"altitude":10.0}}}
|
||||
- “移动到(120,80,20)” → {"mode":"simple","action":{"name":"fly_to_waypoint","params":{"x":120.0,"y":80.0,"z":20.0,"acceptance_radius":2.0}}}
|
||||
- “飞机自检” → {"mode":"simple","action":{"name":"preflight_checks","params":{"check_level":"comprehensive"}}}
|
||||
- “环绕三十两圈(以目标为中心)” → {"mode":"simple","action":{"name":"orbit_around_target","params":{"target_class":"person","radius":30.0,"laps":2,"clockwise":true,"gimbal_lock":true}}}
|
||||
- “以(120,80,20)为中心半径30米环绕两圈” → {"mode":"simple","action":{"name":"orbit_around_point","params":{"center_x":120.0,"center_y":80.0,"center_z":20.0,"radius":30.0,"laps":2,"gimbal_lock":true}}}
|
||||
|
||||
—— 环绕口令语义说明——
|
||||
- “环绕X米Y圈”:以指定中心(坐标或目标)为圆心,半径 X 米,等速飞行 Y 圈;默认顺时针(`clockwise:true`),默认云台持续指向中心(`gimbal_lock:true`)。
|
||||
- 中心选择:
|
||||
- 明确给出坐标 → 使用 `orbit_around_point`(`center_x/center_y/center_z` 来自口令或参考知识)。
|
||||
- 明确“以目标为中心/围绕某类目标” → 使用 `orbit_around_target`(需要已获目标;若缺少目标实例,复杂模式应先检测/确认)。
|
||||
- 未明确中心但上下文存在当前锁定目标 → 视为以该目标为中心。
|
||||
- 方向与速度:
|
||||
- “顺时针/逆时针” → `clockwise: true/false`;未指明默认 `true`。
|
||||
- “等速/速度V米每秒” → 指明则设置 `speed_mps: V`(范围 [0.5,15]);未指明可省略。
|
||||
- 数字解析:中文数字与阿拉伯数字均可,需规范化为数值,例如“三十两圈” → `radius: 30.0`、`laps: 2`。
|
||||
|
||||
—— 可用节点定义——
|
||||
```json
|
||||
@@ -32,9 +19,9 @@
|
||||
{"name": "takeoff", "description": "无人机从当前位置垂直起飞到指定的海拔高度。", "params": {"altitude": "float, 目标海拔高度(米),范围[1, 100],默认为2"}},
|
||||
{"name": "land", "description": "降落无人机。可选择当前位置或返航点降落。", "params": {"mode": "string, 可选值: 'current'(当前位置), 'home'(返航点)"}},
|
||||
{"name": "fly_to_waypoint", "description": "导航至一个指定坐标点。使用相对坐标系(x,y,z),单位为米。", "params": {"x": "float", "y": "float", "z": "float", "acceptance_radius": "float, 可选,默认2.0"}},
|
||||
{"name": "orbit_around_point", "description": "围绕给定中心点等速环绕飞行,可指定圈数与方向。", "params": {"center_x": "float", "center_y": "float", "center_z": "float", "radius": "float[5,1000]", "laps": "int[1,20]", "clockwise": "boolean, 默认true", "speed_mps": "float[0.5,15], 可选", "gimbal_lock": "boolean, 默认true"}},
|
||||
{"name": "orbit_around_target", "description": "围绕已获目标等速环绕飞行,可指定圈数与方向。", "params": {"target_class": "string", "description": "string, 可选", "radius": "float[5,1000]", "laps": "int[1,20]", "clockwise": "boolean, 默认true", "speed_mps": "float[0.5,15], 可选", "gimbal_lock": "boolean, 默认true"}},
|
||||
{"name": "move_direction", "description": "按指定方向直线移动。方向可为绝对方位或相对机体朝向。", "params": {"direction": "string: north|south|east|west|forward|backward|left|right", "distance": "float[1,10000], 可选, 不指定则持续移动"}},
|
||||
{"name": "orbit_around_point", "description": "以给定中心点为中心,等速圆周飞行指定圈数。", "params": {"center_x": "float", "center_y": "float", "center_z": "float", "radius": "float[5,1000]", "laps": "int[1,20]", "clockwise": "boolean, 可选, 默认true", "speed_mps": "float[0.5,15], 可选", "gimbal_lock": "boolean, 可选, 默认true"}},
|
||||
{"name": "orbit_around_target", "description": "以目标为中心,等速圆周飞行指定圈数(需已有目标)。", "params": {"target_class": "string, 见复杂模式定义列表", "description": "string, 可选", "radius": "float[5,1000]", "laps": "int[1,20]", "clockwise": "boolean, 可选, 默认true", "speed_mps": "float[0.5,15], 可选", "gimbal_lock": "boolean, 可选, 默认true"}},
|
||||
{"name": "loiter", "description": "在当前位置上空悬停一段时间或直到条件触发。", "params": {"duration": "float, 可选[1,600]", "until_condition": "string, 可选"}},
|
||||
{"name": "object_detect", "description": "识别特定目标对象。", "params": {"target_class": "string, 见复杂模式定义列表", "description": "string, 可选", "count": "int, 可选, 默认1"}},
|
||||
{"name": "strike_target", "description": "对已识别目标进行打击。", "params": {"target_class": "string", "description": "string, 可选", "count": "int, 可选, 默认1"}},
|
||||
@@ -62,9 +49,15 @@
|
||||
- fly_to_waypoint.x,y: [-10000, 10000]
|
||||
- search_pattern.radius: [5, 1000]
|
||||
- move_direction.distance: [1, 10000]
|
||||
// 环绕动作
|
||||
- orbit_around_point.radius / orbit_around_target.radius: [5, 1000]
|
||||
- orbit_around_point.laps / orbit_around_target.laps: [1, 20]
|
||||
- orbit_around_point.speed_mps / orbit_around_target.speed_mps: [0.5, 15]
|
||||
- orbit_around_point.radius: [5, 1000]
|
||||
- orbit_around_target.radius: [5, 1000]
|
||||
- orbit_around_point/target.laps: [1, 20]
|
||||
- orbit_around_point/target.speed_mps: [0.5, 15]
|
||||
- 电池阈值等同复杂模式(如需涉及)
|
||||
- 若参考知识提供坐标,必须使用并裁剪到约束范围内
|
||||
- 若参考知识提供坐标,必须使用并裁剪到约束范围内
|
||||
|
||||
—— 口令转化规则(环绕类)——
|
||||
- “环绕X米Y圈” → 若有目标上下文则使用 `orbit_around_target`,否则根据是否给出中心坐标选择 `orbit_around_point`;`radius=X`,`laps=Y`,默认 `clockwise=true`,`gimbal_lock=true`
|
||||
- “顺时针/逆时针” → `clockwise=true/false`
|
||||
- “等速” → 若未给速度则 `speed_mps` 采用默认值(例如3.0);若口令指明速度,裁剪到[0.5,15]
|
||||
- “以(x,y,z)为中心”/“当前位置为中心” → 选择 `orbit_around_point` 并填充 `center_x/center_y/center_z`
|
||||
Reference in New Issue
Block a user