feat: 为 Anthropic DTO 添加 signature、stop_sequence、cache_creation 和 service_tier 字段
在 Yi.Framework.AiHub.Domain.Shared/Dtos/Anthropic/AnthropicChatCompletionDto.cs 中新增字段: - AnthropicChatCompletionDto: Signature、StopSequence(带 JsonPropertyName) - AnthropicChatCompletionDtoContentBlock: signature(小写字段) - AnthropicCompletionDtoUsage: CacheCreation、ServiceTier(带 JsonPropertyName)
This commit is contained in:
@@ -39,6 +39,11 @@ public class AnthropicChatCompletionDtoDelta
|
||||
[JsonPropertyName("partial_json")] public string? PartialJson { get; set; }
|
||||
|
||||
[JsonPropertyName("stop_reason")] public string? StopReason { get; set; }
|
||||
|
||||
[JsonPropertyName("signature")] public string? Signature { get; set; }
|
||||
|
||||
[JsonPropertyName("stop_sequence")] public string? StopSequence { get; set; }
|
||||
|
||||
}
|
||||
|
||||
public class AnthropicChatCompletionDtoContentBlock
|
||||
@@ -103,6 +108,7 @@ public class AnthropicChatCompletionDtoContent
|
||||
[JsonPropertyName("partial_json")] public string? PartialJson { get; set; }
|
||||
|
||||
public string? signature { get; set; }
|
||||
|
||||
}
|
||||
|
||||
public class AnthropicCompletionDtoUsage
|
||||
@@ -118,6 +124,12 @@ public class AnthropicCompletionDtoUsage
|
||||
[JsonPropertyName("output_tokens")] public int? OutputTokens { get; set; }
|
||||
|
||||
[JsonPropertyName("server_tool_use")] public AnthropicServerToolUse? ServerToolUse { get; set; }
|
||||
|
||||
[JsonPropertyName("cache_creation")] public object? CacheCreation { get; set; }
|
||||
|
||||
[JsonPropertyName("service_tier")] public string? ServiceTier { get; set; }
|
||||
|
||||
|
||||
}
|
||||
|
||||
public class AnthropicServerToolUse
|
||||
|
||||
Reference in New Issue
Block a user