exa-py 1.0.12__tar.gz → 1.0.14__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of exa-py might be problematic. Click here for more details.
- {exa_py-1.0.12 → exa_py-1.0.14}/PKG-INFO +1 -1
- {exa_py-1.0.12 → exa_py-1.0.14}/exa_py/api.py +2 -2
- {exa_py-1.0.12 → exa_py-1.0.14}/exa_py/utils.py +3 -3
- {exa_py-1.0.12 → exa_py-1.0.14}/exa_py.egg-info/PKG-INFO +1 -1
- {exa_py-1.0.12 → exa_py-1.0.14}/exa_py.egg-info/requires.txt +1 -1
- {exa_py-1.0.12 → exa_py-1.0.14}/setup.py +2 -2
- {exa_py-1.0.12 → exa_py-1.0.14}/README.md +0 -0
- {exa_py-1.0.12 → exa_py-1.0.14}/exa_py/__init__.py +0 -0
- {exa_py-1.0.12 → exa_py-1.0.14}/exa_py/py.typed +0 -0
- {exa_py-1.0.12 → exa_py-1.0.14}/exa_py.egg-info/SOURCES.txt +0 -0
- {exa_py-1.0.12 → exa_py-1.0.14}/exa_py.egg-info/dependency_links.txt +0 -0
- {exa_py-1.0.12 → exa_py-1.0.14}/exa_py.egg-info/top_level.txt +0 -0
- {exa_py-1.0.12 → exa_py-1.0.14}/setup.cfg +0 -0
|
@@ -19,7 +19,7 @@ from typing import (
|
|
|
19
19
|
from typing_extensions import TypedDict
|
|
20
20
|
|
|
21
21
|
import httpx
|
|
22
|
-
from openai import
|
|
22
|
+
from openai import OpenAI
|
|
23
23
|
from openai.types.chat.chat_completion_message_param import ChatCompletionMessageParam
|
|
24
24
|
from openai.types.chat_model import ChatModel
|
|
25
25
|
from exa_py.utils import (
|
|
@@ -335,7 +335,7 @@ class Exa:
|
|
|
335
335
|
self,
|
|
336
336
|
api_key: Optional[str],
|
|
337
337
|
base_url: str = "https://api.exa.ai",
|
|
338
|
-
user_agent: str = "exa-py 1.0.
|
|
338
|
+
user_agent: str = "exa-py 1.0.14",
|
|
339
339
|
):
|
|
340
340
|
"""Initialize the Exa client with the provided API key and optional base URL and user agent.
|
|
341
341
|
|
|
@@ -2,13 +2,13 @@ import json
|
|
|
2
2
|
from typing import Optional
|
|
3
3
|
from openai.types.chat import ChatCompletion
|
|
4
4
|
|
|
5
|
-
from typing import TYPE_CHECKING
|
|
5
|
+
from typing import TYPE_CHECKING
|
|
6
6
|
if TYPE_CHECKING:
|
|
7
7
|
from exa_py.api import ResultWithText, SearchResponse
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
|
|
11
|
-
def maybe_get_query(completion) -> str
|
|
11
|
+
def maybe_get_query(completion) -> Optional[str]:
|
|
12
12
|
"""Extract query from completion if it exists."""
|
|
13
13
|
if completion.choices[0].message.tool_calls:
|
|
14
14
|
for tool_call in completion.choices[0].message.tool_calls:
|
|
@@ -75,4 +75,4 @@ class ExaOpenAICompletion(ChatCompletion):
|
|
|
75
75
|
object=completion.object,
|
|
76
76
|
system_fingerprint=completion.system_fingerprint,
|
|
77
77
|
usage=completion.usage,
|
|
78
|
-
)
|
|
78
|
+
)
|
|
@@ -2,7 +2,7 @@ from setuptools import setup, find_packages
|
|
|
2
2
|
|
|
3
3
|
setup(
|
|
4
4
|
name="exa_py",
|
|
5
|
-
version="1.0.
|
|
5
|
+
version="1.0.14",
|
|
6
6
|
description="Python SDK for Exa API.",
|
|
7
7
|
long_description_content_type="text/markdown",
|
|
8
8
|
long_description=open("README.md").read(),
|
|
@@ -14,7 +14,7 @@ setup(
|
|
|
14
14
|
install_requires=[
|
|
15
15
|
"requests",
|
|
16
16
|
"typing-extensions",
|
|
17
|
-
"openai"
|
|
17
|
+
"openai>=1.10.0"
|
|
18
18
|
],
|
|
19
19
|
classifiers=[
|
|
20
20
|
"Development Status :: 5 - Production/Stable",
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|