stream method
Streams the output of invoking the Runnable on the given input
.
Implementation
@override
Stream<LLMResult> stream(
final PromptValue input, {
final LLMOptions? options,
}) {
final promptChars = input.toString().split('');
return Stream.fromIterable(promptChars).map(
(final item) => LLMResult(
id: 'fake-echo',
output: item,
finishReason: FinishReason.unspecified,
metadata: const {},
usage: const LanguageModelUsage(),
streaming: true,
),
);
}