waldiez 0.1.9__tar.gz → 0.1.11__tar.gz

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.

Potentially problematic release.


This version of waldiez might be problematic. Click here for more details.

Files changed (93) hide show
  1. {waldiez-0.1.9 → waldiez-0.1.11}/PKG-INFO +37 -22
  2. {waldiez-0.1.9 → waldiez-0.1.11}/README.md +15 -1
  3. {waldiez-0.1.9 → waldiez-0.1.11}/pyproject.toml +23 -23
  4. waldiez-0.1.11/waldiez/__init__.py +31 -0
  5. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/_version.py +1 -1
  6. waldiez-0.1.11/waldiez/conflict_checker.py +23 -0
  7. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/exporting/agents/agent.py +7 -0
  8. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/exporting/agents/rag_user/chroma_utils.py +6 -4
  9. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/exporting/agents/rag_user/rag_user.py +9 -0
  10. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/exporting/skills/__init__.py +36 -1
  11. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/agents/agent/agent_data.py +11 -0
  12. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/waldiez.py +7 -0
  13. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/runner.py +31 -6
  14. waldiez-0.1.9/waldiez/__init__.py +0 -13
  15. {waldiez-0.1.9 → waldiez-0.1.11}/.gitignore +0 -0
  16. {waldiez-0.1.9 → waldiez-0.1.11}/LICENSE +0 -0
  17. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/__main__.py +0 -0
  18. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/cli.py +0 -0
  19. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/exporter.py +0 -0
  20. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/exporting/__init__.py +0 -0
  21. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/exporting/agents/__init__.py +0 -0
  22. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/exporting/agents/agent_skills.py +0 -0
  23. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/exporting/agents/code_execution.py +0 -0
  24. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/exporting/agents/group_manager.py +0 -0
  25. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/exporting/agents/llm_config.py +0 -0
  26. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/exporting/agents/rag_user/__init__.py +0 -0
  27. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/exporting/agents/rag_user/mongo_utils.py +0 -0
  28. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/exporting/agents/rag_user/pgvector_utils.py +0 -0
  29. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/exporting/agents/rag_user/qdrant_utils.py +0 -0
  30. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/exporting/agents/rag_user/vector_db.py +0 -0
  31. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/exporting/agents/teachability.py +0 -0
  32. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/exporting/agents/termination_message.py +0 -0
  33. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/exporting/chats/__init__.py +0 -0
  34. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/exporting/chats/chats.py +0 -0
  35. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/exporting/chats/helpers.py +0 -0
  36. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/exporting/chats/nested.py +0 -0
  37. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/exporting/flow/__init__.py +0 -0
  38. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/exporting/flow/def_main.py +0 -0
  39. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/exporting/flow/flow.py +0 -0
  40. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/exporting/models/__init__.py +0 -0
  41. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/exporting/utils/__init__.py +0 -0
  42. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/exporting/utils/comments.py +0 -0
  43. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/exporting/utils/importing.py +0 -0
  44. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/exporting/utils/logging_utils.py +0 -0
  45. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/exporting/utils/method_utils.py +0 -0
  46. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/exporting/utils/naming.py +0 -0
  47. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/exporting/utils/object_string.py +0 -0
  48. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/exporting/utils/path_check.py +0 -0
  49. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/io/__init__.py +0 -0
  50. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/__init__.py +0 -0
  51. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/agents/__init__.py +0 -0
  52. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/agents/agent/__init__.py +0 -0
  53. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/agents/agent/agent.py +0 -0
  54. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/agents/agent/code_execution.py +0 -0
  55. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/agents/agent/linked_skill.py +0 -0
  56. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/agents/agent/nested_chat.py +0 -0
  57. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/agents/agent/teachability.py +0 -0
  58. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/agents/agent/termination_message.py +0 -0
  59. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/agents/agents.py +0 -0
  60. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/agents/assistant/__init__.py +0 -0
  61. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/agents/assistant/assistant.py +0 -0
  62. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/agents/assistant/assistant_data.py +0 -0
  63. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/agents/group_manager/__init__.py +0 -0
  64. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/agents/group_manager/group_manager.py +0 -0
  65. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/agents/group_manager/group_manager_data.py +0 -0
  66. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/agents/group_manager/speakers.py +0 -0
  67. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/agents/rag_user/__init__.py +0 -0
  68. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/agents/rag_user/rag_user.py +0 -0
  69. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/agents/rag_user/rag_user_data.py +0 -0
  70. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/agents/rag_user/retrieve_config.py +0 -0
  71. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/agents/rag_user/vector_db_config.py +0 -0
  72. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/agents/user_proxy/__init__.py +0 -0
  73. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/agents/user_proxy/user_proxy.py +0 -0
  74. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/agents/user_proxy/user_proxy_data.py +0 -0
  75. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/chat/__init__.py +0 -0
  76. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/chat/chat.py +0 -0
  77. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/chat/chat_data.py +0 -0
  78. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/chat/chat_message.py +0 -0
  79. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/chat/chat_nested.py +0 -0
  80. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/chat/chat_summary.py +0 -0
  81. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/common/__init__.py +0 -0
  82. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/common/base.py +0 -0
  83. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/common/method_utils.py +0 -0
  84. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/flow/__init__.py +0 -0
  85. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/flow/flow.py +0 -0
  86. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/flow/flow_data.py +0 -0
  87. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/model/__init__.py +0 -0
  88. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/model/model.py +0 -0
  89. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/model/model_data.py +0 -0
  90. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/skill/__init__.py +0 -0
  91. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/skill/skill.py +0 -0
  92. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/models/skill/skill_data.py +0 -0
  93. {waldiez-0.1.9 → waldiez-0.1.11}/waldiez/py.typed +0 -0
