Instructions to use tensorblock/BioNER-GGUF with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use tensorblock/BioNER-GGUF with Transformers:
# Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("tensorblock/BioNER-GGUF", dtype="auto") - llama-cpp-python
How to use tensorblock/BioNER-GGUF with llama-cpp-python:
# !pip install llama-cpp-python from llama_cpp import Llama llm = Llama.from_pretrained( repo_id="tensorblock/BioNER-GGUF", filename="BioNER-Q2_K.gguf", )
llm.create_chat_completion( messages = "No input example has been defined for this model task." )
- Notebooks
- Google Colab
- Kaggle
- Local Apps
- llama.cpp
How to use tensorblock/BioNER-GGUF with llama.cpp:
Install from brew
brew install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama-server -hf tensorblock/BioNER-GGUF:Q2_K # Run inference directly in the terminal: llama-cli -hf tensorblock/BioNER-GGUF:Q2_K
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama-server -hf tensorblock/BioNER-GGUF:Q2_K # Run inference directly in the terminal: llama-cli -hf tensorblock/BioNER-GGUF:Q2_K
Use pre-built binary
# Download pre-built binary from: # https://github.com/ggerganov/llama.cpp/releases # Start a local OpenAI-compatible server with a web UI: ./llama-server -hf tensorblock/BioNER-GGUF:Q2_K # Run inference directly in the terminal: ./llama-cli -hf tensorblock/BioNER-GGUF:Q2_K
Build from source code
git clone https://github.com/ggerganov/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-server llama-cli # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama-server -hf tensorblock/BioNER-GGUF:Q2_K # Run inference directly in the terminal: ./build/bin/llama-cli -hf tensorblock/BioNER-GGUF:Q2_K
Use Docker
docker model run hf.co/tensorblock/BioNER-GGUF:Q2_K
- LM Studio
- Jan
- Ollama
How to use tensorblock/BioNER-GGUF with Ollama:
ollama run hf.co/tensorblock/BioNER-GGUF:Q2_K
- Unsloth Studio new
How to use tensorblock/BioNER-GGUF with Unsloth Studio:
Install Unsloth Studio (macOS, Linux, WSL)
curl -fsSL https://unsloth.ai/install.sh | sh # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for tensorblock/BioNER-GGUF to start chatting
Install Unsloth Studio (Windows)
irm https://unsloth.ai/install.ps1 | iex # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for tensorblock/BioNER-GGUF to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for tensorblock/BioNER-GGUF to start chatting
- Pi new
How to use tensorblock/BioNER-GGUF with Pi:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama-server -hf tensorblock/BioNER-GGUF:Q2_K
Configure the model in Pi
# Install Pi: npm install -g @mariozechner/pi-coding-agent # Add to ~/.pi/agent/models.json: { "providers": { "llama-cpp": { "baseUrl": "http://localhost:8080/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "tensorblock/BioNER-GGUF:Q2_K" } ] } } }Run Pi
# Start Pi in your project directory: pi
- Hermes Agent new
How to use tensorblock/BioNER-GGUF with Hermes Agent:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama-server -hf tensorblock/BioNER-GGUF:Q2_K
Configure Hermes
# Install Hermes: curl -fsSL https://hermes-agent.nousresearch.com/install.sh | bash hermes setup # Point Hermes at the local server: hermes config set model.provider custom hermes config set model.base_url http://127.0.0.1:8080/v1 hermes config set model.default tensorblock/BioNER-GGUF:Q2_K
Run Hermes
hermes
- Docker Model Runner
How to use tensorblock/BioNER-GGUF with Docker Model Runner:
docker model run hf.co/tensorblock/BioNER-GGUF:Q2_K
- Lemonade
How to use tensorblock/BioNER-GGUF with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull tensorblock/BioNER-GGUF:Q2_K
Run and chat with the model
lemonade run user.BioNER-GGUF-Q2_K
List all available models
lemonade list
Upload folder using huggingface_hub
Browse files- .gitattributes +12 -0
- BioNER-Q2_K.gguf +3 -0
- BioNER-Q3_K_L.gguf +3 -0
- BioNER-Q3_K_M.gguf +3 -0
- BioNER-Q3_K_S.gguf +3 -0
- BioNER-Q4_0.gguf +3 -0
- BioNER-Q4_K_M.gguf +3 -0
- BioNER-Q4_K_S.gguf +3 -0
- BioNER-Q5_0.gguf +3 -0
- BioNER-Q5_K_M.gguf +3 -0
- BioNER-Q5_K_S.gguf +3 -0
- BioNER-Q6_K.gguf +3 -0
- BioNER-Q8_0.gguf +3 -0
- README.md +92 -0
.gitattributes
CHANGED
|
@@ -33,3 +33,15 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
|
|
| 33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
| 34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
| 34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
| 36 |
+
BioNER-Q2_K.gguf filter=lfs diff=lfs merge=lfs -text
|
| 37 |
+
BioNER-Q3_K_L.gguf filter=lfs diff=lfs merge=lfs -text
|
| 38 |
+
BioNER-Q3_K_M.gguf filter=lfs diff=lfs merge=lfs -text
|
| 39 |
+
BioNER-Q3_K_S.gguf filter=lfs diff=lfs merge=lfs -text
|
| 40 |
+
BioNER-Q4_0.gguf filter=lfs diff=lfs merge=lfs -text
|
| 41 |
+
BioNER-Q4_K_M.gguf filter=lfs diff=lfs merge=lfs -text
|
| 42 |
+
BioNER-Q4_K_S.gguf filter=lfs diff=lfs merge=lfs -text
|
| 43 |
+
BioNER-Q5_0.gguf filter=lfs diff=lfs merge=lfs -text
|
| 44 |
+
BioNER-Q5_K_M.gguf filter=lfs diff=lfs merge=lfs -text
|
| 45 |
+
BioNER-Q5_K_S.gguf filter=lfs diff=lfs merge=lfs -text
|
| 46 |
+
BioNER-Q6_K.gguf filter=lfs diff=lfs merge=lfs -text
|
| 47 |
+
BioNER-Q8_0.gguf filter=lfs diff=lfs merge=lfs -text
|
BioNER-Q2_K.gguf
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:baca510e6d53f5131d3da1bcff5420cd6d7fc1fc77123e5abe974b320d124177
|
| 3 |
+
size 3179136608
|
BioNER-Q3_K_L.gguf
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:67af44af9a63883b7e7a4c84f9a576863662a9a629d64f87c20531d589fbc715
|
| 3 |
+
size 4321961568
|
BioNER-Q3_K_M.gguf
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:374ea54c6e9f5b7b146c2a42604021d334b46ec9d0dadbd8c1a762b69b1a3cfe
|
| 3 |
+
size 4018923104
|
BioNER-Q3_K_S.gguf
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:87bf4d6ccc7c02333919b594e6122bc85637d1045b388c0819417448997c419c
|
| 3 |
+
size 3664504416
|
BioNER-Q4_0.gguf
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:e2f26cc2d59f5d8e04875f4dacde1e6005dc06b68078ef9f4273a764e3e72df8
|
| 3 |
+
size 4661216864
|
BioNER-Q4_K_M.gguf
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:56e0fffc87bb3b54b22afdebe2bc73b08c8d6ace54aa8597f1c667d92c92f9c3
|
| 3 |
+
size 4920739424
|
BioNER-Q4_K_S.gguf
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:c8ccbcf08f10b751c450d4ca5b21980a2d81a3f5a3151949a53c7a24d48743f9
|
| 3 |
+
size 4692674144
|
BioNER-Q5_0.gguf
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:f031537c9c0202afbf13059f4169df455429a687c28ef21fb3c84614efb3f3be
|
| 3 |
+
size 5599299168
|
BioNER-Q5_K_M.gguf
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:bad844d6cb199f89096d09254426be3864cb8b9d5a7931be1232fdd8a00271f1
|
| 3 |
+
size 5732992608
|
BioNER-Q5_K_S.gguf
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:9df99409b82ff926ee92bff449cd3b8553cb5eddd546394566ea23172cc7a709
|
| 3 |
+
size 5599299168
|
BioNER-Q6_K.gguf
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:1f97fbba7b2cba555f090995281e9f5c2a2351999a8e48b46d5479f48d0be03d
|
| 3 |
+
size 6596011616
|
BioNER-Q8_0.gguf
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:006a6d3b0088406e9cf6691a13448e63d1c12728d42b47e46eeeb5116a11a344
|
| 3 |
+
size 8540776032
|
README.md
ADDED
|
@@ -0,0 +1,92 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
library_name: transformers
|
| 3 |
+
tags:
|
| 4 |
+
- TensorBlock
|
| 5 |
+
- GGUF
|
| 6 |
+
base_model: haydn-jones/BioNER
|
| 7 |
+
---
|
| 8 |
+
|
| 9 |
+
<div style="width: auto; margin-left: auto; margin-right: auto">
|
| 10 |
+
<img src="https://i.imgur.com/jC7kdl8.jpeg" alt="TensorBlock" style="width: 100%; min-width: 400px; display: block; margin: auto;">
|
| 11 |
+
</div>
|
| 12 |
+
<div style="display: flex; justify-content: space-between; width: 100%;">
|
| 13 |
+
<div style="display: flex; flex-direction: column; align-items: flex-start;">
|
| 14 |
+
<p style="margin-top: 0.5em; margin-bottom: 0em;">
|
| 15 |
+
Feedback and support: TensorBlock's <a href="https://x.com/tensorblock_aoi">Twitter/X</a>, <a href="https://t.me/TensorBlock">Telegram Group</a> and <a href="https://x.com/tensorblock_aoi">Discord server</a>
|
| 16 |
+
</p>
|
| 17 |
+
</div>
|
| 18 |
+
</div>
|
| 19 |
+
|
| 20 |
+
## haydn-jones/BioNER - GGUF
|
| 21 |
+
|
| 22 |
+
This repo contains GGUF format model files for [haydn-jones/BioNER](https://huggingface.co/haydn-jones/BioNER).
|
| 23 |
+
|
| 24 |
+
The files were quantized using machines provided by [TensorBlock](https://tensorblock.co/), and they are compatible with llama.cpp as of [commit b4242](https://github.com/ggerganov/llama.cpp/commit/a6744e43e80f4be6398fc7733a01642c846dce1d).
|
| 25 |
+
|
| 26 |
+
<div style="text-align: left; margin: 20px 0;">
|
| 27 |
+
<a href="https://tensorblock.co/waitlist/client" style="display: inline-block; padding: 10px 20px; background-color: #007bff; color: white; text-decoration: none; border-radius: 5px; font-weight: bold;">
|
| 28 |
+
Run them on the TensorBlock client using your local machine ↗
|
| 29 |
+
</a>
|
| 30 |
+
</div>
|
| 31 |
+
|
| 32 |
+
## Prompt template
|
| 33 |
+
|
| 34 |
+
```
|
| 35 |
+
<|begin_of_text|><|start_header_id|>system<|end_header_id|>
|
| 36 |
+
|
| 37 |
+
Cutting Knowledge Date: December 2023
|
| 38 |
+
Today Date: 26 Jul 2024
|
| 39 |
+
{system_prompt}
|
| 40 |
+
Analyze the given paragraph to identify and categorize small molecules and macromolecules/biologics (or classes thereof), including their synonyms.
|
| 41 |
+
|
| 42 |
+
Output format:
|
| 43 |
+
{"categories":["cat1"],"molecules":[{"name":"name","alternatives":["alt1","alt2"],"is_class":false}],"biologics":[{"name":"name","alternatives":[],"is_class":true}]}
|
| 44 |
+
|
| 45 |
+
Instructions:
|
| 46 |
+
1. Identify all small molecules and biologics in the paragraph
|
| 47 |
+
2. Tag each entity, including all synonyms
|
| 48 |
+
3. Assign one or more of the following category tags to the paragraph if relevant information is present
|
| 49 |
+
- Structure/Properties, Chemistry, Pharmacology, Synthesis/Formulation, Safety/Regulation, None<|eot_id|><|start_header_id|>user<|end_header_id|>
|
| 50 |
+
|
| 51 |
+
{prompt}<|eot_id|><|start_header_id|>assistant<|end_header_id|>
|
| 52 |
+
```
|
| 53 |
+
|
| 54 |
+
## Model file specification
|
| 55 |
+
|
| 56 |
+
| Filename | Quant type | File Size | Description |
|
| 57 |
+
| -------- | ---------- | --------- | ----------- |
|
| 58 |
+
| [BioNER-Q2_K.gguf](https://huggingface.co/tensorblock/BioNER-GGUF/blob/main/BioNER-Q2_K.gguf) | Q2_K | 3.179 GB | smallest, significant quality loss - not recommended for most purposes |
|
| 59 |
+
| [BioNER-Q3_K_S.gguf](https://huggingface.co/tensorblock/BioNER-GGUF/blob/main/BioNER-Q3_K_S.gguf) | Q3_K_S | 3.665 GB | very small, high quality loss |
|
| 60 |
+
| [BioNER-Q3_K_M.gguf](https://huggingface.co/tensorblock/BioNER-GGUF/blob/main/BioNER-Q3_K_M.gguf) | Q3_K_M | 4.019 GB | very small, high quality loss |
|
| 61 |
+
| [BioNER-Q3_K_L.gguf](https://huggingface.co/tensorblock/BioNER-GGUF/blob/main/BioNER-Q3_K_L.gguf) | Q3_K_L | 4.322 GB | small, substantial quality loss |
|
| 62 |
+
| [BioNER-Q4_0.gguf](https://huggingface.co/tensorblock/BioNER-GGUF/blob/main/BioNER-Q4_0.gguf) | Q4_0 | 4.661 GB | legacy; small, very high quality loss - prefer using Q3_K_M |
|
| 63 |
+
| [BioNER-Q4_K_S.gguf](https://huggingface.co/tensorblock/BioNER-GGUF/blob/main/BioNER-Q4_K_S.gguf) | Q4_K_S | 4.693 GB | small, greater quality loss |
|
| 64 |
+
| [BioNER-Q4_K_M.gguf](https://huggingface.co/tensorblock/BioNER-GGUF/blob/main/BioNER-Q4_K_M.gguf) | Q4_K_M | 4.921 GB | medium, balanced quality - recommended |
|
| 65 |
+
| [BioNER-Q5_0.gguf](https://huggingface.co/tensorblock/BioNER-GGUF/blob/main/BioNER-Q5_0.gguf) | Q5_0 | 5.599 GB | legacy; medium, balanced quality - prefer using Q4_K_M |
|
| 66 |
+
| [BioNER-Q5_K_S.gguf](https://huggingface.co/tensorblock/BioNER-GGUF/blob/main/BioNER-Q5_K_S.gguf) | Q5_K_S | 5.599 GB | large, low quality loss - recommended |
|
| 67 |
+
| [BioNER-Q5_K_M.gguf](https://huggingface.co/tensorblock/BioNER-GGUF/blob/main/BioNER-Q5_K_M.gguf) | Q5_K_M | 5.733 GB | large, very low quality loss - recommended |
|
| 68 |
+
| [BioNER-Q6_K.gguf](https://huggingface.co/tensorblock/BioNER-GGUF/blob/main/BioNER-Q6_K.gguf) | Q6_K | 6.596 GB | very large, extremely low quality loss |
|
| 69 |
+
| [BioNER-Q8_0.gguf](https://huggingface.co/tensorblock/BioNER-GGUF/blob/main/BioNER-Q8_0.gguf) | Q8_0 | 8.541 GB | very large, extremely low quality loss - not recommended |
|
| 70 |
+
|
| 71 |
+
|
| 72 |
+
## Downloading instruction
|
| 73 |
+
|
| 74 |
+
### Command line
|
| 75 |
+
|
| 76 |
+
Firstly, install Huggingface Client
|
| 77 |
+
|
| 78 |
+
```shell
|
| 79 |
+
pip install -U "huggingface_hub[cli]"
|
| 80 |
+
```
|
| 81 |
+
|
| 82 |
+
Then, downoad the individual model file the a local directory
|
| 83 |
+
|
| 84 |
+
```shell
|
| 85 |
+
huggingface-cli download tensorblock/BioNER-GGUF --include "BioNER-Q2_K.gguf" --local-dir MY_LOCAL_DIR
|
| 86 |
+
```
|
| 87 |
+
|
| 88 |
+
If you wanna download multiple model files with a pattern (e.g., `*Q4_K*gguf`), you can try:
|
| 89 |
+
|
| 90 |
+
```shell
|
| 91 |
+
huggingface-cli download tensorblock/BioNER-GGUF --local-dir MY_LOCAL_DIR --local-dir-use-symlinks False --include='*Q4_K*gguf'
|
| 92 |
+
```
|