Run this model with HF Jobs
Run mlx-community/Qwen3-Coder-Next-bf16 on Hugging Face's managed compute, monitor its progress, and retrieve the results when it's done.
Paste one of these prompts into your coding agent:
Fine-tune on my dataset
Use HF Jobs to fine-tune https://huggingface.co/mlx-community/Qwen3-Coder-Next-bf16. Ask me which dataset to train on, then push the fine-tuned model to a new model repo. Run `hf jobs --help` first to learn the CLI.
Run batch inference
Use HF Jobs to run batch inference with https://huggingface.co/mlx-community/Qwen3-Coder-Next-bf16 on the inputs in a mounted HF Bucket. Ask me which Bucket to use, then write the outputs back to it and keep each input ID. Run `hf jobs --help` first to learn the CLI.
Evaluate on a benchmark
Use HF Jobs to evaluate https://huggingface.co/mlx-community/Qwen3-Coder-Next-bf16. Ask me which benchmark to run, then save the scores and the per-example results to a new dataset repo. Run `hf jobs --help` first to learn the CLI.
Quantize for lower memory use
Use HF Jobs to create a 4-bit version of https://huggingface.co/mlx-community/Qwen3-Coder-Next-bf16. Push it to a new model repo, then reload it from there and report its memory footprint. Run `hf jobs --help` first to learn the CLI.
Instructions to use mlx-community/Qwen3-Coder-Next-bf16 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- MLX
How to use mlx-community/Qwen3-Coder-Next-bf16 with MLX:
# Make sure mlx-lm is installed # pip install --upgrade mlx-lm # Generate text with mlx-lm from mlx_lm import load, generate model, tokenizer = load("mlx-community/Qwen3-Coder-Next-bf16") prompt = "Write a story about Einstein" messages = [{"role": "user", "content": prompt}] prompt = tokenizer.apply_chat_template( messages, add_generation_prompt=True ) text = generate(model, tokenizer, prompt=prompt, verbose=True) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- LM Studio
- Pi
How to use mlx-community/Qwen3-Coder-Next-bf16 with Pi:
Start the MLX server
# Install MLX LM: uv tool install mlx-lm # Start a local OpenAI-compatible server: mlx_lm.server --model "mlx-community/Qwen3-Coder-Next-bf16"
Configure the model in Pi
# Install Pi: npm install -g @earendil-works/pi-coding-agent # Add to ~/.pi/agent/models.json: { "providers": { "mlx-lm": { "baseUrl": "http://localhost:8080/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "mlx-community/Qwen3-Coder-Next-bf16" } ] } } }Run Pi
# Start Pi in your project directory: pi
- MLX LM
How to use mlx-community/Qwen3-Coder-Next-bf16 with MLX LM:
Generate or start a chat session
# Install MLX LM uv tool install mlx-lm # Interactive chat REPL mlx_lm.chat --model "mlx-community/Qwen3-Coder-Next-bf16"
Run an OpenAI-compatible server
# Install MLX LM uv tool install mlx-lm # Start the server mlx_lm.server --model "mlx-community/Qwen3-Coder-Next-bf16" # Calling the OpenAI-compatible server with curl curl -X POST "http://localhost:8080/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "mlx-community/Qwen3-Coder-Next-bf16", "messages": [ {"role": "user", "content": "Hello"} ] }' - Hermes Agent
How to use mlx-community/Qwen3-Coder-Next-bf16 with Hermes Agent:
Start the MLX server
# Install MLX LM: uv tool install mlx-lm # Start a local OpenAI-compatible server: mlx_lm.server --model "mlx-community/Qwen3-Coder-Next-bf16"
Configure Hermes
# Install Hermes: curl -fsSL https://hermes-agent.nousresearch.com/install.sh | bash hermes setup # Point Hermes at the local server: hermes config set model.provider custom hermes config set model.base_url http://127.0.0.1:8080/v1 hermes config set model.default mlx-community/Qwen3-Coder-Next-bf16
Run Hermes
hermes
- Atomic Chat
- OpenClaw
How to use mlx-community/Qwen3-Coder-Next-bf16 with OpenClaw:
Start the MLX server
# Install MLX LM: uv tool install mlx-lm # Start a local OpenAI-compatible server: mlx_lm.server --model "mlx-community/Qwen3-Coder-Next-bf16"
Configure OpenClaw
# Install OpenClaw: npm install -g openclaw@latest # Register the local server and set it as the default model: openclaw onboard --non-interactive --mode local \ --auth-choice custom-api-key \ --custom-base-url http://127.0.0.1:8080/v1 \ --custom-model-id "mlx-community/Qwen3-Coder-Next-bf16" \ --custom-provider-id mlx-lm \ --custom-compatibility openai \ --custom-text-input \ --accept-risk \ --skip-health
Run OpenClaw
openclaw agent --local --agent main --message "Hello from Hugging Face"
Add files using upload-large-folder tool
Browse filesFiles changed (46)
- .gitattributes+1
- README.mdAdded+37
- chat_template.jinjaAdded+117
- config.jsonAdded+47
- generation_config.jsonAdded+13
- model-00001-of-00036.safetensorsAdded+3
- model-00002-of-00036.safetensorsAdded+3
- model-00003-of-00036.safetensorsAdded+3
- model-00004-of-00036.safetensorsAdded+3
- model-00005-of-00036.safetensorsAdded+3
- model-00006-of-00036.safetensorsAdded+3
- model-00007-of-00036.safetensorsAdded+3
- model-00008-of-00036.safetensorsAdded+3
- model-00009-of-00036.safetensorsAdded+3
- model-00010-of-00036.safetensorsAdded+3
- model-00011-of-00036.safetensorsAdded+3
- model-00012-of-00036.safetensorsAdded+3
- model-00013-of-00036.safetensorsAdded+3
- model-00014-of-00036.safetensorsAdded+3
- model-00015-of-00036.safetensorsAdded+3
- model-00016-of-00036.safetensorsAdded+3
- model-00017-of-00036.safetensorsAdded+3
- model-00018-of-00036.safetensorsAdded+3
- model-00019-of-00036.safetensorsAdded+3
- model-00020-of-00036.safetensorsAdded+3
- model-00021-of-00036.safetensorsAdded+3
- model-00022-of-00036.safetensorsAdded+3
- model-00023-of-00036.safetensorsAdded+3
- model-00024-of-00036.safetensorsAdded+3
- model-00025-of-00036.safetensorsAdded+3
- model-00026-of-00036.safetensorsAdded+3
- model-00027-of-00036.safetensorsAdded+3
- model-00028-of-00036.safetensorsAdded+3
- model-00029-of-00036.safetensorsAdded+3
- model-00030-of-00036.safetensorsAdded+3
- model-00031-of-00036.safetensorsAdded+3
- model-00032-of-00036.safetensorsAdded+3
- model-00033-of-00036.safetensorsAdded+3
- model-00034-of-00036.safetensorsAdded+3
- model-00035-of-00036.safetensorsAdded+3
- model-00036-of-00036.safetensorsAdded+3
- model.safetensors.index.jsonAdded+815
- qwen3_coder_detector_sgl.pyAdded+474
- qwen3coder_tool_parser_vllm.pyAdded+690
- tokenizer.jsonAdded+3
- tokenizer_config.jsonAdded+30
32 unmodified lines33343532 unmodified lines*.zip filter=lfs diff=lfs merge=lfs -text*.zst filter=lfs diff=lfs merge=lfs -text*tfevents* filter=lfs diff=lfs merge=lfs -text32 unmodified lines3334353632 unmodified lines*.zip filter=lfs diff=lfs merge=lfs -text*.zst filter=lfs diff=lfs merge=lfs -text*tfevents* filter=lfs diff=lfs merge=lfs -texttokenizer.json filter=lfs diff=lfs merge=lfs -text
12345678910111213141516171819202122232425262728293031323334353637---library_name: mlxlicense: apache-2.0license_link: https://huggingface.co/Qwen/Qwen3-Coder-Next/blob/main/LICENSEpipeline_tag: text-generationtags:- mlxbase_model: Qwen/Qwen3-Coder-Next---
# mlx-community/Qwen3-Coder-Next-bf16
This model [mlx-community/Qwen3-Coder-Next-bf16](https://huggingface.co/mlx-community/Qwen3-Coder-Next-bf16) wasconverted to MLX format from [Qwen/Qwen3-Coder-Next](https://huggingface.co/Qwen/Qwen3-Coder-Next)using mlx-lm version **0.30.5**.
## Use with mlx
```bashpip install mlx-lm```
```pythonfrom mlx_lm import load, generate
model, tokenizer = load("mlx-community/Qwen3-Coder-Next-bf16")
prompt = "hello"
if tokenizer.chat_template is not None: messages = [{"role": "user", "content": prompt}] prompt = tokenizer.apply_chat_template( messages, add_generation_prompt=True, return_dict=False, )
response = generate(model, tokenizer, prompt=prompt, verbose=True)```123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117{% macro render_extra_keys(json_dict, handled_keys) %} {%- if json_dict is mapping %} {%- for json_key in json_dict if json_key not in handled_keys %} {%- if json_dict[json_key] is string %} {{-'\n<' ~ json_key ~ '>' ~ (json_dict[json_key] | string) ~ '</' ~ json_key ~ '>' }} {%- else %} {{- '\n<' ~ json_key ~ '>' ~ (json_dict[json_key] | tojson | safe) ~ '</' ~ json_key ~ '>' }} {%- endif %} {%- endfor %} {%- endif %}{%- endmacro %}
{%- if messages[0]["role"] == "system" %} {%- set system_message = messages[0]["content"] %} {%- set loop_messages = messages[1:] %}{%- else %} {%- set loop_messages = messages %}{%- endif %}
{%- if not tools is defined %} {%- set tools = [] %}{%- endif %}
{%- if system_message is defined %} {{- "<|im_start|>system\n" + system_message }}{%- else %} {%- if tools is iterable and tools | length > 0 %} {{- "<|im_start|>system\nYou are Qwen, a helpful AI assistant that can interact with a computer to solve tasks." }} {%- endif %}{%- endif %}{%- if tools is iterable and tools | length > 0 %} {{- "\n\n# Tools\n\nYou have access to the following functions:\n\n" }} {{- "<tools>" }} {%- for tool in tools %} {%- if tool.function is defined %} {%- set tool = tool.function %} {%- endif %} {{- "\n<function>\n<name>" ~ tool.name ~ "</name>" }} {%- if tool.description is defined %} {{- '\n<description>' ~ (tool.description | trim) ~ '</description>' }} {%- endif %} {{- '\n<parameters>' }} {%- if tool.parameters is defined and tool.parameters is mapping and tool.parameters.properties is defined and tool.parameters.properties is mapping %} {%- for param_name, param_fields in tool.parameters.properties|items %} {{- '\n<parameter>' }} {{- '\n<name>' ~ param_name ~ '</name>' }} {%- if param_fields.type is defined %} {{- '\n<type>' ~ (param_fields.type | string) ~ '</type>' }} {%- endif %} {%- if param_fields.description is defined %} {{- '\n<description>' ~ (param_fields.description | trim) ~ '</description>' }} {%- endif %} {%- set handled_keys = ['name', 'type', 'description'] %} {{- render_extra_keys(param_fields, handled_keys) }} {{- '\n</parameter>' }} {%- endfor %} {%- endif %} {%- set handled_keys = ['type', 'properties'] %} {{- render_extra_keys(tool.parameters, handled_keys) }} {{- '\n</parameters>' }} {%- set handled_keys = ['type', 'name', 'description', 'parameters'] %} {{- render_extra_keys(tool, handled_keys) }} {{- '\n</function>' }} {%- endfor %} {{- "\n</tools>" }} {{- '\n\nIf you choose to call a function ONLY reply in the following format with NO suffix:\n\n<tool_call>\n<function=example_function_name>\n<parameter=example_parameter_1>\nvalue_1\n</parameter>\n<parameter=example_parameter_2>\nThis is the value for the second parameter\nthat can span\nmultiple lines\n</parameter>\n</function>\n</tool_call>\n\n<IMPORTANT>\nReminder:\n- Function calls MUST follow the specified format: an inner <function=...></function> block must be nested within <tool_call></tool_call> XML tags\n- Required parameters MUST be specified\n- You may provide optional reasoning for your function call in natural language BEFORE the function call, but NOT after\n- If there is no function call available, answer the question like normal with your current knowledge and do not tell the user about function calls\n</IMPORTANT>' }}{%- endif %}{%- if system_message is defined %} {{- '<|im_end|>\n' }}{%- else %} {%- if tools is iterable and tools | length > 0 %} {{- '<|im_end|>\n' }} {%- endif %}{%- endif %}{%- for message in loop_messages %} {%- if message.role == "assistant" and message.tool_calls is defined and message.tool_calls is iterable and message.tool_calls | length > 0 %} {{- '<|im_start|>' + message.role }} {%- if message.content is defined and message.content is string and message.content | trim | length > 0 %} {{- '\n' + message.content | trim + '\n' }} {%- endif %} {%- for tool_call in message.tool_calls %} {%- if tool_call.function is defined %} {%- set tool_call = tool_call.function %} {%- endif %} {{- '\n<tool_call>\n<function=' + tool_call.name + '>\n' }} {%- if tool_call.arguments is defined %} {%- for args_name, args_value in tool_call.arguments|items %} {{- '<parameter=' + args_name + '>\n' }} {%- set args_value = args_value if args_value is string else args_value | tojson | safe %} {{- args_value }} {{- '\n</parameter>\n' }} {%- endfor %} {%- endif %} {{- '</function>\n</tool_call>' }} {%- endfor %} {{- '<|im_end|>\n' }} {%- elif message.role == "user" or message.role == "system" or message.role == "assistant" %} {{- '<|im_start|>' + message.role + '\n' + message.content + '<|im_end|>' + '\n' }} {%- elif message.role == "tool" %} {%- if loop.previtem and loop.previtem.role != "tool" %} {{- '<|im_start|>user' }} {%- endif %} {{- '\n<tool_response>\n' }} {{- message.content }} {{- '\n</tool_response>' }} {%- if not loop.last and loop.nextitem.role != "tool" %} {{- '<|im_end|>\n' }} {%- elif loop.last %} {{- '<|im_end|>\n' }} {%- endif %} {%- else %} {{- '<|im_start|>' + message.role + '\n' + message.content + '<|im_end|>\n' }} {%- endif %}{%- endfor %}{%- if add_generation_prompt %} {{- '<|im_start|>assistant\n' }}{%- endif %}1234567891011121314151617181920212223242526272829303132333435363738394041424344454647{ "architectures": [ "Qwen3NextForCausalLM" ], "attention_bias": false, "attention_dropout": 0, "bos_token_id": 151643, "decoder_sparse_step": 1, "eos_token_id": [ 151645, 151643 ], "full_attention_interval": 4, "head_dim": 256, "hidden_act": "silu", "hidden_size": 2048, "initializer_range": 0.02, "intermediate_size": 5120, "linear_conv_kernel_dim": 4, "linear_key_head_dim": 128, "linear_num_key_heads": 16, "linear_num_value_heads": 32, "linear_value_head_dim": 128, "max_position_embeddings": 262144, "mlp_only_layers": [], "model_type": "qwen3_next", "moe_intermediate_size": 512, "norm_topk_prob": true, "num_attention_heads": 16, "num_experts": 512, "num_experts_per_tok": 10, "num_hidden_layers": 48, "num_key_value_heads": 2, "output_router_logits": false, "partial_rotary_factor": 0.25, "rms_norm_eps": 1e-06, "rope_scaling": null, "rope_theta": 5000000, "router_aux_loss_coef": 0.001, "shared_expert_intermediate_size": 512, "tie_word_embeddings": false, "torch_dtype": "bfloat16", "transformers_version": "4.57.0.dev0", "use_cache": true, "use_sliding_window": false, "vocab_size": 151936}12345678910111213{ "bos_token_id": 151643, "do_sample": true, "eos_token_id": [ 151645, 151643 ], "pad_token_id": 151643, "temperature": 1.0, "top_k": 40, "top_p": 0.95, "transformers_version": "4.57.3"}123version https://git-lfs.github.com/spec/v1oid sha256:66109f53e021bbc7747d860b965b0db140c03f9addfb6f92563107537c3ffa15size 5062680687123version https://git-lfs.github.com/spec/v1oid sha256:221a4b76ae593231f72026739a42b9440a76d553bdc4ee38eff4ee32cc7611d5size 4370807305123version https://git-lfs.github.com/spec/v1oid sha256:1f77df8f548e76f0b749edab31e14bffd113cd000edc52c2f8e91d5ca66c316fsize 4433736661123version https://git-lfs.github.com/spec/v1oid sha256:24cc0bd2edfcb099c61f71f29120ed20e17f795a6abeafd70937c1eae9b14460size 4370807259123version https://git-lfs.github.com/spec/v1oid sha256:810ab413d72df7ccb4083cae624260292288c7b5c791cda047861aae891428easize 4370807305123version https://git-lfs.github.com/spec/v1oid sha256:a99da623b02764a5b3c791e52b701b4f782260e05d5cc148401b02516fd88957size 4433736633123version https://git-lfs.github.com/spec/v1oid sha256:5531f81b7352712d52a9650f912f3e70c89f8818210eb546a5a0321808fff2cbsize 4370807269123version https://git-lfs.github.com/spec/v1oid sha256:d273c1fca321be0763dda503dbaea92dfbf3e5a288b9d7469ea87421945a433fsize 4370807317123version https://git-lfs.github.com/spec/v1oid sha256:90e855a213c4df2deaf101adb3e6a117ae8f55e156c61ddfd443109a3dc6bcf4size 4433736696123version https://git-lfs.github.com/spec/v1oid sha256:96a7ecafd42fb5c41aa212ceaf06bffd32fbd74bca9a0b3fe3d41b50ace8161fsize 4370807325123version https://git-lfs.github.com/spec/v1oid sha256:0ee71670ed2f971d5c138bc7be1945525823fc50e1e05308723f4c74f0165eb1size 4370807323123version https://git-lfs.github.com/spec/v1oid sha256:84dd276970f4a8742026b8e31f2246fc155d0c2882c2079fcb28a88c27d1c5e3size 4433736690123version https://git-lfs.github.com/spec/v1oid sha256:b2fe52a77ead5726cc7074e48d4fb36971fda3206a95405e54c9e0ee915a53bfsize 4370807303123version https://git-lfs.github.com/spec/v1oid sha256:ecd8c2f3cc872a14abe16c292a8fe5a75e507184e6ad306057ccc7a59978689esize 4370807323123version https://git-lfs.github.com/spec/v1oid sha256:da0045b47e751ab03fc00f76b3277abe1f9e463e101a71f3aa370ee057144f0csize 4433736688123version https://git-lfs.github.com/spec/v1oid sha256:928ef7e6e9f25bc8be1f98099f1612fcf56fd9a7470e6f930f4c268e46892e8bsize 4370807325123version https://git-lfs.github.com/spec/v1oid sha256:d85443a2a10175fd33abb9402c6e538263d8c9da3bc5b13aae63f94594b45022size 4370807323123version https://git-lfs.github.com/spec/v1oid sha256:8866a32d611795ffcd8b0a1340f833d062a10ded826698d58c7024c228214e87size 4433736682123version https://git-lfs.github.com/spec/v1oid sha256:d53cca9ee6d15bd8dacd2e67b48785478ad550662e64b3a09ffdbbe0560a8182size 4370807325123version https://git-lfs.github.com/spec/v1oid sha256:7fb2c2e728a859fedc9cabbdab6b52ba4aaff876d68df2548c4e731ac6c4d109size 4370807323123version https://git-lfs.github.com/spec/v1oid sha256:adca58e8b8f9a7468f2701f53ddc2120dac578c7284453891924fbe0993ef1a1size 4433736672123version https://git-lfs.github.com/spec/v1oid sha256:1598056296f23be8073c4a00dcda4817926c7a9ab04bc5f588869558172a395csize 4370807289123version https://git-lfs.github.com/spec/v1oid sha256:e42d54042c7e8bbca6516c8ff728cfa4fe21518d167516d023d2d043ce2e2265size 4370807323123version https://git-lfs.github.com/spec/v1oid sha256:f99235946486b26f3811a79f3bd35abd68aa3dbc66bebd0bdd6654d3c2105c07size 4433736680123version https://git-lfs.github.com/spec/v1oid sha256:35e1d55024ad77beadb674a1610d75dd4deb2c268311d13c5c2da3fcbf6d85desize 4370807325123version https://git-lfs.github.com/spec/v1oid sha256:62e8b1acd1ac65a704c281966696bd0d266b34e8e7dd69ce01ebd8f4bece7e36size 4370807323123version https://git-lfs.github.com/spec/v1oid sha256:572ff5a75314783d19d25b595a102156633416373184966e048aa86fe90c87fesize 4433736680123version https://git-lfs.github.com/spec/v1oid sha256:500220f8ea85d5a81c3503b93085fb14d0568d3868b19dc78f2e6a12fb535f58size 4370807297123version https://git-lfs.github.com/spec/v1oid sha256:45ae198bc8525b43f2875662a833e95432fc5b98086b28ac028ab07d08014ce7size 4370807323123version https://git-lfs.github.com/spec/v1oid sha256:403375a1fe4769ad11c8f88e74c0e9584e166385322bb858fa321dbe40dd2db2size 4433736696123version https://git-lfs.github.com/spec/v1oid sha256:fedeb1385f89d93a4b6d588a21c6c7aae79278aa646f68c7e1cb633d7d8e8190size 4370807273123version https://git-lfs.github.com/spec/v1oid sha256:e48f6e652f41c862ddceb47a22dc799f1f651d00fcf783fe8efdf430c5254ac6size 4370807323123version https://git-lfs.github.com/spec/v1oid sha256:baf7bca0ae14294db2c7cf9e71c8053605303a6e6e740249a71a6154b3cc424esize 4433736690123version https://git-lfs.github.com/spec/v1oid sha256:f2cb79e166da110f28a2b771fdcf9bfc6fb192bb97155a12cdd82596026274fesize 4370807325123version https://git-lfs.github.com/spec/v1oid sha256:0e460dcb53aa76ad6fe91d624e046fd01fdd572d8f3f97efb7890dd7acaafaf6size 4370807323123version https://git-lfs.github.com/spec/v1oid sha256:1a09d21809eae5bd5e48ea49705e3dd91914192aabed280e2e857430bc97bc07size 4986527436123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815{ "metadata": { "total_size": 159348782592, "total_parameters": 79674388992 }, "weight_map": { "lm_head.weight": "model-00036-of-00036.safetensors", "model.embed_tokens.weight": "model-00001-of-00036.safetensors", "model.layers.0.input_layernorm.weight": "model-00001-of-00036.safetensors", "model.layers.0.linear_attn.A_log": "model-00001-of-00036.safetensors", "model.layers.0.linear_attn.conv1d.weight": "model-00001-of-00036.safetensors", "model.layers.0.linear_attn.dt_bias": "model-00001-of-00036.safetensors", "model.layers.0.linear_attn.in_proj_ba.weight": "model-00001-of-00036.safetensors", "model.layers.0.linear_attn.in_proj_qkvz.weight": "model-00001-of-00036.safetensors", "model.layers.0.linear_attn.norm.weight": "model-00001-of-00036.safetensors", "model.layers.0.linear_attn.out_proj.weight": "model-00001-of-00036.safetensors", "model.layers.0.mlp.gate.weight": "model-00001-of-00036.safetensors", "model.layers.0.mlp.shared_expert.down_proj.weight": "model-00001-of-00036.safetensors", "model.layers.0.mlp.shared_expert.gate_proj.weight": "model-00001-of-00036.safetensors", "model.layers.0.mlp.shared_expert.up_proj.weight": "model-00001-of-00036.safetensors", "model.layers.0.mlp.shared_expert_gate.weight": "model-00001-of-00036.safetensors", "model.layers.0.mlp.switch_mlp.down_proj.weight": "model-00001-of-00036.safetensors", "model.layers.0.mlp.switch_mlp.gate_proj.weight": "model-00001-of-00036.safetensors", "model.layers.0.mlp.switch_mlp.up_proj.weight": "model-00001-of-00036.safetensors", "model.layers.0.post_attention_layernorm.weight": "model-00001-of-00036.safetensors", "model.layers.1.input_layernorm.weight": "model-00001-of-00036.safetensors", "model.layers.1.linear_attn.A_log": "model-00001-of-00036.safetensors", "model.layers.1.linear_attn.conv1d.weight": "model-00001-of-00036.safetensors", "model.layers.1.linear_attn.dt_bias": "model-00001-of-00036.safetensors", "model.layers.1.linear_attn.in_proj_ba.weight": "model-00001-of-00036.safetensors", "model.layers.1.linear_attn.in_proj_qkvz.weight": "model-00001-of-00036.safetensors", "model.layers.1.linear_attn.norm.weight": "model-00001-of-00036.safetensors", "model.layers.1.linear_attn.out_proj.weight": "model-00001-of-00036.safetensors", "model.layers.1.mlp.gate.weight": "model-00001-of-00036.safetensors", "model.layers.1.mlp.shared_expert.down_proj.weight": "model-00002-of-00036.safetensors", "model.layers.1.mlp.shared_expert.gate_proj.weight": "model-00002-of-00036.safetensors", "model.layers.1.mlp.shared_expert.up_proj.weight": "model-00002-of-00036.safetensors", "model.layers.1.mlp.shared_expert_gate.weight": "model-00002-of-00036.safetensors", "model.layers.1.mlp.switch_mlp.down_proj.weight": "model-00002-of-00036.safetensors", "model.layers.1.mlp.switch_mlp.gate_proj.weight": "model-00001-of-00036.safetensors", "model.layers.1.mlp.switch_mlp.up_proj.weight": "model-00002-of-00036.safetensors", "model.layers.1.post_attention_layernorm.weight": "model-00001-of-00036.safetensors", "model.layers.10.input_layernorm.weight": "model-00008-of-00036.safetensors", "model.layers.10.linear_attn.A_log": "model-00008-of-00036.safetensors", "model.layers.10.linear_attn.conv1d.weight": "model-00008-of-00036.safetensors", "model.layers.10.linear_attn.dt_bias": "model-00008-of-00036.safetensors", "model.layers.10.linear_attn.in_proj_ba.weight": "model-00008-of-00036.safetensors", "model.layers.10.linear_attn.in_proj_qkvz.weight": "model-00008-of-00036.safetensors", "model.layers.10.linear_attn.norm.weight": "model-00008-of-00036.safetensors", "model.layers.10.linear_attn.out_proj.weight": "model-00008-of-00036.safetensors", "model.layers.10.mlp.gate.weight": "model-00008-of-00036.safetensors", "model.layers.10.mlp.shared_expert.down_proj.weight": "model-00009-of-00036.safetensors", "model.layers.10.mlp.shared_expert.gate_proj.weight": "model-00009-of-00036.safetensors", "model.layers.10.mlp.shared_expert.up_proj.weight": "model-00009-of-00036.safetensors", "model.layers.10.mlp.shared_expert_gate.weight": "model-00009-of-00036.safetensors", "model.layers.10.mlp.switch_mlp.down_proj.weight": "model-00009-of-00036.safetensors", "model.layers.10.mlp.switch_mlp.gate_proj.weight": "model-00008-of-00036.safetensors", "model.layers.10.mlp.switch_mlp.up_proj.weight": "model-00008-of-00036.safetensors", "model.layers.10.post_attention_layernorm.weight": "model-00008-of-00036.safetensors", "model.layers.11.input_layernorm.weight": "model-00009-of-00036.safetensors", "model.layers.11.mlp.gate.weight": "model-00009-of-00036.safetensors", "model.layers.11.mlp.shared_expert.down_proj.weight": "model-00009-of-00036.safetensors", "model.layers.11.mlp.shared_expert.gate_proj.weight": "model-00009-of-00036.safetensors", "model.layers.11.mlp.shared_expert.up_proj.weight": "model-00009-of-00036.safetensors", "model.layers.11.mlp.shared_expert_gate.weight": "model-00009-of-00036.safetensors", "model.layers.11.mlp.switch_mlp.down_proj.weight": "model-00009-of-00036.safetensors", "model.layers.11.mlp.switch_mlp.gate_proj.weight": "model-00009-of-00036.safetensors", "model.layers.11.mlp.switch_mlp.up_proj.weight": "model-00009-of-00036.safetensors", "model.layers.11.post_attention_layernorm.weight": "model-00009-of-00036.safetensors", "model.layers.11.self_attn.k_norm.weight": "model-00009-of-00036.safetensors", "model.layers.11.self_attn.k_proj.weight": "model-00009-of-00036.safetensors", "model.layers.11.self_attn.o_proj.weight": "model-00009-of-00036.safetensors", "model.layers.11.self_attn.q_norm.weight": "model-00009-of-00036.safetensors", "model.layers.11.self_attn.q_proj.weight": "model-00009-of-00036.safetensors", "model.layers.11.self_attn.v_proj.weight": "model-00009-of-00036.safetensors", "model.layers.12.input_layernorm.weight": "model-00009-of-00036.safetensors", "model.layers.12.linear_attn.A_log": "model-00009-of-00036.safetensors", "model.layers.12.linear_attn.conv1d.weight": "model-00009-of-00036.safetensors", "model.layers.12.linear_attn.dt_bias": "model-00009-of-00036.safetensors", "model.layers.12.linear_attn.in_proj_ba.weight": "model-00009-of-00036.safetensors", "model.layers.12.linear_attn.in_proj_qkvz.weight": "model-00009-of-00036.safetensors", "model.layers.12.linear_attn.norm.weight": "model-00009-of-00036.safetensors", "model.layers.12.linear_attn.out_proj.weight": "model-00009-of-00036.safetensors", "model.layers.12.mlp.gate.weight": "model-00009-of-00036.safetensors", "model.layers.12.mlp.shared_expert.down_proj.weight": "model-00010-of-00036.safetensors", "model.layers.12.mlp.shared_expert.gate_proj.weight": "model-00010-of-00036.safetensors", "model.layers.12.mlp.shared_expert.up_proj.weight": "model-00010-of-00036.safetensors", "model.layers.12.mlp.shared_expert_gate.weight": "model-00010-of-00036.safetensors", "model.layers.12.mlp.switch_mlp.down_proj.weight": "model-00010-of-00036.safetensors", "model.layers.12.mlp.switch_mlp.gate_proj.weight": "model-00010-of-00036.safetensors", "model.layers.12.mlp.switch_mlp.up_proj.weight": "model-00010-of-00036.safetensors", "model.layers.12.post_attention_layernorm.weight": "model-00009-of-00036.safetensors", "model.layers.13.input_layernorm.weight": "model-00010-of-00036.safetensors", "model.layers.13.linear_attn.A_log": "model-00010-of-00036.safetensors", "model.layers.13.linear_attn.conv1d.weight": "model-00010-of-00036.safetensors", "model.layers.13.linear_attn.dt_bias": "model-00010-of-00036.safetensors", "model.layers.13.linear_attn.in_proj_ba.weight": "model-00010-of-00036.safetensors", "model.layers.13.linear_attn.in_proj_qkvz.weight": "model-00010-of-00036.safetensors", "model.layers.13.linear_attn.norm.weight": "model-00010-of-00036.safetensors", "model.layers.13.linear_attn.out_proj.weight": "model-00010-of-00036.safetensors", "model.layers.13.mlp.gate.weight": "model-00010-of-00036.safetensors", "model.layers.13.mlp.shared_expert.down_proj.weight": "model-00011-of-00036.safetensors", "model.layers.13.mlp.shared_expert.gate_proj.weight": "model-00011-of-00036.safetensors", "model.layers.13.mlp.shared_expert.up_proj.weight": "model-00011-of-00036.safetensors", "model.layers.13.mlp.shared_expert_gate.weight": "model-00011-of-00036.safetensors", "model.layers.13.mlp.switch_mlp.down_proj.weight": "model-00011-of-00036.safetensors", "model.layers.13.mlp.switch_mlp.gate_proj.weight": "model-00010-of-00036.safetensors", "model.layers.13.mlp.switch_mlp.up_proj.weight": "model-00011-of-00036.safetensors", "model.layers.13.post_attention_layernorm.weight": "model-00010-of-00036.safetensors", "model.layers.14.input_layernorm.weight": "model-00011-of-00036.safetensors", "model.layers.14.linear_attn.A_log": "model-00011-of-00036.safetensors", "model.layers.14.linear_attn.conv1d.weight": "model-00011-of-00036.safetensors", "model.layers.14.linear_attn.dt_bias": "model-00011-of-00036.safetensors", "model.layers.14.linear_attn.in_proj_ba.weight": "model-00011-of-00036.safetensors", "model.layers.14.linear_attn.in_proj_qkvz.weight": "model-00011-of-00036.safetensors", "model.layers.14.linear_attn.norm.weight": "model-00011-of-00036.safetensors", "model.layers.14.linear_attn.out_proj.weight": "model-00011-of-00036.safetensors", "model.layers.14.mlp.gate.weight": "model-00011-of-00036.safetensors", "model.layers.14.mlp.shared_expert.down_proj.weight": "model-00012-of-00036.safetensors", "model.layers.14.mlp.shared_expert.gate_proj.weight": "model-00012-of-00036.safetensors", "model.layers.14.mlp.shared_expert.up_proj.weight": "model-00012-of-00036.safetensors", "model.layers.14.mlp.shared_expert_gate.weight": "model-00012-of-00036.safetensors", "model.layers.14.mlp.switch_mlp.down_proj.weight": "model-00012-of-00036.safetensors", "model.layers.14.mlp.switch_mlp.gate_proj.weight": "model-00011-of-00036.safetensors", "model.layers.14.mlp.switch_mlp.up_proj.weight": "model-00011-of-00036.safetensors", "model.layers.14.post_attention_layernorm.weight": "model-00011-of-00036.safetensors", "model.layers.15.input_layernorm.weight": "model-00012-of-00036.safetensors", "model.layers.15.mlp.gate.weight": "model-00012-of-00036.safetensors", "model.layers.15.mlp.shared_expert.down_proj.weight": "model-00012-of-00036.safetensors", "model.layers.15.mlp.shared_expert.gate_proj.weight": "model-00012-of-00036.safetensors", "model.layers.15.mlp.shared_expert.up_proj.weight": "model-00012-of-00036.safetensors", "model.layers.15.mlp.shared_expert_gate.weight": "model-00012-of-00036.safetensors", "model.layers.15.mlp.switch_mlp.down_proj.weight": "model-00012-of-00036.safetensors", "model.layers.15.mlp.switch_mlp.gate_proj.weight": "model-00012-of-00036.safetensors", "model.layers.15.mlp.switch_mlp.up_proj.weight": "model-00012-of-00036.safetensors", "model.layers.15.post_attention_layernorm.weight": "model-00012-of-00036.safetensors", "model.layers.15.self_attn.k_norm.weight": "model-00012-of-00036.safetensors", "model.layers.15.self_attn.k_proj.weight": "model-00012-of-00036.safetensors", "model.layers.15.self_attn.o_proj.weight": "model-00012-of-00036.safetensors", "model.layers.15.self_attn.q_norm.weight": "model-00012-of-00036.safetensors", "model.layers.15.self_attn.q_proj.weight": "model-00012-of-00036.safetensors", "model.layers.15.self_attn.v_proj.weight": "model-00012-of-00036.safetensors", "model.layers.16.input_layernorm.weight": "model-00012-of-00036.safetensors", "model.layers.16.linear_attn.A_log": "model-00012-of-00036.safetensors", "model.layers.16.linear_attn.conv1d.weight": "model-00012-of-00036.safetensors", "model.layers.16.linear_attn.dt_bias": "model-00012-of-00036.safetensors", "model.layers.16.linear_attn.in_proj_ba.weight": "model-00012-of-00036.safetensors", "model.layers.16.linear_attn.in_proj_qkvz.weight": "model-00012-of-00036.safetensors", "model.layers.16.linear_attn.norm.weight": "model-00012-of-00036.safetensors", "model.layers.16.linear_attn.out_proj.weight": "model-00012-of-00036.safetensors", "model.layers.16.mlp.gate.weight": "model-00012-of-00036.safetensors", "model.layers.16.mlp.shared_expert.down_proj.weight": "model-00013-of-00036.safetensors", "model.layers.16.mlp.shared_expert.gate_proj.weight": "model-00013-of-00036.safetensors", "model.layers.16.mlp.shared_expert.up_proj.weight": "model-00013-of-00036.safetensors", "model.layers.16.mlp.shared_expert_gate.weight": "model-00013-of-00036.safetensors", "model.layers.16.mlp.switch_mlp.down_proj.weight": "model-00013-of-00036.safetensors", "model.layers.16.mlp.switch_mlp.gate_proj.weight": "model-00013-of-00036.safetensors", "model.layers.16.mlp.switch_mlp.up_proj.weight": "model-00013-of-00036.safetensors", "model.layers.16.post_attention_layernorm.weight": "model-00012-of-00036.safetensors", "model.layers.17.input_layernorm.weight": "model-00013-of-00036.safetensors", "model.layers.17.linear_attn.A_log": "model-00013-of-00036.safetensors", "model.layers.17.linear_attn.conv1d.weight": "model-00013-of-00036.safetensors", "model.layers.17.linear_attn.dt_bias": "model-00013-of-00036.safetensors", "model.layers.17.linear_attn.in_proj_ba.weight": "model-00013-of-00036.safetensors", "model.layers.17.linear_attn.in_proj_qkvz.weight": "model-00013-of-00036.safetensors", "model.layers.17.linear_attn.norm.weight": "model-00013-of-00036.safetensors", "model.layers.17.linear_attn.out_proj.weight": "model-00013-of-00036.safetensors", "model.layers.17.mlp.gate.weight": "model-00013-of-00036.safetensors", "model.layers.17.mlp.shared_expert.down_proj.weight": "model-00014-of-00036.safetensors", "model.layers.17.mlp.shared_expert.gate_proj.weight": "model-00014-of-00036.safetensors", "model.layers.17.mlp.shared_expert.up_proj.weight": "model-00014-of-00036.safetensors", "model.layers.17.mlp.shared_expert_gate.weight": "model-00014-of-00036.safetensors", "model.layers.17.mlp.switch_mlp.down_proj.weight": "model-00014-of-00036.safetensors", "model.layers.17.mlp.switch_mlp.gate_proj.weight": "model-00013-of-00036.safetensors", "model.layers.17.mlp.switch_mlp.up_proj.weight": "model-00014-of-00036.safetensors", "model.layers.17.post_attention_layernorm.weight": "model-00013-of-00036.safetensors", "model.layers.18.input_layernorm.weight": "model-00014-of-00036.safetensors", "model.layers.18.linear_attn.A_log": "model-00014-of-00036.safetensors", "model.layers.18.linear_attn.conv1d.weight": "model-00014-of-00036.safetensors", "model.layers.18.linear_attn.dt_bias": "model-00014-of-00036.safetensors", "model.layers.18.linear_attn.in_proj_ba.weight": "model-00014-of-00036.safetensors", "model.layers.18.linear_attn.in_proj_qkvz.weight": "model-00014-of-00036.safetensors", "model.layers.18.linear_attn.norm.weight": "model-00014-of-00036.safetensors", "model.layers.18.linear_attn.out_proj.weight": "model-00014-of-00036.safetensors", "model.layers.18.mlp.gate.weight": "model-00014-of-00036.safetensors", "model.layers.18.mlp.shared_expert.down_proj.weight": "model-00015-of-00036.safetensors", "model.layers.18.mlp.shared_expert.gate_proj.weight": "model-00015-of-00036.safetensors", "model.layers.18.mlp.shared_expert.up_proj.weight": "model-00015-of-00036.safetensors", "model.layers.18.mlp.shared_expert_gate.weight": "model-00015-of-00036.safetensors", "model.layers.18.mlp.switch_mlp.down_proj.weight": "model-00015-of-00036.safetensors", "model.layers.18.mlp.switch_mlp.gate_proj.weight": "model-00014-of-00036.safetensors", "model.layers.18.mlp.switch_mlp.up_proj.weight": "model-00014-of-00036.safetensors", "model.layers.18.post_attention_layernorm.weight": "model-00014-of-00036.safetensors", "model.layers.19.input_layernorm.weight": "model-00015-of-00036.safetensors", "model.layers.19.mlp.gate.weight": "model-00015-of-00036.safetensors", "model.layers.19.mlp.shared_expert.down_proj.weight": "model-00015-of-00036.safetensors", "model.layers.19.mlp.shared_expert.gate_proj.weight": "model-00015-of-00036.safetensors", "model.layers.19.mlp.shared_expert.up_proj.weight": "model-00015-of-00036.safetensors", "model.layers.19.mlp.shared_expert_gate.weight": "model-00015-of-00036.safetensors", "model.layers.19.mlp.switch_mlp.down_proj.weight": "model-00015-of-00036.safetensors", "model.layers.19.mlp.switch_mlp.gate_proj.weight": "model-00015-of-00036.safetensors", "model.layers.19.mlp.switch_mlp.up_proj.weight": "model-00015-of-00036.safetensors", "model.layers.19.post_attention_layernorm.weight": "model-00015-of-00036.safetensors", "model.layers.19.self_attn.k_norm.weight": "model-00015-of-00036.safetensors", "model.layers.19.self_attn.k_proj.weight": "model-00015-of-00036.safetensors", "model.layers.19.self_attn.o_proj.weight": "model-00015-of-00036.safetensors", "model.layers.19.self_attn.q_norm.weight": "model-00015-of-00036.safetensors", "model.layers.19.self_attn.q_proj.weight": "model-00015-of-00036.safetensors", "model.layers.19.self_attn.v_proj.weight": "model-00015-of-00036.safetensors", "model.layers.2.input_layernorm.weight": "model-00002-of-00036.safetensors", "model.layers.2.linear_attn.A_log": "model-00002-of-00036.safetensors", "model.layers.2.linear_attn.conv1d.weight": "model-00002-of-00036.safetensors", "model.layers.2.linear_attn.dt_bias": "model-00002-of-00036.safetensors", "model.layers.2.linear_attn.in_proj_ba.weight": "model-00002-of-00036.safetensors", "model.layers.2.linear_attn.in_proj_qkvz.weight": "model-00002-of-00036.safetensors", "model.layers.2.linear_attn.norm.weight": "model-00002-of-00036.safetensors", "model.layers.2.linear_attn.out_proj.weight": "model-00002-of-00036.safetensors", "model.layers.2.mlp.gate.weight": "model-00002-of-00036.safetensors", "model.layers.2.mlp.shared_expert.down_proj.weight": "model-00003-of-00036.safetensors", "model.layers.2.mlp.shared_expert.gate_proj.weight": "model-00003-of-00036.safetensors", "model.layers.2.mlp.shared_expert.up_proj.weight": "model-00003-of-00036.safetensors", "model.layers.2.mlp.shared_expert_gate.weight": "model-00003-of-00036.safetensors", "model.layers.2.mlp.switch_mlp.down_proj.weight": "model-00003-of-00036.safetensors", "model.layers.2.mlp.switch_mlp.gate_proj.weight": "model-00002-of-00036.safetensors", "model.layers.2.mlp.switch_mlp.up_proj.weight": "model-00002-of-00036.safetensors", "model.layers.2.post_attention_layernorm.weight": "model-00002-of-00036.safetensors", "model.layers.20.input_layernorm.weight": "model-00015-of-00036.safetensors", "model.layers.20.linear_attn.A_log": "model-00015-of-00036.safetensors", "model.layers.20.linear_attn.conv1d.weight": "model-00015-of-00036.safetensors", "model.layers.20.linear_attn.dt_bias": "model-00015-of-00036.safetensors", "model.layers.20.linear_attn.in_proj_ba.weight": "model-00015-of-00036.safetensors", "model.layers.20.linear_attn.in_proj_qkvz.weight": "model-00015-of-00036.safetensors", "model.layers.20.linear_attn.norm.weight": "model-00015-of-00036.safetensors", "model.layers.20.linear_attn.out_proj.weight": "model-00015-of-00036.safetensors", "model.layers.20.mlp.gate.weight": "model-00015-of-00036.safetensors", "model.layers.20.mlp.shared_expert.down_proj.weight": "model-00016-of-00036.safetensors", "model.layers.20.mlp.shared_expert.gate_proj.weight": "model-00016-of-00036.safetensors", "model.layers.20.mlp.shared_expert.up_proj.weight": "model-00016-of-00036.safetensors", "model.layers.20.mlp.shared_expert_gate.weight": "model-00016-of-00036.safetensors", "model.layers.20.mlp.switch_mlp.down_proj.weight": "model-00016-of-00036.safetensors", "model.layers.20.mlp.switch_mlp.gate_proj.weight": "model-00016-of-00036.safetensors", "model.layers.20.mlp.switch_mlp.up_proj.weight": "model-00016-of-00036.safetensors", "model.layers.20.post_attention_layernorm.weight": "model-00015-of-00036.safetensors", "model.layers.21.input_layernorm.weight": "model-00016-of-00036.safetensors", "model.layers.21.linear_attn.A_log": "model-00016-of-00036.safetensors", "model.layers.21.linear_attn.conv1d.weight": "model-00016-of-00036.safetensors", "model.layers.21.linear_attn.dt_bias": "model-00016-of-00036.safetensors", "model.layers.21.linear_attn.in_proj_ba.weight": "model-00016-of-00036.safetensors", "model.layers.21.linear_attn.in_proj_qkvz.weight": "model-00016-of-00036.safetensors", "model.layers.21.linear_attn.norm.weight": "model-00016-of-00036.safetensors", "model.layers.21.linear_attn.out_proj.weight": "model-00016-of-00036.safetensors", "model.layers.21.mlp.gate.weight": "model-00016-of-00036.safetensors", "model.layers.21.mlp.shared_expert.down_proj.weight": "model-00017-of-00036.safetensors", "model.layers.21.mlp.shared_expert.gate_proj.weight": "model-00017-of-00036.safetensors", "model.layers.21.mlp.shared_expert.up_proj.weight": "model-00017-of-00036.safetensors", "model.layers.21.mlp.shared_expert_gate.weight": "model-00017-of-00036.safetensors", "model.layers.21.mlp.switch_mlp.down_proj.weight": "model-00017-of-00036.safetensors", "model.layers.21.mlp.switch_mlp.gate_proj.weight": "model-00016-of-00036.safetensors", "model.layers.21.mlp.switch_mlp.up_proj.weight": "model-00017-of-00036.safetensors", "model.layers.21.post_attention_layernorm.weight": "model-00016-of-00036.safetensors", "model.layers.22.input_layernorm.weight": "model-00017-of-00036.safetensors", "model.layers.22.linear_attn.A_log": "model-00017-of-00036.safetensors", "model.layers.22.linear_attn.conv1d.weight": "model-00017-of-00036.safetensors", "model.layers.22.linear_attn.dt_bias": "model-00017-of-00036.safetensors", "model.layers.22.linear_attn.in_proj_ba.weight": "model-00017-of-00036.safetensors", "model.layers.22.linear_attn.in_proj_qkvz.weight": "model-00017-of-00036.safetensors", "model.layers.22.linear_attn.norm.weight": "model-00017-of-00036.safetensors", "model.layers.22.linear_attn.out_proj.weight": "model-00017-of-00036.safetensors", "model.layers.22.mlp.gate.weight": "model-00017-of-00036.safetensors", "model.layers.22.mlp.shared_expert.down_proj.weight": "model-00018-of-00036.safetensors", "model.layers.22.mlp.shared_expert.gate_proj.weight": "model-00018-of-00036.safetensors", "model.layers.22.mlp.shared_expert.up_proj.weight": "model-00018-of-00036.safetensors", "model.layers.22.mlp.shared_expert_gate.weight": "model-00018-of-00036.safetensors", "model.layers.22.mlp.switch_mlp.down_proj.weight": "model-00018-of-00036.safetensors", "model.layers.22.mlp.switch_mlp.gate_proj.weight": "model-00017-of-00036.safetensors", "model.layers.22.mlp.switch_mlp.up_proj.weight": "model-00017-of-00036.safetensors", "model.layers.22.post_attention_layernorm.weight": "model-00017-of-00036.safetensors", "model.layers.23.input_layernorm.weight": "model-00018-of-00036.safetensors", "model.layers.23.mlp.gate.weight": "model-00018-of-00036.safetensors", "model.layers.23.mlp.shared_expert.down_proj.weight": "model-00018-of-00036.safetensors", "model.layers.23.mlp.shared_expert.gate_proj.weight": "model-00018-of-00036.safetensors", "model.layers.23.mlp.shared_expert.up_proj.weight": "model-00018-of-00036.safetensors", "model.layers.23.mlp.shared_expert_gate.weight": "model-00018-of-00036.safetensors", "model.layers.23.mlp.switch_mlp.down_proj.weight": "model-00018-of-00036.safetensors", "model.layers.23.mlp.switch_mlp.gate_proj.weight": "model-00018-of-00036.safetensors", "model.layers.23.mlp.switch_mlp.up_proj.weight": "model-00018-of-00036.safetensors", "model.layers.23.post_attention_layernorm.weight": "model-00018-of-00036.safetensors", "model.layers.23.self_attn.k_norm.weight": "model-00018-of-00036.safetensors", "model.layers.23.self_attn.k_proj.weight": "model-00018-of-00036.safetensors", "model.layers.23.self_attn.o_proj.weight": "model-00018-of-00036.safetensors", "model.layers.23.self_attn.q_norm.weight": "model-00018-of-00036.safetensors", "model.layers.23.self_attn.q_proj.weight": "model-00018-of-00036.safetensors", "model.layers.23.self_attn.v_proj.weight": "model-00018-of-00036.safetensors", "model.layers.24.input_layernorm.weight": "model-00018-of-00036.safetensors", "model.layers.24.linear_attn.A_log": "model-00018-of-00036.safetensors", "model.layers.24.linear_attn.conv1d.weight": "model-00018-of-00036.safetensors", "model.layers.24.linear_attn.dt_bias": "model-00018-of-00036.safetensors", "model.layers.24.linear_attn.in_proj_ba.weight": "model-00018-of-00036.safetensors", "model.layers.24.linear_attn.in_proj_qkvz.weight": "model-00018-of-00036.safetensors", "model.layers.24.linear_attn.norm.weight": "model-00018-of-00036.safetensors", "model.layers.24.linear_attn.out_proj.weight": "model-00018-of-00036.safetensors", "model.layers.24.mlp.gate.weight": "model-00018-of-00036.safetensors", "model.layers.24.mlp.shared_expert.down_proj.weight": "model-00019-of-00036.safetensors", "model.layers.24.mlp.shared_expert.gate_proj.weight": "model-00019-of-00036.safetensors", "model.layers.24.mlp.shared_expert.up_proj.weight": "model-00019-of-00036.safetensors", "model.layers.24.mlp.shared_expert_gate.weight": "model-00019-of-00036.safetensors", "model.layers.24.mlp.switch_mlp.down_proj.weight": "model-00019-of-00036.safetensors", "model.layers.24.mlp.switch_mlp.gate_proj.weight": "model-00019-of-00036.safetensors", "model.layers.24.mlp.switch_mlp.up_proj.weight": "model-00019-of-00036.safetensors", "model.layers.24.post_attention_layernorm.weight": "model-00018-of-00036.safetensors", "model.layers.25.input_layernorm.weight": "model-00019-of-00036.safetensors", "model.layers.25.linear_attn.A_log": "model-00019-of-00036.safetensors", "model.layers.25.linear_attn.conv1d.weight": "model-00019-of-00036.safetensors", "model.layers.25.linear_attn.dt_bias": "model-00019-of-00036.safetensors", "model.layers.25.linear_attn.in_proj_ba.weight": "model-00019-of-00036.safetensors", "model.layers.25.linear_attn.in_proj_qkvz.weight": "model-00019-of-00036.safetensors", "model.layers.25.linear_attn.norm.weight": "model-00019-of-00036.safetensors", "model.layers.25.linear_attn.out_proj.weight": "model-00019-of-00036.safetensors", "model.layers.25.mlp.gate.weight": "model-00019-of-00036.safetensors", "model.layers.25.mlp.shared_expert.down_proj.weight": "model-00020-of-00036.safetensors", "model.layers.25.mlp.shared_expert.gate_proj.weight": "model-00020-of-00036.safetensors", "model.layers.25.mlp.shared_expert.up_proj.weight": "model-00020-of-00036.safetensors", "model.layers.25.mlp.shared_expert_gate.weight": "model-00020-of-00036.safetensors", "model.layers.25.mlp.switch_mlp.down_proj.weight": "model-00020-of-00036.safetensors", "model.layers.25.mlp.switch_mlp.gate_proj.weight": "model-00019-of-00036.safetensors", "model.layers.25.mlp.switch_mlp.up_proj.weight": "model-00020-of-00036.safetensors", "model.layers.25.post_attention_layernorm.weight": "model-00019-of-00036.safetensors", "model.layers.26.input_layernorm.weight": "model-00020-of-00036.safetensors", "model.layers.26.linear_attn.A_log": "model-00020-of-00036.safetensors", "model.layers.26.linear_attn.conv1d.weight": "model-00020-of-00036.safetensors", "model.layers.26.linear_attn.dt_bias": "model-00020-of-00036.safetensors", "model.layers.26.linear_attn.in_proj_ba.weight": "model-00020-of-00036.safetensors", "model.layers.26.linear_attn.in_proj_qkvz.weight": "model-00020-of-00036.safetensors", "model.layers.26.linear_attn.norm.weight": "model-00020-of-00036.safetensors", "model.layers.26.linear_attn.out_proj.weight": "model-00020-of-00036.safetensors", "model.layers.26.mlp.gate.weight": "model-00020-of-00036.safetensors", "model.layers.26.mlp.shared_expert.down_proj.weight": "model-00021-of-00036.safetensors", "model.layers.26.mlp.shared_expert.gate_proj.weight": "model-00021-of-00036.safetensors", "model.layers.26.mlp.shared_expert.up_proj.weight": "model-00021-of-00036.safetensors", "model.layers.26.mlp.shared_expert_gate.weight": "model-00021-of-00036.safetensors", "model.layers.26.mlp.switch_mlp.down_proj.weight": "model-00021-of-00036.safetensors", "model.layers.26.mlp.switch_mlp.gate_proj.weight": "model-00020-of-00036.safetensors", "model.layers.26.mlp.switch_mlp.up_proj.weight": "model-00020-of-00036.safetensors", "model.layers.26.post_attention_layernorm.weight": "model-00020-of-00036.safetensors", "model.layers.27.input_layernorm.weight": "model-00021-of-00036.safetensors", "model.layers.27.mlp.gate.weight": "model-00021-of-00036.safetensors", "model.layers.27.mlp.shared_expert.down_proj.weight": "model-00021-of-00036.safetensors", "model.layers.27.mlp.shared_expert.gate_proj.weight": "model-00021-of-00036.safetensors", "model.layers.27.mlp.shared_expert.up_proj.weight": "model-00021-of-00036.safetensors", "model.layers.27.mlp.shared_expert_gate.weight": "model-00021-of-00036.safetensors", "model.layers.27.mlp.switch_mlp.down_proj.weight": "model-00021-of-00036.safetensors", "model.layers.27.mlp.switch_mlp.gate_proj.weight": "model-00021-of-00036.safetensors", "model.layers.27.mlp.switch_mlp.up_proj.weight": "model-00021-of-00036.safetensors", "model.layers.27.post_attention_layernorm.weight": "model-00021-of-00036.safetensors", "model.layers.27.self_attn.k_norm.weight": "model-00021-of-00036.safetensors", "model.layers.27.self_attn.k_proj.weight": "model-00021-of-00036.safetensors", "model.layers.27.self_attn.o_proj.weight": "model-00021-of-00036.safetensors", "model.layers.27.self_attn.q_norm.weight": "model-00021-of-00036.safetensors", "model.layers.27.self_attn.q_proj.weight": "model-00021-of-00036.safetensors", "model.layers.27.self_attn.v_proj.weight": "model-00021-of-00036.safetensors", "model.layers.28.input_layernorm.weight": "model-00021-of-00036.safetensors", "model.layers.28.linear_attn.A_log": "model-00021-of-00036.safetensors", "model.layers.28.linear_attn.conv1d.weight": "model-00021-of-00036.safetensors", "model.layers.28.linear_attn.dt_bias": "model-00021-of-00036.safetensors", "model.layers.28.linear_attn.in_proj_ba.weight": "model-00021-of-00036.safetensors", "model.layers.28.linear_attn.in_proj_qkvz.weight": "model-00021-of-00036.safetensors", "model.layers.28.linear_attn.norm.weight": "model-00021-of-00036.safetensors", "model.layers.28.linear_attn.out_proj.weight": "model-00021-of-00036.safetensors", "model.layers.28.mlp.gate.weight": "model-00021-of-00036.safetensors", "model.layers.28.mlp.shared_expert.down_proj.weight": "model-00022-of-00036.safetensors", "model.layers.28.mlp.shared_expert.gate_proj.weight": "model-00022-of-00036.safetensors", "model.layers.28.mlp.shared_expert.up_proj.weight": "model-00022-of-00036.safetensors", "model.layers.28.mlp.shared_expert_gate.weight": "model-00022-of-00036.safetensors", "model.layers.28.mlp.switch_mlp.down_proj.weight": "model-00022-of-00036.safetensors", "model.layers.28.mlp.switch_mlp.gate_proj.weight": "model-00022-of-00036.safetensors", "model.layers.28.mlp.switch_mlp.up_proj.weight": "model-00022-of-00036.safetensors", "model.layers.28.post_attention_layernorm.weight": "model-00021-of-00036.safetensors", "model.layers.29.input_layernorm.weight": "model-00022-of-00036.safetensors", "model.layers.29.linear_attn.A_log": "model-00022-of-00036.safetensors", "model.layers.29.linear_attn.conv1d.weight": "model-00022-of-00036.safetensors", "model.layers.29.linear_attn.dt_bias": "model-00022-of-00036.safetensors", "model.layers.29.linear_attn.in_proj_ba.weight": "model-00022-of-00036.safetensors", "model.layers.29.linear_attn.in_proj_qkvz.weight": "model-00022-of-00036.safetensors", "model.layers.29.linear_attn.norm.weight": "model-00022-of-00036.safetensors", "model.layers.29.linear_attn.out_proj.weight": "model-00022-of-00036.safetensors", "model.layers.29.mlp.gate.weight": "model-00022-of-00036.safetensors", "model.layers.29.mlp.shared_expert.down_proj.weight": "model-00023-of-00036.safetensors", "model.layers.29.mlp.shared_expert.gate_proj.weight": "model-00023-of-00036.safetensors", "model.layers.29.mlp.shared_expert.up_proj.weight": "model-00023-of-00036.safetensors", "model.layers.29.mlp.shared_expert_gate.weight": "model-00023-of-00036.safetensors", "model.layers.29.mlp.switch_mlp.down_proj.weight": "model-00023-of-00036.safetensors", "model.layers.29.mlp.switch_mlp.gate_proj.weight": "model-00022-of-00036.safetensors", "model.layers.29.mlp.switch_mlp.up_proj.weight": "model-00023-of-00036.safetensors", "model.layers.29.post_attention_layernorm.weight": "model-00022-of-00036.safetensors", "model.layers.3.input_layernorm.weight": "model-00003-of-00036.safetensors", "model.layers.3.mlp.gate.weight": "model-00003-of-00036.safetensors", "model.layers.3.mlp.shared_expert.down_proj.weight": "model-00003-of-00036.safetensors", "model.layers.3.mlp.shared_expert.gate_proj.weight": "model-00003-of-00036.safetensors", "model.layers.3.mlp.shared_expert.up_proj.weight": "model-00003-of-00036.safetensors", "model.layers.3.mlp.shared_expert_gate.weight": "model-00003-of-00036.safetensors", "model.layers.3.mlp.switch_mlp.down_proj.weight": "model-00003-of-00036.safetensors", "model.layers.3.mlp.switch_mlp.gate_proj.weight": "model-00003-of-00036.safetensors", "model.layers.3.mlp.switch_mlp.up_proj.weight": "model-00003-of-00036.safetensors", "model.layers.3.post_attention_layernorm.weight": "model-00003-of-00036.safetensors", "model.layers.3.self_attn.k_norm.weight": "model-00003-of-00036.safetensors", "model.layers.3.self_attn.k_proj.weight": "model-00003-of-00036.safetensors", "model.layers.3.self_attn.o_proj.weight": "model-00003-of-00036.safetensors", "model.layers.3.self_attn.q_norm.weight": "model-00003-of-00036.safetensors", "model.layers.3.self_attn.q_proj.weight": "model-00003-of-00036.safetensors", "model.layers.3.self_attn.v_proj.weight": "model-00003-of-00036.safetensors", "model.layers.30.input_layernorm.weight": "model-00023-of-00036.safetensors", "model.layers.30.linear_attn.A_log": "model-00023-of-00036.safetensors", "model.layers.30.linear_attn.conv1d.weight": "model-00023-of-00036.safetensors", "model.layers.30.linear_attn.dt_bias": "model-00023-of-00036.safetensors", "model.layers.30.linear_attn.in_proj_ba.weight": "model-00023-of-00036.safetensors", "model.layers.30.linear_attn.in_proj_qkvz.weight": "model-00023-of-00036.safetensors", "model.layers.30.linear_attn.norm.weight": "model-00023-of-00036.safetensors", "model.layers.30.linear_attn.out_proj.weight": "model-00023-of-00036.safetensors", "model.layers.30.mlp.gate.weight": "model-00023-of-00036.safetensors", "model.layers.30.mlp.shared_expert.down_proj.weight": "model-00024-of-00036.safetensors", "model.layers.30.mlp.shared_expert.gate_proj.weight": "model-00024-of-00036.safetensors", "model.layers.30.mlp.shared_expert.up_proj.weight": "model-00024-of-00036.safetensors", "model.layers.30.mlp.shared_expert_gate.weight": "model-00024-of-00036.safetensors", "model.layers.30.mlp.switch_mlp.down_proj.weight": "model-00024-of-00036.safetensors", "model.layers.30.mlp.switch_mlp.gate_proj.weight": "model-00023-of-00036.safetensors", "model.layers.30.mlp.switch_mlp.up_proj.weight": "model-00023-of-00036.safetensors", "model.layers.30.post_attention_layernorm.weight": "model-00023-of-00036.safetensors", "model.layers.31.input_layernorm.weight": "model-00024-of-00036.safetensors", "model.layers.31.mlp.gate.weight": "model-00024-of-00036.safetensors", "model.layers.31.mlp.shared_expert.down_proj.weight": "model-00024-of-00036.safetensors", "model.layers.31.mlp.shared_expert.gate_proj.weight": "model-00024-of-00036.safetensors", "model.layers.31.mlp.shared_expert.up_proj.weight": "model-00024-of-00036.safetensors", "model.layers.31.mlp.shared_expert_gate.weight": "model-00024-of-00036.safetensors", "model.layers.31.mlp.switch_mlp.down_proj.weight": "model-00024-of-00036.safetensors", "model.layers.31.mlp.switch_mlp.gate_proj.weight": "model-00024-of-00036.safetensors", "model.layers.31.mlp.switch_mlp.up_proj.weight": "model-00024-of-00036.safetensors", "model.layers.31.post_attention_layernorm.weight": "model-00024-of-00036.safetensors", "model.layers.31.self_attn.k_norm.weight": "model-00024-of-00036.safetensors", "model.layers.31.self_attn.k_proj.weight": "model-00024-of-00036.safetensors", "model.layers.31.self_attn.o_proj.weight": "model-00024-of-00036.safetensors", "model.layers.31.self_attn.q_norm.weight": "model-00024-of-00036.safetensors", "model.layers.31.self_attn.q_proj.weight": "model-00024-of-00036.safetensors", "model.layers.31.self_attn.v_proj.weight": "model-00024-of-00036.safetensors", "model.layers.32.input_layernorm.weight": "model-00024-of-00036.safetensors", "model.layers.32.linear_attn.A_log": "model-00024-of-00036.safetensors", "model.layers.32.linear_attn.conv1d.weight": "model-00024-of-00036.safetensors", "model.layers.32.linear_attn.dt_bias": "model-00024-of-00036.safetensors", "model.layers.32.linear_attn.in_proj_ba.weight": "model-00024-of-00036.safetensors", "model.layers.32.linear_attn.in_proj_qkvz.weight": "model-00024-of-00036.safetensors", "model.layers.32.linear_attn.norm.weight": "model-00024-of-00036.safetensors", "model.layers.32.linear_attn.out_proj.weight": "model-00024-of-00036.safetensors", "model.layers.32.mlp.gate.weight": "model-00024-of-00036.safetensors", "model.layers.32.mlp.shared_expert.down_proj.weight": "model-00025-of-00036.safetensors", "model.layers.32.mlp.shared_expert.gate_proj.weight": "model-00025-of-00036.safetensors", "model.layers.32.mlp.shared_expert.up_proj.weight": "model-00025-of-00036.safetensors", "model.layers.32.mlp.shared_expert_gate.weight": "model-00025-of-00036.safetensors", "model.layers.32.mlp.switch_mlp.down_proj.weight": "model-00025-of-00036.safetensors", "model.layers.32.mlp.switch_mlp.gate_proj.weight": "model-00025-of-00036.safetensors", "model.layers.32.mlp.switch_mlp.up_proj.weight": "model-00025-of-00036.safetensors", "model.layers.32.post_attention_layernorm.weight": "model-00024-of-00036.safetensors", "model.layers.33.input_layernorm.weight": "model-00025-of-00036.safetensors", "model.layers.33.linear_attn.A_log": "model-00025-of-00036.safetensors", "model.layers.33.linear_attn.conv1d.weight": "model-00025-of-00036.safetensors", "model.layers.33.linear_attn.dt_bias": "model-00025-of-00036.safetensors", "model.layers.33.linear_attn.in_proj_ba.weight": "model-00025-of-00036.safetensors", "model.layers.33.linear_attn.in_proj_qkvz.weight": "model-00025-of-00036.safetensors", "model.layers.33.linear_attn.norm.weight": "model-00025-of-00036.safetensors", "model.layers.33.linear_attn.out_proj.weight": "model-00025-of-00036.safetensors", "model.layers.33.mlp.gate.weight": "model-00025-of-00036.safetensors", "model.layers.33.mlp.shared_expert.down_proj.weight": "model-00026-of-00036.safetensors", "model.layers.33.mlp.shared_expert.gate_proj.weight": "model-00026-of-00036.safetensors", "model.layers.33.mlp.shared_expert.up_proj.weight": "model-00026-of-00036.safetensors", "model.layers.33.mlp.shared_expert_gate.weight": "model-00026-of-00036.safetensors", "model.layers.33.mlp.switch_mlp.down_proj.weight": "model-00026-of-00036.safetensors", "model.layers.33.mlp.switch_mlp.gate_proj.weight": "model-00025-of-00036.safetensors", "model.layers.33.mlp.switch_mlp.up_proj.weight": "model-00026-of-00036.safetensors", "model.layers.33.post_attention_layernorm.weight": "model-00025-of-00036.safetensors", "model.layers.34.input_layernorm.weight": "model-00026-of-00036.safetensors", "model.layers.34.linear_attn.A_log": "model-00026-of-00036.safetensors", "model.layers.34.linear_attn.conv1d.weight": "model-00026-of-00036.safetensors", "model.layers.34.linear_attn.dt_bias": "model-00026-of-00036.safetensors", "model.layers.34.linear_attn.in_proj_ba.weight": "model-00026-of-00036.safetensors", "model.layers.34.linear_attn.in_proj_qkvz.weight": "model-00026-of-00036.safetensors", "model.layers.34.linear_attn.norm.weight": "model-00026-of-00036.safetensors", "model.layers.34.linear_attn.out_proj.weight": "model-00026-of-00036.safetensors", "model.layers.34.mlp.gate.weight": "model-00026-of-00036.safetensors", "model.layers.34.mlp.shared_expert.down_proj.weight": "model-00027-of-00036.safetensors", "model.layers.34.mlp.shared_expert.gate_proj.weight": "model-00027-of-00036.safetensors", "model.layers.34.mlp.shared_expert.up_proj.weight": "model-00027-of-00036.safetensors", "model.layers.34.mlp.shared_expert_gate.weight": "model-00027-of-00036.safetensors", "model.layers.34.mlp.switch_mlp.down_proj.weight": "model-00027-of-00036.safetensors", "model.layers.34.mlp.switch_mlp.gate_proj.weight": "model-00026-of-00036.safetensors", "model.layers.34.mlp.switch_mlp.up_proj.weight": "model-00026-of-00036.safetensors", "model.layers.34.post_attention_layernorm.weight": "model-00026-of-00036.safetensors", "model.layers.35.input_layernorm.weight": "model-00027-of-00036.safetensors", "model.layers.35.mlp.gate.weight": "model-00027-of-00036.safetensors", "model.layers.35.mlp.shared_expert.down_proj.weight": "model-00027-of-00036.safetensors", "model.layers.35.mlp.shared_expert.gate_proj.weight": "model-00027-of-00036.safetensors", "model.layers.35.mlp.shared_expert.up_proj.weight": "model-00027-of-00036.safetensors", "model.layers.35.mlp.shared_expert_gate.weight": "model-00027-of-00036.safetensors", "model.layers.35.mlp.switch_mlp.down_proj.weight": "model-00027-of-00036.safetensors", "model.layers.35.mlp.switch_mlp.gate_proj.weight": "model-00027-of-00036.safetensors", "model.layers.35.mlp.switch_mlp.up_proj.weight": "model-00027-of-00036.safetensors", "model.layers.35.post_attention_layernorm.weight": "model-00027-of-00036.safetensors", "model.layers.35.self_attn.k_norm.weight": "model-00027-of-00036.safetensors", "model.layers.35.self_attn.k_proj.weight": "model-00027-of-00036.safetensors", "model.layers.35.self_attn.o_proj.weight": "model-00027-of-00036.safetensors", "model.layers.35.self_attn.q_norm.weight": "model-00027-of-00036.safetensors", "model.layers.35.self_attn.q_proj.weight": "model-00027-of-00036.safetensors", "model.layers.35.self_attn.v_proj.weight": "model-00027-of-00036.safetensors", "model.layers.36.input_layernorm.weight": "model-00027-of-00036.safetensors", "model.layers.36.linear_attn.A_log": "model-00027-of-00036.safetensors", "model.layers.36.linear_attn.conv1d.weight": "model-00027-of-00036.safetensors", "model.layers.36.linear_attn.dt_bias": "model-00027-of-00036.safetensors", "model.layers.36.linear_attn.in_proj_ba.weight": "model-00027-of-00036.safetensors", "model.layers.36.linear_attn.in_proj_qkvz.weight": "model-00027-of-00036.safetensors", "model.layers.36.linear_attn.norm.weight": "model-00027-of-00036.safetensors", "model.layers.36.linear_attn.out_proj.weight": "model-00027-of-00036.safetensors", "model.layers.36.mlp.gate.weight": "model-00027-of-00036.safetensors", "model.layers.36.mlp.shared_expert.down_proj.weight": "model-00028-of-00036.safetensors", "model.layers.36.mlp.shared_expert.gate_proj.weight": "model-00028-of-00036.safetensors", "model.layers.36.mlp.shared_expert.up_proj.weight": "model-00028-of-00036.safetensors", "model.layers.36.mlp.shared_expert_gate.weight": "model-00028-of-00036.safetensors", "model.layers.36.mlp.switch_mlp.down_proj.weight": "model-00028-of-00036.safetensors", "model.layers.36.mlp.switch_mlp.gate_proj.weight": "model-00028-of-00036.safetensors", "model.layers.36.mlp.switch_mlp.up_proj.weight": "model-00028-of-00036.safetensors", "model.layers.36.post_attention_layernorm.weight": "model-00027-of-00036.safetensors", "model.layers.37.input_layernorm.weight": "model-00028-of-00036.safetensors", "model.layers.37.linear_attn.A_log": "model-00028-of-00036.safetensors", "model.layers.37.linear_attn.conv1d.weight": "model-00028-of-00036.safetensors", "model.layers.37.linear_attn.dt_bias": "model-00028-of-00036.safetensors", "model.layers.37.linear_attn.in_proj_ba.weight": "model-00028-of-00036.safetensors", "model.layers.37.linear_attn.in_proj_qkvz.weight": "model-00028-of-00036.safetensors", "model.layers.37.linear_attn.norm.weight": "model-00028-of-00036.safetensors", "model.layers.37.linear_attn.out_proj.weight": "model-00028-of-00036.safetensors", "model.layers.37.mlp.gate.weight": "model-00028-of-00036.safetensors", "model.layers.37.mlp.shared_expert.down_proj.weight": "model-00029-of-00036.safetensors", "model.layers.37.mlp.shared_expert.gate_proj.weight": "model-00029-of-00036.safetensors", "model.layers.37.mlp.shared_expert.up_proj.weight": "model-00029-of-00036.safetensors", "model.layers.37.mlp.shared_expert_gate.weight": "model-00029-of-00036.safetensors", "model.layers.37.mlp.switch_mlp.down_proj.weight": "model-00029-of-00036.safetensors", "model.layers.37.mlp.switch_mlp.gate_proj.weight": "model-00028-of-00036.safetensors", "model.layers.37.mlp.switch_mlp.up_proj.weight": "model-00029-of-00036.safetensors", "model.layers.37.post_attention_layernorm.weight": "model-00028-of-00036.safetensors", "model.layers.38.input_layernorm.weight": "model-00029-of-00036.safetensors", "model.layers.38.linear_attn.A_log": "model-00029-of-00036.safetensors", "model.layers.38.linear_attn.conv1d.weight": "model-00029-of-00036.safetensors", "model.layers.38.linear_attn.dt_bias": "model-00029-of-00036.safetensors", "model.layers.38.linear_attn.in_proj_ba.weight": "model-00029-of-00036.safetensors", "model.layers.38.linear_attn.in_proj_qkvz.weight": "model-00029-of-00036.safetensors", "model.layers.38.linear_attn.norm.weight": "model-00029-of-00036.safetensors", "model.layers.38.linear_attn.out_proj.weight": "model-00029-of-00036.safetensors", "model.layers.38.mlp.gate.weight": "model-00029-of-00036.safetensors", "model.layers.38.mlp.shared_expert.down_proj.weight": "model-00030-of-00036.safetensors", "model.layers.38.mlp.shared_expert.gate_proj.weight": "model-00030-of-00036.safetensors", "model.layers.38.mlp.shared_expert.up_proj.weight": "model-00030-of-00036.safetensors", "model.layers.38.mlp.shared_expert_gate.weight": "model-00030-of-00036.safetensors", "model.layers.38.mlp.switch_mlp.down_proj.weight": "model-00030-of-00036.safetensors", "model.layers.38.mlp.switch_mlp.gate_proj.weight": "model-00029-of-00036.safetensors", "model.layers.38.mlp.switch_mlp.up_proj.weight": "model-00029-of-00036.safetensors", "model.layers.38.post_attention_layernorm.weight": "model-00029-of-00036.safetensors", "model.layers.39.input_layernorm.weight": "model-00030-of-00036.safetensors", "model.layers.39.mlp.gate.weight": "model-00030-of-00036.safetensors", "model.layers.39.mlp.shared_expert.down_proj.weight": "model-00030-of-00036.safetensors", "model.layers.39.mlp.shared_expert.gate_proj.weight": "model-00030-of-00036.safetensors", "model.layers.39.mlp.shared_expert.up_proj.weight": "model-00030-of-00036.safetensors", "model.layers.39.mlp.shared_expert_gate.weight": "model-00030-of-00036.safetensors", "model.layers.39.mlp.switch_mlp.down_proj.weight": "model-00030-of-00036.safetensors", "model.layers.39.mlp.switch_mlp.gate_proj.weight": "model-00030-of-00036.safetensors", "model.layers.39.mlp.switch_mlp.up_proj.weight": "model-00030-of-00036.safetensors", "model.layers.39.post_attention_layernorm.weight": "model-00030-of-00036.safetensors", "model.layers.39.self_attn.k_norm.weight": "model-00030-of-00036.safetensors", "model.layers.39.self_attn.k_proj.weight": "model-00030-of-00036.safetensors", "model.layers.39.self_attn.o_proj.weight": "model-00030-of-00036.safetensors", "model.layers.39.self_attn.q_norm.weight": "model-00030-of-00036.safetensors", "model.layers.39.self_attn.q_proj.weight": "model-00030-of-00036.safetensors", "model.layers.39.self_attn.v_proj.weight": "model-00030-of-00036.safetensors", "model.layers.4.input_layernorm.weight": "model-00003-of-00036.safetensors", "model.layers.4.linear_attn.A_log": "model-00003-of-00036.safetensors", "model.layers.4.linear_attn.conv1d.weight": "model-00003-of-00036.safetensors", "model.layers.4.linear_attn.dt_bias": "model-00003-of-00036.safetensors", "model.layers.4.linear_attn.in_proj_ba.weight": "model-00003-of-00036.safetensors", "model.layers.4.linear_attn.in_proj_qkvz.weight": "model-00003-of-00036.safetensors", "model.layers.4.linear_attn.norm.weight": "model-00003-of-00036.safetensors", "model.layers.4.linear_attn.out_proj.weight": "model-00003-of-00036.safetensors", "model.layers.4.mlp.gate.weight": "model-00003-of-00036.safetensors", "model.layers.4.mlp.shared_expert.down_proj.weight": "model-00004-of-00036.safetensors", "model.layers.4.mlp.shared_expert.gate_proj.weight": "model-00004-of-00036.safetensors", "model.layers.4.mlp.shared_expert.up_proj.weight": "model-00004-of-00036.safetensors", "model.layers.4.mlp.shared_expert_gate.weight": "model-00004-of-00036.safetensors", "model.layers.4.mlp.switch_mlp.down_proj.weight": "model-00004-of-00036.safetensors", "model.layers.4.mlp.switch_mlp.gate_proj.weight": "model-00004-of-00036.safetensors", "model.layers.4.mlp.switch_mlp.up_proj.weight": "model-00004-of-00036.safetensors", "model.layers.4.post_attention_layernorm.weight": "model-00003-of-00036.safetensors", "model.layers.40.input_layernorm.weight": "model-00030-of-00036.safetensors", "model.layers.40.linear_attn.A_log": "model-00030-of-00036.safetensors", "model.layers.40.linear_attn.conv1d.weight": "model-00030-of-00036.safetensors", "model.layers.40.linear_attn.dt_bias": "model-00030-of-00036.safetensors", "model.layers.40.linear_attn.in_proj_ba.weight": "model-00030-of-00036.safetensors", "model.layers.40.linear_attn.in_proj_qkvz.weight": "model-00030-of-00036.safetensors", "model.layers.40.linear_attn.norm.weight": "model-00030-of-00036.safetensors", "model.layers.40.linear_attn.out_proj.weight": "model-00030-of-00036.safetensors", "model.layers.40.mlp.gate.weight": "model-00030-of-00036.safetensors", "model.layers.40.mlp.shared_expert.down_proj.weight": "model-00031-of-00036.safetensors", "model.layers.40.mlp.shared_expert.gate_proj.weight": "model-00031-of-00036.safetensors", "model.layers.40.mlp.shared_expert.up_proj.weight": "model-00031-of-00036.safetensors", "model.layers.40.mlp.shared_expert_gate.weight": "model-00031-of-00036.safetensors", "model.layers.40.mlp.switch_mlp.down_proj.weight": "model-00031-of-00036.safetensors", "model.layers.40.mlp.switch_mlp.gate_proj.weight": "model-00031-of-00036.safetensors", "model.layers.40.mlp.switch_mlp.up_proj.weight": "model-00031-of-00036.safetensors", "model.layers.40.post_attention_layernorm.weight": "model-00030-of-00036.safetensors", "model.layers.41.input_layernorm.weight": "model-00031-of-00036.safetensors", "model.layers.41.linear_attn.A_log": "model-00031-of-00036.safetensors", "model.layers.41.linear_attn.conv1d.weight": "model-00031-of-00036.safetensors", "model.layers.41.linear_attn.dt_bias": "model-00031-of-00036.safetensors", "model.layers.41.linear_attn.in_proj_ba.weight": "model-00031-of-00036.safetensors", "model.layers.41.linear_attn.in_proj_qkvz.weight": "model-00031-of-00036.safetensors", "model.layers.41.linear_attn.norm.weight": "model-00031-of-00036.safetensors", "model.layers.41.linear_attn.out_proj.weight": "model-00031-of-00036.safetensors", "model.layers.41.mlp.gate.weight": "model-00031-of-00036.safetensors", "model.layers.41.mlp.shared_expert.down_proj.weight": "model-00032-of-00036.safetensors", "model.layers.41.mlp.shared_expert.gate_proj.weight": "model-00032-of-00036.safetensors", "model.layers.41.mlp.shared_expert.up_proj.weight": "model-00032-of-00036.safetensors", "model.layers.41.mlp.shared_expert_gate.weight": "model-00032-of-00036.safetensors", "model.layers.41.mlp.switch_mlp.down_proj.weight": "model-00032-of-00036.safetensors", "model.layers.41.mlp.switch_mlp.gate_proj.weight": "model-00031-of-00036.safetensors", "model.layers.41.mlp.switch_mlp.up_proj.weight": "model-00032-of-00036.safetensors", "model.layers.41.post_attention_layernorm.weight": "model-00031-of-00036.safetensors", "model.layers.42.input_layernorm.weight": "model-00032-of-00036.safetensors", "model.layers.42.linear_attn.A_log": "model-00032-of-00036.safetensors", "model.layers.42.linear_attn.conv1d.weight": "model-00032-of-00036.safetensors", "model.layers.42.linear_attn.dt_bias": "model-00032-of-00036.safetensors", "model.layers.42.linear_attn.in_proj_ba.weight": "model-00032-of-00036.safetensors", "model.layers.42.linear_attn.in_proj_qkvz.weight": "model-00032-of-00036.safetensors", "model.layers.42.linear_attn.norm.weight": "model-00032-of-00036.safetensors", "model.layers.42.linear_attn.out_proj.weight": "model-00032-of-00036.safetensors", "model.layers.42.mlp.gate.weight": "model-00032-of-00036.safetensors", "model.layers.42.mlp.shared_expert.down_proj.weight": "model-00033-of-00036.safetensors", "model.layers.42.mlp.shared_expert.gate_proj.weight": "model-00033-of-00036.safetensors", "model.layers.42.mlp.shared_expert.up_proj.weight": "model-00033-of-00036.safetensors", "model.layers.42.mlp.shared_expert_gate.weight": "model-00033-of-00036.safetensors", "model.layers.42.mlp.switch_mlp.down_proj.weight": "model-00033-of-00036.safetensors", "model.layers.42.mlp.switch_mlp.gate_proj.weight": "model-00032-of-00036.safetensors", "model.layers.42.mlp.switch_mlp.up_proj.weight": "model-00032-of-00036.safetensors", "model.layers.42.post_attention_layernorm.weight": "model-00032-of-00036.safetensors", "model.layers.43.input_layernorm.weight": "model-00033-of-00036.safetensors", "model.layers.43.mlp.gate.weight": "model-00033-of-00036.safetensors", "model.layers.43.mlp.shared_expert.down_proj.weight": "model-00033-of-00036.safetensors", "model.layers.43.mlp.shared_expert.gate_proj.weight": "model-00033-of-00036.safetensors", "model.layers.43.mlp.shared_expert.up_proj.weight": "model-00033-of-00036.safetensors", "model.layers.43.mlp.shared_expert_gate.weight": "model-00033-of-00036.safetensors", "model.layers.43.mlp.switch_mlp.down_proj.weight": "model-00033-of-00036.safetensors", "model.layers.43.mlp.switch_mlp.gate_proj.weight": "model-00033-of-00036.safetensors", "model.layers.43.mlp.switch_mlp.up_proj.weight": "model-00033-of-00036.safetensors", "model.layers.43.post_attention_layernorm.weight": "model-00033-of-00036.safetensors", "model.layers.43.self_attn.k_norm.weight": "model-00033-of-00036.safetensors", "model.layers.43.self_attn.k_proj.weight": "model-00033-of-00036.safetensors", "model.layers.43.self_attn.o_proj.weight": "model-00033-of-00036.safetensors", "model.layers.43.self_attn.q_norm.weight": "model-00033-of-00036.safetensors", "model.layers.43.self_attn.q_proj.weight": "model-00033-of-00036.safetensors", "model.layers.43.self_attn.v_proj.weight": "model-00033-of-00036.safetensors", "model.layers.44.input_layernorm.weight": "model-00033-of-00036.safetensors", "model.layers.44.linear_attn.A_log": "model-00033-of-00036.safetensors", "model.layers.44.linear_attn.conv1d.weight": "model-00033-of-00036.safetensors", "model.layers.44.linear_attn.dt_bias": "model-00033-of-00036.safetensors", "model.layers.44.linear_attn.in_proj_ba.weight": "model-00033-of-00036.safetensors", "model.layers.44.linear_attn.in_proj_qkvz.weight": "model-00033-of-00036.safetensors", "model.layers.44.linear_attn.norm.weight": "model-00033-of-00036.safetensors", "model.layers.44.linear_attn.out_proj.weight": "model-00033-of-00036.safetensors", "model.layers.44.mlp.gate.weight": "model-00033-of-00036.safetensors", "model.layers.44.mlp.shared_expert.down_proj.weight": "model-00034-of-00036.safetensors", "model.layers.44.mlp.shared_expert.gate_proj.weight": "model-00034-of-00036.safetensors", "model.layers.44.mlp.shared_expert.up_proj.weight": "model-00034-of-00036.safetensors", "model.layers.44.mlp.shared_expert_gate.weight": "model-00034-of-00036.safetensors", "model.layers.44.mlp.switch_mlp.down_proj.weight": "model-00034-of-00036.safetensors", "model.layers.44.mlp.switch_mlp.gate_proj.weight": "model-00034-of-00036.safetensors", "model.layers.44.mlp.switch_mlp.up_proj.weight": "model-00034-of-00036.safetensors", "model.layers.44.post_attention_layernorm.weight": "model-00033-of-00036.safetensors", "model.layers.45.input_layernorm.weight": "model-00034-of-00036.safetensors", "model.layers.45.linear_attn.A_log": "model-00034-of-00036.safetensors", "model.layers.45.linear_attn.conv1d.weight": "model-00034-of-00036.safetensors", "model.layers.45.linear_attn.dt_bias": "model-00034-of-00036.safetensors", "model.layers.45.linear_attn.in_proj_ba.weight": "model-00034-of-00036.safetensors", "model.layers.45.linear_attn.in_proj_qkvz.weight": "model-00034-of-00036.safetensors", "model.layers.45.linear_attn.norm.weight": "model-00034-of-00036.safetensors", "model.layers.45.linear_attn.out_proj.weight": "model-00034-of-00036.safetensors", "model.layers.45.mlp.gate.weight": "model-00034-of-00036.safetensors", "model.layers.45.mlp.shared_expert.down_proj.weight": "model-00035-of-00036.safetensors", "model.layers.45.mlp.shared_expert.gate_proj.weight": "model-00035-of-00036.safetensors", "model.layers.45.mlp.shared_expert.up_proj.weight": "model-00035-of-00036.safetensors", "model.layers.45.mlp.shared_expert_gate.weight": "model-00035-of-00036.safetensors", "model.layers.45.mlp.switch_mlp.down_proj.weight": "model-00035-of-00036.safetensors", "model.layers.45.mlp.switch_mlp.gate_proj.weight": "model-00034-of-00036.safetensors", "model.layers.45.mlp.switch_mlp.up_proj.weight": "model-00035-of-00036.safetensors", "model.layers.45.post_attention_layernorm.weight": "model-00034-of-00036.safetensors", "model.layers.46.input_layernorm.weight": "model-00035-of-00036.safetensors", "model.layers.46.linear_attn.A_log": "model-00035-of-00036.safetensors", "model.layers.46.linear_attn.conv1d.weight": "model-00035-of-00036.safetensors", "model.layers.46.linear_attn.dt_bias": "model-00035-of-00036.safetensors", "model.layers.46.linear_attn.in_proj_ba.weight": "model-00035-of-00036.safetensors", "model.layers.46.linear_attn.in_proj_qkvz.weight": "model-00035-of-00036.safetensors", "model.layers.46.linear_attn.norm.weight": "model-00035-of-00036.safetensors", "model.layers.46.linear_attn.out_proj.weight": "model-00035-of-00036.safetensors", "model.layers.46.mlp.gate.weight": "model-00035-of-00036.safetensors", "model.layers.46.mlp.shared_expert.down_proj.weight": "model-00036-of-00036.safetensors", "model.layers.46.mlp.shared_expert.gate_proj.weight": "model-00036-of-00036.safetensors", "model.layers.46.mlp.shared_expert.up_proj.weight": "model-00036-of-00036.safetensors", "model.layers.46.mlp.shared_expert_gate.weight": "model-00036-of-00036.safetensors", "model.layers.46.mlp.switch_mlp.down_proj.weight": "model-00036-of-00036.safetensors", "model.layers.46.mlp.switch_mlp.gate_proj.weight": "model-00035-of-00036.safetensors", "model.layers.46.mlp.switch_mlp.up_proj.weight": "model-00035-of-00036.safetensors", "model.layers.46.post_attention_layernorm.weight": "model-00035-of-00036.safetensors", "model.layers.47.input_layernorm.weight": "model-00036-of-00036.safetensors", "model.layers.47.mlp.gate.weight": "model-00036-of-00036.safetensors", "model.layers.47.mlp.shared_expert.down_proj.weight": "model-00036-of-00036.safetensors", "model.layers.47.mlp.shared_expert.gate_proj.weight": "model-00036-of-00036.safetensors", "model.layers.47.mlp.shared_expert.up_proj.weight": "model-00036-of-00036.safetensors", "model.layers.47.mlp.shared_expert_gate.weight": "model-00036-of-00036.safetensors", "model.layers.47.mlp.switch_mlp.down_proj.weight": "model-00036-of-00036.safetensors", "model.layers.47.mlp.switch_mlp.gate_proj.weight": "model-00036-of-00036.safetensors", "model.layers.47.mlp.switch_mlp.up_proj.weight": "model-00036-of-00036.safetensors", "model.layers.47.post_attention_layernorm.weight": "model-00036-of-00036.safetensors", "model.layers.47.self_attn.k_norm.weight": "model-00036-of-00036.safetensors", "model.layers.47.self_attn.k_proj.weight": "model-00036-of-00036.safetensors", "model.layers.47.self_attn.o_proj.weight": "model-00036-of-00036.safetensors", "model.layers.47.self_attn.q_norm.weight": "model-00036-of-00036.safetensors", "model.layers.47.self_attn.q_proj.weight": "model-00036-of-00036.safetensors", "model.layers.47.self_attn.v_proj.weight": "model-00036-of-00036.safetensors", "model.layers.5.input_layernorm.weight": "model-00004-of-00036.safetensors", "model.layers.5.linear_attn.A_log": "model-00004-of-00036.safetensors", "model.layers.5.linear_attn.conv1d.weight": "model-00004-of-00036.safetensors", "model.layers.5.linear_attn.dt_bias": "model-00004-of-00036.safetensors", "model.layers.5.linear_attn.in_proj_ba.weight": "model-00004-of-00036.safetensors", "model.layers.5.linear_attn.in_proj_qkvz.weight": "model-00004-of-00036.safetensors", "model.layers.5.linear_attn.norm.weight": "model-00004-of-00036.safetensors", "model.layers.5.linear_attn.out_proj.weight": "model-00004-of-00036.safetensors", "model.layers.5.mlp.gate.weight": "model-00004-of-00036.safetensors", "model.layers.5.mlp.shared_expert.down_proj.weight": "model-00005-of-00036.safetensors", "model.layers.5.mlp.shared_expert.gate_proj.weight": "model-00005-of-00036.safetensors", "model.layers.5.mlp.shared_expert.up_proj.weight": "model-00005-of-00036.safetensors", "model.layers.5.mlp.shared_expert_gate.weight": "model-00005-of-00036.safetensors", "model.layers.5.mlp.switch_mlp.down_proj.weight": "model-00005-of-00036.safetensors", "model.layers.5.mlp.switch_mlp.gate_proj.weight": "model-00004-of-00036.safetensors", "model.layers.5.mlp.switch_mlp.up_proj.weight": "model-00005-of-00036.safetensors", "model.layers.5.post_attention_layernorm.weight": "model-00004-of-00036.safetensors", "model.layers.6.input_layernorm.weight": "model-00005-of-00036.safetensors", "model.layers.6.linear_attn.A_log": "model-00005-of-00036.safetensors", "model.layers.6.linear_attn.conv1d.weight": "model-00005-of-00036.safetensors", "model.layers.6.linear_attn.dt_bias": "model-00005-of-00036.safetensors", "model.layers.6.linear_attn.in_proj_ba.weight": "model-00005-of-00036.safetensors", "model.layers.6.linear_attn.in_proj_qkvz.weight": "model-00005-of-00036.safetensors", "model.layers.6.linear_attn.norm.weight": "model-00005-of-00036.safetensors", "model.layers.6.linear_attn.out_proj.weight": "model-00005-of-00036.safetensors", "model.layers.6.mlp.gate.weight": "model-00005-of-00036.safetensors", "model.layers.6.mlp.shared_expert.down_proj.weight": "model-00006-of-00036.safetensors", "model.layers.6.mlp.shared_expert.gate_proj.weight": "model-00006-of-00036.safetensors", "model.layers.6.mlp.shared_expert.up_proj.weight": "model-00006-of-00036.safetensors", "model.layers.6.mlp.shared_expert_gate.weight": "model-00006-of-00036.safetensors", "model.layers.6.mlp.switch_mlp.down_proj.weight": "model-00006-of-00036.safetensors", "model.layers.6.mlp.switch_mlp.gate_proj.weight": "model-00005-of-00036.safetensors", "model.layers.6.mlp.switch_mlp.up_proj.weight": "model-00005-of-00036.safetensors", "model.layers.6.post_attention_layernorm.weight": "model-00005-of-00036.safetensors", "model.layers.7.input_layernorm.weight": "model-00006-of-00036.safetensors", "model.layers.7.mlp.gate.weight": "model-00006-of-00036.safetensors", "model.layers.7.mlp.shared_expert.down_proj.weight": "model-00006-of-00036.safetensors", "model.layers.7.mlp.shared_expert.gate_proj.weight": "model-00006-of-00036.safetensors", "model.layers.7.mlp.shared_expert.up_proj.weight": "model-00006-of-00036.safetensors", "model.layers.7.mlp.shared_expert_gate.weight": "model-00006-of-00036.safetensors", "model.layers.7.mlp.switch_mlp.down_proj.weight": "model-00006-of-00036.safetensors", "model.layers.7.mlp.switch_mlp.gate_proj.weight": "model-00006-of-00036.safetensors", "model.layers.7.mlp.switch_mlp.up_proj.weight": "model-00006-of-00036.safetensors", "model.layers.7.post_attention_layernorm.weight": "model-00006-of-00036.safetensors", "model.layers.7.self_attn.k_norm.weight": "model-00006-of-00036.safetensors", "model.layers.7.self_attn.k_proj.weight": "model-00006-of-00036.safetensors", "model.layers.7.self_attn.o_proj.weight": "model-00006-of-00036.safetensors", "model.layers.7.self_attn.q_norm.weight": "model-00006-of-00036.safetensors", "model.layers.7.self_attn.q_proj.weight": "model-00006-of-00036.safetensors", "model.layers.7.self_attn.v_proj.weight": "model-00006-of-00036.safetensors", "model.layers.8.input_layernorm.weight": "model-00006-of-00036.safetensors", "model.layers.8.linear_attn.A_log": "model-00006-of-00036.safetensors", "model.layers.8.linear_attn.conv1d.weight": "model-00006-of-00036.safetensors", "model.layers.8.linear_attn.dt_bias": "model-00006-of-00036.safetensors", "model.layers.8.linear_attn.in_proj_ba.weight": "model-00006-of-00036.safetensors", "model.layers.8.linear_attn.in_proj_qkvz.weight": "model-00006-of-00036.safetensors", "model.layers.8.linear_attn.norm.weight": "model-00006-of-00036.safetensors", "model.layers.8.linear_attn.out_proj.weight": "model-00006-of-00036.safetensors", "model.layers.8.mlp.gate.weight": "model-00006-of-00036.safetensors", "model.layers.8.mlp.shared_expert.down_proj.weight": "model-00007-of-00036.safetensors", "model.layers.8.mlp.shared_expert.gate_proj.weight": "model-00007-of-00036.safetensors", "model.layers.8.mlp.shared_expert.up_proj.weight": "model-00007-of-00036.safetensors", "model.layers.8.mlp.shared_expert_gate.weight": "model-00007-of-00036.safetensors", "model.layers.8.mlp.switch_mlp.down_proj.weight": "model-00007-of-00036.safetensors", "model.layers.8.mlp.switch_mlp.gate_proj.weight": "model-00007-of-00036.safetensors", "model.layers.8.mlp.switch_mlp.up_proj.weight": "model-00007-of-00036.safetensors", "model.layers.8.post_attention_layernorm.weight": "model-00006-of-00036.safetensors", "model.layers.9.input_layernorm.weight": "model-00007-of-00036.safetensors", "model.layers.9.linear_attn.A_log": "model-00007-of-00036.safetensors", "model.layers.9.linear_attn.conv1d.weight": "model-00007-of-00036.safetensors", "model.layers.9.linear_attn.dt_bias": "model-00007-of-00036.safetensors", "model.layers.9.linear_attn.in_proj_ba.weight": "model-00007-of-00036.safetensors", "model.layers.9.linear_attn.in_proj_qkvz.weight": "model-00007-of-00036.safetensors", "model.layers.9.linear_attn.norm.weight": "model-00007-of-00036.safetensors", "model.layers.9.linear_attn.out_proj.weight": "model-00007-of-00036.safetensors", "model.layers.9.mlp.gate.weight": "model-00007-of-00036.safetensors", "model.layers.9.mlp.shared_expert.down_proj.weight": "model-00008-of-00036.safetensors", "model.layers.9.mlp.shared_expert.gate_proj.weight": "model-00008-of-00036.safetensors", "model.layers.9.mlp.shared_expert.up_proj.weight": "model-00008-of-00036.safetensors", "model.layers.9.mlp.shared_expert_gate.weight": "model-00008-of-00036.safetensors", "model.layers.9.mlp.switch_mlp.down_proj.weight": "model-00008-of-00036.safetensors", "model.layers.9.mlp.switch_mlp.gate_proj.weight": "model-00007-of-00036.safetensors", "model.layers.9.mlp.switch_mlp.up_proj.weight": "model-00008-of-00036.safetensors", "model.layers.9.post_attention_layernorm.weight": "model-00007-of-00036.safetensors", "model.norm.weight": "model-00036-of-00036.safetensors" }}123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474import astimport jsonimport loggingimport refrom typing import Any, List, Optional
from sglang.srt.entrypoints.openai.protocol import Toolfrom sglang.srt.function_call.base_format_detector import BaseFormatDetectorfrom sglang.srt.function_call.core_types import ( StreamingParseResult, ToolCallItem, _GetInfoFunc,)
logger = logging.getLogger(__name__)
class Qwen3CoderDetector(BaseFormatDetector): def __init__(self): super().__init__()
# Sentinel tokens self.tool_call_start_token: str = "<tool_call>" self.tool_call_end_token: str = "</tool_call>" self.tool_call_prefix: str = "<function=" self.function_end_token: str = "</function>" self.parameter_prefix: str = "<parameter=" self.parameter_end_token: str = "</parameter>"
# Regex for non-streaming fallback self.tool_call_regex = re.compile(r"<tool_call>(.*?)</tool_call>", re.DOTALL) self.tool_call_function_regex = re.compile( r"<function=(.*?)</function>|<function=(.*)$", re.DOTALL ) self.tool_call_parameter_regex = re.compile( r"<parameter=(.*?)(?:</parameter>|(?=<parameter=)|(?=</function>)|$)", re.DOTALL, )
# Streaming State # Base class already initializes _buffer, we just use it directly # No need to check with hasattr - we control the lifecycle through inheritance
# Index pointing to the next character to be processed in buffer self.parsed_pos: int = 0 # Parameter count inside the current tool being processed, used to determine whether to add comma self.current_tool_param_count: int = 0 # Flag indicating whether current tool has already sent '{' self.json_started: bool = False
# [FIX] New state flag: mark whether inside tool_call structure block self.is_inside_tool_call: bool = False
# Initialize attributes that were missing in the original PR self.current_func_name: Optional[str] = None
def has_tool_call(self, text: str) -> bool: return self.tool_call_start_token in text
def _get_arguments_config( self, func_name: str, tools: Optional[list[Tool]] ) -> dict: """Extract argument configuration for a function.""" if tools is None: return {} for config in tools: try: config_type = config.type config_function = config.function config_function_name = config_function.name except AttributeError: continue
if config_type == "function" and config_function_name == func_name: try: params = config_function.parameters except AttributeError: return {}
if isinstance(params, dict) and "properties" in params: return params["properties"] elif isinstance(params, dict): return params else: return {} logger.warning(f"Tool '{func_name}' is not defined in the tools list.") return {}
def _convert_param_value( self, param_value: str, param_name: str, param_config: dict, func_name: str ) -> Any: """Convert parameter value based on its type in the schema.""" # Handle null value for any type if param_value.lower() == "null": return None
if param_name not in param_config: if param_config != {}: logger.warning( f"Parsed parameter '{param_name}' is not defined in the tool " f"parameters for tool '{func_name}', directly returning the string value." ) return param_value
if ( isinstance(param_config[param_name], dict) and "type" in param_config[param_name] ): param_type = str(param_config[param_name]["type"]).strip().lower() else: param_type = "string" if param_type in ["string", "str", "text", "varchar", "char", "enum"]: return param_value elif ( param_type.startswith("int") or param_type.startswith("uint") or param_type.startswith("long") or param_type.startswith("short") or param_type.startswith("unsigned") ): try: param_value = int(param_value) except Exception: logger.warning( f"Parsed value '{param_value}' of parameter '{param_name}' is not an integer in tool " f"'{func_name}', degenerating to string." ) return param_value elif param_type.startswith("num") or param_type.startswith("float"): try: maybe_convert = ( False if "." in param_value or "e" in param_value.lower() else True ) param_value: float = float(param_value) if maybe_convert and param_value.is_integer(): param_value = int(param_value) except Exception: logger.warning( f"Parsed value '{param_value}' of parameter '{param_name}' is not a float in tool " f"'{func_name}', degenerating to string." ) return param_value elif param_type in ["boolean", "bool", "binary"]: param_value = param_value.lower() if param_value not in ["true", "false"]: logger.warning( f"Parsed value '{param_value}' of parameter '{param_name}' is not a boolean (`true` of `false`) in tool '{func_name}', degenerating to false." ) return param_value == "true" else: if ( param_type in ["object", "array", "arr"] or param_type.startswith("dict") or param_type.startswith("list") ): try: param_value = json.loads(param_value) return param_value except Exception: logger.warning( f"Parsed value '{param_value}' of parameter '{param_name}' cannot be parsed with json.loads in tool " f"'{func_name}', will try other methods to parse it." ) try: param_value = ast.literal_eval(param_value) # safer except Exception: logger.warning( f"Parsed value '{param_value}' of parameter '{param_name}' cannot be converted via Python `ast.literal_eval()` in tool '{func_name}', degenerating to string." ) return param_value
def detect_and_parse(self, text: str, tools: List[Tool]) -> StreamingParseResult: """One-shot parsing for non-streaming scenarios.""" if self.tool_call_start_token not in text: return StreamingParseResult(normal_text=text)
calls = [] try: # Simple cleanup of the text to find tool calls # Note: This is a simplified regex approach consistent with vLLM raw_tool_calls = self.tool_call_regex.findall(text) if not raw_tool_calls: # Fallback: maybe the whole text is inside the tag or tags are stripped if self.tool_call_prefix in text: raw_tool_calls = [text]
tool_idx = 0 for tool_content in raw_tool_calls: # Find function calls funcs = self.tool_call_function_regex.findall(tool_content) for func_match in funcs: func_body = func_match[0] or func_match[1] if ">" not in func_body: continue
name_end = func_body.index(">") func_name = func_body[:name_end] params_str = func_body[name_end + 1 :]
param_config = self._get_arguments_config(func_name, tools) parsed_params = {}
for p_match in self.tool_call_parameter_regex.findall(params_str): if ">" not in p_match: continue p_idx = p_match.index(">") p_name = p_match[:p_idx] p_val = p_match[p_idx + 1 :] # Remove prefixing and trailing \n if p_val.startswith("\n"): p_val = p_val[1:] if p_val.endswith("\n"): p_val = p_val[:-1]
parsed_params[p_name] = self._convert_param_value( p_val, p_name, param_config, func_name )
calls.append( ToolCallItem( tool_index=tool_idx, name=func_name, parameters=json.dumps(parsed_params, ensure_ascii=False), ) ) tool_idx += 1
# Determine normal text (text before the first tool call) start_idx = text.find(self.tool_call_start_token) if start_idx == -1: start_idx = text.find(self.tool_call_prefix) normal_text = text[:start_idx] if start_idx > 0 else ""
return StreamingParseResult(normal_text=normal_text, calls=calls)
except Exception as e: logger.error(f"Error in detect_and_parse: {e}") return StreamingParseResult(normal_text=text)
def parse_streaming_increment( self, new_text: str, tools: List[Tool] ) -> StreamingParseResult: """ Robust cursor-based streaming parser. """ self._buffer += new_text
# Guard against empty buffer if not self._buffer: return StreamingParseResult()
calls = [] normal_text_chunks = []
while True: # Working text slice current_slice = self._buffer[self.parsed_pos :]
# Optimization: If almost empty, wait for more if not current_slice: break
# ------------------------------------------------------- # 1. Priority detection: check if it's the start of Tool Call # ------------------------------------------------------- if current_slice.startswith(self.tool_call_start_token): self.parsed_pos += len(self.tool_call_start_token) self.is_inside_tool_call = True continue
# ------------------------------------------------------- # 2. Function Name: <function=name> # ------------------------------------------------------- if current_slice.startswith(self.tool_call_prefix): end_angle = current_slice.find(">") if end_angle != -1: func_name = current_slice[len(self.tool_call_prefix) : end_angle]
self.current_tool_id += 1 self.current_tool_name_sent = True self.current_tool_param_count = 0 self.json_started = False self.current_func_name = func_name
calls.append( ToolCallItem( tool_index=self.current_tool_id, name=func_name, parameters="", ) )
self.parsed_pos += end_angle + 1 continue else: # Incomplete tag break
# ------------------------------------------------------- # 3. Parameter: <parameter=name>value... # ------------------------------------------------------- if current_slice.startswith(self.parameter_prefix): name_end = current_slice.find(">") if name_end != -1: value_start_idx = name_end + 1 rest_of_slice = current_slice[value_start_idx:]
# A parameter can end in multiple ways: # 1. [Normal] Encounter </parameter> # 2. [Abnormal] Encounter next <parameter= # 3. [Abnormal] Encounter </function> # So we need to find the smallest one as the parameter end position. cand_end_param = rest_of_slice.find(self.parameter_end_token) cand_next_param = rest_of_slice.find(self.parameter_prefix) cand_end_func = rest_of_slice.find(self.function_end_token)
candidates = [] if cand_end_param != -1: candidates.append( (cand_end_param, len(self.parameter_end_token)) ) if cand_next_param != -1: candidates.append((cand_next_param, 0)) if cand_end_func != -1: candidates.append((cand_end_func, 0))
if candidates: best_cand = min(candidates, key=lambda x: x[0]) end_pos = best_cand[0] end_token_len = best_cand[1]
param_name = current_slice[ len(self.parameter_prefix) : name_end ] raw_value = rest_of_slice[:end_pos]
# Cleanup value if raw_value.startswith("\n"): raw_value = raw_value[1:] if raw_value.endswith("\n"): raw_value = raw_value[:-1]
# JSON Construction if not self.json_started: calls.append( ToolCallItem( tool_index=self.current_tool_id, parameters="{" ) ) self.json_started = True
param_config = self._get_arguments_config( self.current_func_name, tools ) converted_val = self._convert_param_value( raw_value, param_name, param_config, self.current_func_name )
# Construct JSON fragment: "key": value # Note: We must be careful with json.dumps to ensure valid JSON streaming json_key_val = f"{json.dumps(param_name)}: {json.dumps(converted_val, ensure_ascii=False)}"
if self.current_tool_param_count > 0: fragment = f", {json_key_val}" else: fragment = json_key_val
calls.append( ToolCallItem( tool_index=self.current_tool_id, parameters=fragment ) ) self.current_tool_param_count += 1
# Advance cursor total_len = (name_end + 1) + end_pos + end_token_len self.parsed_pos += total_len continue
# Incomplete parameter tag or value break
# ------------------------------------------------------- # 4. Function End: </function> # ------------------------------------------------------- if current_slice.startswith(self.function_end_token): if not self.json_started: calls.append( ToolCallItem(tool_index=self.current_tool_id, parameters="{") ) self.json_started = True
calls.append( ToolCallItem(tool_index=self.current_tool_id, parameters="}") ) self.parsed_pos += len(self.function_end_token) self.current_func_name = None continue
# ------------------------------------------------------- # 5. Tool Call End: </tool_call> # ------------------------------------------------------- if current_slice.startswith(self.tool_call_end_token): self.parsed_pos += len(self.tool_call_end_token) self.is_inside_tool_call = False # [FIX] Exit tool call region continue
# ------------------------------------------------------- # 6. Handling content / whitespace / normal text # ------------------------------------------------------- # If current position is not the start of a tag (i.e., doesn't start with <), it might be plain text, # or a newline between two tags. # But we need to be careful not to output truncated tags like "<fun" as text.
next_open_angle = current_slice.find("<")
if next_open_angle == -1: # This entire segment is plain text if not self.is_inside_tool_call: normal_text_chunks.append(current_slice) # [FIX] If inside tool call, discard this text (usually \n), don't append self.parsed_pos += len(current_slice) continue
elif next_open_angle == 0: # Looks like a Tag, but doesn't match any known Tag above
possible_tags = [ self.tool_call_start_token, self.tool_call_end_token, self.tool_call_prefix, self.function_end_token, self.parameter_prefix, self.parameter_end_token, ]
is_potential_tag = False for tag in possible_tags: if tag.startswith(current_slice): is_potential_tag = True break
if is_potential_tag: break # Wait for more else: # Just a plain '<' symbol if not self.is_inside_tool_call: normal_text_chunks.append("<") self.parsed_pos += 1 continue
else: # '<' is in the middle text_segment = current_slice[:next_open_angle] if not self.is_inside_tool_call: normal_text_chunks.append(text_segment) # [FIX] If inside tool call, discard whitespace/text before Tag self.parsed_pos += next_open_angle continue
# Memory Cleanup: Slice the buffer # Keep unparsed part, discard parsed part if self.parsed_pos > 0: self._buffer = self._buffer[self.parsed_pos :] self.parsed_pos = 0
normal_text = "".join(normal_text_chunks) if normal_text_chunks else "" return StreamingParseResult(calls=calls, normal_text=normal_text)
def supports_structural_tag(self) -> bool: return False
def structure_info(self) -> _GetInfoFunc: raise NotImplementedError123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690# SPDX-License-Identifier: Apache-2.0# SPDX-FileCopyrightText: Copyright contributors to the vLLM projectimport astimport jsonimport uuidfrom collections.abc import Sequencefrom typing import Any, List, Optional, Union
import regex as re
from vllm.entrypoints.openai.protocol import (ChatCompletionRequest, ChatCompletionToolsParam, DeltaFunctionCall, DeltaMessage, DeltaToolCall, ExtractedToolCallInformation, FunctionCall, ToolCall)from vllm.entrypoints.openai.tool_parsers.abstract_tool_parser import ( ToolParser, ToolParserManager)from vllm.logger import init_loggerfrom vllm.transformers_utils.tokenizer import AnyTokenizer
logger = init_logger(__name__)
@ToolParserManager.register_module("qwen3_coder")class Qwen3CoderToolParser(ToolParser):
def __init__(self, tokenizer: AnyTokenizer): super().__init__(tokenizer)
self.current_tool_name_sent: bool = False self.prev_tool_call_arr: list[dict] = [] self.current_tool_id: int = -1 self.streamed_args_for_tool: list[str] = []
# Sentinel tokens for streaming mode self.tool_call_start_token: str = "<tool_call>" self.tool_call_end_token: str = "</tool_call>" self.tool_call_prefix: str = "<function=" self.function_end_token: str = "</function>" self.parameter_prefix: str = "<parameter=" self.parameter_end_token: str = "</parameter>" self.is_tool_call_started: bool = False self.failed_count: int = 0
# Enhanced streaming state - reset for each new message self._reset_streaming_state()
# Regex patterns self.tool_call_complete_regex = re.compile( r"<tool_call>(.*?)</tool_call>", re.DOTALL) self.tool_call_regex = re.compile( r"<tool_call>(.*?)</tool_call>|<tool_call>(.*?)$", re.DOTALL) self.tool_call_function_regex = re.compile( r"<function=(.*?)</function>|<function=(.*)$", re.DOTALL) self.tool_call_parameter_regex = re.compile( r"<parameter=(.*?)(?:</parameter>|(?=<parameter=)|(?=</function>)|$)", re.DOTALL)
if not self.model_tokenizer: raise ValueError( "The model tokenizer must be passed to the ToolParser " "constructor during construction.")
self.tool_call_start_token_id = self.vocab.get( self.tool_call_start_token) self.tool_call_end_token_id = self.vocab.get(self.tool_call_end_token)
if self.tool_call_start_token_id is None or self.tool_call_end_token_id is None: raise RuntimeError( "Qwen3 XML Tool parser could not locate tool call start/end " "tokens in the tokenizer!")
logger.info( f"vLLM Successfully import tool parser {self.__class__.__name__} !" )
def _generate_tool_call_id(self) -> str: """Generate a unique tool call ID.""" return f"call_{uuid.uuid4().hex[:24]}"
def _reset_streaming_state(self): """Reset all streaming state.""" self.current_tool_index = 0 self.is_tool_call_started = False self.header_sent = False self.current_tool_id = None self.current_function_name = None self.current_param_name = None self.current_param_value = "" self.param_count = 0 self.in_param = False self.in_function = False self.accumulated_text = "" self.json_started = False self.json_closed = False # Store accumulated parameters for type conversion self.accumulated_params = {} self.streaming_request = None
def _get_arguments_config( self, func_name: str, tools: Optional[list[ChatCompletionToolsParam]]) -> dict: """Extract argument configuration for a function.""" if tools is None: return {} for config in tools: if not hasattr(config, "type") or not (hasattr( config, "function") and hasattr(config.function, "name")): continue if config.type == "function" and config.function.name == func_name: if not hasattr(config.function, "parameters"): return {} params = config.function.parameters if isinstance(params, dict) and "properties" in params: return params["properties"] elif isinstance(params, dict): return params else: return {} logger.warning(f"Tool '{func_name}' is not defined in the tools list.") return {}
def _convert_param_value(self, param_value: str, param_name: str, param_config: dict, func_name: str) -> Any: """Convert parameter value based on its type in the schema.""" # Handle null value for any type if param_value.lower() == "null": return None
if param_name not in param_config: if param_config != {}: logger.warning( f"Parsed parameter '{param_name}' is not defined in the tool " f"parameters for tool '{func_name}', directly returning the string value." ) return param_value
if isinstance(param_config[param_name], dict) and "type" in param_config[param_name]: param_type = str(param_config[param_name]["type"]).strip().lower() else: param_type = "string" if param_type in ["string", "str", "text", "varchar", "char", "enum"]: return param_value elif param_type.startswith("int") or param_type.startswith( "uint") or param_type.startswith( "long") or param_type.startswith( "short") or param_type.startswith("unsigned"): try: param_value = int(param_value) except: logger.warning( f"Parsed value '{param_value}' of parameter '{param_name}' is not an integer in tool " f"'{func_name}', degenerating to string.") return param_value elif param_type.startswith("num") or param_type.startswith("float"): try: maybe_convert = False if "." in param_value or "e" in param_value.lower() else True param_value: float = float(param_value) if maybe_convert and param_value.is_integer(): param_value = int(param_value) except: logger.warning( f"Parsed value '{param_value}' of parameter '{param_name}' is not a float in tool " f"'{func_name}', degenerating to string.") return param_value elif param_type in ["boolean", "bool", "binary"]: param_value = param_value.lower() if param_value not in ["true", "false"]: logger.warning( f"Parsed value '{param_value}' of parameter '{param_name}' is not a boolean (`true` of `false`) in tool '{func_name}', degenerating to false." ) return param_value == "true" else: if param_type in ["object", "array", "arr" ] or param_type.startswith( "dict") or param_type.startswith("list"): try: param_value = json.loads(param_value) return param_value except: logger.warning( f"Parsed value '{param_value}' of parameter '{param_name}' cannot be parsed with json.loads in tool " f"'{func_name}', will try other methods to parse it.") try: param_value = ast.literal_eval(param_value) # safer except: logger.warning( f"Parsed value '{param_value}' of parameter '{param_name}' cannot be converted via Python `ast.literal_eval()` in tool '{func_name}', degenerating to string." ) return param_value
def _parse_xml_function_call( self, function_call_str: str, tools: Optional[list[ChatCompletionToolsParam]] ) -> Optional[ToolCall]:
# Extract function name end_index = function_call_str.index(">") function_name = function_call_str[:end_index] param_config = self._get_arguments_config(function_name, tools) parameters = function_call_str[end_index + 1:] param_dict = {} for match_text in self.tool_call_parameter_regex.findall(parameters): idx = match_text.index(">") param_name = match_text[:idx] param_value = str(match_text[idx + 1:]) # Remove prefix and trailing \n if param_value.startswith("\n"): param_value = param_value[1:] if param_value.endswith("\n"): param_value = param_value[:-1]
param_dict[param_name] = self._convert_param_value( param_value, param_name, param_config, function_name) return ToolCall( type="function", function=FunctionCall(name=function_name, arguments=json.dumps(param_dict, ensure_ascii=False)), )
def _get_function_calls(self, model_output: str) -> List[str]: # Find all tool calls matched_ranges = self.tool_call_regex.findall(model_output) raw_tool_calls = [ match[0] if match[0] else match[1] for match in matched_ranges ]
# Back-off strategy if no tool_call tags found if len(raw_tool_calls) == 0: raw_tool_calls = [model_output]
raw_function_calls = [] for tool_call in raw_tool_calls: raw_function_calls.extend( self.tool_call_function_regex.findall(tool_call))
function_calls = [ match[0] if match[0] else match[1] for match in raw_function_calls ] return function_calls
def extract_tool_calls( self, model_output: str, request: ChatCompletionRequest, ) -> ExtractedToolCallInformation: # Quick check to avoid unnecessary processing if self.tool_call_prefix not in model_output: return ExtractedToolCallInformation(tools_called=False, tool_calls=[], content=model_output)
try: function_calls = self._get_function_calls(model_output) if len(function_calls) == 0: return ExtractedToolCallInformation(tools_called=False, tool_calls=[], content=model_output)
tool_calls = [ self._parse_xml_function_call(function_call_str, request.tools) for function_call_str in function_calls ]
# Populate prev_tool_call_arr for serving layer to set finish_reason self.prev_tool_call_arr.clear() # Clear previous calls for tool_call in tool_calls: if tool_call: self.prev_tool_call_arr.append({ "name": tool_call.function.name, "arguments": tool_call.function.arguments, })
# Extract content before tool calls content_index = model_output.find(self.tool_call_start_token) content_index = content_index if content_index >= 0 else model_output.find( self.tool_call_prefix) content = model_output[:content_index] # .rstrip()
return ExtractedToolCallInformation( tools_called=(len(tool_calls) > 0), tool_calls=tool_calls, content=content if content else None, )
except Exception: logger.exception("Error in extracting tool call from response.") return ExtractedToolCallInformation(tools_called=False, tool_calls=[], content=model_output)
def extract_tool_calls_streaming( self, previous_text: str, current_text: str, delta_text: str, previous_token_ids: Sequence[int], current_token_ids: Sequence[int], delta_token_ids: Sequence[int], request: ChatCompletionRequest, ) -> Union[DeltaMessage, None]: # Store request for type conversion if not previous_text: self._reset_streaming_state() self.streaming_request = request
# If no delta text, return None unless it's an EOS token after tool calls if not delta_text: # Check if this is an EOS token after all tool calls are complete # We check for tool calls in the text even if is_tool_call_started is False # because it might have been reset after processing all tools if delta_token_ids and self.tool_call_end_token_id not in delta_token_ids: # Count complete tool calls complete_calls = len( self.tool_call_complete_regex.findall(current_text))
# If we have completed tool calls and populated prev_tool_call_arr if complete_calls > 0 and len(self.prev_tool_call_arr) > 0: # Check if all tool calls are closed open_calls = current_text.count( self.tool_call_start_token) - current_text.count( self.tool_call_end_token) if open_calls == 0: # Return empty delta message to allow finish_reason processing return DeltaMessage(content="") elif not self.is_tool_call_started and current_text: # This is a regular content response that's now complete return DeltaMessage(content="") return None
# Update accumulated text self.accumulated_text = current_text
# Check if we need to advance to next tool if self.json_closed and not self.in_function: # Check if this tool call has ended tool_ends = current_text.count(self.tool_call_end_token) if tool_ends > self.current_tool_index: # This tool has ended, advance to next self.current_tool_index += 1 self.header_sent = False self.param_count = 0 self.json_started = False self.json_closed = False self.accumulated_params = {}
# Check if there are more tool calls tool_starts = current_text.count(self.tool_call_start_token) if self.current_tool_index >= tool_starts: # No more tool calls self.is_tool_call_started = False # Continue processing next tool return None
# Handle normal content before tool calls if not self.is_tool_call_started: # Check if tool call is starting if self.tool_call_start_token_id in delta_token_ids or self.tool_call_start_token in delta_text: self.is_tool_call_started = True # Return any content before the tool call if self.tool_call_start_token in delta_text: content_before = delta_text[:delta_text.index( self.tool_call_start_token)] if content_before: return DeltaMessage(content=content_before) return None else: # Check if we're between tool calls - skip whitespace if current_text.rstrip().endswith(self.tool_call_end_token): # We just ended a tool call, skip whitespace if delta_text.strip() == "": return None # Normal content, no tool call return DeltaMessage(content=delta_text)
# Check if we're between tool calls (waiting for next one) # Count tool calls we've seen vs processed tool_starts_count = current_text.count(self.tool_call_start_token) if self.current_tool_index >= tool_starts_count: # We're past all tool calls, shouldn't be here return None
# We're in a tool call, find the current tool call portion # Need to find the correct tool call based on current_tool_index tool_starts = [] idx = 0 while True: idx = current_text.find(self.tool_call_start_token, idx) if idx == -1: break tool_starts.append(idx) idx += len(self.tool_call_start_token)
if self.current_tool_index >= len(tool_starts): # No more tool calls to process yet return None
tool_start_idx = tool_starts[self.current_tool_index] # Find where this tool call ends (or current position if not ended yet) tool_end_idx = current_text.find(self.tool_call_end_token, tool_start_idx) if tool_end_idx == -1: tool_text = current_text[tool_start_idx:] else: tool_text = current_text[tool_start_idx:tool_end_idx + len(self.tool_call_end_token)]
# Looking for function header if not self.header_sent: if self.tool_call_prefix in tool_text: func_start = tool_text.find(self.tool_call_prefix) + len( self.tool_call_prefix) func_end = tool_text.find(">", func_start)
if func_end != -1: # Found complete function name self.current_function_name = tool_text[func_start:func_end] self.current_tool_id = self._generate_tool_call_id() self.header_sent = True self.in_function = True
# IMPORTANT: Add to prev_tool_call_arr immediately when we detect a tool call # This ensures finish_reason="tool_calls" even if parsing isn't complete already_added = any( tool.get("name") == self.current_function_name for tool in self.prev_tool_call_arr) if not already_added: self.prev_tool_call_arr.append({ "name": self.current_function_name, "arguments": "{}", # Placeholder, will be updated later })
# Send header with function info return DeltaMessage(tool_calls=[ DeltaToolCall( index=self.current_tool_index, id=self.current_tool_id, function=DeltaFunctionCall( name=self.current_function_name, arguments=""), type="function", ) ]) return None
# We've sent header, now handle function body if self.in_function: # Send opening brace if not sent yet if not self.json_started and self.parameter_prefix not in delta_text: self.json_started = True return DeltaMessage(tool_calls=[ DeltaToolCall( index=self.current_tool_index, function=DeltaFunctionCall(arguments="{"), ) ])
# Make sure json_started is set if we're processing parameters if not self.json_started: self.json_started = True
# Check for function end in accumulated text if not self.json_closed and self.function_end_token in tool_text: # Close JSON self.json_closed = True
# Extract the complete tool call to update prev_tool_call_arr with final arguments # Find the function content func_start = tool_text.find(self.tool_call_prefix) + len( self.tool_call_prefix) func_content_end = tool_text.find(self.function_end_token, func_start) if func_content_end != -1: func_content = tool_text[func_start:func_content_end] # Parse to get the complete arguments try: parsed_tool = self._parse_xml_function_call( func_content, self.streaming_request.tools if self.streaming_request else None) if parsed_tool: # Update existing entry in prev_tool_call_arr with complete arguments for i, tool in enumerate(self.prev_tool_call_arr): if tool.get( "name") == parsed_tool.function.name: self.prev_tool_call_arr[i][ "arguments"] = parsed_tool.function.arguments break except Exception: pass # Ignore parsing errors during streaming
result = DeltaMessage(tool_calls=[ DeltaToolCall( index=self.current_tool_index, function=DeltaFunctionCall(arguments="}"), ) ])
# Reset state for next tool self.in_function = False self.json_closed = True self.accumulated_params = {}
return result
# Look for parameters # Find all parameter starts param_starts = [] idx = 0 while True: idx = tool_text.find(self.parameter_prefix, idx) if idx == -1: break param_starts.append(idx) idx += len(self.parameter_prefix)
# Check if we should start a new parameter if not self.in_param and self.param_count < len(param_starts):
if len(param_starts) > self.param_count: # Process the next parameter param_idx = param_starts[self.param_count] param_start = param_idx + len(self.parameter_prefix) remaining = tool_text[param_start:]
if ">" in remaining: # We have the complete parameter name name_end = remaining.find(">") self.current_param_name = remaining[:name_end]
# Find the parameter value value_start = param_start + name_end + 1 value_text = tool_text[value_start:] if value_text.startswith("\n"): value_text = value_text[1:]
# Find where this parameter ends param_end_idx = value_text.find( self.parameter_end_token) if param_end_idx == -1: # No closing tag, look for next parameter or function end next_param_idx = value_text.find( self.parameter_prefix) func_end_idx = value_text.find( self.function_end_token)
if next_param_idx != -1 and (func_end_idx == -1 or next_param_idx < func_end_idx): param_end_idx = next_param_idx elif func_end_idx != -1: param_end_idx = func_end_idx else: # Neither found, check if tool call is complete if self.tool_call_end_token in tool_text: # Tool call is complete, so parameter must be complete too # Use all remaining text before function end as value param_end_idx = len(value_text) else: # Still streaming, wait for more content return None
if param_end_idx != -1: # Complete parameter found param_value = value_text[:param_end_idx] if param_value.endswith("\n"): param_value = param_value[:-1]
# Store raw value for later processing self.accumulated_params[ self.current_param_name] = param_value
# Get parameter configuration for type conversion param_config = self._get_arguments_config( self.current_function_name, self.streaming_request.tools if self.streaming_request else None)
# Convert the parameter value to the appropriate type converted_value = self._convert_param_value( param_value, self.current_param_name, param_config, self.current_function_name)
# Build JSON fragment based on the converted type # Use json.dumps to properly serialize the value serialized_value = json.dumps(converted_value, ensure_ascii=False)
if self.param_count == 0: json_fragment = f'"{self.current_param_name}": {serialized_value}' else: json_fragment = f', "{self.current_param_name}": {serialized_value}'
self.param_count += 1
return DeltaMessage(tool_calls=[ DeltaToolCall( index=self.current_tool_index, function=DeltaFunctionCall( arguments=json_fragment), ) ])
# Continue parameter value - Not used in the current implementation # since we process complete parameters above if self.in_param: if self.parameter_end_token in delta_text: # End of parameter end_idx = delta_text.find(self.parameter_end_token) value_chunk = delta_text[:end_idx]
# Skip past > if at start if not self.current_param_value and ">" in value_chunk: gt_idx = value_chunk.find(">") value_chunk = value_chunk[gt_idx + 1:]
if not self.current_param_value and value_chunk.startswith( "\n"): value_chunk = value_chunk[1:]
# Store complete value full_value = self.current_param_value + value_chunk self.accumulated_params[ self.current_param_name] = full_value
# Get parameter configuration for type conversion param_config = self._get_arguments_config( self.current_function_name, self.streaming_request.tools if self.streaming_request else None)
# Convert the parameter value to the appropriate type converted_value = self._convert_param_value( full_value, self.current_param_name, param_config, self.current_function_name)
# Serialize the converted value serialized_value = json.dumps(converted_value, ensure_ascii=False)
# Since we've been streaming the quoted version, we need to close it properly # This is complex - for now just complete the value self.in_param = False self.current_param_value = ""
# Just close the current parameter string return DeltaMessage(tool_calls=[ DeltaToolCall( index=self.current_tool_index, function=DeltaFunctionCall( arguments='"'), # Close the string quote ) ]) else: # Continue accumulating value value_chunk = delta_text
# Handle first chunk after param name if not self.current_param_value and ">" in value_chunk: gt_idx = value_chunk.find(">") value_chunk = value_chunk[gt_idx + 1:]
if not self.current_param_value and value_chunk.startswith( "\n"): value_chunk = value_chunk[1:]
if value_chunk: # Stream the escaped delta prev_escaped = json.dumps( self.current_param_value, ensure_ascii=False )[1:-1] if self.current_param_value else "" self.current_param_value += value_chunk full_escaped = json.dumps(self.current_param_value, ensure_ascii=False)[1:-1] delta_escaped = full_escaped[len(prev_escaped):]
if delta_escaped: return DeltaMessage(tool_calls=[ DeltaToolCall( index=self.current_tool_index, function=DeltaFunctionCall( arguments=delta_escaped), ) ])
return None123version https://git-lfs.github.com/spec/v1oid sha256:be75606093db2094d7cd20f3c2f385c212750648bd6ea4fb2bf507a6a4c55506size 11422650123456789101112131415161718192021222324252627282930{ "add_prefix_space": false, "backend": "tokenizers", "bos_token": null, "clean_up_tokenization_spaces": false, "eos_token": "<|im_end|>", "errors": "replace", "extra_special_tokens": [ "<|im_start|>", "<|im_end|>", "<|object_ref_start|>", "<|object_ref_end|>", "<|box_start|>", "<|box_end|>", "<|quad_start|>", "<|quad_end|>", "<|vision_start|>", "<|vision_end|>", "<|vision_pad|>", "<|image_pad|>", "<|video_pad|>" ], "is_local": true, "model_max_length": 1048576, "pad_token": "<|endoftext|>", "split_special_tokens": false, "tokenizer_class": "Qwen2Tokenizer", "tool_parser_type": "json_tools", "unk_token": null}.gitattributes+1
README.mdAdded+37
chat_template.jinjaAdded+117
config.jsonAdded+47
generation_config.jsonAdded+13
model-00001-of-00036.safetensorsAdded+3
model-00002-of-00036.safetensorsAdded+3
model-00003-of-00036.safetensorsAdded+3
model-00004-of-00036.safetensorsAdded+3
model-00005-of-00036.safetensorsAdded+3
model-00006-of-00036.safetensorsAdded+3
model-00007-of-00036.safetensorsAdded+3
model-00008-of-00036.safetensorsAdded+3
model-00009-of-00036.safetensorsAdded+3
model-00010-of-00036.safetensorsAdded+3
model-00011-of-00036.safetensorsAdded+3
model-00012-of-00036.safetensorsAdded+3
model-00013-of-00036.safetensorsAdded+3
model-00014-of-00036.safetensorsAdded+3
model-00015-of-00036.safetensorsAdded+3
model-00016-of-00036.safetensorsAdded+3
model-00017-of-00036.safetensorsAdded+3
model-00018-of-00036.safetensorsAdded+3
model-00019-of-00036.safetensorsAdded+3
model-00020-of-00036.safetensorsAdded+3
model-00021-of-00036.safetensorsAdded+3
model-00022-of-00036.safetensorsAdded+3
model-00023-of-00036.safetensorsAdded+3
model-00024-of-00036.safetensorsAdded+3
model-00025-of-00036.safetensorsAdded+3
model-00026-of-00036.safetensorsAdded+3
model-00027-of-00036.safetensorsAdded+3
model-00028-of-00036.safetensorsAdded+3
model-00029-of-00036.safetensorsAdded+3
model-00030-of-00036.safetensorsAdded+3
model-00031-of-00036.safetensorsAdded+3
model-00032-of-00036.safetensorsAdded+3
model-00033-of-00036.safetensorsAdded+3
model-00034-of-00036.safetensorsAdded+3
model-00035-of-00036.safetensorsAdded+3
model-00036-of-00036.safetensorsAdded+3
model.safetensors.index.jsonAdded+815
qwen3_coder_detector_sgl.pyAdded+474
qwen3coder_tool_parser_vllm.pyAdded+690
tokenizer.jsonAdded+3
tokenizer_config.jsonAdded+30