Skip to main content
QUICK REVIEW

[논문 리뷰] EyeLayer: Integrating Human Attention Patterns into LLM-Based Code Summarization

Jiahao Zhang, Yifan Zhang|arXiv (Cornell University)|2026. 02. 25.
Software Engineering Research인용 수 0
한 줄 요약

EyeLayer는 코드 요약을 위한 디코더- 및 인코더 기반 모델에 인간의 시선 추적 기반 주의 priors를 추가하여, 아키텍처에 관계없이 일관된 이득과 BLEU-4에서 최대 13.17% 개선을 제공합니다.

ABSTRACT

Code summarization is the task of generating natural language descriptions of source code, which is critical for software comprehension and maintenance. While large language models (LLMs) have achieved remarkable progress on this task, an open question remains: can human expertise in code understanding further guide and enhance these models? We propose EyeLayer, a lightweight attention-augmentation module that incorporates human eye-gaze patterns, as a proxy of human expertise, into LLM-based code summarization. EyeLayer models human attention during code reading via a Multimodal Gaussian Mixture, redistributing token embeddings based on learned parameters (μ_i, σ_i^2) that capture where and how intensively developers focus. This design enables learning generalizable attention priors from eye-tracking data and incorporating them into LLMs seamlessly, without disturbing existing representations. We evaluate EyeLayer across diverse model families (i.e., LLaMA-3.2, Qwen3, and CodeBERT) covering different scales and architectures. EyeLayer consistently outperforms strong fine-tuning baselines across standard metrics, achieving gains of up to 13.17% on BLEU-4. These results demonstrate that human gaze patterns encode complementary attention signals that enhance the semantic focus of LLMs and transfer effectively across diverse models for code summarization.

연구 동기 및 목표

  • 인간의 주의 신호가 표준 미세 조정 이상으로 LLM 기반 코드 요약을 향상시킬 수 있는지 여부를 연구한다.
  • 눈 추적 데이터를 priors로 사용하는 경량화되고 이전 가능한 주의 보강 모듈을 제안한다.
  • 다양한 모델 계열과 규모에 걸친 접근법의 일반화 성능을 입증한다.
  • 재현성을 위한 구현 및 데이터셋을 공개한다.

제안 방법

  • 학습된 가우시안 혼합을 통해 코드 토큰 임베딩을 재분배하는 다중모달 가우시안 EyeLayer를 도입한다.
  • compact한 코드 임베딩에서 가우시안 매개변수(mu_k, sigma_k^2)을 예측하고 활성 모드를 선택하는 스파스 게이팅 메커니즘을 사용한다.
  • 디코더-전용 트랜스포머의 은닉 상태에 인과성을 보존하면서 인과 의식적 잔차 교란을 통해 인간 정렬 주의를 주입한다.
  • 세 단계의 AST-서브토큰 정렬 파이프라인을 통해 시선 추적 데이터를 부분토큰 표현으로 연결한다.
  • L_gen + L_align으로 PCGrad를 사용하여 상충하는 그래디언트를 관리하며 코드 요약 데이터와 보조 시선 추적 정렬 데이터를 함께 학습한다.
  • CodeXGLUE Java 벤치마크에서 BLEU-4, ROUGE-L, METEOR, BERTScore를 사용하여 다섯 모델(CodeBERT, LLaMA-3.2 1B/3B, Qwen-3 1.7B/4B)을 평가한다.
Figure 1 . Overview of our joint training pipeline.
Figure 1 . Overview of our joint training pipeline.

실험 결과

연구 질문

  • RQ1RQ1: EyeLayer가 표준 감독 미세 조정보다 코드 요약 품질을 향상시키는가?
  • RQ2RQ2: 트랜스포머 스택 내 EyeLayer의 위치가 성능에 어떤 영향을 미치는가?
  • RQ3RQ3: EyeLayer가 인코더 전용 아키텍처에 얼마나 잘 일반화되는가?
  • RQ4RQ4: 다중모달 설계의 기여가 성능에 미치는 영향은 무엇인가?

주요 결과

ModelBLEU-4ROUGE-LMETEORBERTScore
Llama3.2-1B14.3122.1227.4587.55
Llama3.2-1B + EyeLayer16.1823.5129.3388.51
Llama3.2-3B15.6424.5729.8388.29
Llama3.2-3B + EyeLayer16.8625.2531.0488.72
Qwen3-1.7B13.3621.3926.6086.04
Qwen3-1.7B + EyeLayer15.1226.6732.0386.38
Qwen3-4B15.2423.7329.4585.87
Qwen3-4B + EyeLayer17.2225.3031.3186.27
  • EyeLayer는 평가된 모든 모델과 지표에서 일관된 개선을 보여준다.
  • BLEU-4 개선은 일부 모델에서 최대 1.98 포인트에 이른다(예: Qwen-3 4B).
  • Qwen-3-1.7B는 ROUGE-L과 METEOR에서 각각 5.28과 5.43의 상당한 증가를 보인다.
  • 디코더-전용 모델에서 EyeLayer는 어휘적 및 의미적 지표(BLEU, ROUGE, METEOR, BERTScore)에서 이득을 보인다.
  • 이 접근법은 아키텍처 간 이전 가능성과 대형 LLM 및 소형 인코더로의 확장성을 입증한다.
  • EyeLayer는 평가 설정에서 최대 13.17%의 절대 BLEU-4 이득을 달성한다(초록에 명시됨).
Figure 2 . The Multimodal Gaussian EyeLayer architecture.
Figure 2 . The Multimodal Gaussian EyeLayer architecture.

더 나은 연구,지금 바로 시작하세요

연구 설계부터 논문 작성까지, 연구 시간을 획기적으로 줄여보세요.

카드 등록 없음 · 무료 플랜 제공

이 리뷰는 AI가 만들고, 인간 에디터가 검토했습니다.