WordPress\AiClient\Providers\Models\Contracts
ModelInterface{}
Interface for AI models.
Models represent specific AI models from providers and define their capabilities, configuration, and execution methods.
Хуков нет.
Использование
$ModelInterface = new ModelInterface(); // use class methods
Методы
- public getConfig()
- public metadata()
- public providerMetadata()
- public setConfig(ModelConfig $config)
Список изменений
| С версии 0.1.0 | Введена. |
Код ModelInterface{} ModelInterface{} WP 7.0
interface ModelInterface
{
/**
* Gets model metadata.
*
* @since 0.1.0
*
* @return ModelMetadata Model metadata.
*/
public function metadata(): ModelMetadata;
/**
* Returns the metadata for the model's provider.
*
* @since 0.1.0
*
* @return ProviderMetadata The provider metadata.
*/
public function providerMetadata(): ProviderMetadata;
/**
* Sets model configuration.
*
* @since 0.1.0
*
* @param ModelConfig $config Model configuration.
* @return void
*/
public function setConfig(ModelConfig $config): void;
/**
* Gets model configuration.
*
* @since 0.1.0
*
* @return ModelConfig Current model configuration.
*/
public function getConfig(): ModelConfig;
}