spacy-llm is spaCy's recent integration with large language models and is maintained by the team behind spaCy. In this talk I elaborate on the motivation behind this library, which problems it tries to solve, and lessons learned while working on it.
Recent LLMs exhibit impressive capabilities and enable extremely fast prototyping of NLP applications. spacy-llm addresses some of the challenges in making LLMs production-ready:
- LLMs turn text into … more text. NLP applications however often aim to extract structured information from text and use it further downstream.
- spacy-llm parses LLM responses and maps the parsed responses onto existing data structures for documents, spans and tokens.
- Closed and open models have markedly different drawbacks. Closed models aren't free, induce network latency, are inflexible black boxes, aren't suitable for all (commercial) use-cases - check the TOS!
- and may leak user data. Also, you may get rate-limited. Open models require quite a bit of computing power to run locally, are more complicated to set up, and are still less capable than (some) closed models.
- Your mileage with closed and open models may therefore vary depending on which point in your dev cycle you're at. spacy-llm allows smoothly transitioning between open and closed LLMs without touching any code.
spacy-llm plugs open and proprietary LLMs into spaCy, leveraging its modular and customizable framework for working with text. This allows for a cheaper, faster and more robust NLP workflow - driven by cutting-edge LLMs.