private IndexedTensor evaluateDecoder(Tensor input, Tensor encoderMask, Tensor encoderOutput) {
        var inputs = Map.of(
                decoderInputIdsName, input,
                decoderAttentionMaskName, encoderMask,  // yes, encoder's attention mask
                decoderEncoderHiddenStateName, encoderOutput
        );
        var output = decoder.evaluate(inputs, decoderOutputName);
        if (!(output instanceof IndexedTensor indexedTensor)) {
            throw new IllegalArgumentException("Output of decoder model is not an 'IndexedTensor'");
        }
        return indexedTensor;
    }
Generates text by evaluating an encoder model to encode the prompt, and
repeatedly evaluating a decoding model to generate tokens until some
stopping criteria has been met.

@param prompt  the prompt to generate text from
@param options options for text generation
@return a text generated from the prompt
model-integration/src/main/java/ai/vespa/llm/clients/OnnxEncoderDecoder.java