perplexityai 0.22.3__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.
Files changed (64) hide show
  1. perplexity/__init__.py +102 -0
  2. perplexity/_base_client.py +2001 -0
  3. perplexity/_client.py +529 -0
  4. perplexity/_compat.py +219 -0
  5. perplexity/_constants.py +14 -0
  6. perplexity/_exceptions.py +108 -0
  7. perplexity/_files.py +123 -0
  8. perplexity/_models.py +857 -0
  9. perplexity/_qs.py +150 -0
  10. perplexity/_resource.py +43 -0
  11. perplexity/_response.py +832 -0
  12. perplexity/_streaming.py +371 -0
  13. perplexity/_types.py +261 -0
  14. perplexity/_utils/__init__.py +64 -0
  15. perplexity/_utils/_compat.py +45 -0
  16. perplexity/_utils/_datetime_parse.py +136 -0
  17. perplexity/_utils/_logs.py +25 -0
  18. perplexity/_utils/_proxy.py +65 -0
  19. perplexity/_utils/_reflection.py +42 -0
  20. perplexity/_utils/_resources_proxy.py +24 -0
  21. perplexity/_utils/_streams.py +12 -0
  22. perplexity/_utils/_sync.py +58 -0
  23. perplexity/_utils/_transform.py +457 -0
  24. perplexity/_utils/_typing.py +156 -0
  25. perplexity/_utils/_utils.py +421 -0
  26. perplexity/_version.py +4 -0
  27. perplexity/lib/.keep +4 -0
  28. perplexity/py.typed +0 -0
  29. perplexity/resources/__init__.py +47 -0
  30. perplexity/resources/async_/__init__.py +33 -0
  31. perplexity/resources/async_/async_.py +102 -0
  32. perplexity/resources/async_/chat/__init__.py +33 -0
  33. perplexity/resources/async_/chat/chat.py +102 -0
  34. perplexity/resources/async_/chat/completions.py +359 -0
  35. perplexity/resources/chat/__init__.py +33 -0
  36. perplexity/resources/chat/chat.py +102 -0
  37. perplexity/resources/chat/completions.py +900 -0
  38. perplexity/resources/search.py +228 -0
  39. perplexity/types/__init__.py +14 -0
  40. perplexity/types/async_/__init__.py +3 -0
  41. perplexity/types/async_/chat/__init__.py +9 -0
  42. perplexity/types/async_/chat/completion_create_params.py +242 -0
  43. perplexity/types/async_/chat/completion_create_response.py +30 -0
  44. perplexity/types/async_/chat/completion_get_params.py +25 -0
  45. perplexity/types/async_/chat/completion_get_response.py +30 -0
  46. perplexity/types/async_/chat/completion_list_response.py +31 -0
  47. perplexity/types/chat/__init__.py +5 -0
  48. perplexity/types/chat/completion_create_params.py +244 -0
  49. perplexity/types/search_create_params.py +40 -0
  50. perplexity/types/search_create_response.py +27 -0
  51. perplexity/types/shared/__init__.py +7 -0
  52. perplexity/types/shared/api_public_search_result.py +22 -0
  53. perplexity/types/shared/chat_message_input.py +176 -0
  54. perplexity/types/shared/chat_message_output.py +176 -0
  55. perplexity/types/shared/choice.py +19 -0
  56. perplexity/types/shared/usage_info.py +41 -0
  57. perplexity/types/shared_params/__init__.py +4 -0
  58. perplexity/types/shared_params/api_public_search_result.py +22 -0
  59. perplexity/types/shared_params/chat_message_input.py +178 -0
  60. perplexity/types/stream_chunk.py +33 -0
  61. perplexityai-0.22.3.dist-info/METADATA +548 -0
  62. perplexityai-0.22.3.dist-info/RECORD +64 -0
  63. perplexityai-0.22.3.dist-info/WHEEL +4 -0
  64. perplexityai-0.22.3.dist-info/licenses/LICENSE +201 -0
