Exploring How LLMs Capture and Represent Domain-Specific Knowledge

Fuente: arXiv
Guardado en:
Detalles Bibliográficos
Autores principales: Garcia, Mirian Hipolito, Couturier, Camille, Diaz, Daniel Madrigal, Mallick, Ankur, Kyrillidis, Anastasios, Sim, Robert, Ruhle, Victor, Rajmohan, Saravan
Formato: Preprint
Publicado: 2025
Materias:
Acceso en línea:
Etiquetas: Agregar Etiqueta
Sin Etiquetas, Sea el primero en etiquetar este registro!
_version_ 1866913806901313536
author Garcia, Mirian Hipolito
Couturier, Camille
Diaz, Daniel Madrigal
Mallick, Ankur
Kyrillidis, Anastasios
Sim, Robert
Ruhle, Victor
Rajmohan, Saravan
author_facet Garcia, Mirian Hipolito
Couturier, Camille
Diaz, Daniel Madrigal
Mallick, Ankur
Kyrillidis, Anastasios
Sim, Robert
Ruhle, Victor
Rajmohan, Saravan
contents We study whether Large Language Models (LLMs) inherently capture domain-specific nuances in natural language. Our experiments probe the domain sensitivity of LLMs by examining their ability to distinguish queries from different domains using hidden states generated during the prefill phase. We reveal latent domain-related trajectories that indicate the model's internal recognition of query domains. We also study the robustness of these domain representations to variations in prompt styles and sources. Our approach leverages these representations for model selection, mapping the LLM that best matches the domain trace of the input query (i.e., the model with the highest performance on similar traces). Our findings show that LLMs can differentiate queries for related domains, and that the fine-tuned model is not always the most accurate. Unlike previous work, our interpretations apply to both closed and open-ended generative tasks
format Preprint
id arxiv_https___arxiv_org_abs_2504_16871
institution arXiv
publishDate 2025
record_format arxiv
spellingShingle Exploring How LLMs Capture and Represent Domain-Specific Knowledge
Garcia, Mirian Hipolito
Couturier, Camille
Diaz, Daniel Madrigal
Mallick, Ankur
Kyrillidis, Anastasios
Sim, Robert
Ruhle, Victor
Rajmohan, Saravan
Machine Learning
We study whether Large Language Models (LLMs) inherently capture domain-specific nuances in natural language. Our experiments probe the domain sensitivity of LLMs by examining their ability to distinguish queries from different domains using hidden states generated during the prefill phase. We reveal latent domain-related trajectories that indicate the model's internal recognition of query domains. We also study the robustness of these domain representations to variations in prompt styles and sources. Our approach leverages these representations for model selection, mapping the LLM that best matches the domain trace of the input query (i.e., the model with the highest performance on similar traces). Our findings show that LLMs can differentiate queries for related domains, and that the fine-tuned model is not always the most accurate. Unlike previous work, our interpretations apply to both closed and open-ended generative tasks
title Exploring How LLMs Capture and Represent Domain-Specific Knowledge
topic Machine Learning
url https://arxiv.org/abs/2504.16871