diff --git a/.changeset/wet-crabs-rhyme.md b/.changeset/wet-crabs-rhyme.md new file mode 100644 index 000000000..a30d70d8a --- /dev/null +++ b/.changeset/wet-crabs-rhyme.md @@ -0,0 +1,5 @@ +--- +"livekit-plugins-rag": patch +--- + +rag: add missing logger file diff --git a/.github/workflows/check-types.yml b/.github/workflows/check-types.yml index aa38c7bef..aa560e70c 100644 --- a/.github/workflows/check-types.yml +++ b/.github/workflows/check-types.yml @@ -39,6 +39,7 @@ jobs: ./livekit-plugins/livekit-plugins-silero \ ./livekit-plugins/livekit-plugins-elevenlabs \ ./livekit-plugins/livekit-plugins-cartesia \ + ./livekit-plugins/livekit-plugins-rag \ ./livekit-plugins/livekit-plugins-azure - name: Install stub packages @@ -65,4 +66,5 @@ jobs: -p livekit.plugins.silero \ -p livekit.plugins.elevenlabs \ -p livekit.plugins.cartesia \ + -p livekit.plugins.rag \ -p livekit.plugins.azure diff --git a/livekit-plugins/livekit-plugins-rag/livekit/plugins/rag/chunking.py b/livekit-plugins/livekit-plugins-rag/livekit/plugins/rag/chunking.py index 2a2be3402..f866ec6b9 100644 --- a/livekit-plugins/livekit-plugins-rag/livekit/plugins/rag/chunking.py +++ b/livekit-plugins/livekit-plugins-rag/livekit/plugins/rag/chunking.py @@ -26,9 +26,9 @@ def __init__( def chunk(self, *, text: str) -> list[str]: chunks = [] - buf_words = [] + buf_words: list[str] = [] for paragraph in self._paragraph_tokenizer(text): - last_buf_words = [] + last_buf_words: list[str] = [] for sentence in self._sentence_tokenizer.tokenize(text=paragraph): for word in self._word_tokenizer.tokenize(text=sentence): diff --git a/livekit-plugins/livekit-plugins-rag/livekit/plugins/rag/log.py b/livekit-plugins/livekit-plugins-rag/livekit/plugins/rag/log.py new file mode 100644 index 000000000..2ffcf32bb --- /dev/null +++ b/livekit-plugins/livekit-plugins-rag/livekit/plugins/rag/log.py @@ -0,0 +1,3 @@ +import logging + +logger = logging.getLogger("livekit.plugins.rag")