Edit model card

SLIM-SA_NER-TOOL

slim-sa-ner-tool is a 4_K_M quantized GGUF version of slim-sa-ner, providing a small, fast inference implementation, optimized for multi-model concurrent deployment.

slim-sa-ner combines two of the most popular traditional classifier functions (Sentiment Analysis and Named Entity Recognition), and reimagines them as function calls on a specialized decoder-based LLM, generating output consisting of a python dictionary with keys corresponding to sentiment, and NER identifiers, such as people, organization, and place, e.g.:

{'sentiment': ['positive'], people': ['..'], 'organization': ['..'],
 'place': ['..]}

This 3B parameter 'combo' model is designed to illustrate the potential power of using function calls on small, specialized models to enable a single model architecture to combine the capabilities of what were traditionally two separate model architectures on an encoder.

The intent of SLIMs is to forge a middle-ground between traditional encoder-based classifiers and open-ended API-based LLMs, providing an intuitive, flexible natural language response, without complex prompting, and with improved generalization and ability to fine-tune to a specific domain use case.

To pull the model via API:

from huggingface_hub import snapshot_download           
snapshot_download("llmware/slim-sa-ner-tool", local_dir="/path/on/your/machine/", local_dir_use_symlinks=False)  

Load in your favorite GGUF inference engine, or try with llmware as follows:

from llmware.models import ModelCatalog  

# to load the model and make a basic inference
model = ModelCatalog().load_model("slim-sa-ner-tool")
response = model.function_call(text_sample)  

# this one line will download the model and run a series of tests
ModelCatalog().tool_test_run("slim-sa-ner-tool", verbose=True)  

Note: please review config.json in the repository for prompt wrapping information, details on the model, and full test set.

Model Card Contact

Darren Oberst & llmware team

Any questions? Join us on Discord

Downloads last month
216
Unable to determine this model’s pipeline type. Check the docs .

Collection including llmware/slim-sa-ner-tool