feat: add extraction parameter to SearchInput, deprecate livecrawl - #16
Merged
Conversation
tyler5673
marked this pull request as ready for review
August 21, 2026 19:21
Add `extraction: dict[str, Any] | None = None` to `SearchInput`, mirroring the SDK's `extraction` object (shipped in youdotcom 3.1.0). When set, it takes priority over `livecrawl` / `livecrawl_formats` and is passed to `you.search_async(extraction=...)` instead, avoiding the SDK's `ValueError` on dual-set. The legacy fields remain accepted for backward compatibility. - Add `extraction` field to `SearchInput` in `models.py` - Route `extraction` or `livecrawl`/`livecrawl_formats` in `activities.py` - Add tests for extraction path and priority-over-livecrawl - Update README SearchInput table with `extraction` row and deprecation notes - Update CHANGELOG Unreleased section Closes DX-721 Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
tyler5673
force-pushed
the
dx-721-extraction-replace-livecrawl
branch
from
August 21, 2026 20:43
ac9f267 to
7c88c32
Compare
tyler5673
added a commit
that referenced
this pull request
Aug 21, 2026
Rebased onto main with PR #15 (SDK 3.1.2 + attribution header) and PR #16 (extraction parameter) merged. Squashes the nexus spike into one clean commit. - YouDotComService exposes all six Activities as async Nexus Operations - contract.py holds the Nexus contract with SDK response models - workflows.py ships six thin backing Workflows with per-Activity ceilings - Idempotency key support for deduplication of Nexus StartOperation retries - Unit tests covering contract, handler, and sandbox registration - Integration tests for live Nexus round-trip (gated behind -m integration) Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
tyler5673
added a commit
that referenced
this pull request
Aug 21, 2026
Rebased onto main with PR #15 (SDK 3.1.2 + attribution header) and PR #16 (extraction parameter) merged. Squashes the nexus spike into one clean commit. - YouDotComService exposes all six Activities as async Nexus Operations - contract.py holds the Nexus contract with SDK response models - workflows.py ships six thin backing Workflows with per-Activity ceilings - Idempotency key support for deduplication of Nexus StartOperation retries - Unit tests covering contract, handler, and sandbox registration - Integration tests for live Nexus round-trip (gated behind -m integration) Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What this adds
Adds the
extractionparameter toSearchInput, mirroring the SDK'sextractionobject (shipped inyoudotcom3.1.0). When set, it takes priority over the deprecatedlivecrawl/livecrawl_formatsfields and is passed toyou.search_async(extraction=...)instead, avoiding the SDK'sValueErroron dual-set.The legacy
livecrawl/livecrawl_formatsfields remain accepted for backward compatibility. The server still accepts them, and existing callers need no code change.Changes
src/youdotcom_temporal/models.pyextraction: dict[str, Any] | None = NonetoSearchInputsrc/youdotcom_temporal/activities.pyextractionorlivecrawl/livecrawl_formatstosearch_asynctests/test_activities.pytest_search_passes_extraction_to_sdkandtest_search_extraction_takes_priority_over_livecrawlREADME.mdextractionrow to SearchInput table; marklivecrawl/livecrawl_formatsas deprecatedCHANGELOG.mdVerification
uv run ruff check-- passeduv run mypy src-- passed (0 issues)uv run pytest-- 79 passed, 8 deselected (integration)Stacked on
Related
Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>