UNPKG

@llumiverse/drivers

Version:

LLM driver implementations. Currently supported are: openai, huggingface, bedrock, replicate.

20 lines 703 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.TestErrorCompletionStream = void 0; const utils_js_1 = require("./utils.js"); class TestErrorCompletionStream { segments; options; completion; constructor(segments, options) { this.segments = segments; this.options = options; } async *[Symbol.asyncIterator]() { yield "Started TestError. Next we will thrown an error.\n"; (0, utils_js_1.sleep)(1000); (0, utils_js_1.throwError)("Testing stream completion error.", this.segments); } } exports.TestErrorCompletionStream = TestErrorCompletionStream; //# sourceMappingURL=TestErrorCompletionStream.js.map