diff --git a/VERSION b/VERSION index d57e08b5..db7aded3 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -0.3.52 +0.3.53 diff --git a/src/UAIModelverse/Apis/GetUFSquareModelDetailResponse.php b/src/UAIModelverse/Apis/GetUFSquareModelDetailResponse.php index cf2d457d..04296b77 100644 --- a/src/UAIModelverse/Apis/GetUFSquareModelDetailResponse.php +++ b/src/UAIModelverse/Apis/GetUFSquareModelDetailResponse.php @@ -18,6 +18,10 @@ use UCloud\Core\Response\Response; use UCloud\UAIModelverse\Models\SquareModel; +use UCloud\UAIModelverse\Models\InferenceRegionInfo; +use UCloud\UAIModelverse\Models\ModelTypeMap; +use UCloud\UAIModelverse\Models\ModelCapabilities; +use UCloud\UAIModelverse\Models\ApiProtocols; use UCloud\UAIModelverse\Models\Pricing; use UCloud\UAIModelverse\Models\PriceTier; use UCloud\UAIModelverse\Models\PriceRate; diff --git a/src/UAIModelverse/Apis/ListUFSquareModelFiltersAuthResponse.php b/src/UAIModelverse/Apis/ListUFSquareModelFiltersAuthResponse.php index ebf295c2..4ca64add 100644 --- a/src/UAIModelverse/Apis/ListUFSquareModelFiltersAuthResponse.php +++ b/src/UAIModelverse/Apis/ListUFSquareModelFiltersAuthResponse.php @@ -17,10 +17,297 @@ namespace UCloud\UAIModelverse\Apis; use UCloud\Core\Response\Response; +use UCloud\UAIModelverse\Models\FilterOption; class ListUFSquareModelFiltersAuthResponse extends Response { + /** + * ModalTypes: 模型类型筛选(一级/二级分类树) + * + * @return FilterOption[]|null + */ + public function getModalTypes() + { + $items = $this->get("ModalTypes"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new FilterOption($item)); + } + return $result; + } + /** + * ModalTypes: 模型类型筛选(一级/二级分类树) + * + * @param FilterOption[] $modalTypes + */ + public function setModalTypes(array $modalTypes) + { + $result = []; + foreach ($modalTypes as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } + + /** + * Manufacturers: 厂商选项 + * + * @return FilterOption[]|null + */ + public function getManufacturers() + { + $items = $this->get("Manufacturers"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new FilterOption($item)); + } + return $result; + } + + /** + * Manufacturers: 厂商选项 + * + * @param FilterOption[] $manufacturers + */ + public function setManufacturers(array $manufacturers) + { + $result = []; + foreach ($manufacturers as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } + + /** + * MaxModelLens: 最大上下文长度选项 + * + * @return FilterOption[]|null + */ + public function getMaxModelLens() + { + $items = $this->get("MaxModelLens"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new FilterOption($item)); + } + return $result; + } + + /** + * MaxModelLens: 最大上下文长度选项 + * + * @param FilterOption[] $maxModelLens + */ + public function setMaxModelLens(array $maxModelLens) + { + $result = []; + foreach ($maxModelLens as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } + + /** + * Capabilities: 能力选项 + * + * @return FilterOption[]|null + */ + public function getCapabilities() + { + $items = $this->get("Capabilities"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new FilterOption($item)); + } + return $result; + } + + /** + * Capabilities: 能力选项 + * + * @param FilterOption[] $capabilities + */ + public function setCapabilities(array $capabilities) + { + $result = []; + foreach ($capabilities as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } + + /** + * InputModalities: 输入模态选项 + * + * @return FilterOption[]|null + */ + public function getInputModalities() + { + $items = $this->get("InputModalities"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new FilterOption($item)); + } + return $result; + } + + /** + * InputModalities: 输入模态选项 + * + * @param FilterOption[] $inputModalities + */ + public function setInputModalities(array $inputModalities) + { + $result = []; + foreach ($inputModalities as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } + + /** + * OutputModalities: 输出模态选项 + * + * @return FilterOption[]|null + */ + public function getOutputModalities() + { + $items = $this->get("OutputModalities"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new FilterOption($item)); + } + return $result; + } + + /** + * OutputModalities: 输出模态选项 + * + * @param FilterOption[] $outputModalities + */ + public function setOutputModalities(array $outputModalities) + { + $result = []; + foreach ($outputModalities as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } + + /** + * ApiProtocols: API协议选项 + * + * @return FilterOption[]|null + */ + public function getApiProtocols() + { + $items = $this->get("ApiProtocols"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new FilterOption($item)); + } + return $result; + } + + /** + * ApiProtocols: API协议选项 + * + * @param FilterOption[] $apiProtocols + */ + public function setApiProtocols(array $apiProtocols) + { + $result = []; + foreach ($apiProtocols as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } + + /** + * InferenceRegions: 推理地域选项 + * + * @return FilterOption[]|null + */ + public function getInferenceRegions() + { + $items = $this->get("InferenceRegions"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new FilterOption($item)); + } + return $result; + } + + /** + * InferenceRegions: 推理地域选项 + * + * @param FilterOption[] $inferenceRegions + */ + public function setInferenceRegions(array $inferenceRegions) + { + $result = []; + foreach ($inferenceRegions as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } + + /** + * IsComingOffline: 模型状态选项 + * + * @return FilterOption[]|null + */ + public function getIsComingOffline() + { + $items = $this->get("IsComingOffline"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new FilterOption($item)); + } + return $result; + } + + /** + * IsComingOffline: 模型状态选项 + * + * @param FilterOption[] $isComingOffline + */ + public function setIsComingOffline(array $isComingOffline) + { + $result = []; + foreach ($isComingOffline as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } } diff --git a/src/UAIModelverse/Apis/ListUFSquareModelResponse.php b/src/UAIModelverse/Apis/ListUFSquareModelResponse.php index 8a91f269..f6e6ee09 100644 --- a/src/UAIModelverse/Apis/ListUFSquareModelResponse.php +++ b/src/UAIModelverse/Apis/ListUFSquareModelResponse.php @@ -18,6 +18,10 @@ use UCloud\Core\Response\Response; use UCloud\UAIModelverse\Models\SquareModel; +use UCloud\UAIModelverse\Models\InferenceRegionInfo; +use UCloud\UAIModelverse\Models\ModelTypeMap; +use UCloud\UAIModelverse\Models\ModelCapabilities; +use UCloud\UAIModelverse\Models\ApiProtocols; use UCloud\UAIModelverse\Models\Pricing; use UCloud\UAIModelverse\Models\PriceTier; use UCloud\UAIModelverse\Models\PriceRate; diff --git a/src/UAIModelverse/Models/ApiProtocols.php b/src/UAIModelverse/Models/ApiProtocols.php new file mode 100644 index 00000000..cd41507b --- /dev/null +++ b/src/UAIModelverse/Models/ApiProtocols.php @@ -0,0 +1,104 @@ +get("ChatCompletions"); + } + + /** + * ChatCompletions: 是否支持chat协议 + * + * @param boolean $chatCompletions + */ + public function setChatCompletions($chatCompletions) + { + $this->set("ChatCompletions", $chatCompletions); + } + + /** + * Responses: 是否支持responses协议 + * + * @return boolean|null + */ + public function getResponses() + { + return $this->get("Responses"); + } + + /** + * Responses: 是否支持responses协议 + * + * @param boolean $responses + */ + public function setResponses($responses) + { + $this->set("Responses", $responses); + } + + /** + * Gemini: 是否支持gemini协议 + * + * @return boolean|null + */ + public function getGemini() + { + return $this->get("Gemini"); + } + + /** + * Gemini: 是否支持gemini协议 + * + * @param boolean $gemini + */ + public function setGemini($gemini) + { + $this->set("Gemini", $gemini); + } + + /** + * Anthropic: 是否支持Anthropic协议 + * + * @return boolean|null + */ + public function getAnthropic() + { + return $this->get("Anthropic"); + } + + /** + * Anthropic: 是否支持Anthropic协议 + * + * @param boolean $anthropic + */ + public function setAnthropic($anthropic) + { + $this->set("Anthropic", $anthropic); + } +} diff --git a/src/UAIModelverse/Models/FilterOption.php b/src/UAIModelverse/Models/FilterOption.php new file mode 100644 index 00000000..96c605b2 --- /dev/null +++ b/src/UAIModelverse/Models/FilterOption.php @@ -0,0 +1,104 @@ +get("Children"); + } + + /** + * Children: + * + * @param string $children + */ + public function setChildren($children) + { + $this->set("Children", $children); + } + + /** + * Label: 显示标签 + * + * @return string|null + */ + public function getLabel() + { + return $this->get("Label"); + } + + /** + * Label: 显示标签 + * + * @param string $label + */ + public function setLabel($label) + { + $this->set("Label", $label); + } + + /** + * LabelEn: 英文标签 + * + * @return string|null + */ + public function getLabelEn() + { + return $this->get("LabelEn"); + } + + /** + * LabelEn: 英文标签 + * + * @param string $labelEn + */ + public function setLabelEn($labelEn) + { + $this->set("LabelEn", $labelEn); + } + + /** + * Value: 枚举值 + * + * @return string|null + */ + public function getValue() + { + return $this->get("Value"); + } + + /** + * Value: 枚举值 + * + * @param string $value + */ + public function setValue($value) + { + $this->set("Value", $value); + } +} diff --git a/src/UAIModelverse/Models/InferenceRegionInfo.php b/src/UAIModelverse/Models/InferenceRegionInfo.php new file mode 100644 index 00000000..2eb41219 --- /dev/null +++ b/src/UAIModelverse/Models/InferenceRegionInfo.php @@ -0,0 +1,144 @@ +get("RegionCode"); + } + + /** + * RegionCode: 地域代码: sg(新加坡)/us(美国)/hk(香港) + * + * @param string $regionCode + */ + public function setRegionCode($regionCode) + { + $this->set("RegionCode", $regionCode); + } + + /** + * RegionName: 地域名称: 新加坡/美国/香港 + * + * @return string|null + */ + public function getRegionName() + { + return $this->get("RegionName"); + } + + /** + * RegionName: 地域名称: 新加坡/美国/香港 + * + * @param string $regionName + */ + public function setRegionName($regionName) + { + $this->set("RegionName", $regionName); + } + + /** + * RegionNameEn: 地域名称(英文): Singapore/United States/Hong Kong + * + * @return string|null + */ + public function getRegionNameEn() + { + return $this->get("RegionNameEn"); + } + + /** + * RegionNameEn: 地域名称(英文): Singapore/United States/Hong Kong + * + * @param string $regionNameEn + */ + public function setRegionNameEn($regionNameEn) + { + $this->set("RegionNameEn", $regionNameEn); + } + + /** + * ModelId: 地域模型ID (例如: deepseek-v4-flash-sg) + * + * @return string|null + */ + public function getModelId() + { + return $this->get("ModelId"); + } + + /** + * ModelId: 地域模型ID (例如: deepseek-v4-flash-sg) + * + * @param string $modelId + */ + public function setModelId($modelId) + { + $this->set("ModelId", $modelId); + } + + /** + * SquareModelId: 广场模型ID (umodel-xxx) + * + * @return string|null + */ + public function getSquareModelId() + { + return $this->get("SquareModelId"); + } + + /** + * SquareModelId: 广场模型ID (umodel-xxx) + * + * @param string $squareModelId + */ + public function setSquareModelId($squareModelId) + { + $this->set("SquareModelId", $squareModelId); + } + + /** + * Status: 状态: published(已发布)/unpublished(未发布) + * + * @return string|null + */ + public function getStatus() + { + return $this->get("Status"); + } + + /** + * Status: 状态: published(已发布)/unpublished(未发布) + * + * @param string $status + */ + public function setStatus($status) + { + $this->set("Status", $status); + } +} diff --git a/src/UAIModelverse/Models/ModelCapabilities.php b/src/UAIModelverse/Models/ModelCapabilities.php new file mode 100644 index 00000000..fdbc34c5 --- /dev/null +++ b/src/UAIModelverse/Models/ModelCapabilities.php @@ -0,0 +1,184 @@ +get("ContextCaching"); + } + + /** + * ContextCaching: 是否支持上下文缓存 + * + * @param boolean $contextCaching + */ + public function setContextCaching($contextCaching) + { + $this->set("ContextCaching", $contextCaching); + } + + /** + * BatchInference: 是否支持批量推理 + * + * @return boolean|null + */ + public function getBatchInference() + { + return $this->get("BatchInference"); + } + + /** + * BatchInference: 是否支持批量推理 + * + * @param boolean $batchInference + */ + public function setBatchInference($batchInference) + { + $this->set("BatchInference", $batchInference); + } + + /** + * StructuredOutput: 是否支持结构化输出 + * + * @return boolean|null + */ + public function getStructuredOutput() + { + return $this->get("StructuredOutput"); + } + + /** + * StructuredOutput: 是否支持结构化输出 + * + * @param boolean $structuredOutput + */ + public function setStructuredOutput($structuredOutput) + { + $this->set("StructuredOutput", $structuredOutput); + } + + /** + * FunctionCall: 是否支持函数调用 + * + * @return boolean|null + */ + public function getFunctionCall() + { + return $this->get("FunctionCall"); + } + + /** + * FunctionCall: 是否支持函数调用 + * + * @param boolean $functionCall + */ + public function setFunctionCall($functionCall) + { + $this->set("FunctionCall", $functionCall); + } + + /** + * WebSearch: 是否支持联网搜索 + * + * @return boolean|null + */ + public function getWebSearch() + { + return $this->get("WebSearch"); + } + + /** + * WebSearch: 是否支持联网搜索 + * + * @param boolean $webSearch + */ + public function setWebSearch($webSearch) + { + $this->set("WebSearch", $webSearch); + } + + /** + * KnowledgeBase: 是否支持知识库 + * + * @return boolean|null + */ + public function getKnowledgeBase() + { + return $this->get("KnowledgeBase"); + } + + /** + * KnowledgeBase: 是否支持知识库 + * + * @param boolean $knowledgeBase + */ + public function setKnowledgeBase($knowledgeBase) + { + $this->set("KnowledgeBase", $knowledgeBase); + } + + /** + * Mcp: 是否支持MCP + * + * @return boolean|null + */ + public function getMcp() + { + return $this->get("Mcp"); + } + + /** + * Mcp: 是否支持MCP + * + * @param boolean $mcp + */ + public function setMcp($mcp) + { + $this->set("Mcp", $mcp); + } + + /** + * Experience: 是否支持体验 + * + * @return boolean|null + */ + public function getExperience() + { + return $this->get("Experience"); + } + + /** + * Experience: 是否支持体验 + * + * @param boolean $experience + */ + public function setExperience($experience) + { + $this->set("Experience", $experience); + } +} diff --git a/src/UAIModelverse/Models/ModelTypeMap.php b/src/UAIModelverse/Models/ModelTypeMap.php new file mode 100644 index 00000000..a0fcf3ef --- /dev/null +++ b/src/UAIModelverse/Models/ModelTypeMap.php @@ -0,0 +1,164 @@ +get("TextGeneration"); + } + + /** + * TextGeneration: 文生文模型,true 表示是文生文模型,下同 + * + * @param boolean $textGeneration + */ + public function setTextGeneration($textGeneration) + { + $this->set("TextGeneration", $textGeneration); + } + + /** + * ImageToImage: 图生图模型 + * + * @return boolean|null + */ + public function getImageToImage() + { + return $this->get("ImageToImage"); + } + + /** + * ImageToImage: 图生图模型 + * + * @param boolean $imageToImage + */ + public function setImageToImage($imageToImage) + { + $this->set("ImageToImage", $imageToImage); + } + + /** + * TextToImage: 文生图模型 + * + * @return boolean|null + */ + public function getTextToImage() + { + return $this->get("TextToImage"); + } + + /** + * TextToImage: 文生图模型 + * + * @param boolean $textToImage + */ + public function setTextToImage($textToImage) + { + $this->set("TextToImage", $textToImage); + } + + /** + * TextToVideo: 文生视频模型 + * + * @return boolean|null + */ + public function getTextToVideo() + { + return $this->get("TextToVideo"); + } + + /** + * TextToVideo: 文生视频模型 + * + * @param boolean $textToVideo + */ + public function setTextToVideo($textToVideo) + { + $this->set("TextToVideo", $textToVideo); + } + + /** + * ImageToVideo: 图生视频模型 + * + * @return boolean|null + */ + public function getImageToVideo() + { + return $this->get("ImageToVideo"); + } + + /** + * ImageToVideo: 图生视频模型 + * + * @param boolean $imageToVideo + */ + public function setImageToVideo($imageToVideo) + { + $this->set("ImageToVideo", $imageToVideo); + } + + /** + * Sensitive: 海外模型 + * + * @return boolean|null + */ + public function getSensitive() + { + return $this->get("Sensitive"); + } + + /** + * Sensitive: 海外模型 + * + * @param boolean $sensitive + */ + public function setSensitive($sensitive) + { + $this->set("Sensitive", $sensitive); + } + + /** + * Inference: 微调模型 + * + * @return boolean|null + */ + public function getInference() + { + return $this->get("Inference"); + } + + /** + * Inference: 微调模型 + * + * @param boolean $inference + */ + public function setInference($inference) + { + $this->set("Inference", $inference); + } +} diff --git a/src/UAIModelverse/Models/SquareModel.php b/src/UAIModelverse/Models/SquareModel.php index 93234eaa..27c50634 100644 --- a/src/UAIModelverse/Models/SquareModel.php +++ b/src/UAIModelverse/Models/SquareModel.php @@ -42,6 +42,46 @@ public function setBatchSquareModelId($batchSquareModelId) $this->set("BatchSquareModelId", $batchSquareModelId); } + /** + * ModelCategory: 一级分类 + * + * @return string|null + */ + public function getModelCategory() + { + return $this->get("ModelCategory"); + } + + /** + * ModelCategory: 一级分类 + * + * @param string $modelCategory + */ + public function setModelCategory($modelCategory) + { + $this->set("ModelCategory", $modelCategory); + } + + /** + * ModelSubCategories: 二级分类列表 + * + * @return string|null + */ + public function getModelSubCategories() + { + return $this->get("ModelSubCategories"); + } + + /** + * ModelSubCategories: 二级分类列表 + * + * @param string $modelSubCategories + */ + public function setModelSubCategories($modelSubCategories) + { + $this->set("ModelSubCategories", $modelSubCategories); + } + /** * IsHasBatch: 是否关联有可用 batch 模型 * @@ -82,6 +122,58 @@ public function setBatchName($batchName) $this->set("BatchName", $batchName); } + /** + * IsHasInferenceRegions: 是否有关联的推理地域模型 + * + * @return boolean|null + */ + public function getIsHasInferenceRegions() + { + return $this->get("IsHasInferenceRegions"); + } + + /** + * IsHasInferenceRegions: 是否有关联的推理地域模型 + * + * @param boolean $isHasInferenceRegions + */ + public function setIsHasInferenceRegions($isHasInferenceRegions) + { + $this->set("IsHasInferenceRegions", $isHasInferenceRegions); + } + + /** + * InferenceRegions: 推理地域模型列表 + * + * @return InferenceRegionInfo[]|null + */ + public function getInferenceRegions() + { + $items = $this->get("InferenceRegions"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new InferenceRegionInfo($item)); + } + return $result; + } + + /** + * InferenceRegions: 推理地域模型列表 + * + * @param InferenceRegionInfo[] $inferenceRegions + */ + public function setInferenceRegions(array $inferenceRegions) + { + $result = []; + foreach ($inferenceRegions as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } + /** * Manufacturer: 制造商 * @@ -203,7 +295,7 @@ public function setLanguage(array $language) } /** - * MaxModelLen: 模型长度 + * MaxModelLen: 模型长度,单位 token * * @return integer|null */ @@ -213,7 +305,7 @@ public function getMaxModelLen() } /** - * MaxModelLen: 模型长度 + * MaxModelLen: 模型长度,单位 token * * @param int $maxModelLen */ @@ -222,6 +314,86 @@ public function setMaxModelLen($maxModelLen) $this->set("MaxModelLen", $maxModelLen); } + /** + * MaxModelLenNew: 模型长度,单位 K tokens + * + * @return integer|null + */ + public function getMaxModelLenNew() + { + return $this->get("MaxModelLenNew"); + } + + /** + * MaxModelLenNew: 模型长度,单位 K tokens + * + * @param int $maxModelLenNew + */ + public function setMaxModelLenNew($maxModelLenNew) + { + $this->set("MaxModelLenNew", $maxModelLenNew); + } + + /** + * MaxInputTokens: 最大输入token数 + * + * @return integer|null + */ + public function getMaxInputTokens() + { + return $this->get("MaxInputTokens"); + } + + /** + * MaxInputTokens: 最大输入token数 + * + * @param int $maxInputTokens + */ + public function setMaxInputTokens($maxInputTokens) + { + $this->set("MaxInputTokens", $maxInputTokens); + } + + /** + * MaxOutputTokens: 最大输出token数 + * + * @return integer|null + */ + public function getMaxOutputTokens() + { + return $this->get("MaxOutputTokens"); + } + + /** + * MaxOutputTokens: 最大输出token数 + * + * @param int $maxOutputTokens + */ + public function setMaxOutputTokens($maxOutputTokens) + { + $this->set("MaxOutputTokens", $maxOutputTokens); + } + + /** + * ModelTypeMap: 模型类型映射 + * + * @return ModelTypeMap|null + */ + public function getModelTypeMap() + { + return new ModelTypeMap($this->get("ModelTypeMap")); + } + + /** + * ModelTypeMap: 模型类型映射 + * + * @param ModelTypeMap $modelTypeMap + */ + public function setModelTypeMap(array $modelTypeMap) + { + $this->set("ModelTypeMap", $modelTypeMap->getAll()); + } + /** * ModelType: 模型类型 * @@ -242,6 +414,26 @@ public function setModelType($modelType) $this->set("ModelType", $modelType); } + /** + * CoverUrl: 模型封面链接 + * + * @return string|null + */ + public function getCoverUrl() + { + return $this->get("CoverUrl"); + } + + /** + * CoverUrl: 模型封面链接 + * + * @param string $coverUrl + */ + public function setCoverUrl($coverUrl) + { + $this->set("CoverUrl", $coverUrl); + } + /** * HfUpdateTime: HuggingFace 更新时间 * @@ -322,6 +514,106 @@ public function setSupportedCapabilities(array $supportedCapabilities) $this->set("SupportedCapabilities", $supportedCapabilities); } + /** + * Capabilities: 模型能力详细映射 + * + * @return ModelCapabilities|null + */ + public function getCapabilities() + { + return new ModelCapabilities($this->get("Capabilities")); + } + + /** + * Capabilities: 模型能力详细映射 + * + * @param ModelCapabilities $capabilities + */ + public function setCapabilities(array $capabilities) + { + $this->set("Capabilities", $capabilities->getAll()); + } + + /** + * ExtraModelTags: 模型额外标签 + * + * @return string[]|null + */ + public function getExtraModelTags() + { + return $this->get("ExtraModelTags"); + } + + /** + * ExtraModelTags: 模型额外标签 + * + * @param string[] $extraModelTags + */ + public function setExtraModelTags(array $extraModelTags) + { + $this->set("ExtraModelTags", $extraModelTags); + } + + /** + * ApiProtocols: api协议映射 + * + * @return ApiProtocols|null + */ + public function getApiProtocols() + { + return new ApiProtocols($this->get("ApiProtocols")); + } + + /** + * ApiProtocols: api协议映射 + * + * @param ApiProtocols $apiProtocols + */ + public function setApiProtocols(array $apiProtocols) + { + $this->set("ApiProtocols", $apiProtocols->getAll()); + } + + /** + * InputModalities: 输入模态 + * + * @return string[]|null + */ + public function getInputModalities() + { + return $this->get("InputModalities"); + } + + /** + * InputModalities: 输入模态 + * + * @param string[] $inputModalities + */ + public function setInputModalities(array $inputModalities) + { + $this->set("InputModalities", $inputModalities); + } + + /** + * OutputModalities: 输出模态 + * + * @return string[]|null + */ + public function getOutputModalities() + { + return $this->get("OutputModalities"); + } + + /** + * OutputModalities: 输出模态 + * + * @param string[] $outputModalities + */ + public function setOutputModalities(array $outputModalities) + { + $this->set("OutputModalities", $outputModalities); + } + /** * Icon: 图标 * diff --git a/src/UAIModelverse/UAIModelverseClient.php b/src/UAIModelverse/UAIModelverseClient.php index 1adc0930..205db496 100644 --- a/src/UAIModelverse/UAIModelverseClient.php +++ b/src/UAIModelverse/UAIModelverseClient.php @@ -450,20 +450,65 @@ public function getOrderAmount(GetOrderAmountRequest $request = null) * $outputs = [ * "SquareModel" => (object) 模型[ * "BatchSquareModelId" => (string) 关联的 batch 模型广场id + * "ModelCategory" => (string) 一级分类 + * "ModelSubCategories" => (string) 二级分类列表 * "IsHasBatch" => (boolean) 是否关联有可用 batch 模型 * "BatchName" => (string) 关联的 batch 模型名称 + * "IsHasInferenceRegions" => (boolean) 是否有关联的推理地域模型 + * "InferenceRegions" => (array) 推理地域模型列表[ + * [ + * "RegionCode" => (string) 地域代码: sg(新加坡)/us(美国)/hk(香港) + * "RegionName" => (string) 地域名称: 新加坡/美国/香港 + * "RegionNameEn" => (string) 地域名称(英文): Singapore/United States/Hong Kong + * "ModelId" => (string) 地域模型ID (例如: deepseek-v4-flash-sg) + * "SquareModelId" => (string) 广场模型ID (umodel-xxx) + * "Status" => (string) 状态: published(已发布)/unpublished(未发布) + * ] + * ] * "Manufacturer" => (string) 制造商 * "Id" => (string) 主键 * "Name" => (string) 名称 * "SimpleDescribe" => (string) 简要描述 * "Describe" => (string) 详细描述 * "Language" => (array) 语言 - * "MaxModelLen" => (integer) 模型长度 + * "MaxModelLen" => (integer) 模型长度,单位 token + * "MaxModelLenNew" => (integer) 模型长度,单位 K tokens + * "MaxInputTokens" => (integer) 最大输入token数 + * "MaxOutputTokens" => (integer) 最大输出token数 + * "ModelTypeMap" => (object) 模型类型映射[ + * "TextGeneration" => (boolean) 文生文模型,true 表示是文生文模型,下同 + * "ImageToImage" => (boolean) 图生图模型 + * "TextToImage" => (boolean) 文生图模型 + * "TextToVideo" => (boolean) 文生视频模型 + * "ImageToVideo" => (boolean) 图生视频模型 + * "Sensitive" => (boolean) 海外模型 + * "Inference" => (boolean) 微调模型 + * ] * "ModelType" => (string) 模型类型 + * "CoverUrl" => (string) 模型封面链接 * "HfUpdateTime" => (integer) HuggingFace 更新时间 * "CreateAt" => (integer) 创建时间 * "UpdateAt" => (integer) 更新时间 * "SupportedCapabilities" => (array) 模型能力 + * "Capabilities" => (object) 模型能力详细映射[ + * "ContextCaching" => (boolean) 是否支持上下文缓存 + * "BatchInference" => (boolean) 是否支持批量推理 + * "StructuredOutput" => (boolean) 是否支持结构化输出 + * "FunctionCall" => (boolean) 是否支持函数调用 + * "WebSearch" => (boolean) 是否支持联网搜索 + * "KnowledgeBase" => (boolean) 是否支持知识库 + * "Mcp" => (boolean) 是否支持MCP + * "Experience" => (boolean) 是否支持体验 + * ] + * "ExtraModelTags" => (array) 模型额外标签 + * "ApiProtocols" => (object) api协议映射[ + * "ChatCompletions" => (boolean) 是否支持chat协议 + * "Responses" => (boolean) 是否支持responses协议 + * "Gemini" => (boolean) 是否支持gemini协议 + * "Anthropic" => (boolean) 是否支持Anthropic协议 + * ] + * "InputModalities" => (array) 输入模态 + * "OutputModalities" => (array) 输出模态 * "Icon" => (string) 图标 * "Pricing" => (object) 定价策略[ * "Completion" => (number) 输出定价 @@ -779,20 +824,65 @@ public function listPaidOrders(ListPaidOrdersRequest $request = null) * "SquareModels" => (array) 广场模型[ * [ * "BatchSquareModelId" => (string) 关联的 batch 模型广场id + * "ModelCategory" => (string) 一级分类 + * "ModelSubCategories" => (string) 二级分类列表 * "IsHasBatch" => (boolean) 是否关联有可用 batch 模型 * "BatchName" => (string) 关联的 batch 模型名称 + * "IsHasInferenceRegions" => (boolean) 是否有关联的推理地域模型 + * "InferenceRegions" => (array) 推理地域模型列表[ + * [ + * "RegionCode" => (string) 地域代码: sg(新加坡)/us(美国)/hk(香港) + * "RegionName" => (string) 地域名称: 新加坡/美国/香港 + * "RegionNameEn" => (string) 地域名称(英文): Singapore/United States/Hong Kong + * "ModelId" => (string) 地域模型ID (例如: deepseek-v4-flash-sg) + * "SquareModelId" => (string) 广场模型ID (umodel-xxx) + * "Status" => (string) 状态: published(已发布)/unpublished(未发布) + * ] + * ] * "Manufacturer" => (string) 制造商 * "Id" => (string) 主键 * "Name" => (string) 名称 * "SimpleDescribe" => (string) 简要描述 * "Describe" => (string) 详细描述 * "Language" => (array) 语言 - * "MaxModelLen" => (integer) 模型长度 + * "MaxModelLen" => (integer) 模型长度,单位 token + * "MaxModelLenNew" => (integer) 模型长度,单位 K tokens + * "MaxInputTokens" => (integer) 最大输入token数 + * "MaxOutputTokens" => (integer) 最大输出token数 + * "ModelTypeMap" => (object) 模型类型映射[ + * "TextGeneration" => (boolean) 文生文模型,true 表示是文生文模型,下同 + * "ImageToImage" => (boolean) 图生图模型 + * "TextToImage" => (boolean) 文生图模型 + * "TextToVideo" => (boolean) 文生视频模型 + * "ImageToVideo" => (boolean) 图生视频模型 + * "Sensitive" => (boolean) 海外模型 + * "Inference" => (boolean) 微调模型 + * ] * "ModelType" => (string) 模型类型 + * "CoverUrl" => (string) 模型封面链接 * "HfUpdateTime" => (integer) HuggingFace 更新时间 * "CreateAt" => (integer) 创建时间 * "UpdateAt" => (integer) 更新时间 * "SupportedCapabilities" => (array) 模型能力 + * "Capabilities" => (object) 模型能力详细映射[ + * "ContextCaching" => (boolean) 是否支持上下文缓存 + * "BatchInference" => (boolean) 是否支持批量推理 + * "StructuredOutput" => (boolean) 是否支持结构化输出 + * "FunctionCall" => (boolean) 是否支持函数调用 + * "WebSearch" => (boolean) 是否支持联网搜索 + * "KnowledgeBase" => (boolean) 是否支持知识库 + * "Mcp" => (boolean) 是否支持MCP + * "Experience" => (boolean) 是否支持体验 + * ] + * "ExtraModelTags" => (array) 模型额外标签 + * "ApiProtocols" => (object) api协议映射[ + * "ChatCompletions" => (boolean) 是否支持chat协议 + * "Responses" => (boolean) 是否支持responses协议 + * "Gemini" => (boolean) 是否支持gemini协议 + * "Anthropic" => (boolean) 是否支持Anthropic协议 + * ] + * "InputModalities" => (array) 输入模态 + * "OutputModalities" => (array) 输出模态 * "Icon" => (string) 图标 * "Pricing" => (object) 定价策略[ * "Completion" => (number) 输出定价 @@ -850,6 +940,78 @@ public function listUFSquareModel(ListUFSquareModelRequest $request = null) * Outputs: * * $outputs = [ + * "ModalTypes" => (array) 模型类型筛选(一级/二级分类树)[ + * [ + * "Children" => (string) + * "Label" => (string) 显示标签 + * "LabelEn" => (string) 英文标签 + * "Value" => (string) 枚举值 + * ] + * ] + * "Manufacturers" => (array) 厂商选项[ + * [ + * "Children" => (string) + * "Label" => (string) 显示标签 + * "LabelEn" => (string) 英文标签 + * "Value" => (string) 枚举值 + * ] + * ] + * "MaxModelLens" => (array) 最大上下文长度选项[ + * [ + * "Children" => (string) + * "Label" => (string) 显示标签 + * "LabelEn" => (string) 英文标签 + * "Value" => (string) 枚举值 + * ] + * ] + * "Capabilities" => (array) 能力选项[ + * [ + * "Children" => (string) + * "Label" => (string) 显示标签 + * "LabelEn" => (string) 英文标签 + * "Value" => (string) 枚举值 + * ] + * ] + * "InputModalities" => (array) 输入模态选项[ + * [ + * "Children" => (string) + * "Label" => (string) 显示标签 + * "LabelEn" => (string) 英文标签 + * "Value" => (string) 枚举值 + * ] + * ] + * "OutputModalities" => (array) 输出模态选项[ + * [ + * "Children" => (string) + * "Label" => (string) 显示标签 + * "LabelEn" => (string) 英文标签 + * "Value" => (string) 枚举值 + * ] + * ] + * "ApiProtocols" => (array) API协议选项[ + * [ + * "Children" => (string) + * "Label" => (string) 显示标签 + * "LabelEn" => (string) 英文标签 + * "Value" => (string) 枚举值 + * ] + * ] + * "InferenceRegions" => (array) 推理地域选项[ + * [ + * "Children" => (string) + * "Label" => (string) 显示标签 + * "LabelEn" => (string) 英文标签 + * "Value" => (string) 枚举值 + * ] + * ] + * "IsComingOffline" => (array) 模型状态选项[ + * [ + * "Children" => (string) + * "Label" => (string) 显示标签 + * "LabelEn" => (string) 英文标签 + * "Value" => (string) 枚举值 + * ] + * ] * ] * * @return ListUFSquareModelFiltersAuthResponse