mirror of
https://github.com/trustgraph-ai/trustgraph.git
synced 2026-07-01 09:29:38 +02:00
Remove provider stream sentinel assertions
This commit is contained in:
parent
3070ce2b47
commit
bfb5494552
7 changed files with 30 additions and 10 deletions
|
|
@ -164,7 +164,7 @@ export function makeAzureOpenAIProvider(config: AzureOpenAIProcessorConfig): Llm
|
|||
return Stream.unfold<"pulling" | "done", LlmChunk, TextCompletionRuntimeError, never>(
|
||||
"pulling",
|
||||
(state) => {
|
||||
if (state === "done") return Effect.void as Effect.Effect<undefined>;
|
||||
if (state === "done") return Effect.as(Effect.void, undefined);
|
||||
|
||||
return Effect.gen(function* () {
|
||||
while (true) {
|
||||
|
|
|
|||
|
|
@ -142,7 +142,7 @@ export function makeClaudeProvider(config: ClaudeProcessorConfig): LlmProvider {
|
|||
return Stream.unfold<"pulling" | "done", LlmChunk, TextCompletionRuntimeError, never>(
|
||||
"pulling",
|
||||
(state) => {
|
||||
if (state === "done") return Effect.void as Effect.Effect<undefined>;
|
||||
if (state === "done") return Effect.as(Effect.void, undefined);
|
||||
|
||||
return Effect.gen(function* () {
|
||||
while (true) {
|
||||
|
|
|
|||
|
|
@ -142,7 +142,7 @@ export function makeMistralProvider(config: MistralProcessorConfig): LlmProvider
|
|||
return Stream.unfold<"pulling" | "done", LlmChunk, TextCompletionRuntimeError, never>(
|
||||
"pulling",
|
||||
(state) => {
|
||||
if (state === "done") return Effect.void as Effect.Effect<undefined>;
|
||||
if (state === "done") return Effect.as(Effect.void, undefined);
|
||||
|
||||
return Effect.gen(function* () {
|
||||
while (true) {
|
||||
|
|
|
|||
|
|
@ -120,7 +120,7 @@ export function makeOllamaProvider(config: OllamaProcessorConfig): LlmProvider {
|
|||
return Stream.unfold<"pulling" | "done", LlmChunk, TextCompletionRuntimeError, never>(
|
||||
"pulling",
|
||||
(state) => {
|
||||
if (state === "done") return Effect.void as Effect.Effect<undefined>;
|
||||
if (state === "done") return Effect.as(Effect.void, undefined);
|
||||
|
||||
return Effect.gen(function* () {
|
||||
while (true) {
|
||||
|
|
|
|||
|
|
@ -155,7 +155,7 @@ export function makeOpenAICompatibleProvider(
|
|||
return Stream.unfold<"pulling" | "done", LlmChunk, TextCompletionRuntimeError, never>(
|
||||
"pulling",
|
||||
(state) => {
|
||||
if (state === "done") return Effect.void as Effect.Effect<undefined>;
|
||||
if (state === "done") return Effect.as(Effect.void, undefined);
|
||||
|
||||
return Effect.gen(function* () {
|
||||
while (true) {
|
||||
|
|
|
|||
|
|
@ -146,7 +146,7 @@ export function makeOpenAIProvider(config: OpenAIProcessorConfig): LlmProvider {
|
|||
return Stream.unfold<"pulling" | "done", LlmChunk, TextCompletionRuntimeError, never>(
|
||||
"pulling",
|
||||
(state) => {
|
||||
if (state === "done") return Effect.void as Effect.Effect<undefined>;
|
||||
if (state === "done") return Effect.as(Effect.void, undefined);
|
||||
|
||||
return Effect.gen(function* () {
|
||||
while (true) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue