CoreFiles by mySites.guru
TextGenerationOperationModelInterface.php26 lines, 789 bytes, from wordpress-7.0.zip
Raw History Compare with 6.9.11
md5
473063077a3bd4e4d9f1a77f827aae37
sha1
156b890612d35db85c5eaff6a8ec0b29f0fa75c9
sha256
c2e6ff48d08bd8de488e68eaded0bed9f03c193363c5ede985d669fb092f3a54
<?php

declare (strict_types=1);
namespace WordPress\AiClient\Providers\Models\TextGeneration\Contracts;

use WordPress\AiClient\Messages\DTO\Message;
use WordPress\AiClient\Operations\DTO\GenerativeAiOperation;
/**
 * Interface for models that support asynchronous text generation operations.
 *
 * Provides methods for initiating long-running text generation tasks.
 *
 * @since 0.1.0
 */
interface TextGenerationOperationModelInterface
{
    /**
     * Creates a text generation operation.
     *
     * @since 0.1.0
     *
     * @param list<Message> $prompt Array of messages containing the text generation prompt.
     * @return GenerativeAiOperation The initiated text generation operation.
     */
    public function generateTextOperation(array $prompt): GenerativeAiOperation;
}

The same content is in 40 releases, WordPress 7.0-beta1 to 7.2-beta5. See them all, or every version of this file.