|
4 | 4 |
|
5 | 5 | import os
|
6 | 6 | import sys
|
7 |
| -from importlib.metadata import version, PackageNotFoundError |
| 7 | +from importlib.metadata import PackageNotFoundError, version |
8 | 8 | from typing import Any
|
9 | 9 |
|
10 | 10 | try:
|
11 | 11 | __version__ = version("weaviate-client")
|
12 | 12 | except PackageNotFoundError:
|
13 | 13 | __version__ = "unknown version"
|
14 | 14 |
|
15 |
| -from .client import Client, WeaviateAsyncClient, WeaviateClient |
16 |
| -from .collections.batch.client import BatchClient, ClientBatchingContextManager |
17 |
| -from .connect.helpers import ( |
18 |
| - connect_to_custom, |
19 |
| - connect_to_embedded, |
20 |
| - connect_to_local, |
21 |
| - connect_to_wcs, |
22 |
| - connect_to_weaviate_cloud, |
23 |
| - use_async_with_custom, |
24 |
| - use_async_with_embedded, |
25 |
| - use_async_with_local, |
26 |
| - use_async_with_weaviate_cloud, |
27 |
| -) |
28 | 15 | from . import (
|
29 | 16 | auth,
|
30 | 17 | backup,
|
|
38 | 25 | outputs,
|
39 | 26 | types,
|
40 | 27 | )
|
| 28 | +from .client import Client, WeaviateAsyncClient, WeaviateClient |
| 29 | +from .collections.batch.client import BatchClient, ClientBatchingContextManager |
| 30 | +from .connect.helpers import ( |
| 31 | + connect_to_custom, |
| 32 | + connect_to_embedded, |
| 33 | + connect_to_local, |
| 34 | + connect_to_wcs, |
| 35 | + connect_to_weaviate_cloud, |
| 36 | + use_async_with_custom, |
| 37 | + use_async_with_embedded, |
| 38 | + use_async_with_local, |
| 39 | + use_async_with_weaviate_cloud, |
| 40 | +) |
41 | 41 |
|
42 | 42 | if not sys.warnoptions:
|
43 | 43 | from warnings import simplefilter
|
|
76 | 76 | "use_async_with_weaviate_cloud",
|
77 | 77 | ]
|
78 | 78 |
|
| 79 | +try: |
| 80 | + import weaviate_agents as agents |
| 81 | + |
| 82 | + sys.modules["weaviate.agents"] = agents |
| 83 | + __all__.append("agents") |
| 84 | +except ImportError: |
| 85 | + pass |
| 86 | + |
| 87 | + |
79 | 88 | deprs = [
|
80 | 89 | "Collection",
|
81 | 90 | "AuthClientCredentials",
|
|
0 commit comments