Text Generation
Transformers
Safetensors
English
pruned_flex_olmo
custom_code
pruned
distilled
mixture-of-experts
Instructions to use hbfreed/flex-general-2048 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use hbfreed/flex-general-2048 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="hbfreed/flex-general-2048", trust_remote_code=True)# pip install -U transformers accelerate # Load model directly from transformers import AutoModelForCausalLM model = AutoModelForCausalLM.from_pretrained("hbfreed/flex-general-2048", trust_remote_code=True, device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use hbfreed/flex-general-2048 with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "hbfreed/flex-general-2048" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "hbfreed/flex-general-2048", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/hbfreed/flex-general-2048
- SGLang
How to use hbfreed/flex-general-2048 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 "hbfreed/flex-general-2048" \ --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": "hbfreed/flex-general-2048", "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 "hbfreed/flex-general-2048" \ --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": "hbfreed/flex-general-2048", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use hbfreed/flex-general-2048 with Docker Model Runner:
docker model run hf.co/hbfreed/flex-general-2048
Commit History
-
Upload README.md with huggingface_hub
Verified signature9317eec -
Upload README.md with huggingface_hub
Verified signaturea0db8da
-
Fix relative import for trust_remote_code
Verified signature06cc490 -
Upload configuration_pruned_flex_olmo.py with huggingface_hub
Verified signaturee981ada -
Upload modeling_pruned_flex_olmo.py with huggingface_hub
Verified signature3ce9d51 -
Upload config.json with huggingface_hub
Verified signaturebdf5a12
-
step_18999
Verified signature92d2cc5 -
step_17999
Verified signature7ea3724 -
step_16999
Verified signatured4b0dbc -
step_15999
Verified signaturefcd5eba -
step_14999
Verified signature2873d55 -
step_13999
Verified signatureaaaa384 -
step_12999
Verified signaturec082826 -
step_11999
Verified signature8552438 -
step_10999
Verified signature649b5fc -
step_9999
Verified signature021c139 -
step_8999
Verified signatured8132f9 -
step_7999
Verified signature1deb58d -
step_6999
Verified signatureeef340d -
step_5999
Verified signaturec9c4f63 -
step_4999
Verified signature52d73de -
step_3999
Verified signature5fb1f55
-
step_3999
Verified signature4b3e55e -
step_2999
Verified signaturef8f22b0 -
step_1999
Verified signaturea24ed71 -
step_999
Verified signatureaeb1fd7
-
Upload folder using huggingface_hub
Verified signatured6fe048 -
initial commit
Verified signature415dadd