Hello there! I was wondering why there is a `serv...
# agents
a
Hello there! I was wondering why there is a
service_tier
param for the class initialisation in https://github.com/livekit/agents/blob/062b001baff46a3831941dd82ddd9c2e267c67d1/li[…]t-plugins/livekit-plugins-groq/livekit/plugins/groq/services.py (v1.2.8)... ..but with
livekit-plugins-groq==1.2.8
installed (
livekit/plugins/groq/version.py
shows
__version__ = "1.2.8"
),
services.py
contains this (no
service_tier
):
Copy code
class LLM(OpenAILLM):
    def __init__(
        self,
        *,
        model: str | LLMModels = "llama-3.3-70b-versatile",
        api_key: NotGivenOr[str] = NOT_GIVEN,
        user: NotGivenOr[str] = NOT_GIVEN,
        safety_identifier: NotGivenOr[str] = NOT_GIVEN,
        prompt_cache_key: NotGivenOr[str] = NOT_GIVEN,
        temperature: NotGivenOr[float] = NOT_GIVEN,
        top_p: NotGivenOr[float] = NOT_GIVEN,
        parallel_tool_calls: NotGivenOr[bool] = NOT_GIVEN,
        tool_choice: NotGivenOr[ToolChoice] = NOT_GIVEN,
        base_url: NotGivenOr[str] = "https://api.groq.com/openai/v1",
        reasoning_effort: NotGivenOr[ReasoningEffort] = NOT_GIVEN,
        client: openai.AsyncClient | None = None,
    ):
...so it expectedly throws a TypeError:
Copy code
return groq.LLM(**params, service_tier="flex")
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: LLM.__init__() got an unexpected keyword argument 'service_tier'
What am I missing here? Thanks!
j
can you share the output of
pip list | grep livekit
, you probably need to upgrade the livekit-agents and the openai plugin to the same version.
a
Copy code
╰─❯ pip list | grep livekit
livekit                                  1.0.13
livekit-agents                           1.2.8
livekit-api                              1.0.5
livekit-blingfire                        1.0.0
livekit-plugins-anthropic                1.2.8
livekit-plugins-cartesia                 1.2.8
livekit-plugins-deepgram                 1.2.8
livekit-plugins-elevenlabs               1.2.8
livekit-plugins-groq                     1.2.8
livekit-plugins-noise-cancellation       0.2.5
livekit-plugins-openai                   1.2.8
livekit-plugins-silero                   1.2.8
livekit-plugins-turn-detector            1.2.8
livekit-protocol                         1.0.6
@jolly-air-155
j
looks correct, maybe try to recreate the python env
a
I can reproduce this in remote deployments, where everything's built from scratch, so not sure - but I'll give it a try, @jolly-air-155
Nope... still the same 😕 Can you reproduce this or it works fine for you @jolly-air-155? (I'm on
Python 3.11.11 (main, Feb 12 2025, 15:06:01) [Clang 19.1.6 ] on darwin
)
The
openai
LLM class does inclue this param (screenshot below), though, but not `groq`'s.
j
oh the
service_tier
for groq plugin was just merged last week, it will be included in next release
a
oh, got it thanks for the swift reply, @jolly-air-155 🙏
j
1.2.9 just released, it should be included
🙌 1