feat(frameworks): Add native SpaCy integration for v1.0.0+ architecture #5335
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 does this PR address?
Feat: Add native SpaCy runner for v1.0.0 architecture
This PR adds native SpaCy integration for BentoML's v1.0.0+ architecture, providing a complete implementation of the SpaCy framework module. The implementation includes:
save() and load() functions for model serialization
SpacyRunnable class that implements BentoML's Runnable interface
GPU detection and automatic configuration
Support for both call (single text) and pipe (batch processing) methods
SpaCy Projects support (clone and pull)
Compatibility with SpaCy 3.x and above
This restores the SpaCy framework support that was available in earlier versions of BentoML but was removed during the v1.0.0 architecture change.
Fixes #4134
Before submitting:
[x] Does the Pull Request follow Conventional Commits specification naming? Here are GitHub's guide on how to create a pull request.
[x] Does the code follow BentoML's code style, pre-commit run -a script has passed 1?
[x] Did you read through contribution guidelines and follow development guidelines?
[] Did your changes require updates to the documentation? Have you updated
those accordingly? Here are documentation guidelines and tips on writting docs.
[x] Did you write tests to cover your changes?
: )