mirror of
https://github.com/dptech-corp/Uni-Lab-OS.git
synced 2026-02-07 15:35:10 +00:00
增加注册表版本参数,支持将auto-指令人工检查后非auto,不生成人工已检查的指令,取消不必要的description生成
This commit is contained in:
@@ -717,12 +717,13 @@ def ros_message_to_json_schema(msg_class: Any) -> Dict[str, Any]:
|
||||
return schema
|
||||
|
||||
|
||||
def ros_action_to_json_schema(action_class: Any) -> Dict[str, Any]:
|
||||
def ros_action_to_json_schema(action_class: Any, description="") -> Dict[str, Any]:
|
||||
"""
|
||||
将 ROS Action 类转换为 JSON Schema
|
||||
|
||||
Args:
|
||||
action_class: ROS Action 类
|
||||
description: 描述
|
||||
|
||||
Returns:
|
||||
完整的 JSON Schema 定义
|
||||
@@ -737,7 +738,7 @@ def ros_action_to_json_schema(action_class: Any) -> Dict[str, Any]:
|
||||
# 创建基础 schema
|
||||
schema = {
|
||||
"title": action_class.__name__,
|
||||
"description": f"ROS Action {action_class.__name__} 的 JSON Schema",
|
||||
"description": description,
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"goal": {
|
||||
|
||||
Reference in New Issue
Block a user