Browse Source

X-DashScope-DataInspection

deason 2 days ago
parent
commit
72fd5efdd2

+ 3 - 3
src/main/java/com/qmth/ops/biz/ai/client/aliyun/llm/AliyunChatClient.java

@@ -58,9 +58,9 @@ public class AliyunChatClient extends ChatApiClient {
     @Override
     protected Headers buildHeader(Headers.Builder headerBuilder, LlmAppType appType) {
         headerBuilder.add(AUTH_HEADER_NAME, AUTH_HEADER_VALUE + getConfig().getSecret());
-        // if (appType == LlmAppType.AUTO_SCORE) {
-        //     headerBuilder.add("X-DashScope-DataInspection", "{\"input\":\"disable\", \"output\":\"disable\"}");
-        // }
+        if (appType == LlmAppType.AUTO_SCORE) {
+            headerBuilder.add("X-DashScope-DataInspection", "{\"input\":\"disable\", \"output\":\"disable\"}");
+        }
         return headerBuilder.build();
     }