Text Generation
Transformers
PyTorch
English
veronica
polymorphic-mlp
mixture-of-branches
entropy-regularized-routing
decoder-only
causal-lm
rope
expandable-architecture
research
Instructions to use MhaWay/Veronica with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use MhaWay/Veronica with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="MhaWay/Veronica")# Load model directly from transformers import AutoModelForCausalLM model = AutoModelForCausalLM.from_pretrained("MhaWay/Veronica", dtype="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use MhaWay/Veronica with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "MhaWay/Veronica" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "MhaWay/Veronica", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/MhaWay/Veronica
- SGLang
How to use MhaWay/Veronica with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "MhaWay/Veronica" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "MhaWay/Veronica", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "MhaWay/Veronica" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "MhaWay/Veronica", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use MhaWay/Veronica with Docker Model Runner:
docker model run hf.co/MhaWay/Veronica
Update README.md
Browse files
README.md
CHANGED
|
@@ -41,6 +41,13 @@ model-index:
|
|
| 41 |
|
| 42 |
## Installation
|
| 43 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 44 |
| Source | Share | Link |
|
| 45 |
|--------|-------|------|
|
| 46 |
| FinePDFs‑1B | 50% | https://huggingface.co/datasets/codelion/finepdfs-1B |
|
|
@@ -53,13 +60,6 @@ Notes
|
|
| 53 |
|
| 54 |
Total tokens target (example): ~60B. The composition balances semantic density (FinePDFs) and generality (DCLM) per codelion’s guidance.
|
| 55 |
|
| 56 |
-
```bash
|
| 57 |
-
pip install -e .
|
| 58 |
-
from veronica import VeronicaConfig, VeronicaForCausalLM
|
| 59 |
-
cfg = VeronicaConfig(n_layer=24, num_funcs=3) # base polymorphic setup
|
| 60 |
-
model = VeronicaForCausalLM(cfg)
|
| 61 |
-
```
|
| 62 |
-
|
| 63 |
Generation example:
|
| 64 |
```python
|
| 65 |
from transformers import AutoTokenizer
|
|
|
|
| 41 |
|
| 42 |
## Installation
|
| 43 |
|
| 44 |
+
```bash
|
| 45 |
+
pip install -e .
|
| 46 |
+
from veronica import VeronicaConfig, VeronicaForCausalLM
|
| 47 |
+
cfg = VeronicaConfig(n_layer=24, num_funcs=3) # base polymorphic setup
|
| 48 |
+
model = VeronicaForCausalLM(cfg)
|
| 49 |
+
```
|
| 50 |
+
|
| 51 |
| Source | Share | Link |
|
| 52 |
|--------|-------|------|
|
| 53 |
| FinePDFs‑1B | 50% | https://huggingface.co/datasets/codelion/finepdfs-1B |
|
|
|
|
| 60 |
|
| 61 |
Total tokens target (example): ~60B. The composition balances semantic density (FinePDFs) and generality (DCLM) per codelion’s guidance.
|
| 62 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 63 |
Generation example:
|
| 64 |
```python
|
| 65 |
from transformers import AutoTokenizer
|