Backend: - cockpit_chat.dspy: real LLM calls via llm table config, Hermes-style context (system prompt + project/iteration + history), auto model selection (multimodal if files, text otherwise) - cockpit_model_options.dspy: returns active models with capabilities - llm table: added capabilities column (text/vision/multimodal) Frontend: - inputed script: no page reload, updates agent bubble with LLM reply - stats_row refreshed on success, error shown in bubble DB: - sd_agent_settings table for per-user agent preferences
322 lines
7.1 KiB
XML
322 lines
7.1 KiB
XML
|
|
{
|
|
"widgettype":"VBox",
|
|
"options":{"cheight":40,"width":"100%"},
|
|
"subwidgets":[{
|
|
"id":"sd_deploy_envs_tbl",
|
|
"widgettype":"Tabular",
|
|
"options":{
|
|
"width":"100%",
|
|
"height":"100%",
|
|
|
|
|
|
"title":"部署环境表",
|
|
|
|
|
|
|
|
|
|
"css":"card",
|
|
|
|
|
|
"editable":{
|
|
|
|
"new_data_url":"{{entire_url('add_sd_deploy_envs.dspy')}}",
|
|
|
|
|
|
"delete_data_url":"{{entire_url('delete_sd_deploy_envs.dspy')}}",
|
|
|
|
|
|
"update_data_url":"{{entire_url('update_sd_deploy_envs.dspy')}}"
|
|
|
|
},
|
|
|
|
|
|
"data_url":"{{entire_url('./get_sd_deploy_envs.dspy')}}",
|
|
|
|
"data_method":"GET",
|
|
"data_params":{{json.dumps(params_kw, indent=4, ensure_ascii=False)}},
|
|
"row_options":{
|
|
|
|
|
|
|
|
"browserfields": {
|
|
"exclouded": [
|
|
"db_password",
|
|
"ssh_key_path"
|
|
],
|
|
"alters": {
|
|
"project_id": {
|
|
"uitype": "code",
|
|
"dataurl": "{{entire_url('../api/get_project_options.dspy')}}",
|
|
"valueField": "project_id",
|
|
"textField": "project_id_text"
|
|
},
|
|
"env_type": {
|
|
"uitype": "code",
|
|
"dataurl": "{{entire_url('../api/get_search_env_type.dspy')}}",
|
|
"valueField": "value",
|
|
"textField": "text"
|
|
},
|
|
"status": {
|
|
"uitype": "code",
|
|
"dataurl": "{{entire_url('../api/get_search_env_status.dspy')}}",
|
|
"valueField": "value",
|
|
"textField": "text"
|
|
}
|
|
}
|
|
},
|
|
|
|
|
|
"editexclouded":[
|
|
"id",
|
|
"verified_at",
|
|
"created_at",
|
|
"updated_at"
|
|
],
|
|
|
|
"fields":[
|
|
{
|
|
"name": "id",
|
|
"title": "主键ID",
|
|
"type": "str",
|
|
"length": 32,
|
|
"nullable": "no",
|
|
"cwidth": 18,
|
|
"uitype": "str",
|
|
"datatype": "str",
|
|
"label": "主键ID"
|
|
},
|
|
{
|
|
"name": "project_id",
|
|
"title": "项目ID",
|
|
"type": "str",
|
|
"length": 32,
|
|
"nullable": "no",
|
|
"label": "项目ID",
|
|
"uitype": "code",
|
|
"valueField": "project_id",
|
|
"textField": "project_id_text",
|
|
"params": {
|
|
"dbname": "{{'sage'}}",
|
|
"table": "sd_projects",
|
|
"tblvalue": "id",
|
|
"tbltext": "name",
|
|
"valueField": "project_id",
|
|
"textField": "project_id_text"
|
|
},
|
|
"dataurl": "{{entire_url('../api/get_project_options.dspy')}}"
|
|
},
|
|
{
|
|
"name": "env_type",
|
|
"title": "环境类型",
|
|
"type": "str",
|
|
"length": 20,
|
|
"nullable": "no",
|
|
"label": "环境类型",
|
|
"uitype": "code",
|
|
"valueField": "value",
|
|
"textField": "text",
|
|
"params": {
|
|
"dbname": "{{'sage'}}",
|
|
"table": "appcodes_kv",
|
|
"tblvalue": "k",
|
|
"tbltext": "v",
|
|
"valueField": "value",
|
|
"textField": "text",
|
|
"cond": "parentid='sd_env_type'"
|
|
},
|
|
"dataurl": "{{entire_url('../api/get_search_env_type.dspy')}}"
|
|
},
|
|
{
|
|
"name": "host",
|
|
"title": "SSH主机地址",
|
|
"type": "str",
|
|
"length": 200,
|
|
"nullable": "no",
|
|
"cwidth": 18,
|
|
"uitype": "str",
|
|
"datatype": "str",
|
|
"label": "SSH主机地址"
|
|
},
|
|
{
|
|
"name": "port",
|
|
"title": "SSH端口",
|
|
"type": "int",
|
|
"nullable": "no",
|
|
"default": "22",
|
|
"length": 0,
|
|
"uitype": "int",
|
|
"datatype": "int",
|
|
"label": "SSH端口"
|
|
},
|
|
{
|
|
"name": "user",
|
|
"title": "SSH用户",
|
|
"type": "str",
|
|
"length": 100,
|
|
"nullable": "no",
|
|
"cwidth": 18,
|
|
"uitype": "str",
|
|
"datatype": "str",
|
|
"label": "SSH用户"
|
|
},
|
|
{
|
|
"name": "ssh_key_path",
|
|
"title": "SSH密钥路径",
|
|
"type": "str",
|
|
"length": 500,
|
|
"cwidth": 18,
|
|
"uitype": "password",
|
|
"datatype": "str",
|
|
"label": "SSH密钥路径"
|
|
},
|
|
{
|
|
"name": "sudo_enabled",
|
|
"title": "免密Sudo",
|
|
"type": "str",
|
|
"length": 1,
|
|
"nullable": "no",
|
|
"default": "'N'",
|
|
"cwidth": 4,
|
|
"uitype": "str",
|
|
"datatype": "str",
|
|
"label": "免密Sudo"
|
|
},
|
|
{
|
|
"name": "deploy_path",
|
|
"title": "部署目录",
|
|
"type": "str",
|
|
"length": 500,
|
|
"nullable": "no",
|
|
"cwidth": 18,
|
|
"uitype": "str",
|
|
"datatype": "str",
|
|
"label": "部署目录"
|
|
},
|
|
{
|
|
"name": "python_path",
|
|
"title": "Python路径",
|
|
"type": "str",
|
|
"length": 500,
|
|
"cwidth": 18,
|
|
"uitype": "str",
|
|
"datatype": "str",
|
|
"label": "Python路径"
|
|
},
|
|
{
|
|
"name": "db_host",
|
|
"title": "数据库地址",
|
|
"type": "str",
|
|
"length": 200,
|
|
"cwidth": 18,
|
|
"uitype": "str",
|
|
"datatype": "str",
|
|
"label": "数据库地址"
|
|
},
|
|
{
|
|
"name": "db_port",
|
|
"title": "数据库端口",
|
|
"type": "int",
|
|
"default": "3306",
|
|
"length": 0,
|
|
"uitype": "int",
|
|
"datatype": "int",
|
|
"label": "数据库端口"
|
|
},
|
|
{
|
|
"name": "db_name",
|
|
"title": "数据库名",
|
|
"type": "str",
|
|
"length": 100,
|
|
"cwidth": 18,
|
|
"uitype": "str",
|
|
"datatype": "str",
|
|
"label": "数据库名"
|
|
},
|
|
{
|
|
"name": "db_user",
|
|
"title": "数据库用户",
|
|
"type": "str",
|
|
"length": 100,
|
|
"cwidth": 18,
|
|
"uitype": "str",
|
|
"datatype": "str",
|
|
"label": "数据库用户"
|
|
},
|
|
{
|
|
"name": "db_password",
|
|
"title": "数据库密码(加密)",
|
|
"type": "str",
|
|
"length": 500,
|
|
"cwidth": 18,
|
|
"uitype": "password",
|
|
"datatype": "str",
|
|
"label": "数据库密码(加密)"
|
|
},
|
|
{
|
|
"name": "status",
|
|
"title": "环境状态",
|
|
"type": "str",
|
|
"length": 20,
|
|
"nullable": "no",
|
|
"default": "'configured'",
|
|
"label": "环境状态",
|
|
"uitype": "code",
|
|
"valueField": "value",
|
|
"textField": "text",
|
|
"params": {
|
|
"dbname": "{{'sage'}}",
|
|
"table": "appcodes_kv",
|
|
"tblvalue": "k",
|
|
"tbltext": "v",
|
|
"valueField": "value",
|
|
"textField": "text",
|
|
"cond": "parentid='sd_env_status'"
|
|
},
|
|
"dataurl": "{{entire_url('../api/get_search_env_status.dspy')}}"
|
|
},
|
|
{
|
|
"name": "verified_at",
|
|
"title": "最近验证时间",
|
|
"type": "timestamp",
|
|
"length": 0,
|
|
"uitype": "str",
|
|
"datatype": "timestamp",
|
|
"label": "最近验证时间"
|
|
},
|
|
{
|
|
"name": "created_at",
|
|
"title": "创建时间",
|
|
"type": "timestamp",
|
|
"nullable": "no",
|
|
"length": 0,
|
|
"uitype": "str",
|
|
"datatype": "timestamp",
|
|
"label": "创建时间"
|
|
},
|
|
{
|
|
"name": "updated_at",
|
|
"title": "更新时间",
|
|
"type": "timestamp",
|
|
"length": 0,
|
|
"uitype": "str",
|
|
"datatype": "timestamp",
|
|
"label": "更新时间"
|
|
}
|
|
]
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
"page_rows":160,
|
|
"cache_limit":5
|
|
}
|
|
|
|
,"binds":[]
|
|
|
|
}]
|
|
} |