2020-12-05 01:40:27 +08:00
|
|
|
import os
|
2024-05-25 01:58:56 +08:00
|
|
|
import platform
|
2020-12-05 01:40:27 +08:00
|
|
|
|
2023-11-07 05:33:51 +08:00
|
|
|
import setuptools
|
|
|
|
|
2020-12-05 01:40:27 +08:00
|
|
|
here = os.path.abspath(os.path.dirname(__file__))
|
|
|
|
|
2022-01-03 09:12:34 +08:00
|
|
|
with open("README.md", "r", encoding="UTF-8") as fh:
|
2020-12-05 01:40:27 +08:00
|
|
|
long_description = fh.read()
|
|
|
|
|
|
|
|
# Get the code version
|
|
|
|
version = {}
|
2023-09-16 18:57:57 +08:00
|
|
|
with open(os.path.join(here, "autogen/version.py")) as fp:
|
2020-12-05 01:40:27 +08:00
|
|
|
exec(fp.read(), version)
|
|
|
|
__version__ = version["__version__"]
|
|
|
|
|
2024-05-25 01:58:56 +08:00
|
|
|
|
|
|
|
current_os = platform.system()
|
|
|
|
|
2020-12-05 01:40:27 +08:00
|
|
|
install_requires = [
|
2024-04-29 08:27:34 +08:00
|
|
|
"openai>=1.3",
|
2023-09-16 18:57:57 +08:00
|
|
|
"diskcache",
|
|
|
|
"termcolor",
|
2023-09-16 23:30:28 +08:00
|
|
|
"flaml",
|
2024-03-12 23:05:53 +08:00
|
|
|
# numpy is installed by flaml, but we want to pin the version to below 2.x (see https://github.com/microsoft/autogen/issues/1960)
|
|
|
|
"numpy>=1.17.0,<2",
|
2023-10-05 12:45:11 +08:00
|
|
|
"python-dotenv",
|
2023-11-04 12:01:49 +08:00
|
|
|
"tiktoken",
|
2024-02-08 06:15:07 +08:00
|
|
|
# Disallowing 2.6.0 can be removed when this is fixed https://github.com/pydantic/pydantic/issues/8705
|
|
|
|
"pydantic>=1.10,<3,!=2.6.0", # could be both V1 and V2
|
2024-01-19 01:03:49 +08:00
|
|
|
"docker",
|
2024-05-24 22:52:56 +08:00
|
|
|
"packaging",
|
2021-09-11 07:39:16 +08:00
|
|
|
]
|
2020-12-05 01:40:27 +08:00
|
|
|
|
2024-03-20 10:01:16 +08:00
|
|
|
jupyter_executor = [
|
|
|
|
"jupyter-kernel-gateway",
|
|
|
|
"websocket-client",
|
|
|
|
"requests",
|
|
|
|
"jupyter-client>=8.6.0",
|
|
|
|
"ipykernel>=6.29.0",
|
|
|
|
]
|
|
|
|
|
2024-05-02 02:05:45 +08:00
|
|
|
retrieve_chat = [
|
|
|
|
"protobuf==4.25.3",
|
|
|
|
"chromadb",
|
|
|
|
"sentence_transformers",
|
|
|
|
"pypdf",
|
|
|
|
"ipython",
|
|
|
|
"beautifulsoup4",
|
|
|
|
"markdownify",
|
|
|
|
]
|
2024-04-28 21:43:02 +08:00
|
|
|
|
2024-05-25 01:58:56 +08:00
|
|
|
retrieve_chat_pgvector = [*retrieve_chat, "pgvector>=0.2.5"]
|
|
|
|
|
|
|
|
if current_os in ["Windows", "Darwin"]:
|
|
|
|
retrieve_chat_pgvector.extend(["psycopg[binary]>=3.1.18"])
|
|
|
|
elif current_os == "Linux":
|
|
|
|
retrieve_chat_pgvector.extend(["psycopg>=3.1.18"])
|
|
|
|
|
2024-04-28 21:43:02 +08:00
|
|
|
extra_require = {
|
|
|
|
"test": [
|
|
|
|
"ipykernel",
|
|
|
|
"nbconvert",
|
|
|
|
"nbformat",
|
|
|
|
"pre-commit",
|
2024-04-29 08:27:34 +08:00
|
|
|
"pytest-cov>=5",
|
2024-04-28 21:43:02 +08:00
|
|
|
"pytest-asyncio",
|
|
|
|
"pytest>=6.1.1,<8",
|
|
|
|
"pandas",
|
|
|
|
],
|
|
|
|
"blendsearch": ["flaml[blendsearch]"],
|
|
|
|
"mathchat": ["sympy", "pydantic==1.10.9", "wolframalpha"],
|
|
|
|
"retrievechat": retrieve_chat,
|
2024-05-25 01:58:56 +08:00
|
|
|
"retrievechat-pgvector": retrieve_chat_pgvector,
|
2024-07-26 07:11:19 +08:00
|
|
|
"retrievechat-mongodb": [*retrieve_chat, "pymongo>=4.0.0"],
|
2024-07-03 00:00:31 +08:00
|
|
|
"retrievechat-qdrant": [*retrieve_chat, "qdrant_client", "fastembed>=0.3.1"],
|
2024-09-26 01:15:35 +08:00
|
|
|
"retrievechat-couchbase": [*retrieve_chat, "couchbase>=4.3.0"],
|
2024-06-14 22:14:08 +08:00
|
|
|
"autobuild": ["chromadb", "sentence-transformers", "huggingface-hub", "pysqlite3"],
|
2024-04-28 21:43:02 +08:00
|
|
|
"teachable": ["chromadb"],
|
|
|
|
"lmm": ["replicate", "pillow"],
|
|
|
|
"graph": ["networkx", "matplotlib"],
|
2024-06-04 05:00:00 +08:00
|
|
|
"gemini": ["google-generativeai>=0.5,<1", "google-cloud-aiplatform", "google-auth", "pillow", "pydantic"],
|
Together AI Client (#2919)
* First pass together.ai client class
* Config handling, models and cost
* Added tests, moved param management to create function
* Tests, parameter, validation, logging updates
* Added use of client_utils PR 2949
* Updated to return OAI response
* Notebook example
* Improved function calling, updated tests, updated notebook with Chess example
* Tidied up together client class, better parameter handling, simpler exception capture, warning for no cost, reuse in tests, cleaner tests
* Update of documentation notebook, replacement of old version
* Fix of messages parameter for hide_tools function call
* Update autogen/oai/together.py
Co-authored-by: Qingyun Wu <qingyun0327@gmail.com>
* Update together.py to fix text
---------
Co-authored-by: Qingyun Wu <qingyun0327@gmail.com>
Co-authored-by: Yiran Wu <32823396+yiranwu0@users.noreply.github.com>
Co-authored-by: Chi Wang <wang.chi@microsoft.com>
2024-06-22 01:14:44 +08:00
|
|
|
"together": ["together>=1.2"],
|
WebSurfer Updated (Selenium, Playwright, and support for many filetypes) (#1929)
* Feat/headless browser (retargeted) (#1832)
* Add headless browser to the WebSurferAgent, closes #1481
* replace soup.get_text() with markdownify.MarkdownConverter().convert_soup(soup)
* import HeadlessChromeBrowser
* implicitly wait for 10s
* inicrease max. wait time to 99s
* fix: trim trailing whitespace
* test: fix headless tests
* better bing query search
* docs: add example 3 for headless option
---------
Co-authored-by: Vijay Ramesh <vijay@regrello.com>
* Handle missing Selenium package.
* Added browser_chat.py example to simplify testing.
* Based browser on mdconvert. (#1847)
* Based browser on mdconvert.
* Updated web_surfer.
* Renamed HeadlessChromeBrowser to SeleniumChromeBrowser
* Added an initial POC with Playwright.
* Separated Bing search into it's own utility module.
* Simple browser now uses Bing tools.
* Updated Playwright browser to inherit from SimpleTextBrowser
* Got Selenium working too.
* Renamed classes and files for consistency.
* Added more instructions.
* Initial work to support other search providers.
* Added some basic behavior when the BING_API_KEY is missing.
* Cleaned up some search results.
* Moved to using the request.Sessions object. Moved Bing SERP paring to mdconvert to be more broadly useful.
* Added backward compatibility to WebSurferAgent
* Selenium and Playwright now grab the whole DOM, not jus the body, allowing the converters access to metadata.
* Fixed printing of page titles in Playwright.
* Moved installation of WebSurfer dependencies to contrib-tests.yml
* Fixing pre-commit issues.
* Reverting conversable_agent, which should not have been changed in prior commit.
* Added RequestMarkdownBrowser tests.
* Fixed a bug with Bing search, and added search test cases.
* Added tests for Bing search.
* Added tests for md_convert
* Added test files.
* Added missing pptx.
* Added more tests for WebSurfer coverage.
* Fixed guard on requests_markdown_browser test.
* Updated test coverage for mdconvert.
* Fix brwser_utils tests.
* Removed image test from browser, since exiftool isn't installed on test machine.
* Removed image test from browser, since exiftool isn't installed on test machine.
* Disable Selenium GPU and sandbox to ensure it runs headless in Docker.
* Added option for Bing API results to be interleaved (as Bing specifies), or presented in a categorized list (Web, News, Videos), etc
* Print more details when requests exceptions are thrown.
* Added additional documentation to markdown_search
* Added documentation to the selenium_markdown_browser.
* Added documentation to playwright_markdown_browser.py
* Added documentation to requests_markdown_browser
* Added documentation to mdconvert.py
* Updated agentchat_surfer notebook.
* Update .github/workflows/contrib-tests.yml
Co-authored-by: Davor Runje <davor@airt.ai>
* Merge main. Resolve conflicts.
* Resolve pre-commit checks.
* Removed offending LFS file.
* Re-added offending LFS file.
* Fixed browser_utils tests.
* Fixed style errors.
---------
Co-authored-by: Asapanna Rakesh <45640029+INF800@users.noreply.github.com>
Co-authored-by: Vijay Ramesh <vijay@regrello.com>
Co-authored-by: Eric Zhu <ekzhu@users.noreply.github.com>
Co-authored-by: Davor Runje <davor@airt.ai>
2024-09-26 06:17:42 +08:00
|
|
|
"websurfer": [
|
|
|
|
"beautifulsoup4",
|
|
|
|
"markdownify",
|
|
|
|
"pathvalidate",
|
|
|
|
# for mdconvert
|
|
|
|
"puremagic", # File identification
|
|
|
|
"pdfminer.six", # Pdf
|
|
|
|
"mammoth", # Docx
|
|
|
|
"python-pptx", # Ppts
|
|
|
|
"pandas", # Xlsx
|
|
|
|
"openpyxl",
|
|
|
|
"youtube_transcript_api==0.6.0", # Transcription
|
|
|
|
],
|
2024-04-28 21:43:02 +08:00
|
|
|
"redis": ["redis"],
|
|
|
|
"cosmosdb": ["azure-cosmos>=4.2.0"],
|
|
|
|
"websockets": ["websockets>=12.0,<13"],
|
|
|
|
"jupyter-executor": jupyter_executor,
|
|
|
|
"types": ["mypy==1.9.0", "pytest>=6.1.1,<8"] + jupyter_executor,
|
2024-05-06 22:16:49 +08:00
|
|
|
"long-context": ["llmlingua<0.3"],
|
2024-06-19 14:15:12 +08:00
|
|
|
"anthropic": ["anthropic>=0.23.1"],
|
2024-10-01 05:14:55 +08:00
|
|
|
"cerebras": ["cerebras_cloud_sdk>=1.0.0"],
|
2024-08-17 04:55:36 +08:00
|
|
|
"mistral": ["mistralai>=1.0.1"],
|
2024-06-28 13:58:42 +08:00
|
|
|
"groq": ["groq>=0.9.0"],
|
2024-07-03 22:33:03 +08:00
|
|
|
"cohere": ["cohere>=5.5.8"],
|
2024-10-02 07:55:17 +08:00
|
|
|
"ollama": ["ollama>=0.3.3", "fix_busted_json>=0.0.18"],
|
Amazon Bedrock Client for AutoGen (#3232)
* intial commit for aws-bedrock
* format
* converse setup for model req-response
* Renamed to bedrock.py, updated parameter parsing, system message extraction, client class incorporation
* Established Bedrock class based on @astroalek and @ChristianT's code, added ability to disable system prompt separation
* Image parsing and removing access credential checks
* Added tests, added additional parameter support
* Amazon Bedrock documentation
* Moved client parameters to init, align parameter names with Anthropic, spelling fix, remove unnecessary imports, use base and additional parameters, update documentation
* Tidy up comments
* Minor typo fix
* Correct comment re aws_region
---------
Co-authored-by: Mark Sze <mark@sze.family>
Co-authored-by: Mark Sze <66362098+marklysze@users.noreply.github.com>
Co-authored-by: Li Jiang <bnujli@gmail.com>
2024-08-26 15:28:53 +08:00
|
|
|
"bedrock": ["boto3>=1.34.149"],
|
2024-10-17 03:22:50 +08:00
|
|
|
"kubernetes": ["kubernetes>=27.2.0"],
|
2024-04-28 21:43:02 +08:00
|
|
|
}
|
2024-04-21 02:32:57 +08:00
|
|
|
|
2020-12-05 01:40:27 +08:00
|
|
|
setuptools.setup(
|
2024-10-02 08:05:11 +08:00
|
|
|
name="autogen-agentchat",
|
2020-12-05 01:40:27 +08:00
|
|
|
version=__version__,
|
2023-09-16 18:57:57 +08:00
|
|
|
author="AutoGen",
|
2024-10-02 08:05:11 +08:00
|
|
|
author_email="autogen@microsoft.com",
|
2023-09-16 18:57:57 +08:00
|
|
|
description="Enabling Next-Gen LLM Applications via Multi-Agent Conversation Framework",
|
2020-12-05 01:40:27 +08:00
|
|
|
long_description=long_description,
|
|
|
|
long_description_content_type="text/markdown",
|
2023-09-16 18:57:57 +08:00
|
|
|
url="https://github.com/microsoft/autogen",
|
2023-09-20 02:26:50 +08:00
|
|
|
packages=setuptools.find_packages(include=["autogen*"], exclude=["test"]),
|
2020-12-05 01:40:27 +08:00
|
|
|
install_requires=install_requires,
|
2024-04-28 21:43:02 +08:00
|
|
|
extras_require=extra_require,
|
2020-12-05 01:40:27 +08:00
|
|
|
classifiers=[
|
|
|
|
"Programming Language :: Python :: 3",
|
|
|
|
"License :: OSI Approved :: MIT License",
|
2021-04-09 00:29:55 +08:00
|
|
|
"Operating System :: OS Independent",
|
2020-12-05 01:40:27 +08:00
|
|
|
],
|
2024-01-18 15:15:06 +08:00
|
|
|
python_requires=">=3.8,<3.13",
|
2020-12-05 01:40:27 +08:00
|
|
|
)
|