From ed4fdc03a98e9be224d11362b3cda4063355ceb0 Mon Sep 17 00:00:00 2001 From: wangdan-fit2cloud Date: Thu, 24 Sep 2026 10:45:46 +0800 Subject: [PATCH] feat: prompt generate --- ui/src/api/API_README.md | 5 ++ ui/src/components/COMPONENT_README.md | 4 +- .../resource-authorization-drawer/index.vue | 10 ++-- .../business/select-model/index.vue | 8 ++-- .../components/codemirror-editor/python.vue | 15 +++++- .../components/global/mk-icon/LoadingIcon.vue | 5 ++ ui/src/constants/theme.ts | 2 +- ui/src/views/knowledge/index.vue | 4 +- ui/src/views/tool/index.vue | 4 +- .../tool/tool-store/ApplyStoreToolDialog.vue | 8 ++-- ui/src/views/workflow/tool/index.vue | 30 ++++++------ ui/src/workflow-canvas/WORKFLOW_README.md | 6 ++- .../ai-chat-node/component/PromptGenerate.vue | 48 +++++++++++-------- ui/src/workflow-canvas/store/index.ts | 28 +++++------ 14 files changed, 105 insertions(+), 72 deletions(-) diff --git a/ui/src/api/API_README.md b/ui/src/api/API_README.md index afaa658d45d..4a9984e15aa 100644 --- a/ui/src/api/API_README.md +++ b/ui/src/api/API_README.md @@ -96,6 +96,11 @@ FormData;保存返回完整配置,页面以该返回值作为唯一数据来 ### 四类特殊资源 API +根据资源范围或业务上下文选择出的 API 对象统一命名为 `requestApi`,包括 `computed` 结果和 +局部变量,不使用 `toolApi`、`authorizationApi` 或 `request` 等名称。同一作用域确需同时使用 +多套 API 时,以 `request` 为前缀加业务名区分,例如 `requestModelApi`、`requestToolApi`。 +直接导入的 API 保持 PascalCase 命名;请求返回的 Promise 不属于此命名规则。 + `application`、`knowledge`、`model`、`tool` 是需要同时考虑 Workspace、System 资源管理和 System 共享资源的四类特殊资源。其接口按真实后端边界分别维护在 `admin/workspace/` 与 `admin/system/` 下,不把不同范围的 URL 合并为页面侧 API Map,也不让卡片或 Action 根据路由拼接 diff --git a/ui/src/components/COMPONENT_README.md b/ui/src/components/COMPONENT_README.md index 082701d8e91..ff1f19446f4 100644 --- a/ui/src/components/COMPONENT_README.md +++ b/ui/src/components/COMPONENT_README.md @@ -480,7 +480,9 @@ Python 与 JSON 编辑器通过 `