Skip to content

Commit

Permalink
add typedef
Browse files Browse the repository at this point in the history
  • Loading branch information
matt-bernstein committed Nov 26, 2024
1 parent 7131627 commit 9b78da0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions adala/runtimes/_litellm.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import asyncio
import logging
from collections import defaultdict
from typing import Any, Dict, List, Optional, Type, Union, Literal, TypedDict, Iterable
from typing import Any, Dict, List, Optional, Type, Union, Literal, TypedDict, Iterable, Generator
from functools import cached_property
from enum import Enum
import litellm
Expand Down Expand Up @@ -651,7 +651,7 @@ def add_to_current_chunk(
return chunk

# Build chunks by iterating through parsed template parts
def build_chunks(parsed: Iterable[TemplateChunks]):
def build_chunks(parsed: Iterable[TemplateChunks]) -> Generator[MessageChunk, None, None]:
current_chunk: Optional[MessageChunk] = None

for part in parsed:
Expand Down

0 comments on commit 9b78da0

Please sign in to comment.