arcade-core 3.3.1__py3-none-any.whl → 3.3.2__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.
arcade_core/catalog.py CHANGED
@@ -203,9 +203,18 @@ class ToolCatalog(BaseModel):
203
203
  tool_func: Callable,
204
204
  toolkit_or_name: str | Toolkit,
205
205
  module: ModuleType | None = None,
206
+ toolkit_version: str | None = None,
207
+ toolkit_description: str | None = None,
206
208
  ) -> None:
207
209
  """
208
210
  Add a function to the catalog as a tool.
211
+
212
+ Args:
213
+ tool_func: The function to add to the catalog.
214
+ toolkit_or_name: The toolkit or name of the toolkit.
215
+ module: The module to add the tool from.
216
+ toolkit_version: The version of the toolkit. Overrides the version of the toolkit if provided.
217
+ toolkit_description: The description of the toolkit. Overrides the description of the toolkit if provided.
209
218
  """
210
219
 
211
220
  input_model, output_model = create_func_models(tool_func)
@@ -213,6 +222,8 @@ class ToolCatalog(BaseModel):
213
222
  if isinstance(toolkit_or_name, Toolkit):
214
223
  toolkit = toolkit_or_name
215
224
  toolkit_name = toolkit.name
225
+ toolkit_version = toolkit_version or toolkit.version
226
+ toolkit_description = toolkit_description or toolkit.description
216
227
  elif isinstance(toolkit_or_name, str):
217
228
  toolkit = None
218
229
  toolkit_name = toolkit_or_name
@@ -223,8 +234,8 @@ class ToolCatalog(BaseModel):
223
234
  definition = ToolCatalog.create_tool_definition(
224
235
  tool_func,
225
236
  toolkit_name,
226
- toolkit.version if toolkit else None,
227
- toolkit.description if toolkit else None,
237
+ toolkit_version,
238
+ toolkit_description,
228
239
  )
229
240
 
230
241
  fully_qualified_name = definition.get_fully_qualified_name()
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: arcade-core
3
- Version: 3.3.1
3
+ Version: 3.3.2
4
4
  Summary: Arcade Core - Core library for Arcade platform
5
5
  Author-email: Arcade <dev@arcade.dev>
6
6
  License: MIT
@@ -1,7 +1,7 @@
1
1
  arcade_core/__init__.py,sha256=1heu3AROAjpistehPzY2H-2nkj_IjQEh-vVlVOCRF1E,88
2
2
  arcade_core/annotations.py,sha256=Nst6aejLWXlpTu7GwzWETu1gQCG1XVAUR_qcFbNvyRc,198
3
3
  arcade_core/auth.py,sha256=On9sJPOxvHjKBxgKC1yqp7oijF6KYBsG6fG8KUw-9OY,5882
4
- arcade_core/catalog.py,sha256=vAXAvdalLq1YymHw46Yq-mUiVb-DTFsup4599E9GUCw,42069
4
+ arcade_core/catalog.py,sha256=n1HtwpaDYdP2K2zqyxJlPbPoEfR3gCkqqzJNDdFUoRc,42679
5
5
  arcade_core/config.py,sha256=e98XQAkYySGW9T_yrJg54BB8Wuq06GPVHp7xqe2d1vU,572
6
6
  arcade_core/config_model.py,sha256=78BR6Ch9BDuG4ddWGfpuEKqWcb1fyOF6kxiF4qLFogM,4481
7
7
  arcade_core/constants.py,sha256=wakdklI7TyJ0agq9n-Cmb2lbVa95D0oUaMGm30eiv9Y,375
@@ -23,6 +23,6 @@ arcade_core/usage/constants.py,sha256=1FQIhkFFMZUhU-H4A7GvMb7KQ3qLFrNAZb2-LEvSF3
23
23
  arcade_core/usage/identity.py,sha256=2dP1iusI9pE_GrPlz3VXEdz51R5JlNo9_-OXbe6vn7I,6716
24
24
  arcade_core/usage/usage_service.py,sha256=xzWWSEktm58liiNYugBHRactSru8V5foriHcsoH0j1A,3407
25
25
  arcade_core/usage/utils.py,sha256=FqBOmlhwT68cbnpI5Vx9ZW6vLRYPVg4FJ0GaMEp8qEM,398
26
- arcade_core-3.3.1.dist-info/METADATA,sha256=4-Lc2GDL-C3cq4zM2l1bUIoZH7D8HZ-WCWQJn2GC9Mw,2383
27
- arcade_core-3.3.1.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
28
- arcade_core-3.3.1.dist-info/RECORD,,
26
+ arcade_core-3.3.2.dist-info/METADATA,sha256=yn7yDI5j9Ud6kj8S4ffI58UzkgXOYWlE0roic8YjlYk,2383
27
+ arcade_core-3.3.2.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
28
+ arcade_core-3.3.2.dist-info/RECORD,,