Image-Text-to-Text
Transformers
GGUF
English
Chinese
multimodal
text-generation
looped-transformer
mhc
custom_code
conversational
Instructions to use sensenova/SenseNova-Loop-9B-GGUF with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use sensenova/SenseNova-Loop-9B-GGUF with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-text-to-text", model="sensenova/SenseNova-Loop-9B-GGUF", trust_remote_code=True)# pip install -U transformers accelerate # Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("sensenova/SenseNova-Loop-9B-GGUF", trust_remote_code=True, device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- llama.cpp
How to use sensenova/SenseNova-Loop-9B-GGUF with llama.cpp:
Install (macOS, Linux)
curl -LsSf https://llama.app/install.sh | sh # Start a local OpenAI-compatible server with a web UI: llama serve -hf sensenova/SenseNova-Loop-9B-GGUF:Q4_K_M # Run inference directly in the terminal: llama cli -hf sensenova/SenseNova-Loop-9B-GGUF:Q4_K_M
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf sensenova/SenseNova-Loop-9B-GGUF:Q4_K_M # Run inference directly in the terminal: llama cli -hf sensenova/SenseNova-Loop-9B-GGUF:Q4_K_M
Build from source code
git clone https://github.com/ggml-org/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-app # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama serve -hf sensenova/SenseNova-Loop-9B-GGUF:Q4_K_M # Run inference directly in the terminal: ./build/bin/llama cli -hf sensenova/SenseNova-Loop-9B-GGUF:Q4_K_M
Use Docker
docker model run hf.co/sensenova/SenseNova-Loop-9B-GGUF:Q4_K_M
- Llama new
- LM Studio
- Jan
- vLLM
How to use sensenova/SenseNova-Loop-9B-GGUF with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "sensenova/SenseNova-Loop-9B-GGUF" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "sensenova/SenseNova-Loop-9B-GGUF", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }'Use Docker
docker model run hf.co/sensenova/SenseNova-Loop-9B-GGUF:Q4_K_M
- SGLang
How to use sensenova/SenseNova-Loop-9B-GGUF with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "sensenova/SenseNova-Loop-9B-GGUF" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "sensenova/SenseNova-Loop-9B-GGUF", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "sensenova/SenseNova-Loop-9B-GGUF" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "sensenova/SenseNova-Loop-9B-GGUF", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }' - Ollama
How to use sensenova/SenseNova-Loop-9B-GGUF with Ollama:
ollama run hf.co/sensenova/SenseNova-Loop-9B-GGUF:Q4_K_M
- Unsloth Desktop
- Pi
How to use sensenova/SenseNova-Loop-9B-GGUF with Pi:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf sensenova/SenseNova-Loop-9B-GGUF:Q4_K_M
Configure the model in Pi
# Install Pi: npm install -g @earendil-works/pi-coding-agent # Add to ~/.pi/agent/models.json: { "providers": { "llama-cpp": { "baseUrl": "http://localhost:9931/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "sensenova/SenseNova-Loop-9B-GGUF:Q4_K_M" } ] } } }Run Pi
# Start Pi in your project directory: pi
- Docker Model Runner
How to use sensenova/SenseNova-Loop-9B-GGUF with Docker Model Runner:
docker model run hf.co/sensenova/SenseNova-Loop-9B-GGUF:Q4_K_M
- Lemonade
How to use sensenova/SenseNova-Loop-9B-GGUF with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull sensenova/SenseNova-Loop-9B-GGUF:Q4_K_M
Run and chat with the model
lemonade run user.SenseNova-Loop-9B-GGUF-Q4_K_M
List all available models
lemonade list
- Hermes Agent
How to use sensenova/SenseNova-Loop-9B-GGUF with Hermes Agent:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf sensenova/SenseNova-Loop-9B-GGUF:Q4_K_M
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:9931/v1 hermes config set model.default sensenova/SenseNova-Loop-9B-GGUF:Q4_K_M
Run Hermes
hermes
- Atomic Chat
- OpenClaw
How to use sensenova/SenseNova-Loop-9B-GGUF with OpenClaw:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf sensenova/SenseNova-Loop-9B-GGUF:Q4_K_M
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:9931/v1 \ --custom-model-id "sensenova/SenseNova-Loop-9B-GGUF:Q4_K_M" \ --custom-provider-id llama-cpp \ --custom-compatibility openai \ --custom-text-input \ --accept-risk \ --skip-health
Run OpenClaw
openclaw agent --local --agent main --message "Hello from Hugging Face"
Commit ·
384a424
1
Parent(s): 961f260
Add SenseNova-Loop-9B GGUF weights and model card (#1)
Browse files- Add SenseNova-Loop-9B GGUF weights and model card (35670a478bb032e815279b0496f8c501a1eebacd)
Co-authored-by: aaa <[email protected]>
- .gitattributes +13 -0
- LICENSE +201 -0
- README.md +298 -0
- README_CN.md +281 -0
- SenseNova-Loop-9B-BF16.gguf +3 -0
- SenseNova-Loop-9B-Q4_K_M.gguf +3 -0
- SenseNova-Loop-9B-Q5_K_M.gguf +3 -0
- SenseNova-Loop-9B-Q8_0.gguf +3 -0
- assets/hero.png +3 -0
- assets/loop_scaling_zh_latest.png +3 -0
- assets/release_benchmark_iuua.png +3 -0
- assets/showcase_ref_3d.gif +3 -0
- assets/showcase_ref_coast.gif +3 -0
- assets/showcase_ref_orbit.gif +3 -0
- assets/showcase_ref_poster.gif +3 -0
- assets/showcase_ref_web.gif +3 -0
- mmproj-SenseNova-Loop-9B-F16.gguf +3 -0
.gitattributes
CHANGED
|
@@ -33,3 +33,16 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
|
|
| 33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
| 34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
| 34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
| 36 |
+
SenseNova-Loop-9B-BF16.gguf filter=lfs diff=lfs merge=lfs -text
|
| 37 |
+
SenseNova-Loop-9B-Q8_0.gguf filter=lfs diff=lfs merge=lfs -text
|
| 38 |
+
SenseNova-Loop-9B-Q5_K_M.gguf filter=lfs diff=lfs merge=lfs -text
|
| 39 |
+
SenseNova-Loop-9B-Q4_K_M.gguf filter=lfs diff=lfs merge=lfs -text
|
| 40 |
+
mmproj-SenseNova-Loop-9B-F16.gguf filter=lfs diff=lfs merge=lfs -text
|
| 41 |
+
assets/hero.png filter=lfs diff=lfs merge=lfs -text
|
| 42 |
+
assets/loop_scaling_zh_latest.png filter=lfs diff=lfs merge=lfs -text
|
| 43 |
+
assets/release_benchmark_iuua.png filter=lfs diff=lfs merge=lfs -text
|
| 44 |
+
assets/showcase_ref_3d.gif filter=lfs diff=lfs merge=lfs -text
|
| 45 |
+
assets/showcase_ref_coast.gif filter=lfs diff=lfs merge=lfs -text
|
| 46 |
+
assets/showcase_ref_orbit.gif filter=lfs diff=lfs merge=lfs -text
|
| 47 |
+
assets/showcase_ref_poster.gif filter=lfs diff=lfs merge=lfs -text
|
| 48 |
+
assets/showcase_ref_web.gif filter=lfs diff=lfs merge=lfs -text
|
LICENSE
ADDED
|
@@ -0,0 +1,201 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
Apache License
|
| 2 |
+
Version 2.0, January 2004
|
| 3 |
+
http://www.apache.org/licenses/
|
| 4 |
+
|
| 5 |
+
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
| 6 |
+
|
| 7 |
+
1. Definitions.
|
| 8 |
+
|
| 9 |
+
"License" shall mean the terms and conditions for use, reproduction,
|
| 10 |
+
and distribution as defined by Sections 1 through 9 of this document.
|
| 11 |
+
|
| 12 |
+
"Licensor" shall mean the copyright owner or entity authorized by
|
| 13 |
+
the copyright owner that is granting the License.
|
| 14 |
+
|
| 15 |
+
"Legal Entity" shall mean the union of the acting entity and all
|
| 16 |
+
other entities that control, are controlled by, or are under common
|
| 17 |
+
control with that entity. For the purposes of this definition,
|
| 18 |
+
"control" means (i) the power, direct or indirect, to cause the
|
| 19 |
+
direction or management of such entity, whether by contract or
|
| 20 |
+
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
| 21 |
+
outstanding shares, or (iii) beneficial ownership of such entity.
|
| 22 |
+
|
| 23 |
+
"You" (or "Your") shall mean an individual or Legal Entity
|
| 24 |
+
exercising permissions granted by this License.
|
| 25 |
+
|
| 26 |
+
"Source" form shall mean the preferred form for making modifications,
|
| 27 |
+
including but not limited to software source code, documentation
|
| 28 |
+
source, and configuration files.
|
| 29 |
+
|
| 30 |
+
"Object" form shall mean any form resulting from mechanical
|
| 31 |
+
transformation or translation of a Source form, including but
|
| 32 |
+
not limited to compiled object code, generated documentation,
|
| 33 |
+
and conversions to other media types.
|
| 34 |
+
|
| 35 |
+
"Work" shall mean the work of authorship, whether in Source or
|
| 36 |
+
Object form, made available under the License, as indicated by a
|
| 37 |
+
copyright notice that is included in or attached to the work
|
| 38 |
+
(an example is provided in the Appendix below).
|
| 39 |
+
|
| 40 |
+
"Derivative Works" shall mean any work, whether in Source or Object
|
| 41 |
+
form, that is based on (or derived from) the Work and for which the
|
| 42 |
+
editorial revisions, annotations, elaborations, or other modifications
|
| 43 |
+
represent, as a whole, an original work of authorship. For the purposes
|
| 44 |
+
of this License, Derivative Works shall not include works that remain
|
| 45 |
+
separable from, or merely link (or bind by name) to the interfaces of,
|
| 46 |
+
the Work and Derivative Works thereof.
|
| 47 |
+
|
| 48 |
+
"Contribution" shall mean any work of authorship, including
|
| 49 |
+
the original version of the Work and any modifications or additions
|
| 50 |
+
to that Work or Derivative Works thereof, that is intentionally
|
| 51 |
+
submitted to Licensor for inclusion in the Work by the copyright owner
|
| 52 |
+
or by an individual or Legal Entity authorized to submit on behalf of
|
| 53 |
+
the copyright owner. For the purposes of this definition, "submitted"
|
| 54 |
+
means any form of electronic, verbal, or written communication sent
|
| 55 |
+
to the Licensor or its representatives, including but not limited to
|
| 56 |
+
communication on electronic mailing lists, source code control systems,
|
| 57 |
+
and issue tracking systems that are managed by, or on behalf of, the
|
| 58 |
+
Licensor for the purpose of discussing and improving the Work, but
|
| 59 |
+
excluding communication that is conspicuously marked or otherwise
|
| 60 |
+
designated in writing by the copyright owner as "Not a Contribution."
|
| 61 |
+
|
| 62 |
+
"Contributor" shall mean Licensor and any individual or Legal Entity
|
| 63 |
+
on behalf of whom a Contribution has been received by Licensor and
|
| 64 |
+
subsequently incorporated within the Work.
|
| 65 |
+
|
| 66 |
+
2. Grant of Copyright License. Subject to the terms and conditions of
|
| 67 |
+
this License, each Contributor hereby grants to You a perpetual,
|
| 68 |
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
| 69 |
+
copyright license to reproduce, prepare Derivative Works of,
|
| 70 |
+
publicly display, publicly perform, sublicense, and distribute the
|
| 71 |
+
Work and such Derivative Works in Source or Object form.
|
| 72 |
+
|
| 73 |
+
3. Grant of Patent License. Subject to the terms and conditions of
|
| 74 |
+
this License, each Contributor hereby grants to You a perpetual,
|
| 75 |
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
| 76 |
+
(except as stated in this section) patent license to make, have made,
|
| 77 |
+
use, offer to sell, sell, import, and otherwise transfer the Work,
|
| 78 |
+
where such license applies only to those patent claims licensable
|
| 79 |
+
by such Contributor that are necessarily infringed by their
|
| 80 |
+
Contribution(s) alone or by combination of their Contribution(s)
|
| 81 |
+
with the Work to which such Contribution(s) was submitted. If You
|
| 82 |
+
institute patent litigation against any entity (including a
|
| 83 |
+
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
| 84 |
+
or a Contribution incorporated within the Work constitutes direct
|
| 85 |
+
or contributory patent infringement, then any patent licenses
|
| 86 |
+
granted to You under this License for that Work shall terminate
|
| 87 |
+
as of the date such litigation is filed.
|
| 88 |
+
|
| 89 |
+
4. Redistribution. You may reproduce and distribute copies of the
|
| 90 |
+
Work or Derivative Works thereof in any medium, with or without
|
| 91 |
+
modifications, and in Source or Object form, provided that You
|
| 92 |
+
meet the following conditions:
|
| 93 |
+
|
| 94 |
+
(a) You must give any other recipients of the Work or
|
| 95 |
+
Derivative Works a copy of this License; and
|
| 96 |
+
|
| 97 |
+
(b) You must cause any modified files to carry prominent notices
|
| 98 |
+
stating that You changed the files; and
|
| 99 |
+
|
| 100 |
+
(c) You must retain, in the Source form of any Derivative Works
|
| 101 |
+
that You distribute, all copyright, patent, trademark, and
|
| 102 |
+
attribution notices from the Source form of the Work,
|
| 103 |
+
excluding those notices that do not pertain to any part of
|
| 104 |
+
the Derivative Works; and
|
| 105 |
+
|
| 106 |
+
(d) If the Work includes a "NOTICE" text file as part of its
|
| 107 |
+
distribution, then any Derivative Works that You distribute must
|
| 108 |
+
include a readable copy of the attribution notices contained
|
| 109 |
+
within such NOTICE file, excluding those notices that do not
|
| 110 |
+
pertain to any part of the Derivative Works, in at least one
|
| 111 |
+
of the following places: within a NOTICE text file distributed
|
| 112 |
+
as part of the Derivative Works; within the Source form or
|
| 113 |
+
documentation, if provided along with the Derivative Works; or,
|
| 114 |
+
within a display generated by the Derivative Works, if and
|
| 115 |
+
wherever such third-party notices normally appear. The contents
|
| 116 |
+
of the NOTICE file are for informational purposes only and
|
| 117 |
+
do not modify the License. You may add Your own attribution
|
| 118 |
+
notices within Derivative Works that You distribute, alongside
|
| 119 |
+
or as an addendum to the NOTICE text from the Work, provided
|
| 120 |
+
that such additional attribution notices cannot be construed
|
| 121 |
+
as modifying the License.
|
| 122 |
+
|
| 123 |
+
You may add Your own copyright statement to Your modifications and
|
| 124 |
+
may provide additional or different license terms and conditions
|
| 125 |
+
for use, reproduction, or distribution of Your modifications, or
|
| 126 |
+
for any such Derivative Works as a whole, provided Your use,
|
| 127 |
+
reproduction, and distribution of the Work otherwise complies with
|
| 128 |
+
the conditions stated in this License.
|
| 129 |
+
|
| 130 |
+
5. Submission of Contributions. Unless You explicitly state otherwise,
|
| 131 |
+
any Contribution intentionally submitted for inclusion in the Work
|
| 132 |
+
by You to the Licensor shall be under the terms and conditions of
|
| 133 |
+
this License, without any additional terms or conditions.
|
| 134 |
+
Notwithstanding the above, nothing herein shall supersede or modify
|
| 135 |
+
the terms of any separate license agreement you may have executed
|
| 136 |
+
with Licensor regarding such Contributions.
|
| 137 |
+
|
| 138 |
+
6. Trademarks. This License does not grant permission to use the trade
|
| 139 |
+
names, trademarks, service marks, or product names of the Licensor,
|
| 140 |
+
except as required for reasonable and customary use in describing the
|
| 141 |
+
origin of the Work and reproducing the content of the NOTICE file.
|
| 142 |
+
|
| 143 |
+
7. Disclaimer of Warranty. Unless required by applicable law or
|
| 144 |
+
agreed to in writing, Licensor provides the Work (and each
|
| 145 |
+
Contributor provides its Contributions) on an "AS IS" BASIS,
|
| 146 |
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
| 147 |
+
implied, including, without limitation, any warranties or conditions
|
| 148 |
+
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
| 149 |
+
PARTICULAR PURPOSE. You are solely responsible for determining the
|
| 150 |
+
appropriateness of using or redistributing the Work and assume any
|
| 151 |
+
risks associated with Your exercise of permissions under this License.
|
| 152 |
+
|
| 153 |
+
8. Limitation of Liability. In no event and under no legal theory,
|
| 154 |
+
whether in tort (including negligence), contract, or otherwise,
|
| 155 |
+
unless required by applicable law (such as deliberate and grossly
|
| 156 |
+
negligent acts) or agreed to in writing, shall any Contributor be
|
| 157 |
+
liable to You for damages, including any direct, indirect, special,
|
| 158 |
+
incidental, or consequential damages of any character arising as a
|
| 159 |
+
result of this License or out of the use or inability to use the
|
| 160 |
+
Work (including but not limited to damages for loss of goodwill,
|
| 161 |
+
work stoppage, computer failure or malfunction, or any and all
|
| 162 |
+
other commercial damages or losses), even if such Contributor
|
| 163 |
+
has been advised of the possibility of such damages.
|
| 164 |
+
|
| 165 |
+
9. Accepting Warranty or Additional Liability. While redistributing
|
| 166 |
+
the Work or Derivative Works thereof, You may choose to offer,
|
| 167 |
+
and charge a fee for, acceptance of support, warranty, indemnity,
|
| 168 |
+
or other liability obligations and/or rights consistent with this
|
| 169 |
+
License. However, in accepting such obligations, You may act only
|
| 170 |
+
on Your own behalf and on Your sole responsibility, not on behalf
|
| 171 |
+
of any other Contributor, and only if You agree to indemnify,
|
| 172 |
+
defend, and hold each Contributor harmless for any liability
|
| 173 |
+
incurred by, or claims asserted against, such Contributor by reason
|
| 174 |
+
of your accepting any such warranty or additional liability.
|
| 175 |
+
|
| 176 |
+
END OF TERMS AND CONDITIONS
|
| 177 |
+
|
| 178 |
+
APPENDIX: How to apply the Apache License to your work.
|
| 179 |
+
|
| 180 |
+
To apply the Apache License to your work, attach the following
|
| 181 |
+
boilerplate notice, with the fields enclosed by brackets "[]"
|
| 182 |
+
replaced with your own identifying information. (Don't include
|
| 183 |
+
the brackets!) The text should be enclosed in the appropriate
|
| 184 |
+
comment syntax for the file format. We also recommend that a
|
| 185 |
+
file or class name and description of purpose be included on the
|
| 186 |
+
same "printed page" as the copyright notice for easier
|
| 187 |
+
identification within third-party archives.
|
| 188 |
+
|
| 189 |
+
Copyright [yyyy] [name of copyright owner]
|
| 190 |
+
|
| 191 |
+
Licensed under the Apache License, Version 2.0 (the "License");
|
| 192 |
+
you may not use this file except in compliance with the License.
|
| 193 |
+
You may obtain a copy of the License at
|
| 194 |
+
|
| 195 |
+
http://www.apache.org/licenses/LICENSE-2.0
|
| 196 |
+
|
| 197 |
+
Unless required by applicable law or agreed to in writing, software
|
| 198 |
+
distributed under the License is distributed on an "AS IS" BASIS,
|
| 199 |
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
| 200 |
+
See the License for the specific language governing permissions and
|
| 201 |
+
limitations under the License.
|
README.md
ADDED
|
@@ -0,0 +1,298 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
license: apache-2.0
|
| 3 |
+
language:
|
| 4 |
+
- en
|
| 5 |
+
- zh
|
| 6 |
+
library_name: transformers
|
| 7 |
+
pipeline_tag: image-text-to-text
|
| 8 |
+
tags:
|
| 9 |
+
- multimodal
|
| 10 |
+
- text-generation
|
| 11 |
+
- image-text-to-text
|
| 12 |
+
- looped-transformer
|
| 13 |
+
- mhc
|
| 14 |
+
- custom_code
|
| 15 |
+
---
|
| 16 |
+
|
| 17 |
+
# SenseNova-Loop-9B
|
| 18 |
+
|
| 19 |
+
<p align="center">
|
| 20 |
+
<strong>English</strong> | <a href="https://huggingface.co/sensenova/SenseNova-Loop-9B/blob/main/README_CN.md">简体中文</a>
|
| 21 |
+
</p>
|
| 22 |
+
|
| 23 |
+
<p align="center">
|
| 24 |
+
<a href="https://huggingface.co/sensenova/SenseNova-Loop-9B"><img src="https://img.shields.io/badge/%F0%9F%A4%97%20HuggingFace-SenseNova--Loop--9B-yellow" alt="SenseNova-Loop-9B on Hugging Face"></a>
|
| 25 |
+
<a href="https://huggingface.co/sensenova/SenseNova-Loop-9B-Preview"><img src="https://img.shields.io/badge/%F0%9F%A4%97%20HuggingFace-SenseNova--Loop--9B--Preview-yellow" alt="SenseNova-Loop-9B-Preview on Hugging Face"></a>
|
| 26 |
+
<a href="https://modelscope.cn/models/SenseNova/SenseNova-Loop-9B-Preview"><img src="https://img.shields.io/badge/ModelScope-SenseNova--Loop--9B--Preview-624AFF?logo=modelscope&logoColor=white" alt="SenseNova-Loop-9B-Preview on ModelScope"></a>
|
| 27 |
+
<a href="https://github.com/OpenSenseNova/SenseNova-Loop"><img src="https://img.shields.io/badge/GitHub-SenseNova--Loop-181717?logo=github&logoColor=white" alt="GitHub repository"></a>
|
| 28 |
+
<a href="https://github.com/OpenSenseNova/SenseNova-Loop/blob/main/LICENSE"><img src="https://img.shields.io/badge/License-Apache%202.0-blue.svg" alt="Apache 2.0 License"></a>
|
| 29 |
+
<a href="https://huggingface.co/sensenova/SenseNova-Loop-9B-Preview/blob/main/config.json"><img src="https://img.shields.io/badge/Architecture-sensenova__loop-2459B8" alt="sensenova_loop architecture"></a>
|
| 30 |
+
<a href="https://discord.com/invite/BuTXPHmQub"><img src="https://img.shields.io/badge/Discord-Join-5865F2?logo=discord&logoColor=white" alt="Join Discord"></a>
|
| 31 |
+
</p>
|
| 32 |
+
|
| 33 |
+
## 🌐 Architecture
|
| 34 |
+
|
| 35 |
+

|
| 36 |
+
|
| 37 |
+
## 📣 News
|
| 38 |
+
|
| 39 |
+
**🔥 2026-11-17:** We release SenseNova-Loop-9B, with model weights and code available to the community.
|
| 40 |
+
|
| 41 |
+
**🔥 2026-10-31:** We release SenseNova-Loop-9B-Preview, with model weights and code available to the community.
|
| 42 |
+
|
| 43 |
+
## 🚀 SenseNova-Loop-9B: Deeper Computation with Fewer Parameters
|
| 44 |
+
|
| 45 |
+
We officially release SenseNova-Loop-9B. Building on the Preview's exploration of parameter efficiency, the model reuses layer weights through a looped architecture and combines them with manifold-constrained hyper-connections (mHC) to expand computational depth within a compact parameter budget. It is designed for complex reasoning, coding, tool use, and multimodal tasks.
|
| 46 |
+
|
| 47 |
+
Since the Preview release, we have received community interest and feedback on model use, inference deployment, and ecosystem integration. The official release retains the looped architecture and two-stream mHC, further improving performance on agentic, coding, and data analysis tasks while continuing to explore the capabilities of looped computation.
|
| 48 |
+
|
| 49 |
+
SenseNova-Loop-9B has approximately 9B parameters. By repeatedly executing shared middle layers, it extends 32 physical decoder layers into 56 layer executions. The model accepts text and images and generates text, supporting long-context understanding and multi-step tasks. In agentic and data analysis evaluations, the model is competitive with Qwen3.8-27B: it scores 41.36 versus 44.60 on NL2Repo and 65.31 versus 65.01 on AIDABench.
|
| 50 |
+
|
| 51 |
+
### Model Highlights
|
| 52 |
+
|
| 53 |
+
- **Shared looped block:** 24 decoder layers are executed twice in sequence, producing 56 layer computations from 32 distinct layers per forward pass.
|
| 54 |
+
- **Two-stream mHC:** learned mappings route and combine information between two residual streams within the looped block.
|
| 55 |
+
- **Hybrid attention:** the decoder interleaves linear and full attention in a repeating four-layer pattern.
|
| 56 |
+
- **Long-context multimodal training:** the training recipe includes text, images, code, and tool-use trajectories, with the context length extended to 512K tokens.
|
| 57 |
+
- **Low-memory deployment:** With 4-bit weights and an 8-bit KV cache, multimodal inference at a 256K context length requires approximately 15 GiB of GPU memory.
|
| 58 |
+
- **Official quantized release:** An official AWQ 4-bit version is available on launch day for easier deployment.
|
| 59 |
+
|
| 60 |
+
## 🎬 Showcase
|
| 61 |
+
|
| 62 |
+
### 3D
|
| 63 |
+
|
| 64 |
+

|
| 65 |
+
|
| 66 |
+
### SVG + Web
|
| 67 |
+
|
| 68 |
+

|
| 69 |
+
|
| 70 |
+
### Poster
|
| 71 |
+
|
| 72 |
+

|
| 73 |
+
|
| 74 |
+
### Web
|
| 75 |
+
|
| 76 |
+

|
| 77 |
+
|
| 78 |
+
### Design
|
| 79 |
+
|
| 80 |
+

|
| 81 |
+
|
| 82 |
+
## 📊 Model Performance: From Preview to Release
|
| 83 |
+
|
| 84 |
+
We evaluate SenseNova-Loop-9B on agentic, coding, and data analysis tasks, comparing the release with the Preview and other models.
|
| 85 |
+
|
| 86 |
+

|
| 87 |
+
|
| 88 |
+
The release outperforms the Preview on all seven benchmarks shown. AutomationBench rises from 14.33 to 36.67, Terminal-Bench 2.1 from 40.45 to 59.55, and GAIA from 37.86 to 69.90.
|
| 89 |
+
|
| 90 |
+
Compared with Qwen3.8-27B, the release matches its 36.67 on AutomationBench and scores 65.31 versus 65.01 on AIDABench. On NL2Repo, it scores 41.36 versus 44.60. Its BIRD score of 72.34 is 0.96 percentage points above the Preview's 71.38.
|
| 91 |
+
|
| 92 |
+
## 🧠 Model Architecture
|
| 93 |
+
|
| 94 |
+
SenseNova-Loop-9B is built on a 32-layer multimodal decoder combining shared-weight looped computation, hybrid attention, and two-stream manifold-constrained hyper-connections (mHC). It extends computation depth by reusing middle-layer parameters, accepts text and images, generates text, and supports a context length of up to 512K tokens.
|
| 95 |
+
|
| 96 |
+
### Model Specifications
|
| 97 |
+
|
| 98 |
+
| Property | SenseNova-Loop-9B |
|
| 99 |
+
|-|-|
|
| 100 |
+
| Architecture | Autoregressive multimodal decoder; looped block with two-stream mHC |
|
| 101 |
+
| Parameter scale | Approximately 9B total parameters; approximately 14.6B inference-equivalent parameters |
|
| 102 |
+
| Input / output | Text and images / text |
|
| 103 |
+
| Distinct decoder layers | 32 |
|
| 104 |
+
| Looped layer range / passes | [4, 28) / 2, with shared weights |
|
| 105 |
+
| Decoder layer executions | 56 per forward pass |
|
| 106 |
+
| mHC residual streams | 2 |
|
| 107 |
+
| Context length | 512K tokens |
|
| 108 |
+
| Weight precision | BF16 backbone; FP32 mHC routing parameters |
|
| 109 |
+
|
| 110 |
+
### Looped Decoder
|
| 111 |
+
|
| 112 |
+
Inputs first pass through layers 0–3, then through the same block of layers 4–27 twice, and finally through layers 28–31 and the output head. If B denotes the looped block and h its input, the looped computation can be written as B(B(h)).
|
| 113 |
+
|
| 114 |
+
During inference, each forward pass performs 56 decoder-layer computations while storing only 32 sets of decoder-layer weights. The looped block shares the same weights across both passes, with the output of the first pass serving as input to the second.
|
| 115 |
+
|
| 116 |
+
### Hybrid Attention
|
| 117 |
+
|
| 118 |
+
The decoder interleaves linear attention and full attention. Each group of four layers contains three linear-attention layers followed by one full-attention layer. The loop boundaries align with complete four-layer groups, so both passes preserve the same attention pattern.
|
| 119 |
+
|
| 120 |
+
### Two-Stream mHC
|
| 121 |
+
|
| 122 |
+
Within the looped block, mHC uses two residual streams to carry information around decoder-layer computations. Learned mappings determine how each layer reads from the streams, mixes information between them, and writes its output back to the residual state. The stream-mixing map is constrained with Sinkhorn normalization, using 20 iterations in the model configuration.
|
| 123 |
+
|
| 124 |
+
The two streams can be viewed as two sets of hidden states carried in parallel. A looped layer reads from the streams, applies attention or feed-forward computation, and writes its output back. Repeated row and column normalization constrains how information is mixed between the streams. These 20 normalization iterations are internal to mHC and are separate from the two passes through the looped block.
|
| 125 |
+
|
| 126 |
+
The loop range, number of passes, and mHC routing parameters together define the checkpoint's execution configuration. A compatible inference implementation must load these parameters and preserve the same computation order.
|
| 127 |
+
|
| 128 |
+
| Configuration | Value |
|
| 129 |
+
|-|-|
|
| 130 |
+
| Distinct decoder layers / executions | 32 / 56 |
|
| 131 |
+
| Looped layer range / passes | [4, 28) / 2 |
|
| 132 |
+
| Hidden dimension | 4,096 |
|
| 133 |
+
| Feed-forward dimension | 12,288 |
|
| 134 |
+
| Vocabulary size | 248,320 |
|
| 135 |
+
| Full-attention heads / KV heads | 16 / 4 |
|
| 136 |
+
| mHC residual streams / Sinkhorn iterations | 2 / 20 |
|
| 137 |
+
|
| 138 |
+
## 🔬 Loop Scaling: Exploring the Benefits of Looped Computation
|
| 139 |
+
|
| 140 |
+

|
| 141 |
+
|
| 142 |
+
Looped Transformers show promising performance scaling, offering another way to expand model capability through repeated computation. Using the original 9B model with a standard single forward pass (Loop 1) as the baseline, we vary the number of loops while holding the training data and other settings constant. Overall performance improves across the four tasks, with the best results at three or four loops. AIDABench-QA and Workbuddy-office peak at three loops, improving by 6.42% and 16.93% relative to the baseline; LiveCodeBench V6 and AIDABench data visualization peak at four loops, improving by 8.10% and 8.55%.
|
| 143 |
+
|
| 144 |
+
To balance inference efficiency, both the Preview and the release use two loops by default. Deeper loops nevertheless provide further gains: moving from two to four loops improves LiveCodeBench V6 by 1.04 percentage points and AIDABench data visualization by 1.35 percentage points. These experiments cover one to four loops, leaving the potential of deeper looping open for further study.
|
| 145 |
+
|
| 146 |
+
Different tasks respond differently to loop depth. We will continue exploring deeper computation and Dynamic Loop architectures that adapt the number of loops to each input, allocating computation according to task complexity.
|
| 147 |
+
|
| 148 |
+
## 💾 Low-Memory Deployment
|
| 149 |
+
|
| 150 |
+
The shared looped architecture uses approximately 9B distinct parameters. With 4-bit weight quantization, the model weights occupy approximately 4.9 GB. Using an 8-bit or 4-bit KV cache can further reduce memory requirements for long-context inference. The estimated minimum GPU memory requirements for deployment are:
|
| 151 |
+
|
| 152 |
+
| Context length | 8-bit KV cache | 4-bit KV cache |
|
| 153 |
+
| --- | ---: | ---: |
|
| 154 |
+
| 64K | ~10 GiB | ~9 GiB |
|
| 155 |
+
| 128K | ~12 GiB | ~10 GiB |
|
| 156 |
+
| 256K | ~15 GiB | ~12 GiB |
|
| 157 |
+
|
| 158 |
+
## Get Started
|
| 159 |
+
|
| 160 |
+
Use Transformers to load the model from a Hugging Face repository or a local model directory. The examples below cover single-GPU text generation and serving with inference engines.
|
| 161 |
+
|
| 162 |
+
### Requirements
|
| 163 |
+
|
| 164 |
+
The checked Preview environment uses Transformers 5.18.0, PyTorch 2.11.0, and CUDA 13.0. The model directory must include the configuration, tokenizer, chat template, custom model code, and all weight shards.
|
| 165 |
+
|
| 166 |
+
First install a CUDA-compatible build of [PyTorch](https://pytorch.org/get-started/locally/), then install the remaining dependencies:
|
| 167 |
+
|
| 168 |
+
```bash
|
| 169 |
+
python -m pip install "transformers==5.18.0" accelerate safetensors
|
| 170 |
+
```
|
| 171 |
+
|
| 172 |
+
### Text Generation with Transformers
|
| 173 |
+
|
| 174 |
+
Set model_id to the release model directory or repository ID, then run:
|
| 175 |
+
|
| 176 |
+
```python
|
| 177 |
+
import torch
|
| 178 |
+
from transformers import AutoModelForCausalLM, AutoTokenizer
|
| 179 |
+
|
| 180 |
+
model_id = "/path/to/SenseNova-Loop-9B"
|
| 181 |
+
device = "cuda:0"
|
| 182 |
+
|
| 183 |
+
tokenizer = AutoTokenizer.from_pretrained(model_id, trust_remote_code=True)
|
| 184 |
+
model = AutoModelForCausalLM.from_pretrained(
|
| 185 |
+
model_id,
|
| 186 |
+
trust_remote_code=True,
|
| 187 |
+
dtype=torch.bfloat16,
|
| 188 |
+
device_map={"": device},
|
| 189 |
+
).eval()
|
| 190 |
+
|
| 191 |
+
messages = [{"role": "user", "content": "What is 13 times 7?"}]
|
| 192 |
+
prompt = tokenizer.apply_chat_template(
|
| 193 |
+
messages,
|
| 194 |
+
tokenize=False,
|
| 195 |
+
add_generation_prompt=True,
|
| 196 |
+
enable_thinking=True,
|
| 197 |
+
)
|
| 198 |
+
inputs = tokenizer(prompt, return_tensors="pt").to(device)
|
| 199 |
+
with torch.inference_mode():
|
| 200 |
+
outputs = model.generate(
|
| 201 |
+
**inputs,
|
| 202 |
+
max_new_tokens=512,
|
| 203 |
+
do_sample=False,
|
| 204 |
+
use_cache=True,
|
| 205 |
+
)
|
| 206 |
+
response = tokenizer.decode(
|
| 207 |
+
outputs[0, inputs.input_ids.shape[1]:],
|
| 208 |
+
skip_special_tokens=True,
|
| 209 |
+
)
|
| 210 |
+
print(response)
|
| 211 |
+
```
|
| 212 |
+
|
| 213 |
+
The example enables thinking mode, uses greedy decoding, and generates up to 512 new tokens. Set enable_thinking to False to disable thinking, or change device to select a GPU. trust_remote_code=True loads the custom SenseNova Loop model implementation.
|
| 214 |
+
|
| 215 |
+
### Deployment
|
| 216 |
+
|
| 217 |
+
The following commands are adapted from the Preview deployment examples. Replace the model path with the release checkpoint directory; the release engine versions and configurations will be updated with the model.
|
| 218 |
+
|
| 219 |
+
#### LightLLM
|
| 220 |
+
|
| 221 |
+
Four-GPU deployment example:
|
| 222 |
+
|
| 223 |
+
```bash
|
| 224 |
+
docker pull ghcr.io/modeltc/lightllm:main
|
| 225 |
+
|
| 226 |
+
docker run --rm --gpus all --ipc=host -p 8000:8000 \
|
| 227 |
+
-v /path/to/SenseNova-Loop-9B:/model \
|
| 228 |
+
-e LOADWORKER=4 -e LIGHTLLM_TRITON_AUTOTUNE_LEVEL=1 \
|
| 229 |
+
ghcr.io/modeltc/lightllm:main \
|
| 230 |
+
python -m lightllm.server.api_server \
|
| 231 |
+
--model_dir /model --model_name SenseNova-Loop-9B \
|
| 232 |
+
--tp 4 --host 0.0.0.0 --port 8000
|
| 233 |
+
```
|
| 234 |
+
|
| 235 |
+
Once the service is running, send an OpenAI-compatible request:
|
| 236 |
+
|
| 237 |
+
```bash
|
| 238 |
+
curl http://localhost:8000/v1/chat/completions \
|
| 239 |
+
-H 'Content-Type: application/json' \
|
| 240 |
+
-d '{"model": "SenseNova-Loop-9B", "messages": [{"role": "user", "content": "Hello!"}], "max_tokens": 128}'
|
| 241 |
+
```
|
| 242 |
+
|
| 243 |
+
#### SGLang
|
| 244 |
+
|
| 245 |
+
Use the version from [SGLang PR #47281](https://github.com/sgl-project/sglang/pull/47281), which includes the SenseNova Loop implementation, and replace the model path:
|
| 246 |
+
|
| 247 |
+
```bash
|
| 248 |
+
git clone https://github.com/sgl-project/sglang.git
|
| 249 |
+
cd sglang
|
| 250 |
+
git fetch origin pull/47281/head
|
| 251 |
+
git checkout -b sensenova-loop FETCH_HEAD
|
| 252 |
+
python -m pip install -e ./python
|
| 253 |
+
|
| 254 |
+
sglang serve --model-path /path/to/SenseNova-Loop-9B
|
| 255 |
+
```
|
| 256 |
+
|
| 257 |
+
#### vLLM
|
| 258 |
+
|
| 259 |
+
Use the version from [vLLM PR #64832](https://github.com/vllm-project/vllm/pull/64832), which includes the SenseNova Loop implementation, and replace the model path:
|
| 260 |
+
|
| 261 |
+
```bash
|
| 262 |
+
git clone https://github.com/vllm-project/vllm.git
|
| 263 |
+
cd vllm
|
| 264 |
+
git fetch origin pull/64832/head
|
| 265 |
+
git checkout -b sensenova-loop FETCH_HEAD
|
| 266 |
+
python -m pip install -e .
|
| 267 |
+
|
| 268 |
+
vllm serve /path/to/SenseNova-Loop-9B \
|
| 269 |
+
--served-model-name sensenova_loop \
|
| 270 |
+
--tensor-parallel-size 4 \
|
| 271 |
+
--dtype bfloat16
|
| 272 |
+
```
|
| 273 |
+
|
| 274 |
+
### Inference Acceleration
|
| 275 |
+
|
| 276 |
+
SenseNova-Loop supports MTP speculative decoding. DSpark and DFlash2 draft model training instructions are available in [SenseSpec](https://github.com/OpenSenseNova/SenseSpec); available release draft weights and launch settings will be updated with the model.
|
| 277 |
+
|
| 278 |
+
## 🏋️ Training
|
| 279 |
+
|
| 280 |
+
For model fine-tuning, refer to the SenseNova-Loop examples in [OpenSenseNova/torchtitan](https://github.com/OpenSenseNova/torchtitan).
|
| 281 |
+
|
| 282 |
+
Training scripts for DSpark and DFlash2 speculative decoding draft models are available in [OpenSenseNova/SenseSpec](https://github.com/OpenSenseNova/SenseSpec).
|
| 283 |
+
|
| 284 |
+
## ⚠️ Known Limitations
|
| 285 |
+
|
| 286 |
+
Given its size and development time, SenseNova-Loop-9B has room for improvement in the following areas:
|
| 287 |
+
|
| 288 |
+
- **Complex instruction following:** The model may misunderstand or miss requirements when given many complex tool definitions or multiple constraints.
|
| 289 |
+
- **Coding and general agent tasks:** Performance can be inconsistent on coding and general agent tasks. The model can correct some errors through additional steps, but its ability to handle complex, long-horizon tasks still needs improvement.
|
| 290 |
+
- **Complex web generation:** Websites with complex 3D scenes and rich animations may not be completed in a single turn. Some examples require user feedback and two to three rounds of refinement.
|
| 291 |
+
|
| 292 |
+
We will continue to improve the model and plan to apply the Loop architecture to larger models in the future. We welcome community feedback and reports of issues.
|
| 293 |
+
|
| 294 |
+
## 📄 License and Citation
|
| 295 |
+
|
| 296 |
+
The model project is licensed under the [Apache License 2.0](https://github.com/OpenSenseNova/SenseNova-Loop/blob/main/LICENSE).
|
| 297 |
+
|
| 298 |
+
---
|
README_CN.md
ADDED
|
@@ -0,0 +1,281 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# SenseNova-Loop-9B
|
| 2 |
+
|
| 3 |
+
<p align="center">
|
| 4 |
+
<a href="https://huggingface.co/sensenova/SenseNova-Loop-9B">English</a> | <strong>简体中文</strong>
|
| 5 |
+
</p>
|
| 6 |
+
|
| 7 |
+
<p align="center">
|
| 8 |
+
<a href="https://huggingface.co/sensenova/SenseNova-Loop-9B"><img src="https://img.shields.io/badge/%F0%9F%A4%97%20HuggingFace-SenseNova--Loop--9B-yellow" alt="SenseNova-Loop-9B on Hugging Face"></a>
|
| 9 |
+
<a href="https://huggingface.co/sensenova/SenseNova-Loop-9B-Preview"><img src="https://img.shields.io/badge/%F0%9F%A4%97%20HuggingFace-SenseNova--Loop--9B--Preview-yellow" alt="SenseNova-Loop-9B-Preview on Hugging Face"></a>
|
| 10 |
+
<a href="https://modelscope.cn/models/SenseNova/SenseNova-Loop-9B-Preview"><img src="https://img.shields.io/badge/ModelScope-SenseNova--Loop--9B--Preview-624AFF?logo=modelscope&logoColor=white" alt="SenseNova-Loop-9B-Preview on ModelScope"></a>
|
| 11 |
+
<a href="https://github.com/OpenSenseNova/SenseNova-Loop"><img src="https://img.shields.io/badge/GitHub-SenseNova--Loop-181717?logo=github&logoColor=white" alt="GitHub repository"></a>
|
| 12 |
+
<a href="https://github.com/OpenSenseNova/SenseNova-Loop/blob/main/LICENSE"><img src="https://img.shields.io/badge/License-Apache%202.0-blue.svg" alt="Apache 2.0 License"></a>
|
| 13 |
+
<a href="https://huggingface.co/sensenova/SenseNova-Loop-9B-Preview/blob/main/config.json"><img src="https://img.shields.io/badge/Architecture-sensenova__loop-2459B8" alt="sensenova_loop architecture"></a>
|
| 14 |
+
<a href="https://discord.com/invite/BuTXPHmQub"><img src="https://img.shields.io/badge/Discord-Join-5865F2?logo=discord&logoColor=white" alt="Join Discord"></a>
|
| 15 |
+
</p>
|
| 16 |
+
|
| 17 |
+
## 🌐 模型架构
|
| 18 |
+
|
| 19 |
+

|
| 20 |
+
|
| 21 |
+
## 📣 News
|
| 22 |
+
|
| 23 |
+
**🔥 2026-11-17:** 我们正式发布 SenseNova-Loop-9B,开放模型权重与相关代码,欢迎社区下载、部署和探索。
|
| 24 |
+
|
| 25 |
+
**🔥 2026-10-31:** 我们推出 SenseNova-Loop-9B-Preview,开放模型权重与相关代码。
|
| 26 |
+
|
| 27 |
+
## 🚀 SenseNova-Loop-9B:让更少的参数走更深的计算路径
|
| 28 |
+
|
| 29 |
+
我们正式发布 SenseNova-Loop-9B。该模型**延续了 Preview 版本对参数效率的探索**:通过 Loop 结构复用模型层的参数,并结合流形约束超连接(mHC),在有限的参数规模下扩展计算深度,面向复杂推理、代码、工具调用和多模态任务。
|
| 30 |
+
|
| 31 |
+
Preview 发布以来,我们收到了**社区对模型使用、推理部署和生态适配的关注与反馈**。正式版**沿用** Loop 与双流 mHC 的模型结构,**进一步优化**模型在 Agent、代码与数据分析任务中的表现,并继续探索循环计算的能力边界。
|
| 32 |
+
|
| 33 |
+
SenseNova-Loop-9B 使用约 9B 的模型参数,通过循环执行共享的中间层,将 32 个物理解码层扩展为 56 次层计算。模型支持文本与图像输入、文本输出,面向长上下文理解与多步任务。在 Agent 与数据分析评测中,模型展现出与 Qwen3.8-27B 相当的竞争力:NL2Repo 达到 41.36,接近其 44.60;AIDABench 达到 65.31,略高于其 65.01。
|
| 34 |
+
|
| 35 |
+
### 模型亮点
|
| 36 |
+
- **共享循环模块**:24 个解码器层依次执行两遍,使 32 个独立层在一次前向传播中完成 56 次层计算。
|
| 37 |
+
- **双流 mHC**:通过可学习映射,对循环模块中两条残差流的信息进行路由与融合。
|
| 38 |
+
- **混合注意力**:解码器以四层为一组,交替使用线性注意力与全注意力。
|
| 39 |
+
- **长上下文多模态**:训练方案涵盖文本、图像、代码和工具调用轨迹,上下文长度扩展至 512K tokens。
|
| 40 |
+
- **低显存部署**:使用 4-bit 权重和 8-bit KV 缓存时,256K 上下文多模态推理的显存需求约为 15 GiB。
|
| 41 |
+
- **官方量化版同步提供**:模型发布首日提供官方 AWQ 4-bit 量化版本,方便用户快速部署。
|
| 42 |
+
|
| 43 |
+
## 🎬 Showcase
|
| 44 |
+
|
| 45 |
+
### 3D
|
| 46 |
+
|
| 47 |
+

|
| 48 |
+
|
| 49 |
+
### SVG + Web
|
| 50 |
+
|
| 51 |
+

|
| 52 |
+
|
| 53 |
+
### Poster
|
| 54 |
+
|
| 55 |
+

|
| 56 |
+
|
| 57 |
+
### Web
|
| 58 |
+
|
| 59 |
+

|
| 60 |
+
|
| 61 |
+
### Design
|
| 62 |
+
|
| 63 |
+

|
| 64 |
+
|
| 65 |
+
## 📊 模型能力:从 Preview 到正式版
|
| 66 |
+
|
| 67 |
+
我们围绕 **Agent、代码和数据分析任务**评测 SenseNova-Loop-9B,并将正式版与 Preview 及其他模型进行比较。
|
| 68 |
+
|
| 69 |
+

|
| 70 |
+
|
| 71 |
+
正式版在图示的七项评测中均超过 Preview。在 AutomationBench 上,得分从 14.33 提升至 36.67;Terminal-Bench 2.1 从 40.45 提升至 59.55;GAIA 从 37.86 提升至 69.90。
|
| 72 |
+
|
| 73 |
+
与 Qwen3.8-27B 相比,正式版在 AutomationBench 上同为 36.67,在 AIDABench 上以 65.31 略高于 65.01;NL2Repo 得分为 41.36,接近其 44.60。BIRD 得分为 72.34,相比 Preview 的 71.38 提升 0.96 个百分点。
|
| 74 |
+
|
| 75 |
+
## 🧠 模型结构
|
| 76 |
+
|
| 77 |
+
SenseNova-Loop-9B 以 32 层多模态解码器为基础,将共享权重的循环计算、混合注意力和双流流形约束超连接(mHC)结合在一起。模型通过复用中间层参数扩展计算深度,支持文本与图像输入、文本输出,并支持最长 512K token 的上下文。
|
| 78 |
+
|
| 79 |
+
### 模型规格
|
| 80 |
+
|
| 81 |
+
| 项目 | SenseNova-Loop-9B |
|
| 82 |
+
|-|-|
|
| 83 |
+
| 架构 | 自回归多模态解码器;循环模块采用双流 mHC |
|
| 84 |
+
| 参数规模 | 总共约 9B 参数,推理等效参数规模约 14.6B |
|
| 85 |
+
| 输入 / 输出 | 文本和图像 / 文本 |
|
| 86 |
+
| 独立解码器层数 | 32 |
|
| 87 |
+
| 循环层范围 / 执行次数 | [4, 28) / 2 次,共享权重 |
|
| 88 |
+
| 解码器层执行次数 | 每次前向传播执行 56 次 |
|
| 89 |
+
| mHC 残差流数量 | 2 |
|
| 90 |
+
| 上下文长度 | 512K tokens |
|
| 91 |
+
| 权重精度 | 主干为 BF16;mHC 路由参数为 FP32 |
|
| 92 |
+
|
| 93 |
+
#### 循环解码器
|
| 94 |
+
|
| 95 |
+
输入首先经过第 0–3 层,随后依次通过同一组第 4–27 层两次,最后由第 28–31 层和输出头生成模型输出。若用 B 表示循环模块、h 表示其输入,则循环计算可写为 B(B(h))。
|
| 96 |
+
|
| 97 |
+
推理时,模型每次前向传播完成 56 次解码器层计算,只需存储 32 层解码器权重。循环模块在两次执行中复用同一组权重,第二次执行以第一次的输出作为输入。
|
| 98 |
+
|
| 99 |
+
#### 混合注意力
|
| 100 |
+
|
| 101 |
+
解码器交替使用线性注意力层与全注意力层。每四层为一组,依次包含三层线性注意力和一层全注意力。循环模块的边界与完整的四层组对齐,因此两次执行都保持相同的注意力排列。
|
| 102 |
+
|
| 103 |
+
#### 双流 mHC
|
| 104 |
+
|
| 105 |
+
在循环模块中,mHC 使用两条残差流传递解码器层计算前后的信息。可学习映射决定各层如何读取残差流、混合流间信息,以及将层输出写入残差状态。流间混合映射采用 Sinkhorn 归一化进行约束;模型配置使用 20 次迭代。
|
| 106 |
+
|
| 107 |
+
可以将两条残差流理解为并行传递的两组隐藏状态:每个循环层先从残差流读取信息,执行注意力或前馈计算,再把结果写回。流间混合矩阵通过反复进行行、列归一化,约束信息在两条流之间的混合;这 20 次归一化迭代属于 mHC 内部计算,与循环模块执行两遍是不同的步骤。
|
| 108 |
+
|
| 109 |
+
循环层范围、执行次数和 mHC 路由参数共同构成模型检查点的执行配置。兼容的推理实现需要加载这些参数,并保持相同的计算顺序。
|
| 110 |
+
|
| 111 |
+
| 配置 | 数值 |
|
| 112 |
+
|-|-|
|
| 113 |
+
| 独立解码器层数 / 执行次数 | 32 / 56 |
|
| 114 |
+
| 循环层范围 / 执行次数 | [4, 28) / 2 |
|
| 115 |
+
| 隐藏层维度 | 4,096 |
|
| 116 |
+
| 前馈网络维度 | 12,288 |
|
| 117 |
+
| 词表大小 | 248,320 |
|
| 118 |
+
| 全注意力头数 / KV 头数 | 16 / 4 |
|
| 119 |
+
| mHC 残差流数量 / Sinkhorn 迭代次数 | 2 / 20 |
|
| 120 |
+
|
| 121 |
+
## 🔬 Loop Scaling:探索循环计算的收益
|
| 122 |
+
|
| 123 |
+

|
| 124 |
+
|
| 125 |
+
Looped Transformer 展现出良好的性能扩展潜力,为模型能力提升提供了循环计算这一新的探索维度。以原版 9B 模型(即图中对应标准单次前向计算的 Loop 1)为基准,我们在保持训练数据等配置一致的条件下,探索了循环计算的 Scaling 效果。实验结果表明,随着训练与推理循环次数的同步增加,四项核心任务的表现整体提升,最优结果出现在 3–4 次循环。具体而言,AIDAbench-QA 和 Workbuddy-office 任务在 3 次循环时表现最佳,较 9B 基准分别提升了 6.42% 和 16.93%;而在 LiveCodeBench V6 和 AIDAbench-data_visualization 任务中,4 次循环则进一步推高了模型表现,分别实现了 8.10% 和 8.55% 的性能增长。
|
| 126 |
+
|
| 127 |
+
综合考虑实际应用中的推理效率,我们当前的 Preview 和正式版模型均默认采用 2 次循环。然而,深层循环所带来的性能增益依然客观存在。以代码生成(LiveCodeBench V6)和数据可视化(AIDAbench-data_visualization)这两项较为复杂的任务为例,若将循环次数从当前的 2 次增加至 4 次,模型得分仍能分别获得 1.04 和 1.35 个百分点的提升。这一结果印证了 Loop Scaling 的有效性,也表明当前的 1 到 4 次实验只是一个起点,更高循环深度所蕴含的能力空间仍值得进一步挖掘。
|
| 128 |
+
|
| 129 |
+
此外,上述实验结果也直观地反映出,不同类型任务对循环深度的需求存在显著差异。基于这一观察,在后续的研究中,我们不仅会继续探索更高循环深��的能力边界,还将重点研究动态循环(Dynamic Loop)架构。该架构旨在让模型能够根据输入任务的复杂程度,自适应地匹配最优的循环次数,从而在确保复杂任务获得充分算力的同时,兼顾整体的推理效率。
|
| 130 |
+
|
| 131 |
+
## 💾 低显存硬件部署友好
|
| 132 |
+
|
| 133 |
+
得益于 Loop 的循环共享结构,模型仅需约 9B 独立参数,4-bit 量化后权重体积约为 4.9 GB。结合 8-bit 或 4-bit KV 缓存,可以进一步降低长上下文推理的显存需求。不同上下文长度和 KV 缓存精度下,模型部署的最低显存需求如下:
|
| 134 |
+
|
| 135 |
+
| 上下文长度 | 8-bit KV 缓存 | 4-bit KV 缓存 |
|
| 136 |
+
| --- | ---: | ---: |
|
| 137 |
+
| 64K | 约 10 GiB | 约 9 GiB |
|
| 138 |
+
| 128K | 约 12 GiB | 约 10 GiB |
|
| 139 |
+
| 256K | 约 15 GiB | 约 12 GiB |
|
| 140 |
+
|
| 141 |
+
## Get Started
|
| 142 |
+
|
| 143 |
+
使用 Transformers 从 Hugging Face 仓库或本地模型目录加载模型。下方示例展示单张 GPU 上的文本生成,以及使用推理引擎启动服务的方法。
|
| 144 |
+
|
| 145 |
+
### 环境要求
|
| 146 |
+
|
| 147 |
+
Preview 已验证的环境使用 Transformers 5.18.0、PyTorch 2.11.0 和 CUDA 13.0。模型目录需要包含配置、分词器、对话模板、自定义模型代码和全部权重分片。
|
| 148 |
+
|
| 149 |
+
先安装与 CUDA 环境兼容的 [PyTorch](https://pytorch.org/get-started/locally/),再安装其余依赖:
|
| 150 |
+
|
| 151 |
+
```bash
|
| 152 |
+
python -m pip install "transformers==5.18.0" accelerate safetensors
|
| 153 |
+
```
|
| 154 |
+
|
| 155 |
+
### 使用 Transformers 生成文本
|
| 156 |
+
|
| 157 |
+
将 model_id 替换为正式版权重目录或模型仓库 ID,然后运行:
|
| 158 |
+
|
| 159 |
+
```python
|
| 160 |
+
import torch
|
| 161 |
+
from transformers import AutoModelForCausalLM, AutoTokenizer
|
| 162 |
+
|
| 163 |
+
model_id = "/path/to/SenseNova-Loop-9B"
|
| 164 |
+
device = "cuda:0"
|
| 165 |
+
|
| 166 |
+
tokenizer = AutoTokenizer.from_pretrained(model_id, trust_remote_code=True)
|
| 167 |
+
model = AutoModelForCausalLM.from_pretrained(
|
| 168 |
+
model_id,
|
| 169 |
+
trust_remote_code=True,
|
| 170 |
+
dtype=torch.bfloat16,
|
| 171 |
+
device_map={"": device},
|
| 172 |
+
).eval()
|
| 173 |
+
|
| 174 |
+
messages = [{"role": "user", "content": "13 乘以 7 等于多少?"}]
|
| 175 |
+
prompt = tokenizer.apply_chat_template(
|
| 176 |
+
messages,
|
| 177 |
+
tokenize=False,
|
| 178 |
+
add_generation_prompt=True,
|
| 179 |
+
enable_thinking=True,
|
| 180 |
+
)
|
| 181 |
+
inputs = tokenizer(prompt, return_tensors="pt").to(device)
|
| 182 |
+
with torch.inference_mode():
|
| 183 |
+
outputs = model.generate(
|
| 184 |
+
**inputs,
|
| 185 |
+
max_new_tokens=512,
|
| 186 |
+
do_sample=False,
|
| 187 |
+
use_cache=True,
|
| 188 |
+
)
|
| 189 |
+
response = tokenizer.decode(
|
| 190 |
+
outputs[0, inputs.input_ids.shape[1]:],
|
| 191 |
+
skip_special_tokens=True,
|
| 192 |
+
)
|
| 193 |
+
print(response)
|
| 194 |
+
```
|
| 195 |
+
|
| 196 |
+
示例开启思考模式,采用贪心解码并最多生成 512 个新 token。将 enable_thinking 设为 False 可关闭思考模式;修改 device 可选择 GPU。trust_remote_code=True 用于加载 SenseNova Loop 的自定义模型实现。
|
| 197 |
+
|
| 198 |
+
### 部署
|
| 199 |
+
|
| 200 |
+
以下命令参考 Preview 的部署示例,将路径替换为正式版权重目录;正式版对应的引擎版本与配置随发布更新。
|
| 201 |
+
|
| 202 |
+
#### LightLLM
|
| 203 |
+
|
| 204 |
+
以下为四卡 GPU 部署示例:
|
| 205 |
+
|
| 206 |
+
```bash
|
| 207 |
+
docker pull ghcr.io/modeltc/lightllm:main
|
| 208 |
+
|
| 209 |
+
docker run --rm --gpus all --ipc=host -p 8000:8000 \
|
| 210 |
+
-v /path/to/SenseNova-Loop-9B:/model \
|
| 211 |
+
-e LOADWORKER=4 -e LIGHTLLM_TRITON_AUTOTUNE_LEVEL=1 \
|
| 212 |
+
ghcr.io/modeltc/lightllm:main \
|
| 213 |
+
python -m lightllm.server.api_server \
|
| 214 |
+
--model_dir /model --model_name SenseNova-Loop-9B \
|
| 215 |
+
--tp 4 --host 0.0.0.0 --port 8000
|
| 216 |
+
```
|
| 217 |
+
|
| 218 |
+
服务启动后,可以发送 OpenAI 兼容请求:
|
| 219 |
+
|
| 220 |
+
```bash
|
| 221 |
+
curl http://localhost:8000/v1/chat/completions \
|
| 222 |
+
-H 'Content-Type: application/json' \
|
| 223 |
+
-d '{"model": "SenseNova-Loop-9B", "messages": [{"role": "user", "content": "Hello!"}], "max_tokens": 128}'
|
| 224 |
+
```
|
| 225 |
+
|
| 226 |
+
#### SGLang
|
| 227 |
+
|
| 228 |
+
使用包含 SenseNova Loop 实现的 [SGLang PR #47281](https://github.com/sgl-project/sglang/pull/47281) 对应版本,并替换模型路径:
|
| 229 |
+
|
| 230 |
+
```bash
|
| 231 |
+
git clone https://github.com/sgl-project/sglang.git
|
| 232 |
+
cd sglang
|
| 233 |
+
git fetch origin pull/47281/head
|
| 234 |
+
git checkout -b sensenova-loop FETCH_HEAD
|
| 235 |
+
python -m pip install -e ./python
|
| 236 |
+
|
| 237 |
+
sglang serve --model-path /path/to/SenseNova-Loop-9B
|
| 238 |
+
```
|
| 239 |
+
|
| 240 |
+
#### vLLM
|
| 241 |
+
|
| 242 |
+
使用包含 SenseNova Loop 实现的 [vLLM PR #64832](https://github.com/vllm-project/vllm/pull/64832) 对应版本,并替换模型路径:
|
| 243 |
+
|
| 244 |
+
```bash
|
| 245 |
+
git clone https://github.com/vllm-project/vllm.git
|
| 246 |
+
cd vllm
|
| 247 |
+
git fetch origin pull/64832/head
|
| 248 |
+
git checkout -b sensenova-loop FETCH_HEAD
|
| 249 |
+
python -m pip install -e .
|
| 250 |
+
|
| 251 |
+
vllm serve /path/to/SenseNova-Loop-9B \
|
| 252 |
+
--served-model-name sensenova_loop \
|
| 253 |
+
--tensor-parallel-size 4 \
|
| 254 |
+
--dtype bfloat16
|
| 255 |
+
```
|
| 256 |
+
|
| 257 |
+
### 推理加速
|
| 258 |
+
|
| 259 |
+
SenseNova-Loop 支持 MTP 推测解码。DSpark 和 DFlash2 的 draft model 训练方法见 [SenseSpec](https://github.com/OpenSenseNova/SenseSpec);正式版可用的 draft 权重和启动参数将在发布时更新。
|
| 260 |
+
|
| 261 |
+
## 🏋️ Training
|
| 262 |
+
|
| 263 |
+
模型微调可参考 [OpenSenseNova/torchtitan](https://github.com/OpenSenseNova/torchtitan) 中的 SenseNova-Loop 示例。
|
| 264 |
+
|
| 265 |
+
推测解码 draft model 的 DSpark 和 DFlash2 训练脚本见 [OpenSenseNova/SenseSpec](https://github.com/OpenSenseNova/SenseSpec)。
|
| 266 |
+
|
| 267 |
+
## ⚠️ 已知局限
|
| 268 |
+
|
| 269 |
+
受模型体量和迭代时间限制,SenseNova-Loop-9B 在以下方面仍有改进空间:
|
| 270 |
+
|
| 271 |
+
- **复杂指令跟随**:面对较多、较复杂的工具定义或多重条件约束时,模型可能出现理解与执行偏差。
|
| 272 |
+
- **代码与通用 Agent 能力**:模型在代码和通用 Agent 任务中的表现仍有稳定性不足的情况,可以通过更多步骤修正部分错误;处理复杂长程任务的能力仍需提升。
|
| 273 |
+
- **复杂网页生成**:包含复杂 3D 场景和丰富动态元素的网页未必能单轮完成,部分案例需要结合用户反馈,经过 2–3 轮修复才能达到较好的效果。
|
| 274 |
+
|
| 275 |
+
我们将持续改进模型,并计划在未来将 Loop 架构应用于更大规模的模型。欢迎社区分享使用反馈和问题案例。
|
| 276 |
+
|
| 277 |
+
## 📄 License 与引用
|
| 278 |
+
|
| 279 |
+
模型项目采用 [Apache License 2.0](https://github.com/OpenSenseNova/SenseNova-Loop/blob/main/LICENSE)。
|
| 280 |
+
|
| 281 |
+
---
|
SenseNova-Loop-9B-BF16.gguf
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:489f1a439f9794a4cb3cf2eb27d82ebdce8ba3f5627f00c60dd2cca9cb6d81cd
|
| 3 |
+
size 18419909536
|
SenseNova-Loop-9B-Q4_K_M.gguf
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:5528b06c41a92d0a2413e827ab08531be56b10f881606c6659361b5da507eeed
|
| 3 |
+
size 5818631072
|
SenseNova-Loop-9B-Q5_K_M.gguf
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:5f1f7fd99d4153648a5845045f407716c3a8fc8c7d3c600727cdb19ea9fc37d5
|
| 3 |
+
size 6668501920
|
SenseNova-Loop-9B-Q8_0.gguf
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:0db6188dbba93527cfd8e162ad6f8331593025d9f9b9e9a3e846a5faa601a0d1
|
| 3 |
+
size 9798648736
|
assets/hero.png
ADDED
|
Git LFS Details
|
assets/loop_scaling_zh_latest.png
ADDED
|
Git LFS Details
|
assets/release_benchmark_iuua.png
ADDED
|
Git LFS Details
|
assets/showcase_ref_3d.gif
ADDED
|
Git LFS Details
|
assets/showcase_ref_coast.gif
ADDED
|
Git LFS Details
|
assets/showcase_ref_orbit.gif
ADDED
|
Git LFS Details
|
assets/showcase_ref_poster.gif
ADDED
|
Git LFS Details
|
assets/showcase_ref_web.gif
ADDED
|
Git LFS Details
|
mmproj-SenseNova-Loop-9B-F16.gguf
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:1bb6afd085020f555b3dca73b6d2139f3a7b28455228b0f07285d0f0ebc61481
|
| 3 |
+
size 918165984
|