Reinforcement Learning
Transformers
Safetensors
llada
feature-extraction
llm
diffusion-language-model
black-box-optimization
offline-black-box-optimization
design-bench
dibo
custom_code
Instructions to use zpointsun/DiBO-TFBind8 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use zpointsun/DiBO-TFBind8 with Transformers:
# pip install -U transformers accelerate # Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("zpointsun/DiBO-TFBind8", trust_remote_code=True, device_map="auto") - Notebooks
- Google Colab
- Kaggle
Clarify DiBO prompt formatting
Browse filesState that the inherited tokenizer chat template is not used by the DiBO training or evaluation path.
- README.md +10 -5
- SHA256SUMS +20 -19
README.md
CHANGED
|
@@ -50,12 +50,12 @@ from transformers import AutoModel, AutoTokenizer
|
|
| 50 |
repo_id = "zpointsun/DiBO-TFBind8"
|
| 51 |
tokenizer = AutoTokenizer.from_pretrained(
|
| 52 |
repo_id,
|
| 53 |
-
revision="v1.1.
|
| 54 |
trust_remote_code=True,
|
| 55 |
)
|
| 56 |
model = AutoModel.from_pretrained(
|
| 57 |
repo_id,
|
| 58 |
-
revision="v1.1.
|
| 59 |
trust_remote_code=True,
|
| 60 |
use_safetensors=True,
|
| 61 |
torch_dtype="auto",
|
|
@@ -66,6 +66,11 @@ model.eval()
|
|
| 66 |
The packaged tokenizer already includes the four DiBO delimiter tokens. Do not
|
| 67 |
add them or resize embeddings again after loading this export.
|
| 68 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 69 |
## B. Download and load the original checkpoint
|
| 70 |
|
| 71 |
The original artifact uses the released DiBO loader, which initializes the
|
|
@@ -74,7 +79,7 @@ and strictly loads `checkpoint["model"]`.
|
|
| 74 |
|
| 75 |
```bash
|
| 76 |
hf download zpointsun/DiBO-TFBind8 dibo_tfbind8_final.pt \
|
| 77 |
-
--revision v1.1.
|
| 78 |
```
|
| 79 |
|
| 80 |
```python
|
|
@@ -87,7 +92,7 @@ assert LLADA_MODEL_REVISION == "08b83a6feb34df1a6011b80c3c00c7563e963b07"
|
|
| 87 |
checkpoint_path = hf_hub_download(
|
| 88 |
"zpointsun/DiBO-TFBind8",
|
| 89 |
filename="dibo_tfbind8_final.pt",
|
| 90 |
-
revision="v1.1.
|
| 91 |
)
|
| 92 |
model, tokenizer = load_model_and_tokenizer(DEFAULT_MODEL_ID, device="cuda")
|
| 93 |
checkpoint = torch.load(checkpoint_path, map_location="cuda")
|
|
@@ -102,7 +107,7 @@ From a checkout of the released DiBO code and its oracle environment:
|
|
| 102 |
```bash
|
| 103 |
# Standard Transformers export
|
| 104 |
python eval.py --tasks TFBind8-Exact-v0 \
|
| 105 |
-
--model_name_or_path zpointsun/DiBO-TFBind8 --model_revision v1.1.
|
| 106 |
--seeds <SEEDS> --max_attempts 1000
|
| 107 |
|
| 108 |
# Canonical local .pt checkpoint
|
|
|
|
| 50 |
repo_id = "zpointsun/DiBO-TFBind8"
|
| 51 |
tokenizer = AutoTokenizer.from_pretrained(
|
| 52 |
repo_id,
|
| 53 |
+
revision="v1.1.7",
|
| 54 |
trust_remote_code=True,
|
| 55 |
)
|
| 56 |
model = AutoModel.from_pretrained(
|
| 57 |
repo_id,
|
| 58 |
+
revision="v1.1.7",
|
| 59 |
trust_remote_code=True,
|
| 60 |
use_safetensors=True,
|
| 61 |
torch_dtype="auto",
|
|
|
|
| 66 |
The packaged tokenizer already includes the four DiBO delimiter tokens. Do not
|
| 67 |
add them or resize embeddings again after loading this export.
|
| 68 |
|
| 69 |
+
The tokenizer configuration retains LLaDA's `chat_template` metadata, but DiBO
|
| 70 |
+
does not call `apply_chat_template` during training or evaluation. DiBO directly
|
| 71 |
+
tokenizes its rendered unified prompt-response corpus with the delimiter tokens
|
| 72 |
+
above; do not insert chat headers when reproducing the released evaluation path.
|
| 73 |
+
|
| 74 |
## B. Download and load the original checkpoint
|
| 75 |
|
| 76 |
The original artifact uses the released DiBO loader, which initializes the
|
|
|
|
| 79 |
|
| 80 |
```bash
|
| 81 |
hf download zpointsun/DiBO-TFBind8 dibo_tfbind8_final.pt \
|
| 82 |
+
--revision v1.1.7 --local-dir checkpoints/dibo-tfbind8
|
| 83 |
```
|
| 84 |
|
| 85 |
```python
|
|
|
|
| 92 |
checkpoint_path = hf_hub_download(
|
| 93 |
"zpointsun/DiBO-TFBind8",
|
| 94 |
filename="dibo_tfbind8_final.pt",
|
| 95 |
+
revision="v1.1.7",
|
| 96 |
)
|
| 97 |
model, tokenizer = load_model_and_tokenizer(DEFAULT_MODEL_ID, device="cuda")
|
| 98 |
checkpoint = torch.load(checkpoint_path, map_location="cuda")
|
|
|
|
| 107 |
```bash
|
| 108 |
# Standard Transformers export
|
| 109 |
python eval.py --tasks TFBind8-Exact-v0 \
|
| 110 |
+
--model_name_or_path zpointsun/DiBO-TFBind8 --model_revision v1.1.7 \
|
| 111 |
--seeds <SEEDS> --max_attempts 1000
|
| 112 |
|
| 113 |
# Canonical local .pt checkpoint
|
SHA256SUMS
CHANGED
|
@@ -1,19 +1,20 @@
|
|
| 1 |
-
|
| 2 |
-
|
| 3 |
-
|
| 4 |
-
|
| 5 |
-
|
| 6 |
-
|
| 7 |
-
|
| 8 |
-
|
| 9 |
-
|
| 10 |
-
|
| 11 |
-
|
| 12 |
-
|
| 13 |
-
|
| 14 |
-
|
| 15 |
-
|
| 16 |
-
|
| 17 |
-
|
| 18 |
-
|
| 19 |
-
|
|
|
|
|
|
| 1 |
+
model.safetensors.index.json 06db2635e42448b011de23b0b5b4ba22bc1f582ca5af2e745d48123adafc3e27
|
| 2 |
+
special_tokens_map.json 09e3c271fe6b5a3ab93f8a8f3b7239d198c6f5d45eb2eaf8399e4ec5af813dc2
|
| 3 |
+
model-00004-of-00004.safetensors 0a6587d94453234ffa5d0e18cddfde93219c40754a2d5359e0ce1e095f714286
|
| 4 |
+
dibo_tfbind8_final.pt 0d8e17f7aa60baf4173d71a4ec8475d182a992812b59d29a728eec719d1b67bf
|
| 5 |
+
generation_config.json 14d78817248c7e2c9ffe477316ce17b0a51c12e8f5057ddf506ba175991a7a1c
|
| 6 |
+
export_validation.json 1afd19bb061c1f0ae8e664681b84c53a0f12e50daf7464f900e0bc4353b15670
|
| 7 |
+
model-00003-of-00004.safetensors 62c12ec9f508f42811eaa1880dfcb7c4fbca1a48d8379e796d2e8f34f978abfe
|
| 8 |
+
modeling_llada.py 98bac7e53fef0bb7ca01e3716c11a7f710d183e10dbb9783b88db9dbba2e3766
|
| 9 |
+
tokenizer.json 99174cd2c97e90835223e88ed9d7c704f457e725073ca74fcd495b83ba584b56
|
| 10 |
+
7c12b1e90339820f7945f8ea52b08bb1c12e498065227722e3599a99cdbe56dd README.md
|
| 11 |
+
model-00001-of-00004.safetensors b1d0d9d09be47f1c47dff91926fd7f3eda272dc2ecbdd1b1a68f4bf42984473c
|
| 12 |
+
artifact_manifest.json b1d2f6933a003e283cf779b8c46b387bd674d99429db348fe7760063987eab60
|
| 13 |
+
modeling_dibo_llada.py c1d3021bbf2d1291251ea5bc5033f6cbbcdc1e2452285463bae90e0747d8b898
|
| 14 |
+
README.md c5ad7abc64bf9d84fe407ffaa65015297c0b6873855c78c754ab36eb6fbd90d8
|
| 15 |
+
configuration_llada.py c947a64d8b735affa69d5adeb416c83ce607c8925270884e4471ae11068e2bfe
|
| 16 |
+
tokenizer_config.json d6f02013659be27a0d9e2f7fc304f8a95b86ad58c648e9af6bee038feb91cb03
|
| 17 |
+
model-00002-of-00004.safetensors dbe8101a92f660a2c2bd3d5d3dae6cc58f8258ccafc5d487d627f4aa7f48f7ad
|
| 18 |
+
__init__.py ea63d0120e6dac7cfdb9ded5e2f4f9716092ee6f8e1b416b65aa60a8e66164f8
|
| 19 |
+
config.json fa264b764d6e0efe12731bd63bed9725795e188458de4192d418759f3cc9407f
|
| 20 |
+
UPSTREAM_NOTICE.md ffaa3217d5f7d83a027fca9df0070c0082726c6770f44bb94f1caf931036539b
|