{"_id":"696dcefa357a4070754b027e","id":"zai-org/GLM-4.7-Flash","private":false,"pipeline_tag":"text-generation","library_name":"transformers","tags":["transformers","safetensors","glm4_moe_lite","text-generation","conversational","en","zh","arxiv:2508.06471","license:mit","eval-results","endpoints_compatible","deploy:azure","region:us"],"downloads":1896071,"likes":1837,"modelId":"zai-org/GLM-4.7-Flash","author":"zai-org","sha":"7dd20894a642a0aa287e9827cb1a1f7f91386b67","lastModified":"2026-01-29T08:06:19.000Z","gated":false,"disabled":false,"widgetData":[{"text":"Hi, what can you help me with?"},{"text":"What is 84 * 3 / 2?"},{"text":"Tell me an interesting fact about the universe!"},{"text":"Explain quantum computing in simple terms."}],"model-index":null,"config":{"architectures":["Glm4MoeLiteForCausalLM"],"model_type":"glm4_moe_lite","num_experts_per_tok":4,"tokenizer_config":{"eos_token":"<|endoftext|>","pad_token":"<|endoftext|>"},"chat_template_jinja":"[gMASK]<sop>\n{%- if tools -%}\n<|system|>\n# Tools\n\nYou may call one or more functions to assist with the user query.\n\nYou are provided with function signatures within <tools></tools> XML tags:\n<tools>\n{% for tool in tools %}\n{{ tool | tojson(ensure_ascii=False) }}\n{% endfor %}\n</tools>\n\nFor each function call, output the function name and arguments within the following XML format:\n<tool_call>{function-name}<arg_key>{arg-key-1}</arg_key><arg_value>{arg-value-1}</arg_value><arg_key>{arg-key-2}</arg_key><arg_value>{arg-value-2}</arg_value>...</tool_call>{%- endif -%}\n{%- macro visible_text(content) -%}\n    {%- if content is string -%}\n        {{- content }}\n    {%- elif content is iterable and content is not mapping -%}\n        {%- for item in content -%}\n            {%- if item is mapping and item.type == 'text' -%}\n                {{- item.text }}\n            {%- elif item is string -%}\n                {{- item }}\n            {%- endif -%}\n        {%- endfor -%}\n    {%- else -%}\n        {{- content }}\n    {%- endif -%}\n{%- endmacro -%}\n{%- set ns = namespace(last_user_index=-1) %}\n{%- for m in messages %}\n    {%- if m.role == 'user' %}\n        {% set ns.last_user_index = loop.index0 -%}\n    {%- endif %}\n{%- endfor %}\n{% for m in messages %}\n{%- if m.role == 'user' -%}<|user|>{{ visible_text(m.content) }}\n{%- elif m.role == 'assistant' -%}\n<|assistant|>\n{%- set reasoning_content = '' %}\n{%- set content = visible_text(m.content) %}\n{%- if m.reasoning_content is string %}\n    {%- set reasoning_content = m.reasoning_content %}\n{%- else %}\n    {%- if '</think>' in content %}\n        {%- set reasoning_content = content.split('</think>')[0].rstrip('\\n').split('<think>')[-1].lstrip('\\n') %}\n        {%- set content = content.split('</think>')[-1].lstrip('\\n') %}\n    {%- endif %}\n{%- endif %}\n{%- if ((clear_thinking is defined and not clear_thinking) or loop.index0 > ns.last_user_index) and reasoning_content -%}\n{{ '<think>' + reasoning_content.strip() +  '</think>'}}\n{%- else -%}\n{{ '</think>' }}\n{%- endif -%}\n{%- if content.strip() -%}\n{{ content.strip() }}\n{%- endif -%}\n{% if m.tool_calls %}\n{% for tc in m.tool_calls %}\n{%- if tc.function %}\n    {%- set tc = tc.function %}\n{%- endif %}\n{{- '<tool_call>' + tc.name -}}\n{% set _args = tc.arguments %}{% for k, v in _args.items() %}<arg_key>{{ k }}</arg_key><arg_value>{{ v | tojson(ensure_ascii=False) if v is not string else v }}</arg_value>{% endfor %}</tool_call>{% endfor %}\n{% endif %}\n{%- elif m.role == 'tool' -%}\n{%- if m.content is string -%}\n{%- if loop.first or (messages[loop.index0 - 1].role != \"tool\") %}\n    {{- '<|observation|>' }}\n{%- endif %}\n{{- '<tool_response>' }}\n{{- m.content }}\n{{- '</tool_response>' }}\n{%- else -%}\n<|observation|>{% for tr in m.content %}\n<tool_response>{{ tr.output if tr.output is defined else tr }}</tool_response>{% endfor -%}\n{% endif -%}\n{%- elif m.role == 'system' -%}\n<|system|>{{ visible_text(m.content) }}\n{%- endif -%}\n{%- endfor -%}\n{%- if add_generation_prompt -%}\n    <|assistant|>{{- '</think>' if (enable_thinking is defined and not enable_thinking) else '<think>' -}}\n{%- endif -%}"},"cardData":{"language":["en","zh"],"library_name":"transformers","license":"mit","pipeline_tag":"text-generation"},"transformersInfo":{"auto_model":"AutoModelForCausalLM","pipeline_tag":"text-generation","processor":"AutoTokenizer"},"siblings":[{"rfilename":".eval_results/gpqa.yaml"},{"rfilename":".eval_results/hle.yaml"},{"rfilename":".gitattributes"},{"rfilename":"README.md"},{"rfilename":"chat_template.jinja"},{"rfilename":"config.json"},{"rfilename":"generation_config.json"},{"rfilename":"model-00001-of-00048.safetensors"},{"rfilename":"model-00002-of-00048.safetensors"},{"rfilename":"model-00003-of-00048.safetensors"},{"rfilename":"model-00004-of-00048.safetensors"},{"rfilename":"model-00005-of-00048.safetensors"},{"rfilename":"model-00006-of-00048.safetensors"},{"rfilename":"model-00007-of-00048.safetensors"},{"rfilename":"model-00008-of-00048.safetensors"},{"rfilename":"model-00009-of-00048.safetensors"},{"rfilename":"model-00010-of-00048.safetensors"},{"rfilename":"model-00011-of-00048.safetensors"},{"rfilename":"model-00012-of-00048.safetensors"},{"rfilename":"model-00013-of-00048.safetensors"},{"rfilename":"model-00014-of-00048.safetensors"},{"rfilename":"model-00015-of-00048.safetensors"},{"rfilename":"model-00016-of-00048.safetensors"},{"rfilename":"model-00017-of-00048.safetensors"},{"rfilename":"model-00018-of-00048.safetensors"},{"rfilename":"model-00019-of-00048.safetensors"},{"rfilename":"model-00020-of-00048.safetensors"},{"rfilename":"model-00021-of-00048.safetensors"},{"rfilename":"model-00022-of-00048.safetensors"},{"rfilename":"model-00023-of-00048.safetensors"},{"rfilename":"model-00024-of-00048.safetensors"},{"rfilename":"model-00025-of-00048.safetensors"},{"rfilename":"model-00026-of-00048.safetensors"},{"rfilename":"model-00027-of-00048.safetensors"},{"rfilename":"model-00028-of-00048.safetensors"},{"rfilename":"model-00029-of-00048.safetensors"},{"rfilename":"model-00030-of-00048.safetensors"},{"rfilename":"model-00031-of-00048.safetensors"},{"rfilename":"model-00032-of-00048.safetensors"},{"rfilename":"model-00033-of-00048.safetensors"},{"rfilename":"model-00034-of-00048.safetensors"},{"rfilename":"model-00035-of-00048.safetensors"},{"rfilename":"model-00036-of-00048.safetensors"},{"rfilename":"model-00037-of-00048.safetensors"},{"rfilename":"model-00038-of-00048.safetensors"},{"rfilename":"model-00039-of-00048.safetensors"},{"rfilename":"model-00040-of-00048.safetensors"},{"rfilename":"model-00041-of-00048.safetensors"},{"rfilename":"model-00042-of-00048.safetensors"},{"rfilename":"model-00043-of-00048.safetensors"},{"rfilename":"model-00044-of-00048.safetensors"},{"rfilename":"model-00045-of-00048.safetensors"},{"rfilename":"model-00046-of-00048.safetensors"},{"rfilename":"model-00047-of-00048.safetensors"},{"rfilename":"model-00048-of-00048.safetensors"},{"rfilename":"model.safetensors.index.json"},{"rfilename":"tokenizer.json"},{"rfilename":"tokenizer_config.json"}],"spaces":["VIDraft/global-llm-leaderboard","pliny-the-prompter/obliteratus","akhaliq/anycoder","EuroEval/euroeval_leaderboard","ginigen-ai/smol-worldcup","huggingface-projects/ai-video-composer","hfmlsoc/different-flops","SpyC0der77/zai-org-GLM-4.7-Flash","fantaxy/glm47_flash","Chunte/Top-Downloaded-Trending-Models","rifatSDAS/geoai-coding-agent","Kodacoda/obliteratus","dumbordumber/obliteratus","Highgroundbkk/anycoder","ryonmra/zai-org-GLM-4.7-Flash","ppvbooks/Training","PPVTeam/my-first-ai-app","Josedavison/AceNow","dromero14521/obliteratus","kicfk/obliteratus","aaahmet/obliteratus","rbinrs/obliteratus","Ngixdev/obliteratus","Deadmon/obliteratus","Trkaga/anycoder","ZENLLC/anycoder","PARZ2344/PNGTECH","Rikishini/anycoder","tillu-AI/tillu-unified","Superwolff/anycoder","RavichandranJ/obliteratus","S-Dreamer/obliteratus","AlanaSky/asgaard","marchkamal51/obliteratus","rlearsch/LyricsChatBot","PedroM2626/virtual-assistent","jaremaponka/zai-org-GLM-4.7-Flash","aichein/zai-org-GLM-4.7-Flash","Rahik24/zai-org-GLM-4.7-Flash","cassianrook/anycoder","madmaz/anycoder","Diehard704/anycoder","Amitda/anycoder","eleven011/zai-org-GLM-4.7-Flash","amanpmx/anycoder","lsnnasim/zai-org-GLM-4.7-Flash","Sebestianmek/J_AI_J1","Sanyam400/zai-org-GLM-4.7-Flash","Motam/zai-org-GLM-4.7-Flash","alkasima/zai-org-GLM-4.7-Flash","berylwall/zai-org-GLM-4.7-Flash","ppvbooks/beginner-apps","Jack-Hiks/Astra_AI-ILF","Sajid1974/MCQs","IZONE1712/zai-org-GLM-4.7-Flash","Dhruviioo/zai-org-GLM-4.7-Flash","panchal54/zai-org-GLM-4.7-Flash","asdadsd233/anycoder","indianboyz/anycoder","raheem786/anycoder","ashishninehertz/anycoder","vansh1190/Build","xe1stech/anycoder","wajahat-ali-mir-dev/anycoder","sonu275/zai-org-GLM-4.7-Flash","ghost-logic/anycoder","shreerambhakt/anycoder","Joshua0918/zai-org-GLM-4.7-Flash","mohamedtsou/zai-org-GLM-4.7-Flash","MadhavRupala/anycoder","Linacre/anycoder","BikoRiko/anycoder","z4iXsECHS6ND-heighTSAI-INSEGCSyX6T-SYS-ROD/anycoder","Dulam111/zai-org-GLM-4.7-Flash","crabander/anycoder","Galaxydude2/anycoder","sub314xxl/obliteratus","cw4444/obliteratus","kalmuahlaunda/obliteratus","mastodonitis/obliteratus","GrozniMilitq/obliteratus","liminal4423/obliteratus","bassetone/anycoder","kirikir13/obliteratus","RaccoonStampede/obliteratus","ssanjay22/anycoder","Naj1999/zai-org-GLM-4.7-Flash","aiclass2026/anycoder","ankur030685/coder1","ashlarch100/anycoder","ankur030685/anycoder","ashlarch100/anycoder2","AIMLAtul/anycoder","binsmat/anycoder","cypher109/obliteratus","siu5/ccp","duarffodog/obliteratus","AJ3S/anycoder","TOpNeT7/obliteratus","milkygingers/obliteratus"],"createdAt":"2026-01-19T06:28:10.000Z","safetensors":{"parameters":{"BF16":31221485568,"F32":3008},"total":31221488576},"inference":"warm","usedStorage":62937229623}