Views
No views yet
| Thinking Steps (K) | R@1 | BLEU | ROUGE-1 |
|---|---|---|---|
| K=0 (no thinking) | 0.002 | 0.000 | 0.000 |
| K=1 | 0.064 | 0.000 | 0.028 |
| K=2 | 0.256 | 0.009 | 0.084 |
| K=4 | 0.504 | 0.044 | 0.218 |
| K=8 | 0.474 | 0.231 | 0.594 |
| K=16 | 0.406 | 0.185 | 0.542 |
1from src.models.lc_thought import LCThought
2from src.utils.checkpoint import load_checkpoint
3import torch, yaml
4from types import SimpleNamespace
5
6# Load config and model
7cfg = yaml.safe_load(open("configs/decoder.yaml"))
8model = LCThought(cfg)
9load_checkpoint("checkpoints/stage3/step_0050000.pt", model)
10model.eval()
11
12# Inference
13answers = model.generate(q_ids, q_mask, n_steps=8)