接口 ModelProvider
public interface ModelProvider
Service Provider Interface for model adapters discovered from extension modules.
-
方法概要
修饰符和类型方法说明Creates a model for the full model id.default Modelcreate(String modelId, ModelCreationContext context) Creates a model for the full model id using a provider-neutral context.Provider identifier, for exampleopenai.booleanReturns whether this provider can create a model for the full model id, for exampleopenai:gpt-4o.default booleansupports(String modelId, ModelCreationContext context) Returns whether this provider can create a model for the full model id and context.
-
方法详细资料
-
providerId
String providerId()Provider identifier, for exampleopenai. -
supports
Returns whether this provider can create a model for the full model id, for exampleopenai:gpt-4o. -
supports
Returns whether this provider can create a model for the full model id and context. -
create
Creates a model for the full model id. -
create
Creates a model for the full model id using a provider-neutral context.
-