Hi everyone!
Iโm thrilled to announce the release of bridgenlp, a Python package Iโve developed to help you connect advanced AI models and NLP pipelines with minimal friction.
๐ What Is BridgeNLP?
BridgeNLP is a universal adapter framework that lets you plug cutting-edge models (like AllenNLP, Hugging Face, and multimodal tools) directly into structured pipelines like spaCy. Itโs designed for:
- โ NLP tasks like coreference resolution, semantic role labeling, named entity recognition
- โ Multimodal tasks like image captioning, object detection, and text-image alignment
- โ Developers who care about memory safety, modularity, and clean integration
โ๏ธ Key Features
- ๐ Minimal dependencies (just spaCy + NumPy by default)
- ๐งฉ Modular design โ add only the adapters you need
- ๐ Multilingual + multimodal support
- โก Memory-efficient, production-ready code
- ๐ Well-documented, thoroughly tested
๐ฅ Quick Install
pip install bridgenlp
Need extras?
pip install bridgenlp[allennlp]
pip install bridgenlp[huggingface]
pip install bridgenlp[multimodal]
๐ป Example Use
Hook up AllenNLP coreference to your spaCy pipeline:
import spacy
from bridgenlp.adapters.allen_coref import AllenNLPCorefBridge
from bridgenlp.pipes.spacy_pipe import SpacyBridgePipe
nlp = spacy.load("en_core_web_sm")
coref_bridge = AllenNLPCorefBridge()
nlp.add_pipe("bridgenlp", config={"bridge": coref_bridge})
doc = nlp("Julie hugged David because she missed him.")
for cluster in doc._.nlp_bridge_clusters:
print("Coreference cluster:", [doc[start:end].text for start, end in cluster])
*๐ฆ Why Should You Care?
*
If youโve ever:
- Tried gluing together different AI/NLP libraries and cursed at the incompatibilities
- Wanted to add powerful models to a project without heavyweight frameworks
- Needed seamless token alignment across languages or modalities
โฆBridgeNLP is for you.
๐ Learn More
๐ฆ PyPI: https://pypi.org/project/bridgenlp/0.5.0/
๐ป GitHub: https://github.com/dcondrey/BridgeNLP
๐ How You Can Help
Iโd love:
Bug reports and feature requests
Collaborators interested in pushing this to the next level
If this resonates, give it a spin, star the repo, or share with someone who needs it!
Top comments (0)