Skip to content

Add as_tuples argument to spaCyLayout.pipe #36

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Mar 8, 2025
Merged

Conversation

ines
Copy link
Member

@ines ines commented Mar 7, 2025

Add option for as_tuples in spaCyLayout.pipe, analogous to spaCy's Language.pipe.

layout = spaCyLayout(nlp)
sources = [("./foo.pdf", {"baz": 1}), ("./bar.pdf", {"baz": 2})]
for doc, context in layout.pipe(sources, as_tuples=True):
    ...

@ines ines added the enhancement New feature or request label Mar 7, 2025
@ines ines merged commit 63835b0 into main Mar 8, 2025
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant