feat: 完成模型库优化

This commit is contained in:
ccnetcore
2025-12-11 21:12:29 +08:00
parent 53e56134d4
commit a46a552097
3 changed files with 44 additions and 28 deletions

View File

@@ -1,4 +1,5 @@
using Yi.Framework.AiHub.Domain.Shared.Enums;
using Yi.Framework.AiHub.Domain.Shared.Extensions;
namespace Yi.Framework.AiHub.Application.Contracts.Dtos.Model;
@@ -30,18 +31,14 @@ public class ModelLibraryDto
/// <summary>
/// 模型类型名称
/// </summary>
public string ModelTypeName { get; set; }
public string ModelTypeName => ModelType.GetDescription();
/// <summary>
/// 模型API类型
/// 模型支持的API类型
/// </summary>
public ModelApiTypeEnum ModelApiType { get; set; }
/// <summary>
/// 模型API类型名称
/// </summary>
public string ModelApiTypeName { get; set; }
public List<ModelApiTypeOutput> ModelApiTypes { get; set; }
/// <summary>
/// 模型显示倍率
/// </summary>
@@ -61,4 +58,22 @@ public class ModelLibraryDto
/// 是否为尊享模型PremiumChat类型
/// </summary>
public bool IsPremium { get; set; }
/// <summary>
/// 排序
/// </summary>
public int OrderNum { get; set; }
}
public class ModelApiTypeOutput
{
/// <summary>
/// 模型类型
/// </summary>
public ModelApiTypeEnum ModelApiType { get; set; }
/// <summary>
/// 模型类型名称
/// </summary>
public string ModelApiTypeName => ModelApiType.GetDescription();
}