@@ -1,10 +1,10 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: waldiez
3
- Version: 0.1.9
3
+ Version: 0.1.11
4
4
  Summary: waldiez
5
5
  Project-URL: homepage, https://waldiez.github.io/waldiez/
6
6
  Project-URL: repository, https://github.com/waldiez/waldiez.git
7
- Author-email: Panagiotis Kasnesis <pkasnesis@thingenious.io>, Lazaros Toumanidis <laztoum@protonmail.com>
7
+ Author-email: Panagiotis Kasnesis <pkasnesis@thingenious.io>, Lazaros Toumanidis <laztoum@protonmail.com>, Stella Ioannidou <stella@humancentered.gr>
8
8
  Classifier: Development Status :: 3 - Alpha
9
9
  Classifier: Intended Audience :: Developers
10
10
  Classifier: Intended Audience :: Science/Research
@@ -16,29 +16,30 @@ Classifier: Programming Language :: Python :: 3.10
16
16
  Classifier: Programming Language :: Python :: 3.11
17
17
  Classifier: Programming Language :: Python :: 3.12
18
18
  Requires-Python: <3.13,>=3.10
19
- Requires-Dist: ag2==0.3.2
19
+ Requires-Dist: ag2==0.4.1
20
20
  Requires-Dist: jupytext
21
21
  Provides-Extra: ag2-extras
22
- Requires-Dist: ag2[anthropic]==0.3.2; extra == 'ag2-extras'
23
- Requires-Dist: ag2[bedrock]==0.3.2; extra == 'ag2-extras'
24
- Requires-Dist: ag2[gemini]==0.3.2; extra == 'ag2-extras'
25
- Requires-Dist: ag2[groq]==0.3.2; extra == 'ag2-extras'
26
- Requires-Dist: ag2[mistral]==0.3.2; extra == 'ag2-extras'
27
- Requires-Dist: ag2[retrievechat-mongodb]==0.3.2; extra == 'ag2-extras'
28
- Requires-Dist: ag2[retrievechat-pgvector]==0.3.2; extra == 'ag2-extras'
29
- Requires-Dist: ag2[retrievechat-qdrant]==0.3.2; extra == 'ag2-extras'
30
- Requires-Dist: ag2[retrievechat]==0.3.2; extra == 'ag2-extras'
31
- Requires-Dist: ag2[together]==0.3.2; extra == 'ag2-extras'
32
- Requires-Dist: ag2[websurfer]==0.3.2; extra == 'ag2-extras'
33
- Requires-Dist: chromadb==0.5.3; extra == 'ag2-extras'
22
+ Requires-Dist: ag2[anthropic]==0.4.1; extra == 'ag2-extras'
23
+ Requires-Dist: ag2[bedrock]==0.4.1; extra == 'ag2-extras'
24
+ Requires-Dist: ag2[captainagent]==0.4.1; extra == 'ag2-extras'
25
+ Requires-Dist: ag2[gemini]==0.4.1; extra == 'ag2-extras'
26
+ Requires-Dist: ag2[groq]==0.4.1; extra == 'ag2-extras'
27
+ Requires-Dist: ag2[lmm]==0.4.1; extra == 'ag2-extras'
28
+ Requires-Dist: ag2[mistral]==0.4.1; extra == 'ag2-extras'
29
+ Requires-Dist: ag2[retrievechat-mongodb]==0.4.1; extra == 'ag2-extras'
30
+ Requires-Dist: ag2[retrievechat-pgvector]==0.4.1; extra == 'ag2-extras'
31
+ Requires-Dist: ag2[retrievechat-qdrant]==0.4.1; extra == 'ag2-extras'
32
+ Requires-Dist: ag2[retrievechat]==0.4.1; extra == 'ag2-extras'
33
+ Requires-Dist: ag2[together]==0.4.1; extra == 'ag2-extras'
34
+ Requires-Dist: ag2[websurfer]==0.4.1; extra == 'ag2-extras'
34
35
  Requires-Dist: fastembed==0.4.2; extra == 'ag2-extras'
