From 08ef4c34f2015f13feb281549ab2af29f9a3d762 Mon Sep 17 00:00:00 2001 From: hexiaochun Date: Tue, 2 Jul 2024 17:36:23 +0800 Subject: [PATCH] fix: add JsonIgnoreProperties --- .../src/main/java/com/volcengine/ark/runtime/model/Usage.java | 2 ++ .../com/volcengine/ark/runtime/model/embeddings/Embedding.java | 3 +++ .../ark/runtime/model/embeddings/EmbeddingResult.java | 2 ++ 3 files changed, 7 insertions(+) diff --git a/volcengine-java-sdk-ark-runtime/src/main/java/com/volcengine/ark/runtime/model/Usage.java b/volcengine-java-sdk-ark-runtime/src/main/java/com/volcengine/ark/runtime/model/Usage.java index f7ca1f2b..f894af4b 100644 --- a/volcengine-java-sdk-ark-runtime/src/main/java/com/volcengine/ark/runtime/model/Usage.java +++ b/volcengine-java-sdk-ark-runtime/src/main/java/com/volcengine/ark/runtime/model/Usage.java @@ -1,7 +1,9 @@ package com.volcengine.ark.runtime.model; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; import com.fasterxml.jackson.annotation.JsonProperty; +@JsonIgnoreProperties(ignoreUnknown = true) public class Usage { /** * The number of prompt tokens used. diff --git a/volcengine-java-sdk-ark-runtime/src/main/java/com/volcengine/ark/runtime/model/embeddings/Embedding.java b/volcengine-java-sdk-ark-runtime/src/main/java/com/volcengine/ark/runtime/model/embeddings/Embedding.java index da468719..73707dd8 100644 --- a/volcengine-java-sdk-ark-runtime/src/main/java/com/volcengine/ark/runtime/model/embeddings/Embedding.java +++ b/volcengine-java-sdk-ark-runtime/src/main/java/com/volcengine/ark/runtime/model/embeddings/Embedding.java @@ -1,7 +1,10 @@ package com.volcengine.ark.runtime.model.embeddings; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; + import java.util.List; +@JsonIgnoreProperties(ignoreUnknown = true) public class Embedding { /** diff --git a/volcengine-java-sdk-ark-runtime/src/main/java/com/volcengine/ark/runtime/model/embeddings/EmbeddingResult.java b/volcengine-java-sdk-ark-runtime/src/main/java/com/volcengine/ark/runtime/model/embeddings/EmbeddingResult.java index 827cfbf9..48246c76 100644 --- a/volcengine-java-sdk-ark-runtime/src/main/java/com/volcengine/ark/runtime/model/embeddings/EmbeddingResult.java +++ b/volcengine-java-sdk-ark-runtime/src/main/java/com/volcengine/ark/runtime/model/embeddings/EmbeddingResult.java @@ -1,10 +1,12 @@ package com.volcengine.ark.runtime.model.embeddings; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; import com.volcengine.ark.runtime.model.Usage; import java.util.List; +@JsonIgnoreProperties(ignoreUnknown = true) public class EmbeddingResult { /**