CrispEmbed English spaCy
language bundle for native C++ runtime
2 min readupdated
This repository contains an English spaCy 3.8.0 pipeline bundle converted to the GGUF format for CrispEmbed's native C++ and ggml runtime. The model handles tokenization, part-of-speech (POS) tagging, morphological analysis, lemmatization, dependency parsing, and named entity recognition (NER) without needing Python in production. Built on the CrispEmbed library with v2 runtime support, the package requires explicit initialization via a C ABI and targets developers integrating NLP tasks into high-performance C/C++ applications.
Key features
- Native runtime: Pure C/C++ implementation built on ggml with zero Python interpreter dependencies at runtime.
- Full pipeline: Includes F32 weights for tok2vec, tagger, parser, attribute_ruler, lemmatizer, and ner components.
- Integrity checks: Strict runtime verification of SHA-256 hashes and file sizes to prevent loading corrupted weights.
- Exact parity: Matches original spaCy 3.8.18 outputs 100% on UD English-EWT test datasets.
What you can do
- Integrate into C/C++ services: Embed fast linguistic text analysis directly into C++ backends without Python overhead.
- Deploy on edge devices: Run a lightweight language model (around 12 MB) in resource-constrained environments.
- Extract entities and syntax: Perform sentence parsing, named entity recognition, and lemmatization through a clean C ABI.
Example
Initializing the context and analyzing text in C:
crispembed_spacy_set_enabled(CRISPEMBED_SPACY_ENABLE_ANALYSIS);
ctx = crispembed_spacy_create_with_resources("bundle/model.gguf", MODEL_SHA256,
"bundle/resources.json", RESOURCES_SHA256, err, sizeof err);
crispembed_spacy_analyze_utf8(ctx, text, len, &doc, NULL, NULL, NULL, NULL, err, sizeof err);
Read more
DetailsSize of model.gguf: ~12.7 MB, resources.json: ~3.4 MB.
Tests on UD English-EWT (2,077 texts, 25,531 tokens) showed 100% output parity with original spaCy.
Requires a CrispEmbed build with v2 runtime support (PR #244) and the matching language capsule.
License: MIT.










Comments