@@ -0,0 +1,548 @@
1
+ Metadata-Version: 2.3
2
+ Name: perplexityai
3
+ Version: 0.22.3
4
+ Summary: The official Python library for the perplexity API
5
+ Project-URL: Homepage, https://github.com/perplexityai/perplexity-py
6
+ Project-URL: Repository, https://github.com/perplexityai/perplexity-py
7
+ Author-email: Perplexity <api@perplexity.ai>
8
+ License: Apache-2.0
9
+ Classifier: Intended Audience :: Developers
10
+ Classifier: License :: OSI Approved :: Apache Software License
11
+ Classifier: Operating System :: MacOS
12
+ Classifier: Operating System :: Microsoft :: Windows
13
+ Classifier: Operating System :: OS Independent
14
+ Classifier: Operating System :: POSIX
15
+ Classifier: Operating System :: POSIX :: Linux
16
+ Classifier: Programming Language :: Python :: 3.9
17
+ Classifier: Programming Language :: Python :: 3.10
18
+ Classifier: Programming Language :: Python :: 3.11
19
+ Classifier: Programming Language :: Python :: 3.12
20
+ Classifier: Programming Language :: Python :: 3.13
21
+ Classifier: Programming Language :: Python :: 3.14
22
+ Classifier: Topic :: Software Development :: Libraries :: Python Modules
23
+ Classifier: Typing :: Typed
24
+ Requires-Python: >=3.9
25
+ Requires-Dist: anyio<5,>=3.5.0
26
+ Requires-Dist: distro<2,>=1.7.0
27
+ Requires-Dist: httpx<1,>=0.23.0
28
+ Requires-Dist: pydantic<3,>=1.9.0
29
+ Requires-Dist: sniffio
30
+ Requires-Dist: typing-extensions<5,>=4.10
31
+ Provides-Extra: aiohttp
32
+ Requires-Dist: aiohttp; extra == 'aiohttp'
33
+ Requires-Dist: httpx-aiohttp>=0.1.9; extra == 'aiohttp'
34
+ Description-Content-Type: text/markdown
35
+
36
+ # Perplexity Python API library
37
+
38
+ <!-- prettier-ignore -->
39
+ [![PyPI version](https://img.shields.io/pypi/v/perplexityai.svg?label=pypi%20(stable))](https://pypi.org/project/perplexityai/)
40
+
41
+ The Perplexity Python library provides convenient access to the Perplexity REST API from any Python 3.9+
42
+ application. The library includes type definitions for all request params and response fields,
43
+ and offers both synchronous and asynchronous clients powered by [httpx](https://github.com/encode/httpx).
44
+
45
+ It is generated with [Stainless](https://www.stainless.com/).
46
+
47
+ ## Documentation
48
+
49
+ The REST API documentation can be found on [docs.perplexity.ai](https://docs.perplexity.ai/). The full API of this library can be found in [api.md](https://github.com/perplexityai/perplexity-py/tree/main/api.md).
50
+
51
+ ## Installation
52
+
53
+ ```sh
54
+ # install from PyPI
55
+ pip install perplexityai
56
+ ```
57
+
58
+ ## Search API
59
+
60
+ Get web search results:
61
+
62
+ ```python
63
+ import os
64
+ from perplexity import Perplexity
65
+
66
+ client = Perplexity(
67
+ api_key=os.environ.get("PERPLEXITY_API_KEY"), # This is the default and can be omitted
68
+ )
69
+
70
+ search = client.search.create(
71
+ query="latest AI developments 2024",
72
+ max_results=5
73
+ )
74
+
75
+ for result in search.results:
76
+ print(f"{result.title}: {result.url}")
77
+ ```
78
+
79
+ ## Chat Completions
80
+
81
+ The full API of this library can be found in [api.md](https://github.com/perplexityai/perplexity-py/tree/main/api.md).
82
+
83
+ ```python
84
+ import os
85
+ from perplexity import Perplexity
86
+
87
+ client = Perplexity(
88
+ api_key=os.environ.get("PERPLEXITY_API_KEY"), # This is the default and can be omitted
89
+ )
90
+
91
+ stream_chunk = client.chat.completions.create(
92
+ messages=[
93
+ {
94
+ "role": "user",
95
+ "content": "Tell me about the latest developments in AI",
96
+ }
97
+ ],
98
+ model="sonar",
99
+ )
100
+ print(stream_chunk.id)
101
+ ```
102
+
103
+ While you can provide an `api_key` keyword argument,
104
+ we recommend using [python-dotenv](https://pypi.org/project/python-dotenv/)
105
+ to add `PERPLEXITY_API_KEY="My API Key"` to your `.env` file
106
+ so that your API Key is not stored in source control.
107
+
108
+ ## Async usage
109
+
110
+ Simply import `AsyncPerplexity` instead of `Perplexity` and use `await` with each API call:
111
+
112
+ ```python
113
+ import os
114
+ import asyncio
115
+ from perplexity import AsyncPerplexity
116
+
117
+ client = AsyncPerplexity(
118
+ api_key=os.environ.get("PERPLEXITY_API_KEY"), # This is the default and can be omitted
119
+ )
120
+
121
+
122
+ async def main() -> None:
123
+ stream_chunk = await client.chat.completions.create(
124
+ messages=[
125
+ {
126
+ "role": "user",
127
+ "content": "Tell me about the latest developments in AI",
128
+ }
129
+ ],
130
+ model="sonar",
131
+ )
132
+ print(stream_chunk.id)
133
+
134
+
135
+ asyncio.run(main())
136
+ ```
137
+
138
+ Functionality between the synchronous and asynchronous clients is otherwise identical.
139
+
140
+ ### With aiohttp
141
+
142
+ By default, the async client uses `httpx` for HTTP requests. However, for improved concurrency performance you may also use `aiohttp` as the HTTP backend.
143
+
144
+ You can enable this by installing `aiohttp`:
145
+
146
+ ```sh
147
+ # install from PyPI
148
+ pip install perplexityai[aiohttp]
149
+ ```
150
+
151
+ Then you can enable it by instantiating the client with `http_client=DefaultAioHttpClient()`:
152
+
153
+ ```python
154
+ import os
155
+ import asyncio
156
+ from perplexity import DefaultAioHttpClient
157
+ from perplexity import AsyncPerplexity
158
+
159
+
160
+ async def main() -> None:
161
+ async with AsyncPerplexity(
162
+ api_key=os.environ.get("PERPLEXITY_API_KEY"), # This is the default and can be omitted
163
+ http_client=DefaultAioHttpClient(),
164
+ ) as client:
165
+ stream_chunk = await client.chat.completions.create(
166
+ messages=[
167
+ {
168
+ "role": "user",
169
+ "content": "Tell me about the latest developments in AI",
170
+ }
171
+ ],
172
+ model="sonar",
173
+ )
174
+ print(stream_chunk.id)
175
+
176
+
177
+ asyncio.run(main())
178
+ ```
179
+
180
+ ## Streaming responses
181
+
182
+ We provide support for streaming responses using Server Side Events (SSE).
183
+
184
+ ```python
185
+ from perplexity import Perplexity
186
+
187
+ client = Perplexity()
188
+
189
+ stream = client.chat.completions.create(
190
+ messages=[
191
+ {
192
+ "role": "user",
193
+ "content": "Tell me about the latest developments in AI",
194
+ }
195
+ ],
196
+ model="sonar",
197
+ stream=True,
198
+ )
199
+ for stream_chunk in stream:
200
+ print(stream_chunk.id)
201
+ ```
202
+
203
+ The async client uses the exact same interface.
204
+
205
+ ```python
206
+ from perplexity import AsyncPerplexity
207
+
208
+ client = AsyncPerplexity()
209
+
210
+ stream = await client.chat.completions.create(
211
+ messages=[
212
+ {
213
+ "role": "user",
214
+ "content": "Tell me about the latest developments in AI",
215
+ }
216
+ ],
217
+ model="sonar",
218
+ stream=True,
219
+ )
220
+ async for stream_chunk in stream:
221
+ print(stream_chunk.id)
222
+ ```
223
+
224
+ ## Using types
225
+
226
+ Nested request parameters are [TypedDicts](https://docs.python.org/3/library/typing.html#typing.TypedDict). Responses are [Pydantic models](https://docs.pydantic.dev) which also provide helper methods for things like:
227
+
228
+ - Serializing back into JSON, `model.to_json()`
229
+ - Converting to a dictionary, `model.to_dict()`
230
+
231
+ Typed requests and responses provide autocomplete and documentation within your editor. If you would like to see type errors in VS Code to help catch bugs earlier, set `python.analysis.typeCheckingMode` to `basic`.
232
+
233
+ ## Nested params
234
+
235
+ Nested parameters are dictionaries, typed using `TypedDict`, for example:
236
+
237
+ ```python
238
+ from perplexity import Perplexity
239
+
240
+ client = Perplexity()
241
+
242
+ stream_chunk = client.chat.completions.create(
243
+ messages=[
244
+ {
245
+ "content": "string",
246
+ "role": "system",
247
+ }
248
+ ],
249
+ model="model",
250
+ web_search_options={},
251
+ )
252
+ print(stream_chunk.web_search_options)
253
+ ```
254
+
255
+ ## Handling errors
256
+
257
+ When the library is unable to connect to the API (for example, due to network connection problems or a timeout), a subclass of `perplexity.APIConnectionError` is raised.
258
+
259
+ When the API returns a non-success status code (that is, 4xx or 5xx
260
+ response), a subclass of `perplexity.APIStatusError` is raised, containing `status_code` and `response` properties.
261
+
262
+ All errors inherit from `perplexity.APIError`.
263
+
264
+ ```python
265
+ import perplexity
266
+ from perplexity import Perplexity
267
+
268
+ client = Perplexity()
269
+
270
+ try:
271
+ client.chat.completions.create(
272
+ messages=[
273
+ {
274
+ "role": "user",
275
+ "content": "What is the capital of France?",
276
+ }
277
+ ],
278
+ model="sonar",
279
+ )
280
+ except perplexity.APIConnectionError as e:
281
+ print("The server could not be reached")
282
+ print(e.__cause__) # an underlying Exception, likely raised within httpx.
283
+ except perplexity.RateLimitError as e:
284
+ print("A 429 status code was received; we should back off a bit.")
285
+ except perplexity.APIStatusError as e:
286
+ print("Another non-200-range status code was received")
287
+ print(e.status_code)
288
+ print(e.response)
289
+ ```
290
+
291
+ Error codes are as follows:
292
+
293
+ | Status Code | Error Type |
294
+ | ----------- | -------------------------- |
295
+ | 400 | `BadRequestError` |
296
+ | 401 | `AuthenticationError` |
297
+ | 403 | `PermissionDeniedError` |
298
+ | 404 | `NotFoundError` |
299
+ | 422 | `UnprocessableEntityError` |
300
+ | 429 | `RateLimitError` |
301
+ | >=500 | `InternalServerError` |
302
+ | N/A | `APIConnectionError` |
303
+
304
+ ### Retries
305
+
306
+ Certain errors are automatically retried 2 times by default, with a short exponential backoff.
307
+ Connection errors (for example, due to a network connectivity problem), 408 Request Timeout, 409 Conflict,
308
+ 429 Rate Limit, and >=500 Internal errors are all retried by default.
309
+
310
+ You can use the `max_retries` option to configure or disable retry settings:
311
+
312
+ ```python
313
+ from perplexity import Perplexity
314
+
315
+ # Configure the default for all requests:
316
+ client = Perplexity(
317
+ # default is 2
318
+ max_retries=0,
319
+ )
320
+
321
+ # Or, configure per-request:
322
+ client.with_options(max_retries=5).chat.completions.create(
323
+ messages=[
324
+ {
325
+ "role": "user",
326
+ "content": "What is the capital of France?",
327
+ }
328
+ ],
329
+ model="sonar",
330
+ )
331
+ ```
332
+
333
+ ### Timeouts
334
+
335
+ By default requests time out after 15 minutes. You can configure this with a `timeout` option,
336
+ which accepts a float or an [`httpx.Timeout`](https://www.python-httpx.org/advanced/timeouts/#fine-tuning-the-configuration) object:
337
+
338
+ ```python
339
+ from perplexity import Perplexity
340
+
341
+ # Configure the default for all requests:
342
+ client = Perplexity(
343
+ # 20 seconds (default is 15 minutes)
344
+ timeout=20.0,
345
+ )
346
+
347
+ # More granular control:
348
+ client = Perplexity(
349
+ timeout=httpx.Timeout(60.0, read=5.0, write=10.0, connect=2.0),
350
+ )
351
+
352
+ # Override per-request:
353
+ client.with_options(timeout=5.0).chat.completions.create(
354
+ messages=[
355
+ {
356
+ "role": "user",
357
+ "content": "What is the capital of France?",
358
+ }
359
+ ],
360
+ model="sonar",
361
+ )
362
+ ```
363
+
364
+ On timeout, an `APITimeoutError` is thrown.
365
+
366
+ Note that requests that time out are [retried twice by default](https://github.com/perplexityai/perplexity-py/tree/main/#retries).
367
+
368
+ ## Advanced
369
+
370
+ ### Logging
371
+
372
+ We use the standard library [`logging`](https://docs.python.org/3/library/logging.html) module.
373
+
374
+ You can enable logging by setting the environment variable `PERPLEXITY_LOG` to `info`.
375
+
376
+ ```shell
377
+ $ export PERPLEXITY_LOG=info
378
+ ```
379
+
380
+ Or to `debug` for more verbose logging.
381
+
382
+ ### How to tell whether `None` means `null` or missing
383
+
384
+ In an API response, a field may be explicitly `null`, or missing entirely; in either case, its value is `None` in this library. You can differentiate the two cases with `.model_fields_set`:
385
+
386
+ ```py
387
+ if response.my_field is None:
388
+ if 'my_field' not in response.model_fields_set:
389
+ print('Got json like {}, without a "my_field" key present at all.')
390
+ else:
391
+ print('Got json like {"my_field": null}.')
392
+ ```
393
+
394
+ ### Accessing raw response data (e.g. headers)
395
+
396
+ The "raw" Response object can be accessed by prefixing `.with_raw_response.` to any HTTP method call, e.g.,
397
+
398
+ ```py
399
+ from perplexity import Perplexity
400
+
401
+ client = Perplexity()
402
+ response = client.chat.completions.with_raw_response.create(
403
+ messages=[{
404
+ "role": "user",
405
+ "content": "What is the capital of France?",
406
+ }],
407
+ model="sonar",
408
+ )
409
+ print(response.headers.get('X-My-Header'))
410
+
411
+ completion = response.parse() # get the object that `chat.completions.create()` would have returned
412
+ print(completion.id)
413
+ ```
414
+
415
+ These methods return an [`APIResponse`](https://github.com/perplexityai/perplexity-py/tree/main/src/perplexity/_response.py) object.
416
+
417
+ The async client returns an [`AsyncAPIResponse`](https://github.com/perplexityai/perplexity-py/tree/main/src/perplexity/_response.py) with the same structure, the only difference being `await`able methods for reading the response content.
418
+
419
+ #### `.with_streaming_response`
420
+
421
+ The above interface eagerly reads the full response body when you make the request, which may not always be what you want.
422
+
423
+ To stream the response body, use `.with_streaming_response` instead, which requires a context manager and only reads the response body once you call `.read()`, `.text()`, `.json()`, `.iter_bytes()`, `.iter_text()`, `.iter_lines()` or `.parse()`. In the async client, these are async methods.
424
+
425
+ ```python
426
+ with client.chat.completions.with_streaming_response.create(
427
+ messages=[
428
+ {
429
+ "role": "user",
430
+ "content": "What is the capital of France?",
431
+ }
432
+ ],
433
+ model="sonar",
434
+ ) as response:
435
+ print(response.headers.get("X-My-Header"))
436
+
437
+ for line in response.iter_lines():
438
+ print(line)
439
+ ```
440
+
441
+ The context manager is required so that the response will reliably be closed.
442
+
443
+ ### Making custom/undocumented requests
444
+
445
+ This library is typed for convenient access to the documented API.
446
+
447
+ If you need to access undocumented endpoints, params, or response properties, the library can still be used.
448
+
449
+ #### Undocumented endpoints
450
+
451
+ To make requests to undocumented endpoints, you can make requests using `client.get`, `client.post`, and other
452
+ http verbs. Options on the client will be respected (such as retries) when making this request.
453
+
454
+ ```py
455
+ import httpx
456
+
457
+ response = client.post(
458
+ "/foo",
459
+ cast_to=httpx.Response,
460
+ body={"my_param": True},
461
+ )
462
+
463
+ print(response.headers.get("x-foo"))
464
+ ```
465
+
466
+ #### Undocumented request params
467
+
468
+ If you want to explicitly send an extra param, you can do so with the `extra_query`, `extra_body`, and `extra_headers` request
469
+ options.
470
+
471
+ #### Undocumented response properties
472
+
473
+ To access undocumented response properties, you can access the extra fields like `response.unknown_prop`. You
474
+ can also get all the extra fields on the Pydantic model as a dict with
475
+ [`response.model_extra`](https://docs.pydantic.dev/latest/api/base_model/#pydantic.BaseModel.model_extra).
476
+
477
+ ### Configuring the HTTP client
478
+
479
+ You can directly override the [httpx client](https://www.python-httpx.org/api/#client) to customize it for your use case, including:
480
+
481
+ - Support for [proxies](https://www.python-httpx.org/advanced/proxies/)
482
+ - Custom [transports](https://www.python-httpx.org/advanced/transports/)
483
+ - Additional [advanced](https://www.python-httpx.org/advanced/clients/) functionality
484
+
485
+ ```python
486
+ import httpx
487
+ from perplexity import Perplexity, DefaultHttpxClient
488
+
489
+ client = Perplexity(
490
+ # Or use the `PERPLEXITY_BASE_URL` env var
491
+ base_url="http://my.test.server.example.com:8083",
492
+ http_client=DefaultHttpxClient(
493
+ proxy="http://my.test.proxy.example.com",
494
+ transport=httpx.HTTPTransport(local_address="0.0.0.0"),
495
+ ),
496
+ )
497
+ ```
498
+
499
+ You can also customize the client on a per-request basis by using `with_options()`:
500
+
501
+ ```python
502
+ client.with_options(http_client=DefaultHttpxClient(...))
503
+ ```
504
+
505
+ ### Managing HTTP resources
506
+
507
+ By default the library closes underlying HTTP connections whenever the client is [garbage collected](https://docs.python.org/3/reference/datamodel.html#object.__del__). You can manually close the client using the `.close()` method if desired, or with a context manager that closes when exiting.
508
+
509
+ ```py
510
+ from perplexity import Perplexity
511
+
512
+ with Perplexity() as client:
513
+ # make requests here
514
+ ...
515
+
516
+ # HTTP client is now closed
517
+ ```
518
+
519
+ ## Versioning
520
+
521
+ This package generally follows [SemVer](https://semver.org/spec/v2.0.0.html) conventions, though certain backwards-incompatible changes may be released as minor versions:
522
+
523
+ 1. Changes that only affect static types, without breaking runtime behavior.
524
+ 2. Changes to library internals which are technically public but not intended or documented for external use. _(Please open a GitHub issue to let us know if you are relying on such internals.)_
525
+ 3. Changes that we do not expect to impact the vast majority of users in practice.
526
+
527
+ We take backwards-compatibility seriously and work hard to ensure you can rely on a smooth upgrade experience.
528
+
529
+ We are keen for your feedback; please open an [issue](https://www.github.com/perplexityai/perplexity-py/issues) with questions, bugs, or suggestions.
530
+
531
+ ### Determining the installed version
532
+
533
+ If you've upgraded to the latest version but aren't seeing any new features you were expecting then your python environment is likely still using an older version.
534
+
535
+ You can determine the version that is being used at runtime with:
536
+
537
+ ```py
538
+ import perplexity
539
+ print(perplexity.__version__)
540
+ ```
541
+
542
+ ## Requirements
543
+
544
+ Python 3.9 or higher.
545
+
546
+ ## Contributing
547
+
548
+ See [the contributing documentation](https://github.com/perplexityai/perplexity-py/tree/main/./CONTRIBUTING.md).
@@ -0,0 +1,64 @@
1
+ perplexity/__init__.py,sha256=tK4KC0qHjpk-ym2IM9lG56HeBXAHz36gMzb0rmWEa7Y,2701
2
+ perplexity/_base_client.py,sha256=h5mizTpPKlwSg7L-GwomLjrykvjkuFUzFKQ4Zsa30BE,67251
3
+ perplexity/_client.py,sha256=npj0jZnXldAiSV21DAUYxg1zf6_SJJUw-TDjA2MMkOY,18934
4
+ perplexity/_compat.py,sha256=DQBVORjFb33zch24jzkhM14msvnzY7mmSmgDLaVFUM8,6562
5
+ perplexity/_constants.py,sha256=oW-FKtjJhtWarQ-F2rUj1t-cL1dM5ksKu9d5yst1l7c,465
6
+ perplexity/_exceptions.py,sha256=v-hOXWSDTEtXcn_By7pPml3HjEmG5HXpbE-RK_A6_0Q,3228
7
+ perplexity/_files.py,sha256=KnEzGi_O756MvKyJ4fOCW_u3JhOeWPQ4RsmDvqihDQU,3545
8
+ perplexity/_models.py,sha256=3D65psj_C02Mw0K2zpBWrn1khmrvtEXgTTQ6P4r3tUY,31837
9
+ perplexity/_qs.py,sha256=craIKyvPktJ94cvf9zn8j8ekG9dWJzhWv0ob34lIOv4,4828
10
+ perplexity/_resource.py,sha256=Pgc8KNBsIc1ltJn94uhDcDl0-3n5RLbe3iC2AiiNRnE,1124
11
+ perplexity/_response.py,sha256=bpqzmVGq6jnivoMkUgt3OI0Rh6xHd6BMcp5PHgSFPb0,28842
12
+ perplexity/_streaming.py,sha256=jqEfZujFBTZKYT8K82vN8EFHFCivUtZAEiiGVneR64I,11495
13
+ perplexity/_types.py,sha256=l354eUJFtNhWqu0zj44GtXUnC28wq0gXY-RWfRw_RR4,7299
14
+ perplexity/_version.py,sha256=tLcKuJXmO9x6_LQvqbWYGw14FyiuqnFOkFv_XnfUaL8,163
15
+ perplexity/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
16
+ perplexity/_utils/__init__.py,sha256=7fch0GT9zpNnErbciSpUNa-SjTxxjY6kxHxKMOM4AGs,2305
17
+ perplexity/_utils/_compat.py,sha256=D8gtAvjJQrDWt9upS0XaG9Rr5l1QhiAx_I_1utT_tt0,1195
18
+ perplexity/_utils/_datetime_parse.py,sha256=bABTs0Bc6rabdFvnIwXjEhWL15TcRgWZ_6XGTqN8xUk,4204
19
+ perplexity/_utils/_logs.py,sha256=CsE-zYnAQTOCueNGVjEn6bozMyE86gdjMhJDNWDLpaQ,786
20
+ perplexity/_utils/_proxy.py,sha256=aglnj2yBTDyGX9Akk2crZHrl10oqRmceUy2Zp008XEs,1975
21
+ perplexity/_utils/_reflection.py,sha256=ZmGkIgT_PuwedyNBrrKGbxoWtkpytJNU1uU4QHnmEMU,1364
22
+ perplexity/_utils/_resources_proxy.py,sha256=iMCHPeYmXwSunawEq3fcKGszOF3kL9w1ob-48Xnl04I,609
23
+ perplexity/_utils/_streams.py,sha256=SMC90diFFecpEg_zgDRVbdR3hSEIgVVij4taD-noMLM,289
24
+ perplexity/_utils/_sync.py,sha256=HBnZkkBnzxtwOZe0212C4EyoRvxhTVtTrLFDz2_xVCg,1589
25
+ perplexity/_utils/_transform.py,sha256=NjCzmnfqYrsAikUHQig6N9QfuTVbKipuP3ur9mcNF-E,15951
26
+ perplexity/_utils/_typing.py,sha256=N_5PPuFNsaygbtA_npZd98SVN1LQQvFTKL6bkWPBZGU,4786
27
+ perplexity/_utils/_utils.py,sha256=ugfUaneOK7I8h9b3656flwf5u_kthY0gvNuqvgOLoSU,12252
28
+ perplexity/lib/.keep,sha256=wuNrz-5SXo3jJaJOJgz4vFHM41YH_g20F5cRQo0vLes,224
29
+ perplexity/resources/__init__.py,sha256=GGUtTVP3Hlh9qMVd62OlwpV5t7WswIQ1fKqnKiTmyjc,1414
30
+ perplexity/resources/search.py,sha256=tT82b5ApXtAsDKicNq09p70fNDi3Lxq2ZnZl51mHcdw,9510
31
+ perplexity/resources/async_/__init__.py,sha256=hvcoEKx4nCYPDoBSO_sk-uNVQ7y-fmNhzvAlvX19TIo,964
32
+ perplexity/resources/async_/async_.py,sha256=XzvC3AMbXXQ9mqe9TI10ZSmEuXaWPRwNC4E7AjvNdg0,3534
33
+ perplexity/resources/async_/chat/__init__.py,sha256=BVAfz9TM3DT5W9f_mt0P9YRxL_MsUxKCWAH6u1iogmA,1041
34
+ perplexity/resources/async_/chat/chat.py,sha256=M3hN3sfZKAt1C8FhOaWtxFPJAmPyE-GXkiU_LSN9EiA,3682
35
+ perplexity/resources/async_/chat/completions.py,sha256=6SuFVsjkXld0iASJKVKcjPKeFivLzLToZQqqA8nqLr8,14075
36
+ perplexity/resources/chat/__init__.py,sha256=BVAfz9TM3DT5W9f_mt0P9YRxL_MsUxKCWAH6u1iogmA,1041
37
+ perplexity/resources/chat/chat.py,sha256=yvQmxxpr7k9-A8UwUukL5QIXHahfsdFjHQqRFWWbkzE,3680
38
+ perplexity/resources/chat/completions.py,sha256=NCu-cK49SnPB2jkVXYsAQhvWBgqYYoJTp6qWclqtMf0,46318
39
+ perplexity/types/__init__.py,sha256=LpZgQmlRWsFC0_xIzJhxSd2VY-vxDdAplR0Oqmtnu4M,544
40
+ perplexity/types/search_create_params.py,sha256=LsoMsn9thnCUh1CGFPyQN0esZlZ0557DqTATmZsu0ac,973
41
+ perplexity/types/search_create_response.py,sha256=u4biwHjn5krPDOTRuolb1DyCPBRNATsuFs_Hynqxgro,465
42
+ perplexity/types/stream_chunk.py,sha256=GxPn4KENvDhhJ8sLc297_fd3XrhZeEansYbTtjl21kA,782
43
+ perplexity/types/async_/__init__.py,sha256=OKfJYcKb4NObdiRObqJV_dOyDQ8feXekDUge2o_4pXQ,122
44
+ perplexity/types/async_/chat/__init__.py,sha256=xo2Cya_CfjEBRos2yvW_Wrq39PZiXFBT7ukZZBNvIUM,552
45
+ perplexity/types/async_/chat/completion_create_params.py,sha256=X4kBJRLIAJWpisijSdKZyUK5hfUbeSbTS6aL-eNd8IA,5579
46
+ perplexity/types/async_/chat/completion_create_response.py,sha256=XXYz7p2TVGn5iu5TklCm7nNpMjufuUO3YHNGPTpAmWU,676
47
+ perplexity/types/async_/chat/completion_get_params.py,sha256=1z3T0rG-xkDubzUtuBzXkI1M-pb4jcfpWpbF-Qoco7g,768
48
+ perplexity/types/async_/chat/completion_get_response.py,sha256=YTbspM1VcWRpUa5Wxmg6P7oA3S8yLLcY2mPuBXZqECI,670
49
+ perplexity/types/async_/chat/completion_list_response.py,sha256=63QSRV-2YA6gMZhyrmiZuzxasjjwT-kM3MyFuadTnZs,658
50
+ perplexity/types/chat/__init__.py,sha256=9VtUhUp2vFpm5fgy2tMc-XF9NfkBXdFZvSzLmNprkqk,210
51
+ perplexity/types/chat/completion_create_params.py,sha256=RLy23Jy0ymt9Nx_7Qip-HUDYa1wdaHFAXQJ2GmpPR4Q,5604
52
+ perplexity/types/shared/__init__.py,sha256=-RlflcttJZ_q_lP6YD0mVWbKhU33j91tUVuMO5OqMAM,397
53
+ perplexity/types/shared/api_public_search_result.py,sha256=Udw-8Or0dr_24LAhDQp-9OTkli2hw3WWp2BNEWuEeTI,461
54
+ perplexity/types/shared/chat_message_input.py,sha256=HNlYhtj1ZHq05z__g3bRuMl3JQWHFP5sGeWYvVb0PLU,5124
55
+ perplexity/types/shared/chat_message_output.py,sha256=BVX_0wmpAWHe_jdD0tf0aN4s1Cb7NoNlMGqItOoYSJc,5126
56
+ perplexity/types/shared/choice.py,sha256=enGVvSlz6W4fC6scq9j_E1zxvMnSG_IxU0plF9jYiJE,427
57
+ perplexity/types/shared/usage_info.py,sha256=_jE7Nal9cMxtEpJjT4t2SAs6z3MufrjwPugsRomqc9c,782
58
+ perplexity/types/shared_params/__init__.py,sha256=v5gr6-wq7IWgrQ8un401oApylzh3KnsIF_ilz-roX0s,241
59
+ perplexity/types/shared_params/api_public_search_result.py,sha256=JPT8jm4IALOc51HgTQGUiMbSgTt10oeh4zti4KjcnkU,469
60
+ perplexity/types/shared_params/chat_message_input.py,sha256=h08XawbIOMJ8aszLTG7pHsVPnvraJsy0fy7ykBFKA9k,5536
61
+ perplexityai-0.22.3.dist-info/METADATA,sha256=CEIehiWU7uE5kvpqxo8ZI77LZtP38k0G-2k3Bi0RVZI,16791
62
+ perplexityai-0.22.3.dist-info/WHEEL,sha256=C2FUgwZgiLbznR-k0b_5k3Ai_1aASOXDss3lzCUsUug,87
63
+ perplexityai-0.22.3.dist-info/licenses/LICENSE,sha256=zKSCTgriCVxPVz-2OUJLESu2mQA8h5ORBLokMk9tJu8,11340
64
+ perplexityai-0.22.3.dist-info/RECORD,,
@@ -0,0 +1,4 @@
1
+ Wheel-Version: 1.0
2
+ Generator: hatchling 1.26.3
3
+ Root-Is-Purelib: true
4
+ Tag: py3-none-any