35
- Requires-Dist: pgvector>=0.2.5; extra == 'ag2-extras'
36
- Requires-Dist: psycopg[binary]>=3.1.18; extra == 'ag2-extras'
36
+ Requires-Dist: pgvector>=0.3.6; extra == 'ag2-extras'
37
+ Requires-Dist: psycopg[binary]>=3.2.3; extra == 'ag2-extras'
37
38
  Requires-Dist: pymongo==4.10.1; extra == 'ag2-extras'
38
39
  Requires-Dist: qdrant-client==1.12.1; extra == 'ag2-extras'
39
40
  Provides-Extra: dev
40
41
  Requires-Dist: autoflake==2.3.1; extra == 'dev'
41
- Requires-Dist: bandit==1.7.10; extra == 'dev'
42
+ Requires-Dist: bandit==1.8.0; extra == 'dev'
42
43
  Requires-Dist: black[jupyter]==24.10.0; extra == 'dev'
43
44
  Requires-Dist: flake8==7.1.1; extra == 'dev'
44
45
  Requires-Dist: isort==5.13.2; extra == 'dev'
@@ -47,15 +48,15 @@ Requires-Dist: pre-commit==4.0.1; extra == 'dev'
47
48
  Requires-Dist: pydocstyle==6.3.0; extra == 'dev'
48
49
  Requires-Dist: pylint==3.3.1; extra == 'dev'
49
50
  Requires-Dist: python-dotenv==1.0.1; extra == 'dev'
50
- Requires-Dist: ruff==0.7.4; extra == 'dev'
51
- Requires-Dist: types-pyyaml==6.0.12; extra == 'dev'
51
+ Requires-Dist: ruff==0.8.1; extra == 'dev'
52
+ Requires-Dist: types-pyyaml==6.0.12.20240917; extra == 'dev'
52
53
  Requires-Dist: yamllint==1.35.1; extra == 'dev'
53
54
  Provides-Extra: docs
54
55
  Requires-Dist: mdx-include==1.4.2; extra == 'docs'
55
56
  Requires-Dist: mdx-truly-sane-lists==1.3; extra == 'docs'
56
57
  Requires-Dist: mkdocs-jupyter==0.25.1; extra == 'docs'
57
58
  Requires-Dist: mkdocs-macros-plugin==1.3.7; extra == 'docs'
58
- Requires-Dist: mkdocs-material==9.5.45; extra == 'docs'
59
+ Requires-Dist: mkdocs-material==9.5.46; extra == 'docs'
59
60
  Requires-Dist: mkdocs-minify-html-plugin==0.2.3; extra == 'docs'
60
61
  Requires-Dist: mkdocs==1.6.1; extra == 'docs'
61
62
  Requires-Dist: mkdocstrings-python==1.12.2; extra == 'docs'
@@ -71,7 +72,7 @@ Description-Content-Type: text/markdown
71
72
 
72
73
  # Waldiez
73
74
 
