anthropic 0.59.0__py3-none-any.whl → 0.60.0__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.
anthropic/_base_client.py CHANGED
@@ -704,7 +704,7 @@ class BaseClient(Generic[_HttpxClientT, _DefaultStreamT]):
704
704
  expected_time = maximum_time * max_tokens / 128_000
705
705
  if expected_time > default_time or (max_nonstreaming_tokens and max_tokens > max_nonstreaming_tokens):
706
706
  raise ValueError(
707
- "Streaming is strongly recommended for operations that may take longer than 10 minutes. "
707
+ "Streaming is required for operations that may take longer than 10 minutes. "
708
708
  + "See https://github.com/anthropics/anthropic-sdk-python#long-requests for more details",
709
709
  )
710
710
  return Timeout(
anthropic/_version.py CHANGED
@@ -1,4 +1,4 @@
1
1
  # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
2
 
3
3
  __title__ = "anthropic"
4
- __version__ = "0.59.0" # x-release-please-version
4
+ __version__ = "0.60.0" # x-release-please-version
@@ -13,6 +13,8 @@ __all__ = ["Messages", "AsyncMessages"]
13
13
 
14
14
  class Messages(SyncAPIResource):
15
15
  create = FirstPartyMessagesAPI.create
16
+ stream = FirstPartyMessagesAPI.stream
17
+ count_tokens = FirstPartyMessagesAPI.count_tokens
16
18
 
17
19
  @cached_property
18
20
  def with_raw_response(self) -> MessagesWithRawResponse:
@@ -36,6 +38,8 @@ class Messages(SyncAPIResource):
36
38
 
37
39
  class AsyncMessages(AsyncAPIResource):
38
40
  create = FirstPartyAsyncMessagesAPI.create
41
+ stream = FirstPartyAsyncMessagesAPI.stream
42
+ count_tokens = FirstPartyAsyncMessagesAPI.count_tokens
39
43
 
40
44
  @cached_property
41
45
  def with_raw_response(self) -> AsyncMessagesWithRawResponse:
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: anthropic
3
- Version: 0.59.0
3
+ Version: 0.60.0
4
4
  Summary: The official Python library for the anthropic API
5
5
  Project-URL: Homepage, https://github.com/anthropics/anthropic-sdk-python
6
6
  Project-URL: Repository, https://github.com/anthropics/anthropic-sdk-python
@@ -1,5 +1,5 @@
1
1
  anthropic/__init__.py,sha256=_3qHjlaUTyCm_xLr3HAcWvxMuKwKJtVRR1TkwU9WEYE,2845
2
- anthropic/_base_client.py,sha256=pF41xe4VsXrplq61mZw7jm3UxuJ0ysNm3mIwwODVtl8,72736
2
+ anthropic/_base_client.py,sha256=LhenlHQa5Plve7VlV-G-JFA6rEQooRRuEhagRk8Xj6g,72724
3
3
  anthropic/_client.py,sha256=kZlulmKAcSG7WdzYCUdXFFfATn5ZP1PO7gHQbqAe2Dc,22827
4
4
  anthropic/_compat.py,sha256=VWemUKbj6DDkQ-O4baSpHVLJafotzeXmCQGJugfVTIw,6580
5
5
  anthropic/_constants.py,sha256=dZ53c7dQnlC6xcGkes61-8goAEIOwzTfsmcBfzdU9Ho,756
@@ -12,7 +12,7 @@ anthropic/_resource.py,sha256=FYEOzfhB-XWTR2gyTmQuuFoecRiVXxe_SpjZlQQGytU,1080
12
12
  anthropic/_response.py,sha256=1Y7-OrGn1lOwvZ_SmMlwT9Nb2i9A1RYw2Q4-F1cwPSU,30542
13
13
  anthropic/_streaming.py,sha256=vn8K5KgfO3Bv9NE8nwHIQEjEhkQeVE6YMnGqiJlCgqE,14023
14
14
  anthropic/_types.py,sha256=WeAcP68yMpfs3hNEltM_k2nYMiG4xda4cFdf5kHbjP8,6299
15
- anthropic/_version.py,sha256=EW9TFA1pohaF4p9rmYwP8ffwypJpV5zfCMKWeGFB8JE,162
15
+ anthropic/_version.py,sha256=KhuHnm-Rfa7b-qw4-BEkvW3x5Uzeh06Uxlq2zPvpX_w,162
16
16
  anthropic/pagination.py,sha256=hW6DOtNbwwQrNQ8wn4PJj7WB2y_37szSDQeUBnunQ40,2202
17
17
  anthropic/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
18
18
  anthropic/_decoders/jsonl.py,sha256=KDLw-Frjo7gRup5qDp_BWkXIZ-mFZU5vFDz0WBhEKcs,3510
@@ -47,7 +47,7 @@ anthropic/lib/streaming/_types.py,sha256=CrR4948IWgUF7L9O0ase2QwbpiQ1JeiYXrRyVi7
47
47
  anthropic/lib/vertex/__init__.py,sha256=A8vuK1qVPtmKr1_LQgPuDRVA6I4xm_ye2aPdAa4yGsI,102
48
48
  anthropic/lib/vertex/_auth.py,sha256=Kyt_hbUc-DPlkvds4__OLR8FLPpoDas6bXhZTECxO3Y,1644
49
49
  anthropic/lib/vertex/_beta.py,sha256=8kXsUUIGstf6dZfiZtm6s9OWEueuSgra8dPvkaUacy4,3323
50
- anthropic/lib/vertex/_beta_messages.py,sha256=ClPL21UrRbJ9M10G8PcRla_Fu9GoWN_420FUuw91bmY,3197
50
+ anthropic/lib/vertex/_beta_messages.py,sha256=4fsV2F6TzB14DuHLo9k8i95vymcbixIPjsplqpsHfac,3399
51
51
  anthropic/lib/vertex/_client.py,sha256=bvemByz7HdwDIHMojcvBUN7khsI32jFglgtRVDH5o04,16619
52
52
  anthropic/resources/__init__.py,sha256=H0t_V-A_u6bIVmbAUpY9ZfgqoNIjIfyNpZz7hAiErIA,1583
53
53
  anthropic/resources/completions.py,sha256=lrht7C7OY4tNEHXGYUVkciCmnMXwYcte4myEQ7T75LI,37132
@@ -322,7 +322,7 @@ anthropic/types/shared/not_found_error.py,sha256=R6OsCvAmsf_SB2TwoX6E63o049qZMaA
322
322
  anthropic/types/shared/overloaded_error.py,sha256=PlyhHt3wmzcnynSfkWbfP4XkLoWsPa9B39V3CyAdgx8,282
323
323
  anthropic/types/shared/permission_error.py,sha256=nuyxtLXOiEkYEbFRXiAWjxU6XtdyjkAaXQ2NgMB3pjw,282
324
324
  anthropic/types/shared/rate_limit_error.py,sha256=eYULATjXa6KKdqeBauest7RzuN-bhGsY5BWwH9eYv4c,280
325
- anthropic-0.59.0.dist-info/METADATA,sha256=u7i0Mx81_G98nk2e9maKP1y4D0g5E5hYEIdMoLYcmPk,27053
326
- anthropic-0.59.0.dist-info/WHEEL,sha256=C2FUgwZgiLbznR-k0b_5k3Ai_1aASOXDss3lzCUsUug,87
327
- anthropic-0.59.0.dist-info/licenses/LICENSE,sha256=i_lphP-Lz65-SMrnalKeiiUxe6ngKr9_08xk_flWV6Y,1056
328
- anthropic-0.59.0.dist-info/RECORD,,
325
+ anthropic-0.60.0.dist-info/METADATA,sha256=WI6r68K57TrPbEYymhONSUXu-iqFDfDnOk5ZlKi9Ps4,27053
326
+ anthropic-0.60.0.dist-info/WHEEL,sha256=C2FUgwZgiLbznR-k0b_5k3Ai_1aASOXDss3lzCUsUug,87
327
+ anthropic-0.60.0.dist-info/licenses/LICENSE,sha256=i_lphP-Lz65-SMrnalKeiiUxe6ngKr9_08xk_flWV6Y,1056
328
+ anthropic-0.60.0.dist-info/RECORD,,