Text Generation
Transformers
causal-lm
linear-attention
rwkv
reka
knowledge-distillation
multilingual
Instructions to use OpenMOSE/HRWKV7-Reka-Flash3-Preview with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use OpenMOSE/HRWKV7-Reka-Flash3-Preview with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="OpenMOSE/HRWKV7-Reka-Flash3-Preview")# Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("OpenMOSE/HRWKV7-Reka-Flash3-Preview", dtype="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps
- vLLM
How to use OpenMOSE/HRWKV7-Reka-Flash3-Preview with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "OpenMOSE/HRWKV7-Reka-Flash3-Preview" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "OpenMOSE/HRWKV7-Reka-Flash3-Preview", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/OpenMOSE/HRWKV7-Reka-Flash3-Preview
- SGLang
How to use OpenMOSE/HRWKV7-Reka-Flash3-Preview 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 "OpenMOSE/HRWKV7-Reka-Flash3-Preview" \ --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": "OpenMOSE/HRWKV7-Reka-Flash3-Preview", "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 "OpenMOSE/HRWKV7-Reka-Flash3-Preview" \ --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": "OpenMOSE/HRWKV7-Reka-Flash3-Preview", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use OpenMOSE/HRWKV7-Reka-Flash3-Preview with Docker Model Runner:
docker model run hf.co/OpenMOSE/HRWKV7-Reka-Flash3-Preview
Update README.md
Browse files
README.md
CHANGED
|
@@ -45,7 +45,7 @@ The model implements several key improvements over standard RWKV architectures:
|
|
| 45 |
|
| 46 |
### Hybrid Design Benefits
|
| 47 |
|
| 48 |
-
- **Linear Attention Inference**: RWKV blocks enable O(1) memory complexity during inference
|
| 49 |
- **Enhanced Needle Tasks**: Strategic placement of GQA layers significantly improves performance on needle-in-haystack retrieval tasks, addressing a known limitation of pure linear attention models
|
| 50 |
- **Implicit Position Encoding**: Interestingly, the model achieves better performance when RoPE (Rotary Position Embedding) is not applied to GQA layers, suggesting that RWKV blocks provide implicit positional encoding capabilities
|
| 51 |
|
|
|
|
| 45 |
|
| 46 |
### Hybrid Design Benefits
|
| 47 |
|
| 48 |
+
- **Linear Attention Inference**: RWKV blocks enable O(1) memory complexity during inference, and hybrids reduce memory usage by 1/7 KVCache.
|
| 49 |
- **Enhanced Needle Tasks**: Strategic placement of GQA layers significantly improves performance on needle-in-haystack retrieval tasks, addressing a known limitation of pure linear attention models
|
| 50 |
- **Implicit Position Encoding**: Interestingly, the model achieves better performance when RoPE (Rotary Position Embedding) is not applied to GQA layers, suggesting that RWKV blocks provide implicit positional encoding capabilities
|
| 51 |
|