Text Generation
Transformers
Safetensors
English
muse_glimmer
image-text-to-text
knowledge-update
2026-news
built-with-muse-spark-open
conversational
Instructions to use OfflineBase/Muse-Glimmer-30B-2026-Knowledge with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use OfflineBase/Muse-Glimmer-30B-2026-Knowledge with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="OfflineBase/Muse-Glimmer-30B-2026-Knowledge") messages = [ { "role": "user", "content": [ {"type": "image", "url": "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/p-blog/candy.JPG"}, {"type": "text", "text": "What animal is on the candy?"} ] }, ] pipe(text=messages)# pip install -U transformers accelerate # Load model directly from transformers import AutoProcessor, AutoModelForMultimodalLM processor = AutoProcessor.from_pretrained("OfflineBase/Muse-Glimmer-30B-2026-Knowledge") model = AutoModelForMultimodalLM.from_pretrained("OfflineBase/Muse-Glimmer-30B-2026-Knowledge", device_map="auto") messages = [ { "role": "user", "content": [ {"type": "image", "url": "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/p-blog/candy.JPG"}, {"type": "text", "text": "What animal is on the candy?"} ] }, ] inputs = processor.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=256) print(processor.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use OfflineBase/Muse-Glimmer-30B-2026-Knowledge with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "OfflineBase/Muse-Glimmer-30B-2026-Knowledge" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "OfflineBase/Muse-Glimmer-30B-2026-Knowledge", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/OfflineBase/Muse-Glimmer-30B-2026-Knowledge
- SGLang
How to use OfflineBase/Muse-Glimmer-30B-2026-Knowledge 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 "OfflineBase/Muse-Glimmer-30B-2026-Knowledge" \ --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": "OfflineBase/Muse-Glimmer-30B-2026-Knowledge", "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 "OfflineBase/Muse-Glimmer-30B-2026-Knowledge" \ --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": "OfflineBase/Muse-Glimmer-30B-2026-Knowledge", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use OfflineBase/Muse-Glimmer-30B-2026-Knowledge with Docker Model Runner:
docker model run hf.co/OfflineBase/Muse-Glimmer-30B-2026-Knowledge
Download tuned-reasoning-off.jinja from OfflineBase/Muse-Glimmer-30B-2026-Knowledge: direct link, hf CLI and curl.
- Browser
- Download file 11.7 kB
-
https://huggingface.co/OfflineBase/Muse-Glimmer-30B-2026-Knowledge/resolve/main/tuned-reasoning-off.jinja
- Command line
-
hf download hf://OfflineBase/Muse-Glimmer-30B-2026-Knowledge/tuned-reasoning-off.jinja
-
curl -L -o tuned-reasoning-off.jinja https://huggingface.co/OfflineBase/Muse-Glimmer-30B-2026-Knowledge/resolve/main/tuned-reasoning-off.jinja
11.7 kB
| {#- tuned-reasoning-off.jinja | |
| Modified from Meta's chat_template.jinja for Muse Glimmer 30B (meta-models/Muse-Glimmer-30B, revision | |
| cec94fcfd6512f2cfe708138c32533b346ea4f69), which Meta releases under the Apache License 2.0 (see LICENSE and NOTICE). | |
| What changed: unless chat_template_kwargs sets allow_reasoning to true, the generation prompt opens the reply to the | |
| user (" to=user<|message|>"), so there is no reasoning channel and no tool calls on that turn. A comment block | |
| explains this further down. Everything else is Meta's template as released. | |
| Serve with llama.cpp --reasoning-format none and stop on <|eot|> and <|end_of_text|>, never <|eom|>. | |
| Note: when the caller sends no reasoning strength, this template writes "Reasoning strength: high." The training rows | |
| used low. Which works better is under test. | |
| This is not an official Meta file and Meta does not endorse it. -#} | |
| {# | |
| Template: Muse Glimmer ATEM Chat Template | |
| Renders the ATEM tool-calling protocol: reasoning channel (to=self), tool | |
| channels (to=<tool>), and the user channel, plus tool definitions and the | |
| valid-recipient list in the system block. | |
| Whitespace note: every tag uses the {%- -%} / {{- -}} stripping markers, so | |
| the indentation below is purely for readability and contributes nothing to | |
| the rendered output. | |
| #} | |
| {%- macro render_content(content) -%} | |
| {%- if content is string -%} | |
| {{- content -}} | |
| {%- elif content is not none -%} | |
| {%- for part in content -%} | |
| {%- if part['type'] == 'image' -%} | |
| {{- '<|patch|>' -}} | |
| {%- elif part['type'] == 'video' -%} | |
| {{- '<|video|>' -}} | |
| {%- elif part['type'] == 'text' -%} | |
| {{- part['text'] -}} | |
| {%- endif -%} | |
| {%- endfor -%} | |
| {%- endif -%} | |
| {%- endmacro -%} | |
| {%- macro render_atem(tc) -%} | |
| {%- set args = tc.function.arguments -%} | |
| {%- if args is not mapping -%} | |
| {{- raise_exception('Muse Glimmer ATEM chat template requires tool_call.function.arguments to be a dict (mapping); a JSON string cannot be parsed in the HF jinja sandbox.') -}} | |
| {%- endif -%} | |
| {{- '<atem:function_calls>\n<atem:invoke name="' + tc.function.name + '">\n' -}} | |
| {%- for k, v in args.items() -%} | |
| {{- '<atem:parameter name="' + k + '">' -}} | |
| {%- if v is boolean -%} | |
| {%- if v -%} | |
| true | |
| {%- else -%} | |
| false | |
| {%- endif -%} | |
| {%- elif v is none -%} | |
| null | |
| {%- elif v is mapping or (v is iterable and v is not string) -%} | |
| {{- v | tojson -}} | |
| {%- else -%} | |
| {{- v -}} | |
| {%- endif -%} | |
| {{- '</atem:parameter>\n' -}} | |
| {%- endfor -%} | |
| {{- '</atem:invoke>\n</atem:function_calls>' -}} | |
| {%- endmacro -%} | |
| {%- macro render_tool_defs(tools) -%} | |
| {{- 'In this environment you have access to a set of tools you can use to answer the user\'s question.\n\n' -}} | |
| {{- 'You can invoke a function by writing a "<atem:function_calls>" block like the following:\n' -}} | |
| {{- '<atem:function_calls>\n<atem:invoke name="$FUNCTION_NAME">\n<atem:parameter name="$PARAMETER_NAME">$PARAMETER_VALUE</atem:parameter>\n...\n</atem:invoke>\n</atem:function_calls>\n\n' -}} | |
| {{- 'String and scalar parameters should be specified as is, while lists and objects should use JSON format. Note that spaces for string values are not stripped. The output is not expected to be valid XML and is parsed with regular expressions.\n' -}} | |
| {{- 'Here are the functions available in JSONSchema format:\n' -}} | |
| {{- '// Tool metadata\n' -}} | |
| {%- set nsns = namespace(seen=[]) -%} | |
| {%- for tool in tools -%} | |
| {%- set fn = tool.function if tool.function is defined else tool -%} | |
| {%- set tns = fn.name.split('.')[0] -%} | |
| {%- if tns not in nsns.seen -%} | |
| {%- set nsns.seen = nsns.seen + [tns] -%} | |
| {%- endif -%} | |
| {%- endfor -%} | |
| {%- set nd = tool_namespace_descriptions if tool_namespace_descriptions is defined else {} -%} | |
| {%- for tns in nsns.seen -%} | |
| {{- '{"name": ' + (tns | tojson) + ', "description": ' + ((nd[tns] if tns in nd else '') | tojson) + '}\n' -}} | |
| {%- endfor -%} | |
| {{- '// Function schemas' -}} | |
| {%- for tool in tools -%} | |
| {%- set fn = tool.function if tool.function is defined else tool -%} | |
| {{- '\n{"name": ' + (fn.name | tojson) + ', "description": ' + (fn.description | tojson) + ', "parameters": ' + (fn.parameters | tojson) + '}' -}} | |
| {%- endfor -%} | |
| {{- '\n\nHere\'s an example of how to call a function in the tool set:\n' -}} | |
| {{- '(If the tool namespace is not specified, invoke the function directly as `example_function_name` rather than `example_tool_name.example_function_name`)\n\n' -}} | |
| {{- 'to=example_tool_name.example_function_name\n\n' -}} | |
| {{- '<atem:function_calls>\n<atem:invoke name="example_tool_name.example_function_name">\n' -}} | |
| {{- '<atem:parameter name="example_parameter_1">value_1</atem:parameter>\n' -}} | |
| {{- '<atem:parameter name="example_parameter_2">This is the value for the second parameter\nthat can span\n"multiple" lines\n</atem:parameter>\n' -}} | |
| {{- '</atem:invoke>\n</atem:function_calls>' -}} | |
| {%- endmacro -%} | |
| {%- macro render_reasoning() -%} | |
| {%- set rs = reasoning_strength if reasoning_strength is defined and reasoning_strength else 'high' -%} | |
| {{- 'Reasoning strength: ' + rs + '.' -}} | |
| {%- endmacro -%} | |
| {%- macro render_system_meta(tools) -%} | |
| {%- set rns = namespace(recipients=['"self"'], nslist=[]) -%} | |
| {%- if tools -%} | |
| {%- for tool in tools -%} | |
| {%- set fn = tool.function if tool.function is defined else tool -%} | |
| {%- set tns = fn.name.split('.')[0] -%} | |
| {%- if tns not in rns.nslist -%} | |
| {%- set rns.nslist = rns.nslist + [tns] -%} | |
| {%- endif -%} | |
| {%- endfor -%} | |
| {%- for tns in rns.nslist -%} | |
| {%- set rns.recipients = rns.recipients + ['"' + tns + '.*"'] -%} | |
| {%- endfor -%} | |
| {%- endif -%} | |
| {%- set rns.recipients = rns.recipients + ['"user"'] -%} | |
| {{- '# Valid recipients: ' + rns.recipients | join(', ') + '.' -}} | |
| {%- endmacro -%} | |
| {{- bos_token -}} | |
| {%- set ns = namespace(has_system=false) -%} | |
| {%- for m in messages -%} | |
| {%- if m['role'] == 'system' -%} | |
| {%- set ns.has_system = true -%} | |
| {%- endif -%} | |
| {%- endfor -%} | |
| {%- if not ns.has_system -%} | |
| {{- '<|start|>system<|message|>You are a helpful AI assistant.' -}} | |
| {%- set kc = knowledge_cutoff if knowledge_cutoff is defined and knowledge_cutoff else '2026-01-04' -%} | |
| {{- '\nKnowledge cutoff: ' + kc + '.' -}} | |
| {%- if current_date is defined and current_date -%} | |
| {{- '\nCurrent date: ' + current_date + '.' -}} | |
| {%- elif strftime_now is defined -%} | |
| {{- '\nCurrent date: ' + strftime_now('%Y-%m-%d') + '.' -}} | |
| {%- endif -%} | |
| {{- '\n\n' -}} | |
| {{- render_reasoning() -}} | |
| {%- if tools -%} | |
| {{- '\n\n' -}} | |
| {{- render_tool_defs(tools) -}} | |
| {%- endif -%} | |
| {{- '\n\n' -}} | |
| {{- render_system_meta(tools) -}} | |
| {{- '<|eot|>' -}} | |
| {%- endif -%} | |
| {%- for message in messages -%} | |
| {%- set role = message['role'] -%} | |
| {%- set end_token = '<|eom|>' if (not loop.last and messages[loop.index0 + 1]['role'] == role) else '<|eot|>' -%} | |
| {%- if role == 'system' -%} | |
| {#- Callers sometimes write the directive into the system prompt themselves. | |
| Normalise "Reasoning effort" to "Reasoning strength" (jinja has no | |
| case-insensitive replace, hence the four realistic casings), then skip | |
| the kwarg-driven line below if the prompt already carries one. -#} | |
| {%- set sys_text = render_content(message['content']) | |
| | replace('Reasoning effort', 'Reasoning strength') | |
| | replace('Reasoning Effort', 'Reasoning Strength') | |
| | replace('reasoning effort', 'reasoning strength') | |
| | replace('REASONING EFFORT', 'REASONING STRENGTH') -%} | |
| {{- '<|start|>system<|message|>' -}} | |
| {{- sys_text -}} | |
| {%- if 'reasoning strength' not in (sys_text | lower) -%} | |
| {{- '\n\n' -}} | |
| {{- render_reasoning() -}} | |
| {%- endif -%} | |
| {%- if tools -%} | |
| {{- '\n\n' -}} | |
| {{- render_tool_defs(tools) -}} | |
| {%- endif -%} | |
| {{- '\n\n' -}} | |
| {{- render_system_meta(tools) -}} | |
| {{- '<|eot|>' -}} | |
| {%- elif role == 'user' -%} | |
| {{- '<|start|>user<|message|>' -}} | |
| {{- render_content(message['content']) -}} | |
| {{- '<|eot|>' -}} | |
| {%- elif role == 'tool' -%} | |
| {%- set tname = message.get('name') -%} | |
| {%- if not tname -%} | |
| {%- set tcid = message.get('tool_call_id') -%} | |
| {%- set rns = namespace(name=tcid if tcid else '') -%} | |
| {%- for m in messages -%} | |
| {%- if m.get('tool_calls') -%} | |
| {%- for tc in m['tool_calls'] -%} | |
| {%- if tcid is not none and tc.id is defined and tc.id == tcid -%} | |
| {%- set rns.name = tc.function.name -%} | |
| {%- endif -%} | |
| {%- endfor -%} | |
| {%- endif -%} | |
| {%- endfor -%} | |
| {%- set tname = rns.name -%} | |
| {%- endif -%} | |
| {{- '<|start|>tool ' + tname + '<|message|><tool_output name="' + tname + '">\n' -}} | |
| {{- render_content(message['content']) -}} | |
| {{- '\n</tool_output><|eot|>' -}} | |
| {%- elif role == 'assistant' -%} | |
| {%- if message.get('reasoning_content') -%} | |
| {{- '<|start|>assistant to=self<|message|>' + message['reasoning_content'] + '<|eom|>' -}} | |
| {%- endif -%} | |
| {%- if message.get('tool_calls') -%} | |
| {%- for tc in message['tool_calls'] -%} | |
| {{- '<|start|>assistant to=' + tc.function.name + '<|message|>' -}} | |
| {{- render_atem(tc) -}} | |
| {%- if loop.last -%} | |
| {{- end_token -}} | |
| {%- else -%} | |
| {{- '<|eom|>' -}} | |
| {%- endif -%} | |
| {%- endfor -%} | |
| {%- else -%} | |
| {%- set recipient = message.get('recipient') or 'user' -%} | |
| {%- set end_turn = message.get('end_turn') -%} | |
| {%- if end_turn is none -%} | |
| {%- set end_turn = not (recipient and recipient != 'user') -%} | |
| {%- endif -%} | |
| {{- '<|start|>assistant' -}} | |
| {%- if recipient -%} | |
| {{- ' to=' + recipient -}} | |
| {%- endif -%} | |
| {{- '<|message|>' -}} | |
| {{- render_content(message['content']) -}} | |
| {{- ('<|eot|>' if end_turn else '<|eom|>') -}} | |
| {%- endif -%} | |
| {%- endif -%} | |
| {%- endfor -%} | |
| {#- Tuned Muse Glimmer serving: reasoning off by default. The generation prompt opens the final channel, so the reply is the | |
| answer. Needs llama-server --reasoning-format none: llama.cpp's Muse Glimmer parser (common/parsers/muse-glimmer.cpp) expects | |
| to read the channel header in the reply and returns HTTP 500 without it. Send "stop": ["<|eot|>"], since with that format the | |
| end token stays in the text. For the base model's own generation prompt on one request, send chat_template_kwargs | |
| {"allow_reasoning": true} and "reasoning_format": "auto". No tool calls while reasoning is off: the turn already goes to the user. -#} | |
| {%- if add_generation_prompt -%} | |
| {{- '<|start|>assistant' -}} | |
| {%- if not (allow_reasoning is defined and allow_reasoning) -%} | |
| {{- ' to=user<|message|>' -}} | |
| {%- endif -%} | |
| {%- endif -%} | |