guoyuanquan@mail.taiji.com.cn 4 months ago
parent
commit
0c7c5a027a
5 changed files with 16 additions and 12 deletions
  1. 6 6
      manifest.yaml
  2. 2 2
      models/llm/deepseek-chat.yaml
  3. 7 3
      models/llm/llm.py
  4. 1 1
      provider/shenzhen2.yaml
  5. BIN
      shenzhen2.difypkg

+ 6 - 6
manifest.yaml

@@ -1,13 +1,13 @@
-version: 0.0.6
+version: 0.1.1
 type: plugin
 author: gyq
-name: shenzhen2
+name: shenzhenv3
 label:
-  en_US: shenzhen2
-  zh_Hans: 深圳大数据接口
+  en_US: shenzhenv3
+  zh_Hans: deepseek-V3-0324
 description:
-  en_US: shenzhen2
-  zh_Hans: 深圳大数据接口
+  en_US: shenzhenv3
+  zh_Hans: deepseek-V3-0324
 icon: icon.svg
 resource:
   memory: 268435456

+ 2 - 2
models/llm/deepseek-chat.yaml

@@ -1,7 +1,7 @@
-model: deepseek-chat
+model: deepseek-v3
 label:
   zh_Hans: deepseek-chat
-  en_US: deepseek-chat
+  en_US: deepseek-chat-V3
 model_type: llm
 features:
   - agent-thought

+ 7 - 3
models/llm/llm.py

@@ -19,6 +19,7 @@ class DeepseekLargeLanguageModel(OAICompatLargeLanguageModel):
         user: Optional[str] = None,
     ) -> Union[LLMResult, Generator]:
         self._add_custom_parameters(credentials)
+        model="model"
         return super()._invoke(model, credentials, prompt_messages, model_parameters, tools, stop, stream)
 
     # def validate_credentials(self, model: str, credentials: dict) -> None:
@@ -27,14 +28,17 @@ class DeepseekLargeLanguageModel(OAICompatLargeLanguageModel):
 
     @staticmethod
     def _add_custom_parameters(credentials) -> None:
-        credentials["endpoint_url"] = str("http://10.132.200.185:30012/gateway/ti/v1/")
+        # credentials["endpoint_url"] = str("http://10.132.200.185:30012/gateway/ti/v1/")
+        credentials["endpoint_url"] = str("http://10.132.200.185:30012/gateway/ti/ds-v3/v1/")
         credentials["mode"] = LLMMode.CHAT.value
         credentials["function_calling_type"] = "tool_call"
         credentials["stream_function_calling"] = "support"
         credentials["extra_headers"] = {
         "Content-type": "application/json",
-        "X-TC-Project": "1",
-        "X-TC-Service": "deepseek-r1-h800-master-sglang",
+        "X-TC-Project": "744701358",
+        # "X-TC-Project": "1",
+        # "X-TC-Service": "deepseek-r1-h800-master-sglang",
+        "X-TC-Service": "deepseek-v3-0324-w8a8-master",
         "X-TC-Action": "/v1/chat/completions",
         "X-TC-Version": "2020-10-01",
         "szc-api-key": "f4eb2eb55b4f4a17a5"

+ 1 - 1
provider/shenzhen2.yaml

@@ -21,7 +21,7 @@ icon_small:
   en_US: icon_s_en.svg
 label:
   en_US: deepseek
-  zh_Hans: 深圳大数据模型
+  zh_Hans: 深圳大数据模型v3
 models:
   llm:
     position: models/llm/_position.yaml

BIN
shenzhen2.difypkg