Text Generation
Transformers
Safetensors
English
flex_olmo
Mixture of Experts
olmo
flexolmo
conversational
Instructions to use allenai/FlexOlmo-7x7B-1T-RT with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use allenai/FlexOlmo-7x7B-1T-RT with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="allenai/FlexOlmo-7x7B-1T-RT") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("allenai/FlexOlmo-7x7B-1T-RT") model = AutoModelForCausalLM.from_pretrained("allenai/FlexOlmo-7x7B-1T-RT", device_map="auto") messages = [ {"role": "user", "content": "Who are you?"}, ] inputs = tokenizer.apply_chat_template( messages, add_generation_prompt=True, tokenize=True, return_dict=True, return_tensors="pt", ).to(model.device) outputs = model.generate(**inputs, max_new_tokens=40) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use allenai/FlexOlmo-7x7B-1T-RT with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "allenai/FlexOlmo-7x7B-1T-RT" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "allenai/FlexOlmo-7x7B-1T-RT", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/allenai/FlexOlmo-7x7B-1T-RT
- SGLang
How to use allenai/FlexOlmo-7x7B-1T-RT 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 "allenai/FlexOlmo-7x7B-1T-RT" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "allenai/FlexOlmo-7x7B-1T-RT", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'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 "allenai/FlexOlmo-7x7B-1T-RT" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "allenai/FlexOlmo-7x7B-1T-RT", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use allenai/FlexOlmo-7x7B-1T-RT with Docker Model Runner:
docker model run hf.co/allenai/FlexOlmo-7x7B-1T-RT
Upload FlexOlmoForCausalLM
Browse files- config.json +2 -3
- generation_config.json +1 -1
- model-00001-of-00027.safetensors +1 -1
- model-00002-of-00027.safetensors +1 -1
- model-00003-of-00027.safetensors +1 -1
- model-00004-of-00027.safetensors +1 -1
- model-00005-of-00027.safetensors +1 -1
- model-00006-of-00027.safetensors +1 -1
- model-00007-of-00027.safetensors +1 -1
- model-00008-of-00027.safetensors +1 -1
- model-00009-of-00027.safetensors +1 -1
- model-00010-of-00027.safetensors +1 -1
- model-00011-of-00027.safetensors +1 -1
- model-00012-of-00027.safetensors +1 -1
- model-00013-of-00027.safetensors +1 -1
- model-00014-of-00027.safetensors +1 -1
- model-00015-of-00027.safetensors +1 -1
- model-00016-of-00027.safetensors +1 -1
- model-00017-of-00027.safetensors +1 -1
- model-00018-of-00027.safetensors +1 -1
- model-00019-of-00027.safetensors +1 -1
- model-00020-of-00027.safetensors +1 -1
- model-00021-of-00027.safetensors +1 -1
- model-00022-of-00027.safetensors +1 -1
- model-00023-of-00027.safetensors +1 -1
- model-00024-of-00027.safetensors +1 -1
- model-00025-of-00027.safetensors +1 -1
- model-00026-of-00027.safetensors +1 -1
- model-00027-of-00027.safetensors +1 -1
- model.safetensors.index.json +1 -0
config.json
CHANGED
|
@@ -4,7 +4,7 @@
|
|
| 4 |
],
|
| 5 |
"attention_bias": false,
|
| 6 |
"attention_dropout": 0.0,
|
| 7 |
-
"
|
| 8 |
"eos_token_id": 100257,
|
| 9 |
"hidden_act": "silu",
|
| 10 |
"hidden_size": 4096,
|
|
@@ -25,8 +25,7 @@
|
|
| 25 |
"rope_theta": 500000,
|
| 26 |
"router_aux_loss_coef": 0.01,
|
| 27 |
"tie_word_embeddings": false,
|
| 28 |
-
"
|
| 29 |
-
"transformers_version": "4.50.0.dev0",
|
| 30 |
"use_cache": true,
|
| 31 |
"vocab_size": 100352
|
| 32 |
}
|
|
|
|
| 4 |
],
|
| 5 |
"attention_bias": false,
|
| 6 |
"attention_dropout": 0.0,
|
| 7 |
+
"dtype": "float32",
|
| 8 |
"eos_token_id": 100257,
|
| 9 |
"hidden_act": "silu",
|
| 10 |
"hidden_size": 4096,
|
|
|
|
| 25 |
"rope_theta": 500000,
|
| 26 |
"router_aux_loss_coef": 0.01,
|
| 27 |
"tie_word_embeddings": false,
|
| 28 |
+
"transformers_version": "4.57.1",
|
|
|
|
| 29 |
"use_cache": true,
|
| 30 |
"vocab_size": 100352
|
| 31 |
}
|
generation_config.json
CHANGED
|
@@ -1,4 +1,4 @@
|
|
| 1 |
{
|
| 2 |
"_from_model_config": true,
|
| 3 |
-
"transformers_version": "4.
|
| 4 |
}
|
|
|
|
| 1 |
{
|
| 2 |
"_from_model_config": true,
|
| 3 |
+
"transformers_version": "4.57.1"
|
| 4 |
}
|
model-00001-of-00027.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4978789328
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:8277604329d67c65c4c438a1585c655910609449f63172d55c6eceb9c6bb0099
|
| 3 |
size 4978789328
|
model-00002-of-00027.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4978856560
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:a42eb55595a62c70f51fa0ed7442843ff61b233ef894e200cc9e06f895f9e98e
|
| 3 |
size 4978856560
|
model-00003-of-00027.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4844753384
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:d287f1c4ecffd8cce75ab0e9bc5a2d3908632138e39f3b8435dbb661673e4aa2
|
| 3 |
size 4844753384
|
model-00004-of-00027.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4957851816
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:f914acc43224884d0ea904b8107f44990dfc17dc2546af3a61c4d585c61f8d8a
|
| 3 |
size 4957851816
|
model-00005-of-00027.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4957851816
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:2b0a52bde6967bc4a9eaf39885684b156972eab063bcdd9df64bd6d860dbb36c
|
| 3 |
size 4957851816
|
model-00006-of-00027.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4957851816
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:5eb50c10d7853e94889f20f97c163db74e08dcd2b61459ac47234c60d0d24c9d
|
| 3 |
size 4957851816
|
model-00007-of-00027.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4865758128
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:224994f7dac69d773da68ecd9f60739d274f746237977982b4d36ed63fa4ad04
|
| 3 |
size 4865758128
|
model-00008-of-00027.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4957851816
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:95aef95ff1ad4f587a81954ca679ca0fca861a5f66f78e098e4251d5f3bc7896
|
| 3 |
size 4957851816
|
model-00009-of-00027.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4957851832
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:d34f145f1986930d51d249dfb151fe9727749e3478e9141a316c885a470a065b
|
| 3 |
size 4957851832
|
model-00010-of-00027.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4957851848
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:c252c2f3389d4088f2f1e3081fd2c34377816dc624a183b1de8734531861c13a
|
| 3 |
size 4957851848
|
model-00011-of-00027.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4957884856
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:dc5678f496b871c5f8b9064047ca93a1a9d4191905197252a1484de4be03e06a
|
| 3 |
size 4957884856
|
model-00012-of-00027.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4865725168
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:aab30001b0b899bbd0f1840b75159534c61d101fa5c5110c72fcfca1630c6b76
|
| 3 |
size 4865725168
|
model-00013-of-00027.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4957851848
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:076977ddb0c8a74394601bb06788f6c479eda04d1ae1b789f27ba885ae1cffea
|
| 3 |
size 4957851848
|
model-00014-of-00027.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4957851848
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:b02bb19915c03d35cd8c438ab07833e13ae130979d1bd2e77606b5a6565cf993
|
| 3 |
size 4957851848
|
model-00015-of-00027.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4957851848
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:b80d1414c6c08791e07a415f270a8ec9ebe35b4e7a216b18be6fd46582e99a67
|
| 3 |
size 4957851848
|
model-00016-of-00027.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4865758176
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:1eed0003212547dab5d83aa421afd75cdf840b29aa02951809878d726a5b6258
|
| 3 |
size 4865758176
|
model-00017-of-00027.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4957851848
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:87de5700ddf7426ba83a7ac8df07699027f563bf90e67430d3e6d7906c3dbea3
|
| 3 |
size 4957851848
|
model-00018-of-00027.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4957851848
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:3cb36d304d996411d4a8a6493634bf5aba530127486ce5589ecc1d1e417aaec1
|
| 3 |
size 4957851848
|
model-00019-of-00027.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4957851848
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:91855ced18b158fcdc2868590f3c4ad4e9b5309aa5fb4db047af7c70a51cb073
|
| 3 |
size 4957851848
|
model-00020-of-00027.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4957851848
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:a330aede9b461de01b06996f04bb5e4a45c76a5b5764e659e0194f0d43cf4c33
|
| 3 |
size 4957851848
|
model-00021-of-00027.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4865758176
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:ab884316934d7b437b1807eda685181e5d02fa262ba232624d8847d00f4fa7e9
|
| 3 |
size 4865758176
|
model-00022-of-00027.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4957851848
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:cfb111cea2f12472a877acc720acdc5ce49e95b3105702632514d4e4515e5c3a
|
| 3 |
size 4957851848
|
model-00023-of-00027.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4957851848
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:0f24e2e75404bac048ce71213e467833642d2e463b045ff4101e5dd8df4b1384
|
| 3 |
size 4957851848
|
model-00024-of-00027.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4957851848
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:4d0b7a06c50285b5bdfa0e3a402783e024daa2d943f37862cd94168d07179a33
|
| 3 |
size 4957851848
|
model-00025-of-00027.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4978856600
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:bdd7eda115b04757d7088f74a2ba240b5d1b8a2122a66f6d0e1f4c57abe167fc
|
| 3 |
size 4978856600
|
model-00026-of-00027.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4844753424
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:7719c33ac5cfbe42d6f5f52aee8fc0110e368c153f1fb831e682575638f2e657
|
| 3 |
size 4844753424
|
model-00027-of-00027.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4710255120
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:27e017c1bc752c5ca3ec42edb14eabf97c3485c0a7f5c1f32c70a7da5515f017
|
| 3 |
size 4710255120
|
model.safetensors.index.json
CHANGED
|
@@ -1,5 +1,6 @@
|
|
| 1 |
{
|
| 2 |
"metadata": {
|
|
|
|
| 3 |
"total_size": 133082660864
|
| 4 |
},
|
| 5 |
"weight_map": {
|
|
|
|
| 1 |
{
|
| 2 |
"metadata": {
|
| 3 |
+
"total_parameters": 33270665216,
|
| 4 |
"total_size": 133082660864
|
| 5 |
},
|
| 6 |
"weight_map": {
|