14 Commits

Author SHA1 Message Date
wenngong
354dca8035
[Feature]: Add global silent param for ConversableAgent (#3244)
* feat: add is_silent param

* modify param name

* param doc

* fix: silent only overwrite agent own

* fix: change _is_silent to static method and receive verbose print

* fix test failure

* add kwargs for ConversableAgent subclass

---------

Co-authored-by: gongwn1 <gongwn1@lenovo.com>
Co-authored-by: Li Jiang <bnujli@gmail.com>
Co-authored-by: Umer Mansoor <umermk3@gmail.com>
2024-08-02 14:39:42 +00:00
Qingyun Wu
6d4cf406f9
Filter models with tags instead of model name (#2912)
* identify model with tags instead of model name

* models

* model to tag

* add more model name

* format

* Update test/agentchat/test_function_call.py

Co-authored-by: Chi Wang <wang.chi@microsoft.com>

* Update test/agentchat/test_function_call.py

Co-authored-by: Chi Wang <wang.chi@microsoft.com>

* Update test/agentchat/test_tool_calls.py

Co-authored-by: Chi Wang <wang.chi@microsoft.com>

* Update test/agentchat/test_tool_calls.py

Co-authored-by: Chi Wang <wang.chi@microsoft.com>

* remove uncessary tags

* use gpt-4 as tag

* model to tag

* add tag for teachable agent test

---------

Co-authored-by: Chi Wang <wang.chi@microsoft.com>
Co-authored-by: AutoGen-Hub <flaml20201204@gmail.com>
2024-06-14 15:58:17 +00:00
Li Jiang
42b27b9a9d
Add isort (#2265)
* Add isort

* Apply isort on py files

* Fix circular import

* Fix format for notebooks

* Fix format

---------

Co-authored-by: Chi Wang <wang.chi@microsoft.com>
2024-04-05 02:26:06 +00:00
Gunnar Kudrjavets
b8ceb866e6
Add shebang functionality to tests (#1784)
Tests that contain `if __name__ == "__main__":` now have a shebang line
and execute permission.
2024-02-29 01:11:08 +00:00
Eric Zhu
609ba7c649
Code executors (#1405)
* code executor

* test

* revert to main conversable agent

* prepare for pr

* kernel

* run open ai tests only when it's out of draft status

* update workflow file

* revert workflow changes

* ipython executor

* check kernel installed; fix tests

* fix tests

* fix tests

* update system prompt

* Update notebook, more tests

* notebook

* raise instead of return None

* allow user provided code executor.

* fixing types

* wip

* refactoring

* polishing

* fixed failing tests

* resolved merge conflict

* fixing failing test

* wip

* local command line executor and embedded ipython executor

* revert notebook

* fix format

* fix merged error

* fix lmm test

* fix lmm test

* move warning

* name and description should be part of the agent protocol, reset is not as it is only used for ConversableAgent; removing accidentally commited file

* version for dependency

* Update autogen/agentchat/conversable_agent.py

Co-authored-by: Jack Gerrits <jackgerrits@users.noreply.github.com>

* ordering of protocol

* description

* fix tests

* make ipython executor dependency optional

* update document optional dependencies

* Remove exclude from Agent protocol

* Make ConversableAgent consistent with Agent

* fix tests

* add doc string

* add doc string

* fix notebook

* fix interface

* merge and update agents

* disable config usage in reply function

* description field setter

* customize system message update

* update doc

---------

Co-authored-by: Davor Runje <davor@airt.ai>
Co-authored-by: Jack Gerrits <jackgerrits@users.noreply.github.com>
Co-authored-by: Aaron <aaronlaptop12@hotmail.com>
Co-authored-by: Chi Wang <wang.chi@microsoft.com>
2024-02-10 04:52:16 +00:00
Qingyun Wu
2a2e466932
Using a more robust "reflection_with_llm" summary method (#1575)
* summary exception

* badrequest error

* test

* skip reason

* error

* address func call in summary

* reflection_with_llm enhancement and tests

* remove old

* update notebook

* update notebook
2024-02-07 17:17:05 +00:00
afourney
8d1d07308a
Removed "Tool Call Id" from main content string. (#1471)
* Removed Tool Call Id from main content string.

* Fixed tests.
2024-01-30 21:41:27 +00:00
Chi Wang
563b1bb00b
remove filter_dict (#1284) 2024-01-16 17:24:17 +00:00
Eric Zhu
e784f2b9b6
[Core] Update documentation for function call compatibility (#1237)
* #1206

* doc

* add test for azure openai

* prior to

* filter for versions

* up to

* literal type

* update doc

* update doc

* update model list

* Update autogen/agentchat/conversable_agent.py

Co-authored-by: Chi Wang <wang.chi@microsoft.com>

* Update test/agentchat/test_tool_calls.py

Co-authored-by: Chi Wang <wang.chi@microsoft.com>

* Update test_tool_calls.py

---------

Co-authored-by: Chi Wang <wang.chi@microsoft.com>
2024-01-16 03:04:27 +00:00
Brian Finney
d1c1548888
remove name from tool response (#1263)
* remove name from tool response

* fix tool response tests

* fix output string
2024-01-16 02:54:56 +00:00
Brian Finney
63a35e79f8
run sync and async in async (#1242)
* run sync and async in async

* test for async multitool call

* uncomment notebook

---------

Co-authored-by: Chi Wang <wang.chi@microsoft.com>
Co-authored-by: Davor Runje <davor@airt.ai>
2024-01-15 02:34:27 +00:00
Chi Wang
f9c16d26a3
Fix bug in async group chat with func/tool call (#1243)
* test func/tool call in group chat w/ >2 agents

* filter_dict -> exclude

* modify comment

* add last message to groupchat

* typecheck allow_repeat_speaker
2024-01-14 18:24:05 +00:00
Eric Zhu
d6a3304f55
[Core] Compatibility with function call style API (Azure OpenAI and Gemini) (#1227)
* #1206

* doc

* add test for azure openai

* prior to

* filter for versions

* up to

* literal type

* update doc
2024-01-13 20:48:46 +00:00
Brian Finney
40dbf31a92
[Core] [Tool Call] adjust conversable agent to support tool_calls (#974)
* adjust conversable and compressible agents to support tool_calls

* split out tools into their own reply def

* copilot typo

* address review comments

* revert compressible_agent and token_count_utils calls

* cleanup terminate check and remove unnecessary code

* doc search and update

* return function/tool calls as interrupted when user provides a reply to a tool call request

* fix tool name reference

* fix formatting

* fix initiate receiving a dict

* missed changed roled

* ignore incoming role, more similiar to existing code

* consistency

* redundant to_dict

* fix todo comment

* uneeded change

* handle dict reply in groupchat

* Fix generate_tool_call_calls_reply_comment

* change method annotation for register_for_llm from functions to tools

* typo autogen/agentchat/conversable_agent.py

Co-authored-by: Chi Wang <wang.chi@microsoft.com>

* add deprecation comments for function_call

* tweak doc strings

* switch to ToolFunction type

* update the return to

* fix generate_init_message return type

* Revert "fix generate_init_message return type"

This reverts commit 645ba8b76afa06f160223ecdac6f3dc1822fd249.

* undo force init to dict

* fix notebooks and groupchat tool handling

* fix type

* use get for key error

* fix teachable to pull content from dict

* change single message tool response

* cleanup unnessary changes

* little better tool response concatenation

* update tools tests

* add skip openai check to tools tests

* fix nits

* move func name normalization to oai_reply and assert configured names

* fix whitespace

* remove extra normalize

* tool name is now normalized in the generate_reply function, so will not be incorrect when sent to receive

* validate function names in init and expand comments for validation methods

* fix dict comprehension

* Dummy llm config for unit tests

* handle tool_calls set to None

* fix tool name reference

* method operates on responses not calls

---------

Co-authored-by: Yiran Wu <32823396+kevin666aa@users.noreply.github.com>
Co-authored-by: Chi Wang <wang.chi@microsoft.com>
Co-authored-by: Eric Zhu <ekzhu@users.noreply.github.com>
2024-01-06 17:55:25 +00:00