weco 0.1.6__py3-none-any.whl → 0.1.7__py3-none-any.whl

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.
weco/client.py CHANGED
@@ -25,11 +25,18 @@ class WecoAI:
25
25
  """A client for the WecoAI function builder API that allows users to build and query specialized functions built by LLMs.
26
26
  The user must simply provide a task description to build a function, and then query the function with an input to get the result they need.
27
27
  Our client supports both synchronous and asynchronous request paradigms and uses HTTP/2 for faster communication with the API.
28
+ Support for multimodality is included.
28
29
 
29
30
  Attributes
30
31
  ----------
31
32
  api_key : str
32
33
  The API key used for authentication.
34
+
35
+ timeout : float
36
+ The timeout for the HTTP requests in seconds. Default is 120.0.
37
+
38
+ http2 : bool
39
+ Whether to use HTTP/2 protocol for the HTTP requests. Default is True.
33
40
  """
34
41
 
35
42
  def __init__(self, api_key: str = None, timeout: float = 120.0, http2: bool = True) -> None:
@@ -41,7 +48,7 @@ class WecoAI:
41
48
  The API key used for authentication. If not provided, the client will attempt to read it from the environment variable - WECO_API_KEY.
42
49
 
43
50
  timeout : float, optional
44
- The timeout for the HTTP requests in seconds (default is 30.0).
51
+ The timeout for the HTTP requests in seconds (default is 120.0).
45
52
 
46
53
  http2 : bool, optional
47
54
  Whether to use HTTP/2 protocol for the HTTP requests (default is True).
@@ -405,8 +412,6 @@ class WecoAI:
405
412
  ValueError
406
413
  If the input is invalid.
407
414
  """
408
- warnings.warn("Setting the version number of the function is not yet supported. Currently, the first version of the function will be used i.e., version 0.")
409
- version_number = 0
410
415
  # Validate the input
411
416
  image_info = self._validate_query(text_input=text_input, images_input=images_input)
412
417
 
@@ -477,7 +482,7 @@ class WecoAI:
477
482
  Returns
478
483
  -------
479
484
  dict
480
- A dictionary containing the output of the function, the number of input tokens, the number of output tokens,
485
+ A dictionary containing the output of the function, the number of input tokens, the number of output tokens,
481
486
  and the latency in milliseconds.
482
487
  """
483
488
  return self._query(fn_name=fn_name, version_number=version_number, text_input=text_input, images_input=images_input, is_async=False)
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: weco
3
- Version: 0.1.6
3
+ Version: 0.1.7
4
4
  Summary: A client facing API for interacting with the WeCo AI function builder service.
5
5
  Author-email: WeCo AI Team <dhruv@weco.ai>
6
6
  License: MIT
@@ -0,0 +1,10 @@
1
+ weco/__init__.py,sha256=qiKpnrm6t0n0bpAtXEKJO1Yz2xYXnJJRZBWt-cH7DdU,168
2
+ weco/client.py,sha256=RCKuLVsR_o4G1TOhB-btIENCllN3h3d6baKoxVxue2s,21365
3
+ weco/constants.py,sha256=eoAq-9qN2aZrqyIWdrb3V1zomV5kp80PfxxoPoQNMNI,167
4
+ weco/functional.py,sha256=gckeXFVouy4wLHj0uLwxQkRNUj0urldk1f5ZDZk4yhY,6209
5
+ weco/utils.py,sha256=UUSw6ocqWdlSmIXVcH66DAL4NuLU2rFOyviD8aTWsv0,4371
6
+ weco-0.1.7.dist-info/LICENSE,sha256=NvpxfBuSajszAczWBGKxhHe4gsvil1H63zmu8xXZdL0,1064
7
+ weco-0.1.7.dist-info/METADATA,sha256=iPmC7l1aokdeYTACgT0Za8u07dyNxY8L1IJQMkqn7QE,5957
8
+ weco-0.1.7.dist-info/WHEEL,sha256=HiCZjzuy6Dw0hdX5R3LCFPDmFS4BWl8H-8W39XfmgX4,91
9
+ weco-0.1.7.dist-info/top_level.txt,sha256=F0N7v6e2zBSlsorFv-arAq2yDxQbzX3KVO8GxYhPUeE,5
10
+ weco-0.1.7.dist-info/RECORD,,
@@ -1,5 +1,5 @@
1
1
  Wheel-Version: 1.0
2
- Generator: setuptools (72.1.0)
2
+ Generator: setuptools (72.2.0)
3
3
  Root-Is-Purelib: true
4
4
  Tag: py3-none-any
5
5
 
@@ -1,10 +0,0 @@
1
- weco/__init__.py,sha256=qiKpnrm6t0n0bpAtXEKJO1Yz2xYXnJJRZBWt-cH7DdU,168
2
- weco/client.py,sha256=JNpIJz-_YtWqaZHJUldK3tFI1u7wcuU65xxyRUJOdog,21322
3
- weco/constants.py,sha256=eoAq-9qN2aZrqyIWdrb3V1zomV5kp80PfxxoPoQNMNI,167
4
- weco/functional.py,sha256=gckeXFVouy4wLHj0uLwxQkRNUj0urldk1f5ZDZk4yhY,6209
5
- weco/utils.py,sha256=UUSw6ocqWdlSmIXVcH66DAL4NuLU2rFOyviD8aTWsv0,4371
6
- weco-0.1.6.dist-info/LICENSE,sha256=NvpxfBuSajszAczWBGKxhHe4gsvil1H63zmu8xXZdL0,1064
7
- weco-0.1.6.dist-info/METADATA,sha256=CLrbjmTuQJHzW0SUIBkah1rdU7P3Ra9PHFuf_eYd_M0,5957
8
- weco-0.1.6.dist-info/WHEEL,sha256=R0nc6qTxuoLk7ShA2_Y-UWkN8ZdfDBG2B6Eqpz2WXbs,91
9
- weco-0.1.6.dist-info/top_level.txt,sha256=F0N7v6e2zBSlsorFv-arAq2yDxQbzX3KVO8GxYhPUeE,5
10
- weco-0.1.6.dist-info/RECORD,,
File without changes