PyTorchKR Papers

최신 논문

총 5편
태그·기간 등 상세 필터

카테고리 탐색

로그인 후 이 태그 구독

arXiv:2606.28105v2cond-mat.dis-nn

Random Language Model의 스케일링 극한

Scaling limit of the Random Language Model

We develop a quantitative theory of the Random Language Model (RLM), an ensemble of stochastic context-free grammars, in a scaling limit where the number of hidden symbols $N \to \infty$ while the grammar temperature $\tilde\epsilon_d \to 0$ at fixed $x = \tilde\epsilon_d \log N$. In this limit, the model admits a controlled description based on a large-deviation principle over rule-usage patterns. A semi-annealed approximation maps the problem to a class of Random Energy Models with nontrivial combinatorics. We show that the RLM exhibits a freezing transition at a critical value $x_c=1/8$, below which rule usage condenses on a subset of preferred rules and language statistics acquire a nontrivial dependence on corpus length. A second characteristic scale at $x=1/2$, associated with the breakdown of Gaussian fluctuations, separates transition and babbling regimes. Across regimes, we derive explicit scaling laws for the number of distinct rules, entropy, and energy, identifying distinct frozen and critical regimes controlled by the interplay of grammar size, corpus length, and temperature. The theory resolves previous ambiguities regarding the existence of a thermodynamic transition and explains the slow approach to the large-$N$ limit as a consequence of the dependence on $\log N$. It further provides a unified framework in which universal statistical properties of language emerge from typical realizations of generative grammars, with implications for both natural language statistics and the behavior of large language models. Heaps' law and Zipf's law are both derived, and the dependence of predictive entropy on context length is rationalized. Comparison with empirical measurements of Heaps' and Zipf's laws yields parameter estimates for real languages.

arXiv:2605.29986v2cs.AI

토큰 공간 압축을 통한 제약 조건 디코딩 가속화

Accelerating Constrained Decoding with Token Space Compression

대규모 언어 모델(LLM)의 출력이 지정된 구조를 따르도록 보장하기 위해, 문맥 자유 문법(CFG) 디코딩 엔진은 다음 토큰(token) 선택을 강제하여 주어진 CFG를 준수하는 문자열을 생성합니다. 현재의 CFG 기반 제약 조건 디코딩 엔진은 고도로 최적화되어 있지만, 단계별 탐색 공간이 방대하다는 점(즉, 전체 토큰 어휘 집합)에서 비롯되는 본질적인 비용으로 인해 여전히 어려움을 겪고 있습니다. 이는 CFG 엔진이 가장 유용한 상황인 더 복잡한 CFG에서 감당하기 힘들 정도로 높은 오버헤드를 발생시킵니다. 본 논문에서는 토큰 탐색 공간을 압축하여 CFG 엔진 오버헤드를 대폭 줄이는 오프라인 기법인 CFGzip을 소개합니다. 실험을 통해 배치 추론(inference) 중 최대 75배의 지연 시간 단축을 보고하며, 가장 까다로운 문법에서도 오버헤드를 약 1.2~2배 수준으로 줄입니다. CFGzip을 통해 이제 복잡한 CFG에 대해서도 대규모 제약 조건 디코딩이 가능해졌습니다.

arXiv:2607.20483v1cs.AI

자기회귀 언어 모델의 계산 가능한 계층적 제어

Tractable Hierarchical Control of Autoregressive Language Models

자기회귀 대규모 언어 모델(LLM)의 생성을 제약하는 것은 언어 모델을 형식 시스템에 통합하는 데 있어 중요한 구성 요소이다. 프로그램 합성과 같은 작업을 위한 코드 및 데이터 생성에서, 언어 모델이 구문적으로 유효한 출력을 생성하도록 보장하는 것은 그러한 출력을 처리하기 위한 전제 조건이다. 이러한 언어(SQL이나 JSON 등)는 종종 $LR(k)$ 문맥 자유 문법으로 설계된다. LLM을 계산 가능한 확률 모델로 증류함으로써, 그 자기회귀 생성을 조향하고 마스킹하여 논리적 제약을 만족할 확률을 반영할 수 있으며, 유효성이 보장된 고품질 출력을 확보할 수 있다. 본 논문은 유한 지속을 갖는 임의의 $LR(k)$ 문법에 대한 만족을 다항 시간에 계산할 수 있음을 보여내며, 이는 이러한 문법에 기존 방법을 적용할 때의 지수 시간 대비 개선이다. 이 결과는 LLM 생성을 형식적 구문 제약을 더 잘 만족하는 출력을 향해 효율적으로 제약하고 조향하는 것을 가능하게 한다.

arXiv:2606.17522v2cs.CL

유계 깊이 문법을 통한 심층 트랜스포머의 계층적 모델링 표현력 분석

An expressivity analysis of hierarchical modelling in deep transformers via bounded-depth grammars

심층 신경망은 층을 거치며 점점 더 추상적이고 조합적인 특징을 점진적으로 포착하는 계층적 표현을 형성할 수 있다는 능력으로부터 표현력을 얻는다고 널리 여겨진다. 언어 모델링에서 트랜스포머는 지배적인 아키텍처로 등장했으며, 초기 층은 국소적 구문 패턴을 포착하고 후기 층은 더 복잡한 절 수준의 의존 관계를 인코딩한다. 이러한 직관이 모델 설계를 형성해 왔지만, 심층 트랜스포머가 그러한 계층적 구조를 어떻게 표현하는지를 보여주는 엄밀한 이론적 연구는 여전히 부족하다. 본 연구에서는 유계 깊이의 비재귀 문맥자유 문법이라는 형식적 관점을 통해 심층 트랜스포머 모델의 표현력을 분석한다. 이 문법 클래스에 대해, 문법 깊이에 선형적으로 비례하는 깊이를 갖는 위치 어텐션 트랜스포머를 명시적으로 구성하며, 뉴런 수는 유도 트리 형태의 수에 비례하고 생성 규칙 수의 제곱에 비례한다. 이론적 결과는 이러한 아키텍처가 잔차 스트림 내에서 추상적 문법 상태를 저차원의 선형 분리 가능한 부분공간으로 인코딩할 수 있는 구조적 용량을 지님을 보여 줌으로써 선형 표현 가설을 뒷받침한다.

arXiv:2510.02524v3cs.CL

구문 해부: 언어 모델링과 문법의 하위 구조

Unraveling Syntax: Language Modeling and the Substructure of Grammars

문맥 자유 문법(CFG)의 하위 구조인 하위 문법(subgrammar)을 정의하고, 언어 모델링 손실이 이에 대해 선형적으로 재귀함을 이론적으로 증명했다. 실험 결과 모델은 하위 문법을 병렬로 학습하며, 하위 문법 사전학습이 작은 모델의 성능과 내부 표현을 개선함을 확인했다.