* first pass at offline agent eval integration
* Integrating AgentEval for offline scenarios
* removing old changes
* fixing notebook, updating docs
* fixing subcriteria bug
* updating class comment
* cleaning up agent constructors
* moving AgentEval agents to separate folder and adding a brief README
* fixing build breaks
* fixing formatting break
* fixing comments
* consolidating files in the agenteval folder under contrib and cleaning up imports
* fixing import ordering
* adding basic agenteval tests and fixing criteria parsing bug
* first try at adding openai agenteval tests to build process
* adding non-openai agenteval tests to build process
* updating test settings
* updating openai test
* Update test/agentchat/contrib/agent_eval/test_agent_eval.py
Co-authored-by: Wael Karkoub <wael.karkoub96@gmail.com>
* Update .github/workflows/contrib-openai.yml
Co-authored-by: Wael Karkoub <wael.karkoub96@gmail.com>
* test commit
* updating typing and converting to pydantic objects
* fixing test file
---------
Co-authored-by: Beibin Li <BeibinLi@users.noreply.github.com>
Co-authored-by: Chi Wang <wang.chi@microsoft.com>
Co-authored-by: Wael Karkoub <wael.karkoub96@gmail.com>
* Added 'role' as a summary_args and to the reflection_with_llm flow to be able to pass the role for the summarizing prompt
* Added 'role' as a summary_args and to the reflection_with_llm flow to be able to pass the role for the summarizing prompt, minor docstring adjustments
* Added test for summary prompt role assignment
* Fixed docstrings and mocked llm-config in the test
* Update autogen/agentchat/conversable_agent.py
Co-authored-by: Chi Wang <wang.chi@microsoft.com>
* ran pre-commit
* ran pre-commit2
* fixed old arg name
* Delete dasdaasd
No idea what this file was about
* Fixed incorrect merge update on test_groupchat
---------
Co-authored-by: Chi Wang <wang.chi@microsoft.com>
Co-authored-by: Eric Zhu <ekzhu@users.noreply.github.com>
* Initial resume
* Cleaned up resume function
* Further updating resuming group chat
* Added async resume_chat and documentation
* Added test cases, refined group chat function parameters
* compiled documentation
* Added tests to main
* Removed mdx file.
* Revert "Merge remote-tracking branch 'origin/main' into groupchatresume"
This reverts commit 8f709308f0, reversing
changes made to 8bfcb2bff1.
* Refactored resume to remove initiate_chat
* fix git history
* fix history
* Added clean-up of objects, _groupchat references, and messages_to_string updated
* Added termination-based resumption in notebook, added test cases and improved robustness on resuming messages parameter
---------
Co-authored-by: Eric Zhu <ekzhu@users.noreply.github.com>
* Fix for http client
* fixed constructor to only ignore the http_client while copying
* fixed comment formating
* removed check for http_client and added error message with docs
* fix formatting
* fix formatting
* added test for http-fix
* changed title and content of docs
* changed test func name
* Added requery_on_multiple_speaker_names to GroupChat and updated _finalize_speaker to requery on multiple speaker names (if enabled)
* Removed unnecessary comments
* Update to current main
* Tweak error message.
* Comment clarity
* Expanded description of Group Chat requery_on_multiple_speaker_names
* Reworked to two-way nested chat for speaker selection with default of 2 retries.
* Adding validation of new GroupChat attributes
* Updates as per @ekzhu's suggestions
* Update groupchat
- Added select_speaker_auto_multiple_template and select_speaker_auto_none_template
- Added max_attempts comment
- Re-instated support for role_for_select_speaker_messages
-
* Update conversable_agent.py
Added ability to force override role for a message to support select speaker prompt.
* Update test_groupchat.py
Updated existing select_speaker test functions as underlying approach has changed, added necessary tests for new functionality.
* Removed block for manual selection in select_speaker function.
* Catered for no-selection during manual selection mode
---------
Co-authored-by: Chi Wang <wang.chi@microsoft.com>
* Add minimum token threshold in MessageHistoryLimiter
* Update transforms tests for the threshold
* Move min_threshold_tokens from Message to Token Limiter
* Optimize _check_tokens_threshold
Co-authored-by: Wael Karkoub <wael.karkoub96@gmail.com>
* Apply requested changes (renaming, phrasing, validations)
* Fix format
* Fix _check_tokens_threshold logic
* Update docs and notebook
* Improve phrasing
* Add min_tokens example in notebook
* Add min_tokens example in website docs
* Add min_tokens example in notebook
* Update website docs to be in sync with get_logs change
---------
Co-authored-by: Wael Karkoub <wael.karkoub96@gmail.com>
Co-authored-by: Chi Wang <wang.chi@microsoft.com>
* Re-added missing notebook
* Test installing postgres
* Error handle the connection.
* Fixed import.
* Fixed import.
* Fixed creation of collection without client.
* PGVector portion working. OpenAI untested.
* Fixed prints.
* Added output.
* Fixed pre-commits.
* Run pgvector notebook
* Improve efficiency of get_collection
* Fix delete_collection
* Fixed issues with pytests and validated functions.
* Validated pytests.
* Fixed pre-commits
* Separated extra_requires to allow more logic. Retrieve_chat base dependencies included on pgvector and qdrant.
* Fixed extra newline.
* Added username and password fields.
* URL Encode the connection string parameters to support symbols like %
* Fixed pre-commits.
* Added pgvector service
* pgvector doesn't have health intervals.
* Switched to colon based key values.
* Run on Ubuntu only. Linux is only option with container service support.
* Using default credentials instead.
* Fix postgres setup
* Fix postgres setup
* Don't skip tests on win and mac
* Fix command error
* Try apt install postgresql
* Assert table does not exist when deleted.
* Raise value error on a empty list or None value provided for IDs
* pre-commit
* Add install pgvector
* Add install pgvector
* Reorg test files, create a separate job for test pgvector
* Fix format
* Fix env format
* Simplify job name, enable test_retrieve_config
* Fix test_retrieve_config
* Corrected behavior for get_docs_by_ids with no ids returning all docs.
* Corrected behavior for get_docs_by_ids with no ids returning all docs.
* Fixed pre-commits.
* Added return values for all functions.
* Validated distance search is implemented correctly.
* Validated all pytests
* Removed print.
* Added default clause.
* Make ids optional
* Fix test, make it more robust
* Bump version of openai for the vector_store support
* Added support for choosing the sentence transformer model.
* Added error handling for model name entered.
* Updated model info.
* Added model_name db_config param.
* pre-commit fixes and last link fix.
* Use secrets password.
* fix: link fixed
* updated tests
* Updated config_list.
* pre-commit fix.
* Added chat_result to all output.
Unable to re-run notebooks.
* Pre-commit fix detected this requirement.
* Fix python 3.8 and 3.9 not supported for macos
* Fix python 3.8 and 3.9 not supported for macos
* Fix format
* Reran notebook with MetaLlama3Instruct7BQ4_k_M
* added gpt model.
* Reran notebook
---------
Co-authored-by: Li Jiang <bnujli@gmail.com>
Co-authored-by: Hk669 <hrushi669@gmail.com>
* adapted to openai assistant v2 api
* fix comments
* format code
* fix ci
* Update autogen/agentchat/contrib/gpt_assistant_agent.py
Co-authored-by: Eric Zhu <ekzhu@users.noreply.github.com>
---------
Co-authored-by: Eric Zhu <ekzhu@users.noreply.github.com>
* PGVector Contrib Initial Commit - KnucklesTeam:autogen:pgvector_contrib fork
* Update website/docs/ecosystem/pgvector.md
Co-authored-by: Chi Wang <wang.chi@microsoft.com>
* Updated qdrant installation instructions.
* Fixed openai version.
* Added dependencies to install for qdrant and pgvector in contrib tests.
* Added dependencies to install for qdrant and pgvector in contrib tests.
* Cleaned up dependencies.
* Removed flaml out of setup.py. Used only for notebook example.
* Added PGVector notebook link
---------
Co-authored-by: Chi Wang <wang.chi@microsoft.com>
* speed up notebook in CI
* improve notebook
* comment about filter
* bug fix for summary
* bump version to 0.2.26
* restrict openai version
* news update
* add tags in example
* gather_usage_summary has been updated
* updated cost info to 'usage_including_cached_inference' and 'usage_excluding_cached_inference'
* fix: pre-commit formatting for cost_info
* improved cost explanation and doc
* improved cost info doc
* include - exclude
---------
Co-authored-by: Chi Wang <wang.chi@microsoft.com>
* Standardize printing of MessageTransforms
* Fix pre-commit black failure
* Add test for transform_messages printing
* Return str instead of printing
* Rename to_print_stats to verbose
* Cleanup
* t i# This is a combination of 3 commits.
Update requirements
* Remove lazy-fixture
* Avoid calling apply_transform in two code paths
* Format
* Replace stats with logs
* Handle no content messages in TokenLimiter get_logs()
* Move tests from test_transform_messages to test_transforms
---------
Co-authored-by: Wael Karkoub <wael.karkoub96@gmail.com>
* support llm_config in agentoptimizer
* fix doc
* restore seed timeout
---------
Co-authored-by: “skzhang1” <“shaokunzhang529@gmail.com”>
Co-authored-by: Chi Wang <wang.chi@microsoft.com>
* Added vectordb base and chromadb
* Remove timer and unused functions
* Added filter by distance
* Added test utils
* Fix format
* Fix type hint of dict
* Rename test
* Add test chromadb
* Fix test no chromadb
* Add coverage
* Don't skip test vectordb utils
* Add types
* Fix tests
* Fix docs build error
* Add types to base
* Update base
* Update utils
* Update chromadb
* Add get_docs_by_ids
* Improve docstring
* Add get all docs
* Move chroma_results_to_query_results to utils
* Improve type hints
* Update logger
* Update init, add embedding func
* Improve docstring of vectordb, add two attributes
* Improve test workflow
* 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>
* Re-commit of code from PR (#2167) addressing #1861, due to wrong basing
* Update website/docs/topics/non-openai-models/best-tips-for-nonopenai-models.md
Co-authored-by: Eric Zhu <ekzhu@users.noreply.github.com>
* Removed unnecessary notebook images
* Update conversation-patterns.ipynb
Updated to include note about being applicable when auto.
* Updated to include checks that the role is not blank/None. Added tests.
* Changed try-except to use pytest
---------
Co-authored-by: Eric Zhu <ekzhu@users.noreply.github.com>
* Introducing IOStream
* bug fixing
* polishing
* refactoring
* refactoring
* refactoring
* wip: async tests
* websockets added
* wip
* merge with main
* notebook added
* FastAPI example added
* wip
* merge
* getter/setter to iostream added
* website/blog/2024-03-03-AutoGen-Update/img/dalle_gpt4v.png: convert to Git LFS
* website/blog/2024-03-03-AutoGen-Update/img/gaia.png: convert to Git LFS
* website/blog/2024-03-03-AutoGen-Update/img/teach.png: convert to Git LFS
* add SSL support
* wip
* wip
* exception handling added to on_connect()
* refactoring: default iostream is being set in a context manager
* test fix
* polishing
* polishing
* polishing
* fixed bug with new thread
* polishing
* a bit of refactoring and docs added
* notebook added to docs
* type checking added to CI
* CI fix
* CI fix
* CI fix
* polishing
* obsolete todo comment removed
* fixed precommit error
---------
Co-authored-by: Eric Zhu <ekzhu@users.noreply.github.com>
* tried implementing my own regex
* improves tests
* finally works
* removes prints
* fixed test
* adds start and end
* delete unused imports
* refactored to use new tool
* significantly improved algo
* tag content -> tag attr
* fix tests + adds new field
* return full match
* return remove start and end
* update docstrings
* update docstrings
* update docstrings
---------
Co-authored-by: Beibin Li <BeibinLi@users.noreply.github.com>
Co-authored-by: Chi Wang <wang.chi@microsoft.com>
* context to kwargs
* add tag
* add test
* text to kwargs
---------
Co-authored-by: Eric Zhu <ekzhu@users.noreply.github.com>
Co-authored-by: Chi Wang <wang.chi@microsoft.com>
* Add vision capability
* Configurate: description_prompt
* Print warning instead of raising issues for type
* Skip vision capability test if dependencies not installed
* Append "vision" to agent's system message when enabled VisionCapability
* GPT-4V notebook update with ConversableAgent
* Clean GPT-4V notebook
* Add vision capability test to workflow
* Lint import
* Update system message for vision capability
* Add a `custom_caption_func` to VisionCapability
* Add custom function example for vision capability
* Skip test Vision capability custom func
* GPT-4V notebook metadata to website
* Remove redundant files
* The custom caption function takes more inputs now
* Add a more complex example of custom caption func
* Remove trailing space
---------
Co-authored-by: Chi Wang <wang.chi@microsoft.com>
* add assistant config
* add test
* change notebook to use assistant config
* use assistant config in testing
* code refinement
---------
Co-authored-by: Eric Zhu <ekzhu@users.noreply.github.com>
* fix type and default value of the code_execution_config of UserProxAgent
* fix type and default value of the code_execution_config of UserProxAgent
* set default value of llm_config in UserProxyAgent to None
* fixed tests
* revert llm_config to False
---------
Co-authored-by: Chi Wang <wang.chi@microsoft.com>
* improve validation of llm_config
* fixed test_register_for_llm_without_LLM
* docstr about llm_config=None
* Make None a sentinel
* pop tools
---------
Co-authored-by: Davor Runje <davor@airt.ai>