Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add a verbose flag to let gpt assistant print more log #717

Merged
merged 5 commits into from
Dec 4, 2023

Conversation

IANTHEREAL
Copy link
Collaborator

@IANTHEREAL IANTHEREAL commented Nov 19, 2023

Why are these changes needed?

Let GPT Assistant be able to print input/output of function call using a verbose flag

Related issue number

Checks

@codecov-commenter
Copy link

codecov-commenter commented Nov 19, 2023

Codecov Report

Attention: 4 lines in your changes are missing coverage. Please review.

Comparison is base (55b9d0b) 26.65% compared to head (2dbac21) 38.12%.

Files Patch % Lines
autogen/agentchat/contrib/gpt_assistant_agent.py 0.00% 2 Missing ⚠️
autogen/agentchat/conversable_agent.py 33.33% 1 Missing and 1 partial ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##             main     #717       +/-   ##
===========================================
+ Coverage   26.65%   38.12%   +11.46%     
===========================================
  Files          28       28               
  Lines        3722     3725        +3     
  Branches      846      847        +1     
===========================================
+ Hits          992     1420      +428     
+ Misses       2658     2182      -476     
- Partials       72      123       +51     
Flag Coverage Δ
unittests 38.06% <20.00%> (+11.46%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@rickyloynd-microsoft
Copy link
Contributor

@gagb fyi

@sonichi sonichi requested review from gagb, AaronWard, yiranwu0 and a team November 19, 2023 17:57
@sonichi sonichi added function/tool suggestion and execution of function/tool call openai-assistant Issues related to assistants from OpenAI labels Nov 19, 2023
@sonichi
Copy link
Contributor

sonichi commented Nov 19, 2023

Looks good. Please make sure @kevin666aa approves before merging.

@gagb
Copy link
Collaborator

gagb commented Nov 20, 2023

@IANTHEREAL should we first get this merged and base this on it? https://github.com/microsoft/autogen/pull/665/files I worry that there are some overlaps -- it also added kwargs and added some additional logging.

@IANTHEREAL
Copy link
Collaborator Author

@IANTHEREAL should we first get this merged and base this on it? https://github.com/microsoft/autogen/pull/665/files I worry that there are some overlaps -- it also added kwargs and added some additional logging.

@gagb no problem

@sonichi
Copy link
Contributor

sonichi commented Dec 4, 2023

The user seems more urgent about this PR request: #715. I borrowed the kwargs parameter from #665, keeping the necessary parameters simple. Additionally, compared to logging output, I prefer to use a unified format in the ConversableAgent to output complete function execution information when needed by the user. This kind of output is more understandable and convenient for tracking.

@gagb @sonichi @kevin666aa PTAL

@sidhujag FYI.
@gagb @kevin666aa @LeoLjl @qingyun-wu PTAL.

@sonichi sonichi requested a review from LeoLjl December 4, 2023 14:16
Copy link
Contributor

@qingyun-wu qingyun-wu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@qingyun-wu qingyun-wu added this pull request to the merge queue Dec 4, 2023
Merged via the queue into microsoft:main with commit 26f6e0c Dec 4, 2023
80 of 84 checks passed
LinxinS97 added a commit that referenced this pull request Dec 4, 2023
@IANTHEREAL IANTHEREAL deleted the agent_function_print branch December 5, 2023 00:57
github-merge-queue bot pushed a commit that referenced this pull request Dec 5, 2023
…d to #846 (#865)

* try to fix blog

* modify blog

* fix test error in #717; fix blog typo in installation; update blogs with output examples.

* pre-commit

* pre-commit

* Update website/blog/2023-11-26-Agent-AutoBuild/index.mdx

Co-authored-by: Qingyun Wu <qingyun.wu@psu.edu>

* add future work

* fix grammar

---------

Co-authored-by: Jieyu Zhang <jieyuz2@cs.washington.edu>
Co-authored-by: Qingyun Wu <qingyun.wu@psu.edu>
github-merge-queue bot pushed a commit that referenced this pull request Dec 8, 2023
* try to fix blog

* modify blog

* fix test error in #717; fix blog typo in installation; update blogs with output examples.

* pre-commit

* pre-commit

* Update website/blog/2023-11-26-Agent-AutoBuild/index.mdx

Co-authored-by: Qingyun Wu <qingyun.wu@psu.edu>

* add future work

* fix grammar

* update agent_builder

---------

Co-authored-by: Jieyu Zhang <jieyuz2@cs.washington.edu>
Co-authored-by: Qingyun Wu <qingyun.wu@psu.edu>
github-merge-queue bot pushed a commit that referenced this pull request Dec 18, 2023
…tion (#944)

* try to fix blog

* modify blog

* fix test error in #717; fix blog typo in installation; update blogs with output examples.

* pre-commit

* pre-commit

* Update website/blog/2023-11-26-Agent-AutoBuild/index.mdx

Co-authored-by: Qingyun Wu <qingyun.wu@psu.edu>

* add future work

* fix grammar

* update agent_builder

* solve #941; add detailed debug info; support json string config

* pre-commit

* solve #954

* pre-commit

---------

Co-authored-by: Jieyu Zhang <jieyuz2@cs.washington.edu>
Co-authored-by: Qingyun Wu <qingyun.wu@psu.edu>
rlam3 pushed a commit to rlam3/autogen that referenced this pull request Dec 19, 2023
rlam3 pushed a commit to rlam3/autogen that referenced this pull request Dec 19, 2023
…d to microsoft#846 (microsoft#865)

* try to fix blog

* modify blog

* fix test error in microsoft#717; fix blog typo in installation; update blogs with output examples.

* pre-commit

* pre-commit

* Update website/blog/2023-11-26-Agent-AutoBuild/index.mdx

Co-authored-by: Qingyun Wu <qingyun.wu@psu.edu>

* add future work

* fix grammar

---------

Co-authored-by: Jieyu Zhang <jieyuz2@cs.washington.edu>
Co-authored-by: Qingyun Wu <qingyun.wu@psu.edu>
rlam3 pushed a commit to rlam3/autogen that referenced this pull request Dec 19, 2023
…osoft#917)

* try to fix blog

* modify blog

* fix test error in microsoft#717; fix blog typo in installation; update blogs with output examples.

* pre-commit

* pre-commit

* Update website/blog/2023-11-26-Agent-AutoBuild/index.mdx

Co-authored-by: Qingyun Wu <qingyun.wu@psu.edu>

* add future work

* fix grammar

* update agent_builder

---------

Co-authored-by: Jieyu Zhang <jieyuz2@cs.washington.edu>
Co-authored-by: Qingyun Wu <qingyun.wu@psu.edu>
rlam3 pushed a commit to rlam3/autogen that referenced this pull request Dec 19, 2023
…tion (microsoft#944)

* try to fix blog

* modify blog

* fix test error in microsoft#717; fix blog typo in installation; update blogs with output examples.

* pre-commit

* pre-commit

* Update website/blog/2023-11-26-Agent-AutoBuild/index.mdx

Co-authored-by: Qingyun Wu <qingyun.wu@psu.edu>

* add future work

* fix grammar

* update agent_builder

* solve microsoft#941; add detailed debug info; support json string config

* pre-commit

* solve microsoft#954

* pre-commit

---------

Co-authored-by: Jieyu Zhang <jieyuz2@cs.washington.edu>
Co-authored-by: Qingyun Wu <qingyun.wu@psu.edu>
github-merge-queue bot pushed a commit that referenced this pull request Jan 6, 2024
…ng agent descriptions (#1039)

* try to fix blog

* modify blog

* fix test error in #717; fix blog typo in installation; update blogs with output examples.

* pre-commit

* pre-commit

* Update website/blog/2023-11-26-Agent-AutoBuild/index.mdx

Co-authored-by: Qingyun Wu <qingyun.wu@psu.edu>

* add future work

* fix grammar

* update agent_builder

* solve #941; add detailed debug info; support json string config

* pre-commit

* solve #954

* pre-commit

* [new feature] build group chat agents from library.

* pre-commit

* add authors' info in notebook; add a new notebook for build_from_library; reduce prompt effort

* update test and example for build_from_library

* pre-commit

* add notebook; update docs

* change notebook name

* change description for notebook and doc

* remove default value for default_llm_config

* add embedding similarity agent selection

* pre-commit

* update test

* add dependency installation in github workflow

* update test

* pre-commit

* update notebook

* support directly json as library; support customize embedding model

* update test

* pre-commit

* update github test workflow

* Update autobuild_agent_library.ipynb

* add agent description

* refine prompt; update notebook

* pre-commit

* update test example

* update test

* update test

* update test

* change `config_path` to `config_path_or_env`; update test

* pre-commit

* update test

* update test

* update test: add config_file_location

* change `config_path_or_env` to `config_file_or_env`

* update test

* solve noqa

* fix import error for conftest

* fix test error

* pre-commit

* * update error message in `_create_agent`.
* replace `gpt-4-1106-preview` to `gpt-4` in test file.

* add comment on local server creation; modify notebook; update contrib-openai.yml for test; add autobuild option in setup.py; add autotest model name statement

* move import huggingface_hub to _create_agent

* pre-commit

* add uncover comment in the endpoint creation code block

* recover contrib-openai.yml for merge

---------

Co-authored-by: Jieyu Zhang <jieyuz2@cs.washington.edu>
Co-authored-by: Qingyun Wu <qingyun.wu@psu.edu>
github-merge-queue bot pushed a commit that referenced this pull request Feb 21, 2024
* try to fix blog

* modify blog

* fix test error in #717; fix blog typo in installation; update blogs with output examples.

* pre-commit

* pre-commit

* Update website/blog/2023-11-26-Agent-AutoBuild/index.mdx

Co-authored-by: Qingyun Wu <qingyun.wu@psu.edu>

* add future work

* fix grammar

* update agent_builder

* solve #941; add detailed debug info; support json string config

* pre-commit

* solve #954

* pre-commit

* [new feature] build group chat agents from library.

* pre-commit

* add authors' info in notebook; add a new notebook for build_from_library; reduce prompt effort

* update test and example for build_from_library

* pre-commit

* add notebook; update docs

* change notebook name

* change description for notebook and doc

* remove default value for default_llm_config

* add embedding similarity agent selection

* pre-commit

* update test

* add dependency installation in github workflow

* update test

* pre-commit

* update notebook

* support directly json as library; support customize embedding model

* update test

* pre-commit

* update github test workflow

* Update autobuild_agent_library.ipynb

* add agent description

* refine prompt; update notebook

* pre-commit

* update test example

* update test

* update test

* update test

* change `config_path` to `config_path_or_env`; update test

* pre-commit

* update test

* update test

* update test: add config_file_location

* change `config_path_or_env` to `config_file_or_env`

* update test

* solve noqa

* fix import error for conftest

* fix test error

* pre-commit

* * update error message in `_create_agent`.
* replace `gpt-4-1106-preview` to `gpt-4` in test file.

* add comment on local server creation; modify notebook; update contrib-openai.yml for test; add autobuild option in setup.py; add autotest model name statement

* move import huggingface_hub to _create_agent

* pre-commit

* add uncover comment in the endpoint creation code block

* recover contrib-openai.yml for merge

* remove TERMINATE assertion for sys msg

* remove TERMINATE assertion

---------

Co-authored-by: Jieyu Zhang <jieyuz2@cs.washington.edu>
Co-authored-by: Qingyun Wu <qingyun.wu@psu.edu>
whiskyboy pushed a commit to whiskyboy/autogen that referenced this pull request Apr 17, 2024
whiskyboy pushed a commit to whiskyboy/autogen that referenced this pull request Apr 17, 2024
…d to microsoft#846 (microsoft#865)

* try to fix blog

* modify blog

* fix test error in microsoft#717; fix blog typo in installation; update blogs with output examples.

* pre-commit

* pre-commit

* Update website/blog/2023-11-26-Agent-AutoBuild/index.mdx

Co-authored-by: Qingyun Wu <qingyun.wu@psu.edu>

* add future work

* fix grammar

---------

Co-authored-by: Jieyu Zhang <jieyuz2@cs.washington.edu>
Co-authored-by: Qingyun Wu <qingyun.wu@psu.edu>
whiskyboy pushed a commit to whiskyboy/autogen that referenced this pull request Apr 17, 2024
…osoft#917)

* try to fix blog

* modify blog

* fix test error in microsoft#717; fix blog typo in installation; update blogs with output examples.

* pre-commit

* pre-commit

* Update website/blog/2023-11-26-Agent-AutoBuild/index.mdx

Co-authored-by: Qingyun Wu <qingyun.wu@psu.edu>

* add future work

* fix grammar

* update agent_builder

---------

Co-authored-by: Jieyu Zhang <jieyuz2@cs.washington.edu>
Co-authored-by: Qingyun Wu <qingyun.wu@psu.edu>
whiskyboy pushed a commit to whiskyboy/autogen that referenced this pull request Apr 17, 2024
…tion (microsoft#944)

* try to fix blog

* modify blog

* fix test error in microsoft#717; fix blog typo in installation; update blogs with output examples.

* pre-commit

* pre-commit

* Update website/blog/2023-11-26-Agent-AutoBuild/index.mdx

Co-authored-by: Qingyun Wu <qingyun.wu@psu.edu>

* add future work

* fix grammar

* update agent_builder

* solve microsoft#941; add detailed debug info; support json string config

* pre-commit

* solve microsoft#954

* pre-commit

---------

Co-authored-by: Jieyu Zhang <jieyuz2@cs.washington.edu>
Co-authored-by: Qingyun Wu <qingyun.wu@psu.edu>
whiskyboy pushed a commit to whiskyboy/autogen that referenced this pull request Apr 17, 2024
…ng agent descriptions (microsoft#1039)

* try to fix blog

* modify blog

* fix test error in microsoft#717; fix blog typo in installation; update blogs with output examples.

* pre-commit

* pre-commit

* Update website/blog/2023-11-26-Agent-AutoBuild/index.mdx

Co-authored-by: Qingyun Wu <qingyun.wu@psu.edu>

* add future work

* fix grammar

* update agent_builder

* solve microsoft#941; add detailed debug info; support json string config

* pre-commit

* solve microsoft#954

* pre-commit

* [new feature] build group chat agents from library.

* pre-commit

* add authors' info in notebook; add a new notebook for build_from_library; reduce prompt effort

* update test and example for build_from_library

* pre-commit

* add notebook; update docs

* change notebook name

* change description for notebook and doc

* remove default value for default_llm_config

* add embedding similarity agent selection

* pre-commit

* update test

* add dependency installation in github workflow

* update test

* pre-commit

* update notebook

* support directly json as library; support customize embedding model

* update test

* pre-commit

* update github test workflow

* Update autobuild_agent_library.ipynb

* add agent description

* refine prompt; update notebook

* pre-commit

* update test example

* update test

* update test

* update test

* change `config_path` to `config_path_or_env`; update test

* pre-commit

* update test

* update test

* update test: add config_file_location

* change `config_path_or_env` to `config_file_or_env`

* update test

* solve noqa

* fix import error for conftest

* fix test error

* pre-commit

* * update error message in `_create_agent`.
* replace `gpt-4-1106-preview` to `gpt-4` in test file.

* add comment on local server creation; modify notebook; update contrib-openai.yml for test; add autobuild option in setup.py; add autotest model name statement

* move import huggingface_hub to _create_agent

* pre-commit

* add uncover comment in the endpoint creation code block

* recover contrib-openai.yml for merge

---------

Co-authored-by: Jieyu Zhang <jieyuz2@cs.washington.edu>
Co-authored-by: Qingyun Wu <qingyun.wu@psu.edu>
whiskyboy pushed a commit to whiskyboy/autogen that referenced this pull request Apr 17, 2024
* try to fix blog

* modify blog

* fix test error in microsoft#717; fix blog typo in installation; update blogs with output examples.

* pre-commit

* pre-commit

* Update website/blog/2023-11-26-Agent-AutoBuild/index.mdx

Co-authored-by: Qingyun Wu <qingyun.wu@psu.edu>

* add future work

* fix grammar

* update agent_builder

* solve microsoft#941; add detailed debug info; support json string config

* pre-commit

* solve microsoft#954

* pre-commit

* [new feature] build group chat agents from library.

* pre-commit

* add authors' info in notebook; add a new notebook for build_from_library; reduce prompt effort

* update test and example for build_from_library

* pre-commit

* add notebook; update docs

* change notebook name

* change description for notebook and doc

* remove default value for default_llm_config

* add embedding similarity agent selection

* pre-commit

* update test

* add dependency installation in github workflow

* update test

* pre-commit

* update notebook

* support directly json as library; support customize embedding model

* update test

* pre-commit

* update github test workflow

* Update autobuild_agent_library.ipynb

* add agent description

* refine prompt; update notebook

* pre-commit

* update test example

* update test

* update test

* update test

* change `config_path` to `config_path_or_env`; update test

* pre-commit

* update test

* update test

* update test: add config_file_location

* change `config_path_or_env` to `config_file_or_env`

* update test

* solve noqa

* fix import error for conftest

* fix test error

* pre-commit

* * update error message in `_create_agent`.
* replace `gpt-4-1106-preview` to `gpt-4` in test file.

* add comment on local server creation; modify notebook; update contrib-openai.yml for test; add autobuild option in setup.py; add autotest model name statement

* move import huggingface_hub to _create_agent

* pre-commit

* add uncover comment in the endpoint creation code block

* recover contrib-openai.yml for merge

* remove TERMINATE assertion for sys msg

* remove TERMINATE assertion

---------

Co-authored-by: Jieyu Zhang <jieyuz2@cs.washington.edu>
Co-authored-by: Qingyun Wu <qingyun.wu@psu.edu>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
function/tool suggestion and execution of function/tool call openai-assistant Issues related to assistants from OpenAI
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants