Skip to content

Commit 02db6c0

Browse files
feat(api): manual updates - update openapi spec
added session_id
1 parent dec81af commit 02db6c0

64 files changed

Lines changed: 1287 additions & 782 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.stats.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
configured_endpoints: 23
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/parallel-web%2Fparallel-sdk-7099c3aac2f0edacf413e426c176150404e1603f709cdd1f0af5c6689d33bd4f.yml
3-
openapi_spec_hash: eb61e027506aa339543ce33d7f052046
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/parallel-web%2Fparallel-sdk-c4cc922783460c6e65811d13c9abe35807a551c77c126d452806f93caaaf48fb.yml
3+
openapi_spec_hash: 99c9e48d4dafaca71f058107008d174b
44
config_hash: fe820a5a10ee48e143c9e49a153b23b4

src/parallel/_client.py

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -236,6 +236,7 @@ def extract(
236236
max_chars_total: Optional[int] | Omit = omit,
237237
objective: Optional[str] | Omit = omit,
238238
search_queries: Optional[SequenceNotStr[str]] | Omit = omit,
239+
session_id: Optional[str] | Omit = omit,
239240
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
240241
# The extra values given here take precedence over values defined on the client or passed to this method.
241242
extra_headers: Headers | None = None,
@@ -251,6 +252,9 @@ def extract(
251252
252253
advanced_settings: Advanced extract configuration.
253254
255+
These settings may impact result quality and latency unless used carefully. See
256+
https://docs.parallel.ai/search/advanced-extract-settings for more info.
257+
254258
client_model: The model generating this request and consuming the results. Enables
255259
optimizations and tailors default settings for the model's capabilities.
256260
@@ -265,6 +269,10 @@ def extract(
265269
search_queries: Optional keyword search queries, as in SearchRequest. Used together with
266270
objective to focus excerpts on the most relevant content.
267271
272+
session_id: Session identifier for calls to search and extract made by an agent as part of a
273+
larger task. May be a user-generated random string, e.g. a uuid, or a session_id
274+
returned by a previous request.
275+
268276
extra_headers: Send extra headers
269277
270278
extra_query: Add additional query parameters to the request
@@ -283,6 +291,7 @@ def extract(
283291
"max_chars_total": max_chars_total,
284292
"objective": objective,
285293
"search_queries": search_queries,
294+
"session_id": session_id,
286295
},
287296
client_extract_params.ClientExtractParams,
288297
),
@@ -301,6 +310,7 @@ def search(
301310
max_chars_total: Optional[int] | Omit = omit,
302311
mode: Optional[Literal["basic", "standard"]] | Omit = omit,
303312
objective: Optional[str] | Omit = omit,
313+
session_id: Optional[str] | Omit = omit,
304314
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
305315
# The extra values given here take precedence over values defined on the client or passed to this method.
306316
extra_headers: Headers | None = None,
@@ -318,6 +328,9 @@ def search(
318328
319329
advanced_settings: Advanced search configuration.
320330
331+
These settings may impact result quality and latency unless used carefully. See
332+
https://docs.parallel.ai/search/advanced-search-settings for more info.
333+
321334
client_model: The model generating this request and consuming the results. Enables
322335
optimizations and tailors default settings for the model's capabilities.
323336
@@ -334,6 +347,10 @@ def search(
334347
content. Should be self-contained with enough context to understand the intent
335348
of the search.
336349
350+
session_id: Session identifier for calls to search and extract made by an agent as part of a
351+
larger task. May be a user-generated random string, e.g. a uuid, or a session_id
352+
returned by a previous request.
353+
337354
extra_headers: Send extra headers
338355
339356
extra_query: Add additional query parameters to the request
@@ -352,6 +369,7 @@ def search(
352369
"max_chars_total": max_chars_total,
353370
"mode": mode,
354371
"objective": objective,
372+
"session_id": session_id,
355373
},
356374
client_search_params.ClientSearchParams,
357375
),
@@ -562,6 +580,7 @@ async def extract(
562580
max_chars_total: Optional[int] | Omit = omit,
563581
objective: Optional[str] | Omit = omit,
564582
search_queries: Optional[SequenceNotStr[str]] | Omit = omit,
583+
session_id: Optional[str] | Omit = omit,
565584
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
566585
# The extra values given here take precedence over values defined on the client or passed to this method.
567586
extra_headers: Headers | None = None,
@@ -577,6 +596,9 @@ async def extract(
577596
578597
advanced_settings: Advanced extract configuration.
579598
599+
These settings may impact result quality and latency unless used carefully. See
600+
https://docs.parallel.ai/search/advanced-extract-settings for more info.
601+
580602
client_model: The model generating this request and consuming the results. Enables
581603
optimizations and tailors default settings for the model's capabilities.
582604
@@ -591,6 +613,10 @@ async def extract(
591613
search_queries: Optional keyword search queries, as in SearchRequest. Used together with
592614
objective to focus excerpts on the most relevant content.
593615
616+
session_id: Session identifier for calls to search and extract made by an agent as part of a
617+
larger task. May be a user-generated random string, e.g. a uuid, or a session_id
618+
returned by a previous request.
619+
594620
extra_headers: Send extra headers
595621
596622
extra_query: Add additional query parameters to the request
@@ -609,6 +635,7 @@ async def extract(
609635
"max_chars_total": max_chars_total,
610636
"objective": objective,
611637
"search_queries": search_queries,
638+
"session_id": session_id,
612639
},
613640
client_extract_params.ClientExtractParams,
614641
),
@@ -627,6 +654,7 @@ async def search(
627654
max_chars_total: Optional[int] | Omit = omit,
628655
mode: Optional[Literal["basic", "standard"]] | Omit = omit,
629656
objective: Optional[str] | Omit = omit,
657+
session_id: Optional[str] | Omit = omit,
630658
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
631659
# The extra values given here take precedence over values defined on the client or passed to this method.
632660
extra_headers: Headers | None = None,
@@ -644,6 +672,9 @@ async def search(
644672
645673
advanced_settings: Advanced search configuration.
646674
675+
These settings may impact result quality and latency unless used carefully. See
676+
https://docs.parallel.ai/search/advanced-search-settings for more info.
677+
647678
client_model: The model generating this request and consuming the results. Enables
648679
optimizations and tailors default settings for the model's capabilities.
649680
@@ -660,6 +691,10 @@ async def search(
660691
content. Should be self-contained with enough context to understand the intent
661692
of the search.
662693
694+
session_id: Session identifier for calls to search and extract made by an agent as part of a
695+
larger task. May be a user-generated random string, e.g. a uuid, or a session_id
696+
returned by a previous request.
697+
663698
extra_headers: Send extra headers
664699
665700
extra_query: Add additional query parameters to the request
@@ -678,6 +713,7 @@ async def search(
678713
"max_chars_total": max_chars_total,
679714
"mode": mode,
680715
"objective": objective,
716+
"session_id": session_id,
681717
},
682718
client_search_params.ClientSearchParams,
683719
),

src/parallel/resources/beta/beta.py

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -122,6 +122,7 @@ def extract(
122122
full_content: beta_extract_params.FullContent | Omit = omit,
123123
objective: Optional[str] | Omit = omit,
124124
search_queries: Optional[SequenceNotStr[str]] | Omit = omit,
125+
session_id: Optional[str] | Omit = omit,
125126
betas: List[ParallelBetaParam] | Omit = omit,
126127
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
127128
# The extra values given here take precedence over values defined on the client or passed to this method.
@@ -150,6 +151,10 @@ def extract(
150151
151152
search_queries: If provided, focuses extracted content on the specified keyword search queries.
152153
154+
session_id: Session identifier for calls to search and extract made by an agent as part of a
155+
larger task. May be a user-generated random string (e.g. a uuid) or a session_id
156+
from a previous request.
157+
153158
betas: Optional header to specify the beta version(s) to enable.
154159
155160
extra_headers: Send extra headers
@@ -181,6 +186,7 @@ def extract(
181186
"full_content": full_content,
182187
"objective": objective,
183188
"search_queries": search_queries,
189+
"session_id": session_id,
184190
},
185191
beta_extract_params.BetaExtractParams,
186192
),
@@ -202,6 +208,7 @@ def search(
202208
objective: Optional[str] | Omit = omit,
203209
processor: Optional[Literal["base", "pro"]] | Omit = omit,
204210
search_queries: Optional[SequenceNotStr[str]] | Omit = omit,
211+
session_id: Optional[str] | Omit = omit,
205212
source_policy: Optional[SourcePolicy] | Omit = omit,
206213
betas: List[ParallelBetaParam] | Omit = omit,
207214
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
@@ -244,6 +251,10 @@ def search(
244251
contain search operators. At least one of objective or search_queries must be
245252
provided.
246253
254+
session_id: Session identifier for calls to search and extract made by an agent as part of a
255+
larger task. May be a user-generated random string (e.g. a uuid) or a session_id
256+
from a previous request.
257+
247258
source_policy: Source policy for web search results.
248259
249260
This policy governs which sources are allowed/disallowed in results.
@@ -282,6 +293,7 @@ def search(
282293
"objective": objective,
283294
"processor": processor,
284295
"search_queries": search_queries,
296+
"session_id": session_id,
285297
"source_policy": source_policy,
286298
},
287299
beta_search_params.BetaSearchParams,
@@ -361,6 +373,7 @@ async def extract(
361373
full_content: beta_extract_params.FullContent | Omit = omit,
362374
objective: Optional[str] | Omit = omit,
363375
search_queries: Optional[SequenceNotStr[str]] | Omit = omit,
376+
session_id: Optional[str] | Omit = omit,
364377
betas: List[ParallelBetaParam] | Omit = omit,
365378
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
366379
# The extra values given here take precedence over values defined on the client or passed to this method.
@@ -389,6 +402,10 @@ async def extract(
389402
390403
search_queries: If provided, focuses extracted content on the specified keyword search queries.
391404
405+
session_id: Session identifier for calls to search and extract made by an agent as part of a
406+
larger task. May be a user-generated random string (e.g. a uuid) or a session_id
407+
from a previous request.
408+
392409
betas: Optional header to specify the beta version(s) to enable.
393410
394411
extra_headers: Send extra headers
@@ -420,6 +437,7 @@ async def extract(
420437
"full_content": full_content,
421438
"objective": objective,
422439
"search_queries": search_queries,
440+
"session_id": session_id,
423441
},
424442
beta_extract_params.BetaExtractParams,
425443
),
@@ -441,6 +459,7 @@ async def search(
441459
objective: Optional[str] | Omit = omit,
442460
processor: Optional[Literal["base", "pro"]] | Omit = omit,
443461
search_queries: Optional[SequenceNotStr[str]] | Omit = omit,
462+
session_id: Optional[str] | Omit = omit,
444463
source_policy: Optional[SourcePolicy] | Omit = omit,
445464
betas: List[ParallelBetaParam] | Omit = omit,
446465
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
@@ -483,6 +502,10 @@ async def search(
483502
contain search operators. At least one of objective or search_queries must be
484503
provided.
485504
505+
session_id: Session identifier for calls to search and extract made by an agent as part of a
506+
larger task. May be a user-generated random string (e.g. a uuid) or a session_id
507+
from a previous request.
508+
486509
source_policy: Source policy for web search results.
487510
488511
This policy governs which sources are allowed/disallowed in results.
@@ -521,6 +544,7 @@ async def search(
521544
"objective": objective,
522545
"processor": processor,
523546
"search_queries": search_queries,
547+
"session_id": session_id,
524548
"source_policy": source_policy,
525549
},
526550
beta_search_params.BetaSearchParams,

0 commit comments

Comments
 (0)