From c5b43ead61b121055962ed2ee98de420770a781b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=B0=81=E5=B4=87?= Date: Wed, 14 Aug 2024 14:24:54 +0800 Subject: [PATCH] add dipper variable --- publish.yaml | 13 ++++++++++--- src/s.yaml | 30 ++++++++++++------------------ src/variable.yaml | 32 ++++++++++++++++++++++++++++++++ 3 files changed, 54 insertions(+), 21 deletions(-) create mode 100644 src/variable.yaml diff --git a/publish.yaml b/publish.yaml index 65d56ec..e6776b3 100644 --- a/publish.yaml +++ b/publish.yaml @@ -9,12 +9,12 @@ Edition: 3.0.0 Type: Project -Name: start-modelscope-v3 +Name: start-dipper-modelscope Provider: - 阿里云 -Version: 0.1.6 +Version: 0.0.1 Description: ModelScope应用(fc3.0) -HomePage: https://github.com/devsapp/start-modelscope-v3 +HomePage: https://github.com/devsapp/start-modelscope Tags: - AIGC - 大模型 @@ -24,6 +24,13 @@ Service: 函数计算: Authorities: - AliyunFCFullAccess + 硬盘挂载: + Authorities: + - AliyunFCServerlessDevsRolePolicy + 专有网络: + Authorities: + - AliyunFCServerlessDevsRolePolicy + Effective: Public Parameters: type: object diff --git a/src/s.yaml b/src/s.yaml index 560ab42..6c66b37 100644 --- a/src/s.yaml +++ b/src/s.yaml @@ -185,21 +185,15 @@ resources: - GET - POST - PUT - - model_ui_func_domain: - component: 'fc3-domain' - props: - region: ${vars.region} - domainName: auto - protocol: HTTP - routeConfig: - routes: - - functionName: ${resources.model_ui_func.props.functionName} - methods: - - GET - - POST - - PUT - - DELETE - - OPTIONS - path: /* - qualifier: LATEST + customDomain: + domainName: "auto" + protocol: HTTP + route: + methods: + - GET + - POST + - PUT + - DELETE + - OPTIONS + path: /* + qualifier: LATEST diff --git a/src/variable.yaml b/src/variable.yaml new file mode 100644 index 0000000..8edd821 --- /dev/null +++ b/src/variable.yaml @@ -0,0 +1,32 @@ +shared: #共享变量 + modelId: + title: 模型ID + type: string + default: 'damo/nlp_structbert_sentiment-classification_chinese-ecommerce-base' + description: ModelScope的模型ID, 可以从 https://modelscope.cn/models 模型页获取 + modelRevision: + title: 模型版本 + type: string + default: 'v1.0.0' + description: ModelScope的模型版本,可以从 https://modelscope.cn/models 模型页获取 + modelTask: + title: 模型任务类型 + type: string + default: 'text-classification' + description: ModelScope的模型任务类型,可以从 https://modelscope.cn/models 模型页获取 + accessToken: + title: Access Token + type: string + sensitive: true + description: ModelScope的访问令牌(SDK令牌),从https://modelscope.cn/my/myaccesstoken获取 + +services: #服务变量 + tgpu_basic_func: + gpuInstanceType: + title: GPU实例类型 + type: string + default: "fc.gpu.tesla.1" + description: GPU实例类型 + enum: + - "fc.gpu.tesla.1" + - "fc.gpu.ampere.1" \ No newline at end of file