Nirvana让大模型在专业领域实时自适应,像有记忆的专家。
Nirvana: A Specialized Generalist Model With Task-Aware Memory Mechanism
- 用任务感知记忆机制动态调整参数,实现快速领域适配。
- 在生物、金融、法律等领域表现超越通用大模型,磁共振重建精度更高。
- 适合需要快速适配新领域的应用,如医疗影像分析。
大型语言模型在通用语言任务中表现优异,但在专业领域表现不佳。专用通用模型(SGM)在保持广泛能力的同时适应特定领域,但现有架构对任务引导的记忆机制支持有限。本文提出Nirvana,一种具备专用记忆、线性时间复杂度和测试时任务信息提取能力的SGM。核心包括:(1) 任务感知记忆触发器(Trigger),将每个输入视为自监督微调任务,实时调整相关参数;(2) 专用记忆更新器(Updater),动态整合任务相关的上下文。Nirvana在通用基准上达到或超过主流大模型表现,在生物医学、金融、法律等专用领域取得最低困惑度。在磁共振成像(MRI)任务中,通过在冻结的Nirvana主干上附加轻量级编码器,并在配对的k空间信号与图像上微调,Nirvana实现了比传统基于LLM模型更高的重建保真度,且Trigger提供了有效的领域特异性适应。消融实验表明,移除Trigger会导致所有任务性能显著下降,凸显其在任务感知专业化中的关键作用。模型可访问https://huggingface.co/collections/YuhuaJiang/nirvana,代码见https://github.com/YuhuaJiang2002/Nirvana。
原文摘要 · Abstract (English)
Large Language Models (LLMs) excel at general language tasks but struggle in specialized domains. Specialized Generalist Models (SGMs) address this by preserving broad capabilities while adapting to target domains. However, existing architectures provide limited support for task-guided specialized memory mechanisms. In this work, we introduce Nirvana, an SGM featuring specialized memory, linear-time complexity, and test-time task information extraction. Central to Nirvana are: (1) Task-Aware Memory Trigger ($\textit{Trigger}$), which treats each input as a self-supervised fine-tuning task and adjusts task-related parameters on the fly; and (2) Specialized Memory Updater ($\textit{Updater}$), which dynamically consolidates task-relevant context. Nirvana matches or surpasses LLM baselines on general benchmarks and achieves the lowest perplexity across specialized domains including biomedicine, finance, and law. On the challenging task of Magnetic Resonance Imaging (MRI), we attach lightweight codecs to the frozen Nirvana backbone and fine-tune them on paired k-space signals and images. Nirvana achieves higher-fidelity reconstructions than conventional LLM-based models, with Trigger providing effective domain-specific adaptation. Ablation studies confirm that removing Trigger leads to substantial degradation across all tasks, underscoring its essential role in task-aware specialization. Models are available at https://huggingface.co/collections/YuhuaJiang/nirvana. Code is available at https://github.com/YuhuaJiang2002/Nirvana.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。