74
- ![CI Build](https://github.com/waldiez/waldiez/actions/workflows/main.yaml/badge.svg) [![Coverage Status](https://coveralls.io/repos/github/waldiez/waldiez/badge.svg)](https://coveralls.io/github/waldiez/waldiez) [![PyPI version](https://badge.fury.io/waldiez/waldiez.svg)](https://badge.fury.io/py/waldiez)
75
+ ![CI Build](https://github.com/waldiez/waldiez/actions/workflows/main.yaml/badge.svg) [![Coverage Status](https://coveralls.io/repos/github/waldiez/waldiez/badge.svg)](https://coveralls.io/github/waldiez/waldiez) [![PyPI version](https://badge.fury.io/py/waldiez.svg?icon=si%3Apython)](https://badge.fury.io/py/waldiez)
75
76
 
76
77
  Translate a Waldiez flow:
77
78
 
@@ -236,6 +237,20 @@ with WaldiezIOStream.set_default(io_stream):
236
237
  - [juptytext](https://github.com/mwouts/jupytext)
237
238
  - [pydantic](https://github.com/pydantic/pydantic)
238
239
 
240
+ ## Known Conflicts
241
+
242
+ - **autogen-agentchat**: This package conflicts with `ag2`. Ensure that `autogen-agentchat` is uninstalled before installing `waldiez`. If you have already installed `autogen-agentchat`, you can uninstall it with the following command:
243
+
244
+ ```shell
245
+ pip uninstall autogen-agentchat -y
246
+ ```
247
+
248
+ If already installed waldiez you might need to reinstall it after uninstalling `autogen-agentchat`:
249
+
250
+ ```shell
251
+ pip install --force --no-cache waldiez
252
+ ```
253
+
239
254
  ## License
240
255
 
241
256
  This project is licensed under the MIT License - see the [LICENSE](https://github.com/waldiez/waldiez/blob/main/LICENSE) file for details.
@@ -1,6 +1,6 @@
1
1
  # Waldiez
2
2
 
3
- ![CI Build](https://github.com/waldiez/waldiez/actions/workflows/main.yaml/badge.svg) [![Coverage Status](https://coveralls.io/repos/github/waldiez/waldiez/badge.svg)](https://coveralls.io/github/waldiez/waldiez) [![PyPI version](https://badge.fury.io/waldiez/waldiez.svg)](https://badge.fury.io/py/waldiez)
3
+ ![CI Build](https://github.com/waldiez/waldiez/actions/workflows/main.yaml/badge.svg) [![Coverage Status](https://coveralls.io/repos/github/waldiez/waldiez/badge.svg)](https://coveralls.io/github/waldiez/waldiez) [![PyPI version](https://badge.fury.io/py/waldiez.svg?icon=si%3Apython)](https://badge.fury.io/py/waldiez)
4
4
 
5
5
  Translate a Waldiez flow:
6
6
 
@@ -165,6 +165,20 @@ with WaldiezIOStream.set_default(io_stream):
165
165
  - [juptytext](https://github.com/mwouts/jupytext)
166
166
  - [pydantic](https://github.com/pydantic/pydantic)
167
167
 
168
+ ## Known Conflicts
169
+
170
+ - **autogen-agentchat**: This package conflicts with `ag2`. Ensure that `autogen-agentchat` is uninstalled before installing `waldiez`. If you have already installed `autogen-agentchat`, you can uninstall it with the following command:
171
+
172
+ ```shell
173
+ pip uninstall autogen-agentchat -y
174
+ ```
175
+
176
+ If already installed waldiez you might need to reinstall it after uninstalling `autogen-agentchat`:
177
+
178
+ ```shell
179
+ pip install --force --no-cache waldiez
180
+ ```
181
+
168
182
  ## License
169
183
 
170
184
  This project is licensed under the MIT License - see the [LICENSE](https://github.com/waldiez/waldiez/blob/main/LICENSE) file for details.
@@ -4,6 +4,7 @@ description = 'waldiez'
4
4
  authors = [
5
5
  { name = 'Panagiotis Kasnesis', email = 'pkasnesis@thingenious.io' },
6
6
  { name= 'Lazaros Toumanidis', email= 'laztoum@protonmail.com' },
7
+ { name = 'Stella Ioannidou', email = 'stella@humancentered.gr'}
7
8
  ]
8
9
  readme = "README.md"
9
10
  requires-python = '>=3.10,<3.13'
@@ -22,7 +23,7 @@ classifiers = [
22
23
  ]
23
24
  dependencies = [
24
25
  "jupytext",
25
- "ag2==0.3.2"
26
+ "ag2==0.4.1"
26
27
  ]
27
28
 
28
29
  [project.urls]
@@ -40,7 +41,7 @@ exclude = [ "**/example.py" ]
40
41
  [project.optional-dependencies]
41
42
  dev = [
42
43
  'autoflake==2.3.1',
43
- 'bandit==1.7.10',
44
+ 'bandit==1.8.0',
44
45
  'black[jupyter]==24.10.0',
45
46
  'flake8==7.1.1',
46
47
  'isort==5.13.2',
@@ -49,27 +50,28 @@ dev = [
49
50
  'pydocstyle==6.3.0',
50
51
  'pylint==3.3.1',
51
52
  'python-dotenv==1.0.1',
52
- 'ruff==0.7.4',
53
- 'types-PyYAML==6.0.12',
53
+ 'ruff==0.8.1',
54
+ 'types-PyYAML==6.0.12.20240917',
54
55
  'yamllint==1.35.1',
55
56
  ]
56
57
  ag2_extras =[
57
- 'chromadb==0.5.3',
58
58
  'fastembed==0.4.2',
59
- 'pgvector>=0.2.5',
60
- 'psycopg[binary]>=3.1.18',
61
- 'ag2[retrievechat]==0.3.2',
62
- 'ag2[retrievechat-pgvector]==0.3.2',
63
- 'ag2[retrievechat-mongodb]==0.3.2',
64
- 'ag2[retrievechat-qdrant]==0.3.2',
65
- 'ag2[gemini]==0.3.2',
66
- 'ag2[together]==0.3.2',
67
- 'ag2[anthropic]==0.3.2',
68
- 'ag2[mistral]==0.3.2',
69
- 'ag2[groq]==0.3.2',
70
- 'ag2[bedrock]==0.3.2',
71
- 'ag2[websurfer]==0.3.2',
72
- 'ag2[together]==0.3.2',
59
+ 'pgvector>=0.3.6',
60
+ 'psycopg[binary]>=3.2.3',
61
+ 'ag2[captainagent]==0.4.1',
62
+ 'ag2[retrievechat]==0.4.1',
63
+ 'ag2[retrievechat-pgvector]==0.4.1',
64
+ 'ag2[retrievechat-mongodb]==0.4.1',
65
+ 'ag2[retrievechat-qdrant]==0.4.1',
66
+ 'ag2[gemini]==0.4.1',
67
+ 'ag2[together]==0.4.1',
68
+ 'ag2[anthropic]==0.4.1',
69
+ 'ag2[lmm]==0.4.1',
70
+ 'ag2[mistral]==0.4.1',
71
+ 'ag2[groq]==0.4.1',
72
+ 'ag2[bedrock]==0.4.1',
73
+ 'ag2[websurfer]==0.4.1',
74
+ 'ag2[together]==0.4.1',
73
75
  'pymongo==4.10.1',
74
76
  'qdrant-client==1.12.1',
75
77
  ]
@@ -87,7 +89,7 @@ docs = [
87
89
  'mkdocs==1.6.1',
88
90
  'mkdocs-jupyter==0.25.1',
89
91
  'mkdocs-macros-plugin==1.3.7',
90
- 'mkdocs-material==9.5.45',
92
+ 'mkdocs-material==9.5.46',
91
93
  'mkdocs-minify-html-plugin==0.2.3',
92
94
  'mkdocstrings[crystal,python]==0.27.0',
93
95
  'mkdocstrings-python==1.12.2'
@@ -146,8 +148,6 @@ warn_unused_ignores = true
146
148
  plugins = [
147
149
  'pydantic.mypy'
148
150
  ]
149
- # 'mypy_zope:plugin'
150
- # ]
151
151
  exclude = [
152
152
  '.venv',
153
153
  '.local',
@@ -200,7 +200,7 @@ unsafe-load-any-extension="no"
200
200
 
201
201
  [tool.pylint.messages_control]
202
202
  enable=["c-extension-no-member"]
203
- [tool.pylint.fotmat]
203
+ [tool.pylint.format]
204
204
  max-line-length=80
205
205
  [tool.pylint.similarities]
206
206
  ignore-imports="yes"
@@ -0,0 +1,31 @@
1
+ """Waldiez package."""
2
+
3
+ from ._version import __version__
4
+ from .conflict_checker import check_conflicts
5
+ from .exporter import WaldiezExporter
6
+ from .models import Waldiez
7
+ from .runner import WaldiezRunner
8
+
9
+ # flag to check if ag2 and autogen-agentchat
10
+ # are installed at the same time
11
+ __WALDIEZ_CHECKED_FOR_CONFLICTS = False
12
+
13
+
14
+ def _check_conflicts_once() -> None:
15
+ """Check for conflicts once."""
16
+ # pylint: disable=global-statement
17
+ global __WALDIEZ_CHECKED_FOR_CONFLICTS
18
+ if __WALDIEZ_CHECKED_FOR_CONFLICTS is False:
19
+ check_conflicts()
20
+ __WALDIEZ_CHECKED_FOR_CONFLICTS = True
21
+
22
+
23
+ _check_conflicts_once()
24
+
25
+
26
+ __all__ = [
27
+ "Waldiez",
28
+ "WaldiezExporter",
29
+ "WaldiezRunner",
30
+ "__version__",
31
+ ]
@@ -1,3 +1,3 @@
1
1
  """Version information for Waldiez."""
2
2
 
3
- __version__ = "0.1.9"
3
+ __version__ = "0.1.11"
@@ -0,0 +1,23 @@
1
+ """Check for conflicts with 'autogen-agentchat' package."""
2
+
3
+ # pylint: disable=line-too-long
4
+
5
+ import sys
6
+ from importlib.metadata import PackageNotFoundError, version
7
+
8
+
9
+ # fmt: off
10
+ def check_conflicts() -> None: # pragma: no cover
11
+ """Check for conflicts with 'autogen-agentchat' package."""
12
+ try:
13
+ version("autogen-agentchat")
14
+ print(
15
+ "Conflict detected: 'autogen-agentchat' is installed, which conflicts with 'ag2'.\n"
16
+ "Please uninstall 'autogen-agentchat': pip uninstall -y autogen-agentchat \n"
17
+ "And install 'ag2' (or 'waldiez') again: pip install --force ag2"
18
+ )
19
+ sys.exit(1)
20
+ except PackageNotFoundError:
21
+ pass
22
+
23
+ # fmt: on
@@ -26,6 +26,8 @@ def get_agent_class_name(agent: WaldiezAgent) -> str:
26
26
  str
27
27
  The agent class name.
28
28
  """
29
+ if agent.data.is_multimodal:
30
+ return "MultimodalConversableAgent"
29
31
  if agent.agent_type == "assistant":
30
32
  return "AssistantAgent"
31
33
  if agent.agent_type == "user":
@@ -63,6 +65,11 @@ def get_agent_imports(agent_class: str) -> Set[str]:
63
65
  "from autogen.agentchat.contrib.retrieve_user_proxy_agent "
64
66
  "import RetrieveUserProxyAgent"
65
67
  )
68
+ elif agent_class == "MultimodalConversableAgent":
69
+ imports.add(
70
+ "from autogen.agentchat.contrib.multimodal_conversable_agent "
71
+ "import MultimodalConversableAgent"
72
+ )
66
73
  return imports
67
74
 
68
75
 
@@ -32,7 +32,10 @@ def _get_chroma_client_string(agent: WaldiezRagUser) -> Tuple[str, str]:
32
32
  # SyntaxError: (unicode error) 'unicodeescape' codec can't decode bytes
33
33
  # in position 2-3: truncated \UXXXXXXXX escape
34
34
  local_path = Path(agent.retrieve_config.db_config.local_storage_path)
35
- client_str += f'PersistentClient(path=r"{local_path}", settings=Settings(anonymized_telemetry=False))'
35
+ client_str += (
36
+ f'PersistentClient(path=r"{local_path}", '
37
+ "settings=Settings(anonymized_telemetry=False))"
38
+ )
36
39
  else:
37
40
  client_str += "Client(Settings(anonymized_telemetry=False))"
38
41
  return client_str, to_import
@@ -105,7 +108,7 @@ def get_chroma_db_args(
105
108
  if to_import_embedding:
106
109
  to_import.add(to_import_embedding)
107
110
  kwarg_string = (
108
- f" client={client_str},\n"
111
+ f" client={agent_name}_client,\n"
109
112
  f" embedding_function={embedding_function_arg},\n"
110
113
  )
111
114
  # The RAG example:
@@ -115,11 +118,10 @@ def get_chroma_db_args(
115
118
  # https://github.com/microsoft/autogen/issues/3551#issuecomment-2366930994
116
119
  # manually initializing the collection before running the flow,
117
120
  # might be a workaround.
118
- content_before = ""
121
+ content_before = f"{agent_name}_client = {client_str}\n"
119
122
  collection_name = agent.retrieve_config.collection_name
120
123
  get_or_create = agent.retrieve_config.get_or_create
121
124
  if collection_name:
122
- content_before = f"{agent_name}_client = {client_str}\n"
123
125
  if get_or_create:
124
126
  content_before += (
125
127
  f"{agent_name}_client.get_or_create_collection("
@@ -69,6 +69,15 @@ def get_rag_user_retrieve_config_str(
69
69
  args_content = "\n".join(before_vector_db)
70
70
  # add the vector_db arg
71
71
  args_content += f',\n "vector_db": {vector_db_arg},\n'
72
+ # we should not need to include the client, but let's do it
73
+ # to avoid later issues (with telemetry or other client settings)
74
+ # https://github.com/ag2ai/ag2/blob/main/autogen/agentchat/\
75
+ # contrib/retrieve_user_proxy_agent.py#L265-L266
76
+ if (
77
+ f"{agent_name}_client" in before_the_args
78
+ and agent.retrieve_config.vector_db == "chroma"
79
+ ):
80
+ args_content += f' "client": {agent_name}_client,\n'
72
81
  args_content += closing_arg
73
82
  return before_the_args, args_content, imports
74
83
 
@@ -69,6 +69,32 @@ def get_agent_skill_registration(
69
69
  return content
70
70
 
71
71
 
72
+ def _write_skill_secrets(
73
+ skill: WaldiezSkill,
74
+ skill_name: str,
75
+ output_dir: Path,
76
+ ) -> None:
77
+ """Write the skill secrets to a file.
78
+
79
+ Parameters
80
+ ----------
81
+ skill : WaldiezSkill
82
+ The skill.
83
+ skill_name : str
84
+ The name of the skill.
85
+ output_dir : Path
86
+ The output directory to save the secrets to.
87
+ """
88
+ if not skill.secrets:
89
+ return
90
+ secrets_file = output_dir / f"{skill_name}_secrets.py"
91
+ with secrets_file.open("w", encoding="utf-8") as f:
92
+ f.write('"""Secrets for the skill."""\n')
93
+ f.write("from os import environ\n\n")
94
+ for key, value in skill.secrets.items():
95
+ f.write(f'environ["{key}"] = "{value}"\n')
96
+
97
+
72
98
  def export_skills(
73
99
  skills: List[WaldiezSkill],
74
100
  skill_names: Dict[str, str],
@@ -116,12 +142,21 @@ def export_skills(
116
142
  skill_secrets: Set[Tuple[str, str]] = set()
117
143
  for skill in skills:
118
144
  skill_name = skill_names[skill.id]
119
- skill_imports.add(f"from {skill_name} import {skill_name}")
120
145
  skill_secrets.update(skill.secrets.items())
121
146
  if not output_dir:
147
+ skill_imports.add(f"from {skill_name} import {skill_name}")
122
148
  continue
123
149
  if not isinstance(output_dir, Path):
124
150
  output_dir = Path(output_dir)
151
+ if not skill.secrets:
152
+ skill_imports.add(f"from {skill_name} import {skill_name}")
153
+ else:
154
+ # have the secrets before the skill
155
+ skill_imports.add(
156
+ f"import {skill_name}_secrets # noqa\n"
157
+ f"from {skill_name} import {skill_name}"
158
+ )
159
+ _write_skill_secrets(skill, skill_name, output_dir)
125
160
  skill_file = output_dir / f"{skill_name}.py"
126
161
  with skill_file.open("w", encoding="utf-8") as f:
127
162
  f.write(skill.content)
@@ -40,6 +40,8 @@ class WaldiezAgentData(WaldiezBase):
40
40
  A list of skills (id and executor) to register.
41
41
  nested_chats : List[WaldiezAgentNestedChat]
42
42
  A list of nested chats (triggered_by, messages), to register.
43
+ is_multimodal: bool
44
+ A flag to indicate if the agent is multimodal.
43
45
  """
44
46
 
45
47
  model_config = ConfigDict(
@@ -149,3 +151,12 @@ class WaldiezAgentData(WaldiezBase):
149
151
  alias="nestedChats",
150
152
  ),
151
153
  ]
154
+ is_multimodal: Annotated[
155
+ bool,
156
+ Field(
157
+ False,
158
+ title="Is multimodal",
159
+ description="A flag to indicate if the agent is multimodal.",
160
+ alias="isMultimodal",
161
+ ),
162
+ ] = False
@@ -145,6 +145,11 @@ class Waldiez:
145
145
  """Check if the flow has RAG agents."""
146
146
  return any(agent.agent_type == "rag_user" for agent in self.agents)
147
147
 
148
+ @property
149
+ def has_multimodal_agents(self) -> bool:
150
+ """Check if the flow has multimodal agents."""
151
+ return any(agent.data.is_multimodal for agent in self.agents)
152
+
148
153
  @property
149
154
  def chats(self) -> List[Tuple[WaldiezChat, WaldiezAgent, WaldiezAgent]]:
150
155
  """Get the chats."""
@@ -214,6 +219,8 @@ class Waldiez:
214
219
  requirements.add(f"ag2[retrievechat]=={autogen_version}")
215
220
  else:
216
221
  requirements.add(f"ag2=={autogen_version}")
222
+ if self.has_multimodal_agents:
223
+ requirements.add(f"ag2[lmm]=={autogen_version}")
217
224
  # ref: https://github.com/ag2ai/ag2/blob/main/setup.py
218
225
  models_with_additional_requirements = [
219
226
  "together",
@@ -235,10 +235,31 @@ class WaldiezRunner:
235
235
  os.environ[var_key] = var_value
236
236
 
237
237
  def _do_run(
238
- self, output_path: Optional[Union[str, Path]]
238
+ self,
239
+ output_path: Optional[Union[str, Path]],
240
+ uploads_root: Optional[Union[str, Path]],
239
241
  ) -> Union["ChatResult", List["ChatResult"]]:
240
- """Run the Waldiez workflow."""
242
+ """Run the Waldiez workflow.
243
+
244
+ Parameters
245
+ ----------
246
+ output_path : Optional[Union[str, Path]]
247
+ The output path.
248
+ uploads_root : Optional[Union[str, Path]]
249
+ The runtime uploads root.
250
+
251
+ Returns
252
+ -------
253
+ Union[ChatResult, List[ChatResult]]
254
+ The result(s) of the chat(s).
255
+ """
241
256
  results: Union["ChatResult", List["ChatResult"]] = []
257
+ if not uploads_root:
258
+ uploads_root = Path(tempfile.mkdtemp())
259
+ else:
260
+ uploads_root = Path(uploads_root)
261
+ if not uploads_root.exists():
262
+ uploads_root.mkdir(parents=True)
242
263
  temp_dir = Path(tempfile.mkdtemp())
243
264
  file_name = "flow.py" if not output_path else Path(output_path).name
244
265
  if file_name.endswith((".json", ".waldiez")):
@@ -270,6 +291,7 @@ class WaldiezRunner:
270
291
  def _run(
271
292
  self,
272
293
  output_path: Optional[Union[str, Path]],
294
+ uploads_root: Optional[Union[str, Path]],
273
295
  ) -> Union["ChatResult", List["ChatResult"]]:
274
296
  self._install_requirements()
275
297
  token = self._stream.get()
@@ -278,13 +300,14 @@ class WaldiezRunner:
278
300
  from .io import WaldiezIOStream
279
301
 
280
302
  with WaldiezIOStream.set_default(token):
281
- return self._do_run(output_path)
282
- return self._do_run(output_path)
303
+ return self._do_run(output_path, uploads_root)
304
+ return self._do_run(output_path, uploads_root)
283
305
 
284
306
  def run(
285
307
  self,
286
308
  stream: Optional["WaldiezIOStream"] = None,
287
309
  output_path: Optional[Union[str, Path]] = None,
310
+ uploads_root: Optional[Union[str, Path]] = None,
288
311
  ) -> Union["ChatResult", List["ChatResult"]]:
289
312
  """Run the Waldiez workflow.
290
313
 
@@ -294,11 +317,13 @@ class WaldiezRunner:
294
317
  The stream to use, by default None.
295
318
  output_path : Optional[Union[str, Path]], optional
296
319
  The output path, by default None.
320
+ uploads_root : Optional[Union[str, Path]], optional
321
+ The uploads root, to get user-uploaded files, by default None.
297
322
 
298
323
  Returns
299
324
  -------
300
325
  Union[ChatResult, List[ChatResult]]
301
- The result of the chat(s).
326
+ The result(s) of the chat(s).
302
327
 
303
328
  Raises
304
329
  ------
@@ -311,7 +336,7 @@ class WaldiezRunner:
311
336
  token = self._stream.set(stream)
312
337
  file_path = output_path or self._file_path
313
338
  try:
314
- return self._run(file_path)
339
+ return self._run(file_path, uploads_root)
315
340
  finally:
316
341
  self._running = False
317
342
  self._stream.reset(token)
@@ -1,13 +0,0 @@
1
- """Waldiez package."""
2
-
3
- from ._version import __version__
4
- from .exporter import WaldiezExporter
5
- from .models import Waldiez
6
- from .runner import WaldiezRunner
7
-
8
- __all__ = [
9
- "Waldiez",
10
- "WaldiezExporter",
11
- "WaldiezRunner",
12
- "__version__",
13
- ]
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes