ChatPaper.aiChatPaper

DARE: 분포 인식 검색을 통한 LLM 에이전트와 R 통계 생태계의 연동

DARE: Aligning LLM Agents with the R Statistical Ecosystem via Distribution-Aware Retrieval

March 5, 2026
저자: Maojun Sun, Yue Wu, Yifei Xie, Ruijian Han, Binyan Jiang, Defeng Sun, Yancheng Yuan, Jian Huang
cs.AI

초록

대규모 언어 모델(LLM) 에이전트는 데이터 과학 워크플로우를 자동화할 수 있지만, R로 구현된 많은 엄격한 통계 방법론들은 LLM의 통계 지식 및 도구 검색 한계로 인해 활용도가 낮은 실정입니다. 기존 검색 강화 접근법은 함수 수준의 의미론에 집중하고 데이터 분포를 간과하여 최적이 아닌 검색 결과를 생성합니다. 본 연구에서는 R 패키지 검색을 위해 데이터 분포 정보를 함수 표현에 통합한 경량 플러그앤플레이 검색 모델인 DARE(분포 인식 검색 임베딩)를 제안합니다. 주요 기여점은 다음과 같습니다: (i) 8,191개의 고품질 CRAN 패키지에서 도출한 정제된 R 패키지 지식 베이스(RPKB); (ii) 검색 관련성 향상을 위해 분포 특성과 함수 메타데이터를 융합한 임베딩 모델 DARE; (iii) 신뢰할 수 있는 R 코드 생성을 위한 R 지향 LLM 에이전트 RCodingAgent 및 현실적인 분석 시나리오에서 LLM 에이전트를 체계적으로 평가하기 위한 일련의 통계 분석 태스크입니다. 실험적으로 DARE는 93.47%의 NDCG@10를 달성하여 최첨단 오픈소스 임베딩 모델 대비 최대 17% 성능 향상을 보였으며, 매개변수 수는 현저히 적게 사용했습니다. DARE를 RCodingAgent에 통합하면 다운스트림 분석 태스크에서도 상당한 성능 향상을 확인했습니다. 본 연구는 LLM 자동화와 성숙된 R 통계 생태계 간의 격차를 해소하는 데 기여합니다.
English
Large Language Model (LLM) agents can automate data-science workflows, but many rigorous statistical methods implemented in R remain underused because LLMs struggle with statistical knowledge and tool retrieval. Existing retrieval-augmented approaches focus on function-level semantics and ignore data distribution, producing suboptimal matches. We propose DARE (Distribution-Aware Retrieval Embedding), a lightweight, plug-and-play retrieval model that incorporates data distribution information into function representations for R package retrieval. Our main contributions are: (i) RPKB, a curated R Package Knowledge Base derived from 8,191 high-quality CRAN packages; (ii) DARE, an embedding model that fuses distributional features with function metadata to improve retrieval relevance; and (iii) RCodingAgent, an R-oriented LLM agent for reliable R code generation and a suite of statistical analysis tasks for systematically evaluating LLM agents in realistic analytical scenarios. Empirically, DARE achieves an NDCG at 10 of 93.47%, outperforming state-of-the-art open-source embedding models by up to 17% on package retrieval while using substantially fewer parameters. Integrating DARE into RCodingAgent yields significant gains on downstream analysis tasks. This work helps narrow the gap between LLM automation and the mature R statistical ecosystem.
PDF453March 9, 2026