Views
No views yet
This HuggingFace repository holds only the weights and data (data/,results/). The code lives on GitHub — clone it there, then download this bundle into the repo root as shown below.

| Model | Params | Clin-F1 | BLEU-4 | ROUGE-L | LLaMA |
|---|---|---|---|---|---|
| CT-CHAT (repro.) | 8B | 0.224 | 0.188 | 0.303 | 6.73 |
| CT-CHAT (repro.) | 70B | 0.161 | 0.182 | 0.321 | 6.02 |
| BTB3D | 8B | 0.258 | 0.213 | — | — |
| CT-Agent | — | 0.420 | 0.231 | 0.490 | — |
| Base (ViSD-Boost + CT-CLIP) | 8B | 0.455 | 0.205 | 0.315 | 7.30 |
| AdaRAG-CT | 8B | 0.480 | 0.242 | 0.354 | 7.75 |
| Base (ViSD-Boost + CT-CLIP) | 70B | 0.405 | 0.213 | 0.334 | 7.10 |
| AdaRAG-CT | 70B | 0.426 | 0.250 | 0.361 | 7.53 |
1conda create -n adaragct python=3.12 && conda activate adaragct
2pip install -r requirements.txtmeta-llama/Llama-3.1-8B-Instruct (8B)
and meta-llama/Llama-3.3-70B-Instruct (70B).
Only training needs them; evaluation and inference run from the released checkpoints alone.
Point model.model_path in the training configs at your local copy.1# 8B track only: data + Base 8B + AdaRAG-CT 8B (~45 GB)
2huggingface-cli download LiangRenjie/AdaRAG-CT --repo-type model --local-dir . \
3 --include "data/*" "results/base_8b/*" "results/adaragct_8b/*"
4
5# everything, including the 70B checkpoints (~200 GB)
6huggingface-cli download LiangRenjie/AdaRAG-CT --repo-type model --local-dir . \
7 --include "data/*" "results/*"data/ (embeddings, annotations, oracle/retrieval contexts) and
results/{base,adaragct}_{8b,70b}/. Four checkpoints: Base 8B/70B (standalone merged models)
and AdaRAG-CT 8B/70B (LoRA adapter + projector, loaded on top of the matching base).
The released predictions, metrics, and training logs under results/ already ship with this repo.data/embeddings/ instead.python -m adaragct.eval.cal_metrics results/adaragct_8b/infer_step_2000.jsonl --output metrics.json--compute-llama-score for the LLaMA score, --bootstrap 1000 for 95% confidence intervals.1# AdaRAG-CT (adaptive retrieval)
2python -m adaragct.inference.inference_rag --checkpoint results/adaragct_8b/checkpoint_step_2000 --output pred.jsonl
3
4# Base / no-retrieval (same checkpoint, retrieval disabled)
5python -m adaragct.inference.inference_rag --checkpoint results/adaragct_8b/checkpoint_step_2000 --no-rag --output base_pred.jsonl
6
7python -m adaragct.eval.cal_metrics pred.jsonl --output metrics.json--no-rag (disable retrieval), --text2text (Text2Text retrieval pipeline), --oracle (oracle context), --top-k, --max-retrievals.data/retrieval/; it auto-downloads microsoft/BiomedVLP-CXR-BERT-specialized on first run). For a download-free run, use --oracle (precomputed contexts). To reproduce the exact paper numbers, score the released predictions in results/.[RAG] trigger token on top of a frozen base model via LoRA, mixing oracle and retrieved contexts. Every required input — base checkpoint, CT embeddings, and the precomputed oracle/retrieval contexts — comes from the HuggingFace bundle, so training runs directly with no extra preprocessing:1# 8B
2python -m adaragct.train.train_rag --config configs/adaragct_8b.yaml
3# 70B
4python -m adaragct.train.train_rag --config configs/adaragct_70b.yamldata/ (embeddings, oracle_context_top3.jsonl, retrieval_context_top3.jsonl) and a base checkpoint under results/.adaragct.train.train_base.
Download the released Base checkpoints if you only want to train AdaRAG-CT on top of them;
the steps below are for reproducing a Base checkpoint from scratch.train_projector_only: true). The LLM is frozen and only
the five projectors (whole-CT + lung/heart/esophagus/aorta) are trained, to align the visual
embeddings with the LLM hidden space. Saves checkpoints/step_N/projector.pt.1python -m adaragct.train.train_base --config configs/base_8b_projector.yaml # 8B
2python -m adaragct.train.train_base --config configs/base_70b_projector.yaml # 70Bfreeze_projector: true). Loads a Stage-1 projector through
model.pretrain_checkpoint, freezes it, and trains LoRA + embed_tokens/lm_head.
Set model.pretrain_checkpoint to the Stage-1 step you want (the released models used step 9000),
then:1python -m adaragct.train.train_base --config configs/base_8b.yaml # 8B
2python -m adaragct.train.train_base --config configs/base_70b.yaml # 70Bmodel.model_path (this is the format the
released results/base_8b/checkpoint is in):1python -m adaragct.tools.merge_peft_checkpoint \
2 --peft-dir results/train/base_8b/checkpoints/step_5000 \
3 --output-dir results/base_8b/checkpointadaragct/tools/ also holds convert_base_checkpoint.py / convert_rag_checkpoint.py
for converting older single-file .pt checkpoints into the PEFT folder format.1@misc{liang2026embeddingbottleneckadaptiveretrievalaugmented,
2 title={Beyond the Embedding Bottleneck: Adaptive Retrieval-Augmented 3D CT Report Generation},
3 author={Renjie Liang and Yiling Ma and Yang Xing and Zhengkang Fan and Jinqian Pan and Chengkun Sun and Li Li and Kuang Gong and Jie Xu},
4 year={2026},
5 eprint={2603.15822},
6 archivePrefix={arXiv},
7 primaryClass={cs.CV},
8 url={https://arxiv.org/abs/2603.15822},
9}