livekit-plugins-google 1.1.2__py3-none-any.whl → 1.1.4__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- livekit/plugins/google/llm.py +9 -0
- livekit/plugins/google/utils.py +7 -1
- livekit/plugins/google/version.py +1 -1
- {livekit_plugins_google-1.1.2.dist-info → livekit_plugins_google-1.1.4.dist-info}/METADATA +2 -2
- {livekit_plugins_google-1.1.2.dist-info → livekit_plugins_google-1.1.4.dist-info}/RECORD +6 -6
- {livekit_plugins_google-1.1.2.dist-info → livekit_plugins_google-1.1.4.dist-info}/WHEEL +0 -0
livekit/plugins/google/llm.py
CHANGED
@@ -59,6 +59,7 @@ class _LLMOptions:
|
|
59
59
|
presence_penalty: NotGivenOr[float]
|
60
60
|
frequency_penalty: NotGivenOr[float]
|
61
61
|
thinking_config: NotGivenOr[types.ThinkingConfigOrDict]
|
62
|
+
automatic_function_calling_config: NotGivenOr[types.AutomaticFunctionCallingConfigOrDict]
|
62
63
|
gemini_tools: NotGivenOr[list[_LLMTool]]
|
63
64
|
http_options: NotGivenOr[types.HttpOptions]
|
64
65
|
|
@@ -80,6 +81,9 @@ class LLM(llm.LLM):
|
|
80
81
|
frequency_penalty: NotGivenOr[float] = NOT_GIVEN,
|
81
82
|
tool_choice: NotGivenOr[ToolChoice] = NOT_GIVEN,
|
82
83
|
thinking_config: NotGivenOr[types.ThinkingConfigOrDict] = NOT_GIVEN,
|
84
|
+
automatic_function_calling_config: NotGivenOr[
|
85
|
+
types.AutomaticFunctionCallingConfigOrDict
|
86
|
+
] = NOT_GIVEN,
|
83
87
|
gemini_tools: NotGivenOr[list[_LLMTool]] = NOT_GIVEN,
|
84
88
|
http_options: NotGivenOr[types.HttpOptions] = NOT_GIVEN,
|
85
89
|
) -> None:
|
@@ -107,6 +111,7 @@ class LLM(llm.LLM):
|
|
107
111
|
frequency_penalty (float, optional): Penalizes the model for repeating words. Defaults to None.
|
108
112
|
tool_choice (ToolChoice, optional): Specifies whether to use tools during response generation. Defaults to "auto".
|
109
113
|
thinking_config (ThinkingConfigOrDict, optional): The thinking configuration for response generation. Defaults to None.
|
114
|
+
automatic_function_calling_config (AutomaticFunctionCallingConfigOrDict, optional): The automatic function calling configuration for response generation. Defaults to None.
|
110
115
|
gemini_tools (list[LLMTool], optional): The Gemini-specific tools to use for the session.
|
111
116
|
http_options (HttpOptions, optional): The HTTP options to use for the session.
|
112
117
|
""" # noqa: E501
|
@@ -168,6 +173,7 @@ class LLM(llm.LLM):
|
|
168
173
|
presence_penalty=presence_penalty,
|
169
174
|
frequency_penalty=frequency_penalty,
|
170
175
|
thinking_config=thinking_config,
|
176
|
+
automatic_function_calling_config=automatic_function_calling_config,
|
171
177
|
gemini_tools=gemini_tools,
|
172
178
|
http_options=http_options,
|
173
179
|
)
|
@@ -261,6 +267,9 @@ class LLM(llm.LLM):
|
|
261
267
|
if is_given(self._opts.thinking_config):
|
262
268
|
extra["thinking_config"] = self._opts.thinking_config
|
263
269
|
|
270
|
+
if is_given(self._opts.automatic_function_calling_config):
|
271
|
+
extra["automatic_function_calling"] = self._opts.automatic_function_calling_config
|
272
|
+
|
264
273
|
gemini_tools = gemini_tools if is_given(gemini_tools) else self._opts.gemini_tools
|
265
274
|
|
266
275
|
return LLMStream(
|
livekit/plugins/google/utils.py
CHANGED
@@ -28,7 +28,13 @@ def to_fnc_ctx(fncs: list[FunctionTool | RawFunctionTool]) -> list[types.Functio
|
|
28
28
|
for fnc in fncs:
|
29
29
|
if is_raw_function_tool(fnc):
|
30
30
|
info = get_raw_function_info(fnc)
|
31
|
-
tools.append(
|
31
|
+
tools.append(
|
32
|
+
types.FunctionDeclaration(
|
33
|
+
name=info.name,
|
34
|
+
description=info.raw_schema.get("description", ""),
|
35
|
+
parameters_json_schema=info.raw_schema.get("parameters", {}),
|
36
|
+
)
|
37
|
+
)
|
32
38
|
|
33
39
|
elif is_function_tool(fnc):
|
34
40
|
tools.append(_build_gemini_fnc(fnc))
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.4
|
2
2
|
Name: livekit-plugins-google
|
3
|
-
Version: 1.1.
|
3
|
+
Version: 1.1.4
|
4
4
|
Summary: Agent Framework plugin for services from Google Cloud
|
5
5
|
Project-URL: Documentation, https://docs.livekit.io
|
6
6
|
Project-URL: Website, https://livekit.io/
|
@@ -22,7 +22,7 @@ Requires-Dist: google-auth<3,>=2
|
|
22
22
|
Requires-Dist: google-cloud-speech<3,>=2
|
23
23
|
Requires-Dist: google-cloud-texttospeech<3,>=2.27
|
24
24
|
Requires-Dist: google-genai>=v1.21.1
|
25
|
-
Requires-Dist: livekit-agents>=1.1.
|
25
|
+
Requires-Dist: livekit-agents>=1.1.4
|
26
26
|
Description-Content-Type: text/markdown
|
27
27
|
|
28
28
|
# Google AI plugin for LiveKit Agents
|
@@ -1,17 +1,17 @@
|
|
1
1
|
livekit/plugins/google/__init__.py,sha256=XIyZ-iFnRBpaLtOJgVwojlB-a8GjdDugVFcjBpMEww8,1412
|
2
|
-
livekit/plugins/google/llm.py,sha256=
|
2
|
+
livekit/plugins/google/llm.py,sha256=M_276SG-ywReHna818_8y6kkLNwns6E1SJe6DOyao_Y,18786
|
3
3
|
livekit/plugins/google/log.py,sha256=GI3YWN5YzrafnUccljzPRS_ZALkMNk1i21IRnTl2vNA,69
|
4
4
|
livekit/plugins/google/models.py,sha256=hOpfbN_qdQ1ZTpCN9m9dvG2eb6WgQ3KE3WRpIeeM_T0,1569
|
5
5
|
livekit/plugins/google/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
6
6
|
livekit/plugins/google/stt.py,sha256=ssDMH5U1vQOLA44XMlovYWIR4UqVtZSge3YFN-zZ7Iw,24696
|
7
7
|
livekit/plugins/google/tools.py,sha256=tD5HVDHO5JfUF029Cx3axHMJec0Gxalkl7s1FDgxLzI,259
|
8
8
|
livekit/plugins/google/tts.py,sha256=YTfce55MWNJyDH4k8U1O2giOcrtccTs8vrkiW9GuBR0,15541
|
9
|
-
livekit/plugins/google/utils.py,sha256
|
10
|
-
livekit/plugins/google/version.py,sha256=
|
9
|
+
livekit/plugins/google/utils.py,sha256=6iihkKx76DDtLiHOoTU2ZXqzupBRY_gN3njpnwdmeqY,8829
|
10
|
+
livekit/plugins/google/version.py,sha256=B5kiBdHIDDcwA9hDZC77YLcp8cT8rcpNKzBQ-kJeiYY,600
|
11
11
|
livekit/plugins/google/beta/__init__.py,sha256=5PnoG3Ux24bjzMSzmTeSVljE9EINivGcbWUEV6egGnM,216
|
12
12
|
livekit/plugins/google/beta/realtime/__init__.py,sha256=_fW2NMN22F-hnQ4xAJ_g5lPbR7CvM_xXzSWlUQY-E-U,188
|
13
13
|
livekit/plugins/google/beta/realtime/api_proto.py,sha256=NfE7xr2N3JOu7gVfWbAmDcEhs8vuZgMRu5vpScPJzsg,776
|
14
14
|
livekit/plugins/google/beta/realtime/realtime_api.py,sha256=tlAsTFsumqOavC9JT2SuQi_3eGYygZ3bbS-nEM7ea8Q,46293
|
15
|
-
livekit_plugins_google-1.1.
|
16
|
-
livekit_plugins_google-1.1.
|
17
|
-
livekit_plugins_google-1.1.
|
15
|
+
livekit_plugins_google-1.1.4.dist-info/METADATA,sha256=bAtuj6ppByLE5tevgb31naAcKJAiGLo6wAr4tnfnODE,1907
|
16
|
+
livekit_plugins_google-1.1.4.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
17
|
+
livekit_plugins_google-1.1.4.dist-info/RECORD,,
|
File without changes
|