Computation and Language
Names Can Hurt: Spotting Slopsquatting Risks Caused by Package Name Hallucinations in Local Coding LLMs
Akash Raj and Sargam Sahu
When a code generating
language model fabricates a Python package name, an adversary who has pre-registered that name on PyPI can convert that
hallucination into a supply chain compromise. This event has been termed as 'slopsquatting'. We propose a two layer detector to counter this issue. The first layer performs a deterministic PyPI existence check. The second is a Random Forest classifier trained on ten features derived from the package name and its PyPI metadata. An import name reconciler bridges the two, resolving cases such as 'import cv2' versus 'pip install opencv-python' without a security bypass. The detector is embedded in a LangGraph state machine that retries at escalating temperatures and, on repeated failure, routes to a stronger fallback model. Across 300 curated
prompts, the pipeline produces
hallucination free code on 76% of runs. The primary exhausts its retry budget on 28.7%; intra model retries recover roughly a quarter of those, and cross model fallback recovers a further 16.5% of the remainder. Four findings have been observed. First, half of the flagged
hallucinations are packages already registered on PyPI, as low quality lookalikes of well known projects, caught by the classifier rather than the deterministic layer (e.g., pil, faiss, tabula, haystack). Second,
hallucination rate scales almost linearly with
prompt adversariality, from 0 to 10% on routine coding to 40 to 73% on slopsquat baits. Third, the weaker primary refused 6 of 10 direct baits unaided, suggesting recent instruction tuning provides a baseline defense. Fourth, when primary and fallback share a model family, approximately 84% of primary failures recur on the fallback, motivating cross family pairing. A user study (n = 24) reports mean satisfaction 4.4 out of 5 and 21 of 24 stated adoption intent.
Read the full abstract ▾
Computation and Language · Cross-listed from cs.AI
Semantic Overlays: Mitigating Prompt Injection with Annotations Beyond Tokens and Steering Vectors
Joshua Penman
Everything a
language model sees is
tokens. The serving stack knows what each span is – user input, tool output, instructions – but the model must keep track of that itself, and can lose track or be confused: text can be written to read like anything.
Prompt injection is a natural exploit of this phenomenon. By scrambling the model's understanding of span identity, an attacker can induce unwanted and dangerous actions. Adding a non-textual channel to the model's input – a way to communicate span identity beyond text – mitigates this class of attack. We thus introduce a general steering technique called Semantic Overlays: small learned adapters applied at chosen prefill positions to a frozen model's residual stream. Laying an overlay over a span creates an out-of-band annotation channel that cannot be replicated by
tokens. Unlike steering vectors, Semantic Overlays are trained, adaptable, and selectively applied. An overlay can encode complex semantics that reshape how the model perceives the marked span: asked to copy a code snippet under an overlay asserting a different programming
language, the model rewrites the snippet in the asserted
language. Overlays compose, allow transparent reading of underlying content, and can carry complex payloads – including imperatives the model will follow. An overlay which marks a span as "non-executable" defends against the broad class of
prompt injections that add instructions in untrusted context. We report strong results on five
prompt injection
benchmarks: SEP separation rises from 24.3% to 99.0% with utility unchanged (our scoring rule; we correct a defect in the published grader), TensorTrust attack success falls from 34.8% to 6.2%, AlpacaFarm from 99.0% to 0%, and the overlay beats every published PIArena defense that leaves the model able to answer – while marked spans stay readable, all at >95% character similarity to the original.
Read the full abstract ▾
Computation and Language · Cross-listed from cs.MA
Markets, Not Planners: Decentralized Orchestration of LLM Agents with Private Information
Xiao Liu, Haoyang Li, Songwei Li et al. (+4 more)
As LLM
agents proliferate, built by different parties and with different capabilities and costs, orchestrating them is more like assembling labor across the economy than a computer calling a subroutine. Existing orchestration is typically centralized, with a single planner assigning every task, but this creates a bottleneck as
agent pools grow, requires private information (e.g.,
agents' execution costs), and can easily be manipulated, such that a single inserted preference nearly doubles a favored
agent's task share under a centralized LLM allocator. We introduce AgentLance, a repeated labor
market in which
agents bid on tasks using their private costs and self-maintained strategy notes, an allocator selects winners from bids and public reputation records, and a VCG-style payment rule rewards cost-aware bidding. Complex tasks are handled by hierarchical delegation: winning
agents can decompose work and subcontract it through the same mechanism. Across mathematical
reasoning, code generation, knowledge-intensive QA, and agentic tasks, AgentLance matches
agents to their specializations, shifts work toward cheaper
agents as cost sensitivity rises, and consistently outperforms single-model, centralized-orchestration, and
market baselines. Diagnosing
market failures, including inaccurate cost self-estimation and sub-optimal bidding, then correcting them in controlled experiments yields further gains, charting a path toward more efficient
agent economies.
Read the full abstract ▾
All authors Xiao Liu, Haoyang Li, Songwei Li, Hongbo Fang, Fengli Xu, Feng Shi, James Evans
Computation and Language
Does Episodic Memory Help Close the Lexical Frequency Gap in Sensitivity to Syntactic Contrasts? A Test Using Retrieval-Augmented Language Models
Jing Liu and Najoung Kim
Grammatical knowledge and how it is empirically tested are typically considered robust to the frequency of the lexical items in the expressions. However, neural network-based models of grammaticality exhibit high sensitivity to lexical frequency. We draw upon Complementary Learning Systems theory to test the hypothesis that robustness to lexical frequency can arise via a hippocampal episodic
memory mechanism, which enables rapid encoding and
retrieval of specific experiences and allows learners to leverage them when processing rare patterns. We use
retrieval-augmented
language models as an instantiation of such an episodic
memory mechanism (specifically, $k$-nearest-neighbor
language models that augment parametric models with explicit instance storage), and test whether this augmentation helps close the lexical frequency gap that vanilla
language models exhibit in syntactic contrast tests. Using syntactic contrasts with frequency-stratified test items, we find that
retrieval augmentation narrows the performance gap between high- and low-frequency items, consistent with episodic
memory compensating for weak parametric representations. This benefit is consistent across different syntactic phenomena and across models pretrained on child-realistic and large-scale data. Additionally, we show that structural information is critical for effective
retrieval, whereas semantic similarity alone provides little benefit. While these are promising proof-of-concept results supporting our hypothesis, the frequency gap is narrowed rather than fully closed. Based on our analyses, we propose preferential reweighting of retrieved instances, better representations and
retrieval strategies for structural information, and flexible configurations of storage and
retrieval as promising future directions for improving the implementation of episodic
memory in
language models.
Read the full abstract ▾
Computation and Language
Mitigating Exploration Bias in RL for Multi-Instruction Following
Mian Zhang, Yueqin Yin, Kaiyu He et al. (+4 more)
RL has emerged as a powerful paradigm for enhancing the instruction following capabilities of LLMs. While existing training recipes achieve substantial gains, we find that they suffer from exploration bias towards easy instructions when the training data has multiple instructions in a
prompt. This bias is caused by two main reasons: 1) the policy model's initial ability to satisfy hard instructions is too low to trigger successful exploration during RL training, so the optimization is biased towards easy instructions; and 2) canonical RL training recipes typically employ a cumulative reward (the number of instructions fulfilled), treating all instructions equally, which biases the policy model towards fulfilling easy instructions to obtain the same amount of reward. To address these issues, we first propose two metrics to measure the exploration bias in instruction following and then introduce a two-stage framework to alleviate it: 1) Behavioral Bootstrapping, a lightweight rejection sampling fine-tuning stage before RL to activate hard instructions; and 2) Scarcity-Aware Rewards, a new RL reward function that assigns rewards to instructions based on their empirical scarcity. Experiments show that the proposed metrics are highly correlated with model performance, and our methods unleash the potential of RL training: our best models outperform the baselines by a significant margin across three verifiable instruction following
benchmarks. We release codes at https://github.com/mianzhang/MulIF.
Read the full abstract ▾
All authors Mian Zhang, Yueqin Yin, Kaiyu He, Peilin Wu, Xinlu Zhang, Mingyuan Zhou, Zhiyu Zoey Chen
Computation and Language
Beyond Static and Linear: What Attention Constraints Best Fit Human Reading Times?
Lanni Bu, Xiulin Yang, Christian Clark et al. (+2 more)
Transformer-based
language models are widely used as models of human
language processing, yet their
attention mechanisms allow lossless access to the full preceding context, unlike the limited
memory systems of humans. We hypothesize that installing
memory constraints into
transformers'
attention mechanisms can improve their fit to human behavioral data. While previous work has explored individual constraints in isolation, we conduct a systematic comparison of multiple
attention-based
memory mechanisms across different model sizes and training corpora, evaluating both psychometric predictive power for human reading times and grammatical competence. We additionally compare static constraints, in which the constraint strength is fixed throughout training, to dynamic
memory curricula. We find that constraints that are sensitive to the content of intervening
tokens consistently achieve the highest
alignment with human reading times, outperforming distance-based constraints. We observe a dissociation between psychometric fit and grammatical competence under dynamic
memory curricula, suggesting that
Transformers cannot serve as a one-size-fits-all cognitive model.
Read the full abstract ▾
All authors Lanni Bu, Xiulin Yang, Christian Clark, Alex Warstadt, Ethan Gotlieb Wilcox
Computation and Language · Cross-listed from cs.LG
Learning to Grade Efficiently: A Bandit-Driven Prompt-Selection Framework for Low-Cost LLM Essay Scoring
Olga Manakina and Igor Bogdanov
Large
Language Models (LLMs) demonstrate strong capabilities in automated essay scoring (AES), but contemporary approaches typically employ fixed
prompt selection, failing to address operational cost concerns and evolving optimal configurations. We propose a novel cost-aware approach that treats each
prompt type as an arm in a multi-armed bandit (MAB) controller, enabling adaptive selection of optimal prompting strategies during inference. Our experiments on IELTS Writing Task 2 essays show that the MAB framework achieves comparable scoring accuracy to exhaustive grid search while reducing LLM calls by 78.4% to find the best grading approach. We implemented four distinct grading recipes (multi-step vs. single-step assessment, with vs. without calibration examples) and found that the multi-step approach with examples achieves the highest accuracy. By tracking
token usage and latency alongside agreement metrics, we produce the first cost-reliability learning curves for essay scoring, providing actionable insights for educational technology platforms that must balance operational costs against assessment validity. This work represents the first application of online control mechanisms to adaptively select prompting strategies in AES, transforming
prompt selection from an offline hyperparameter optimization problem into an efficient online learning task.
Read the full abstract ▾
Computation and Language
From Preferences to Principles: Rubric-Based Alignment for Grounded Knowledge Answers
Aman Saini, Priyanshu Kumar, Eric Peng et al. (+3 more)
Designing effective reward signals for open-domain question answering is challenging because high-quality responses must simultaneously satisfy multiple aspects of answer quality that are difficult to capture with a holistic scalar objective. We introduce a rubric-based reward framework that generates query-specific rubrics grounded in retrieved evidence and decomposed into multiple quality dimensions, providing fine-grained supervision during post-training. Averaged across three evaluation axes (composition, grounding, and instruction-following), our approach improves over the instruction-tuned baseline by 6.5% and over flat rubric variants by 4%, with consistent gains across all evaluation
datasets. Conditioning rubrics on retrieved evidence improves factual support, while decomposing rubrics into quality-specific dimensions further improves coherence, organization, and adherence to query requirements. Our results show that grounded, multi-dimensional rubrics provide more effective reward supervision for complex open-domain question answering.
Read the full abstract ▾
All authors Aman Saini, Priyanshu Kumar, Eric Peng, Kai Yuan, Harsh Girase, Wanming Chen
Computation and Language · Cross-listed from cs.LG
Discovering Cross-Language Reasoning Invariance in LLMs with Geometry-Invariant Sparse Autoencoders
Igor Bogdanov and Changcheng Huang
Multilingual language models can solve the same mathematical problem in different
languages, but it remains unclear whether they rely on shared features or on
language-specific computations that only produce similar outputs. We study this question in five models from four families using the
Multilingual Grade School Math (MGSM)
dataset, with problems solved in English, German, French, Spanish, Russian, and Chinese, retaining problems with valid
reasoning traces in all six
languages and replaying those traces through the model to record representations at multiple layers. For each model, we first use Centered Kernel
Alignment (CKA) to identify layers with cross-
language alignment. At each selected layer, we train two sparse autoencoders (SAE): a baseline reconstruction-only model and a contrastive variant introduced in this work, the Geometry-Invariant SAE (GI-SAE). GI-SAE supplements the reconstruction loss with an Information Noise-Contrastive Estimation (InfoNCE) loss that trains the encoder to produce similar activations for traces of the same problem, regardless of
language or
token position. We then test whether the resulting shared features are functionally interchangeable by swapping their values between
languages during the model's forward pass and measuring the resulting change in output, quantified by Kullback-Leibler (KL) divergence per feature. Although GI-SAE yields higher CKA and Jaccard similarity at nearly every layer, higher
geometric similarity does not consistently imply greater functional interchangeability. We find that cross-
language feature sharing is model- and architecture-dependent in this sample and appears at different depths in different models. GI-SAE primarily amplifies cross-
language structure already present: the pattern is model-specific, with strengthening in Qwen, no functional benefit in Gemma, and mixed layer-dependent effects in Llama and Phi.
Read the full abstract ▾
Computation and Language
Giga-Embeddings: Mixture-of-Experts Encoders for High-Throughput Text Embeddings
Egor Kolodin, Egor Krasnoperov, Evgeniy Kosarev et al. (+1 more)
We introduce Giga-
Embeddings, a family of text
embedding models designed to combine strong
retrieval quality with efficient serving. Its largest member is a sparse 10B-parameter Mixture-of-Experts encoder with approximately 1.8B active parameters per
token. Across English, Russian,
multilingual, and code MTEB
benchmarks, this model achieves the strongest aggregate performance within the family on all four evaluated suites. In our vLLM
benchmark with 1024-
token inputs, it processes 114.5k
tokens per second, providing 25 percent higher throughput than the dense 3B model and 1.56-2.65x the throughput of the evaluated external systems. The family also includes a dense 3B encoder and a distilled 480M encoder for tighter compute and
memory budgets. We train the compact model using a dimension-agnostic objective that aligns teacher and student similarity distributions. The resulting 480M model scores 70.98 on Russian MTEB, surpassing FRIDA while using 42 percent fewer parameters. We release all three model checkpoints.
Read the full abstract ▾
All authors Egor Kolodin, Egor Krasnoperov, Evgeniy Kosarev, Fyodor Minkin
Computation and Language
Inter-dimension Dependence for Multi-Dimensional Evaluation of Open-Ended Text
Haoyuan Li and Snigdha Chaturvedi
LLM-as-a-judge methods are widely used for evaluating the quality of generated open-ended text. Such evaluations are generally multi-dimensional, since the error patterns in texts can be different for different dimensions. Therefore, reliable LLM judges should evaluate each target dimension independently. To quantify the extent to which LLM judges depend on non-target dimensions when evaluating a target dimension, i.e., inter-dimension dependence, we propose CorrGap. To measure this, CorrGap uses the difference in correlations between LLM-predicted scores and ground truth scores across different groups of texts. Using CorrGap, we show that inter-dimension dependence is pervasive across LLM judges in open-ended text evaluation tasks. To mitigate inter-dimension dependence, we propose DimCheck, a method that iteratively removes unrelated evidence from COTs generated by LLM judges in a step-wise way. We show that DimCheck mitigates inter-dimension dependence and outperforms strong baselines across three LLMs and four tasks. We also show that smaller trained LLMs can approximate larger LLMs in DimCheck, with much lower inference costs.
Read the full abstract ▾
Computation and Language
When Youth Enter The Chat: An Epistemic Shift in the Validation of LLM-Based Measures of Student Talk
Liliana Santos-Deonizio, James Malamut, Ramón Antonio Martínez et al. (+1 more)
LLMs are being used increasingly to measure aspects of student discourse (e.g. talk moves, collaboration, equity of voice) at scale. Typically, LLM-based measures of student talk use transcriptions of classroom conversations that only include verbal contributions, which de-contextualize student
language. Common practices for validating these measures include comparing outputs against expert annotations by adults, using held out evaluation sets and F1 scores. We argue that these approaches are insufficient to ensure that such measures are meaningful and equitable for teaching and learning, particularly for racially and linguistically marginalized youth. In order to center the youth whose talk is being analyzed, re-contextualizing these classroom conversations and engaging youth in the research process is necessary. Sharing epistemic authority with youth, ultimately, centers their point of view and adds crucial nuance to the analysis of their talk that adult experts, researchers, and LLMs cannot provide. In a case study of
multilingual youth in one 8th-grade math classroom, we address the epistemic exclusion of youth by employing multiple ethnographically-oriented methods to re-contextualize student conversations and center youth as epistemic authorities in conversation with researchers and LLMs. We conducted participant observations, interviews, focus groups, and member checks with four focal students. Findings reveal that there were misalignments between students' interpretations of their own math talk experiences and the LLM-based measures of their talk. Students contested both the LLM classifications and the coding scheme used to measure their talk, highlighting the need for youth to be involved in the epistemic process of producing knowledge about their experiences.
Read the full abstract ▾
All authors Liliana Santos-Deonizio, James Malamut, Ramón Antonio Martínez, Dorottya Demszky
Computation and Language
What Reaches Expert Review? Representation, Structural Screening, and Candidate-Form Dependence in AI-Assisted Item Development
Christopher Brooks
Between AI-assisted item generation and expert review sits a computational evaluator whose decisions are usually treated as technical preliminaries. Yet representation, structural reduction, and selection policy determine which items and evidence psychometricians ever receive. Across two linked in-silico studies of 32,000 selected Big Five items, we followed fixed source populations from semantic representation through structural evaluation and candidate-form construction. Broad agreement in semantic geometry concealed consequential local differences: identical wording acquired different construct evidence, different items survived, and intended attributes could disappear even as community correspondence improved. These sensitivities also differed across generated source populations. At the final review boundary, both eligibility policies filled every content
cell in every evaluable form, yet they presented different wording. Across
embedding configurations, inclusive primary forms shared a median of only 6 of 40 items, reflecting the total downstream consequence of changing representation across structural evidence and ranking. The apparent stability of global summaries and complete forms therefore concealed instability in the content reaching psychometricians. The computational evaluator is not neutral infrastructure between generation and expertise; it is an inspectable and revisable part of measurement design.
Read the full abstract ▾
Computation and Language · Cross-listed from cs.LG
Candidate-Label Saliency for Efficient Conformal Pruning of Text Classifiers
Ibne Farabi Shihab, Joyanta Jyoti Mondal and Adria Binte Habib
Recalibration can preserve conformal coverage after
pruning while enlarging prediction sets and leaving more alternatives for downstream decisions. Directly searching for deletions that keep sets small is costly. We study whether a small candidate-gradient budget can approximate this search at lower cost. Candidate-Saliency
Pruning (CSP) estimates the squared first-order change in two plausible labels' scores when each parameter is deleted. CSP averages these changes, combines the resulting importance with a base pruner, and selects the mixing weight under validation accuracy and coverage requirements. Independent split-conformal calibration supplies marginal coverage under exchangeability. We evaluate CSP on three classification tasks, two base pruners, and three sparsity levels against a squared true-label control that separates candidate choice from gradient squaring, under fixed recovery updates, equal total time, and restricted access to the training corpus. Before recovery, CSP reduces mean set size by 13.2% to 19.2% against the reference pruner and by 7.7% to 13.2% against the control in all six encoder
cells at 50% sparsity. The advantage over the control shrinks with recovery to practical equivalence in all six
cells at 1,000 updates, and at equal total time the cheaper reference pruner is practically equivalent in 18 of 18 settings. When recovery is limited to the retained
pruning pool, CSP keeps a meaningful advantage in all six
cells. Its value therefore depends on the time and data available for recovery.
Read the full abstract ▾
Computation and Language
ADE: Agentic Data Evolution Framework for Human-Centered Objectives
Yang Yu, Yilin Jiang, Zexuan Fei et al. (+6 more)
Aligning large
language models to human-centered objectives is difficult when targets are non-executable and context-dependent, limiting reliable verification and scalable supervision. Although synthetic data expands coverage, weak verification shifts the bottleneck from generation to selection. Noisy signals destabilize iterative refinement and can cause silent regressions. We propose Agentic Data
Evolution (ADE), a data-centric framework that organizes synthetic supervision as evolving data snapshots. ADE improves data snapshots through a closed-loop Observation-Variation-Selection (OVS) procedure, where a steady-state admission mechanism acts as a quality ratchet that conservatively gates updates for sustained cross-round improvement. We validate these improvements through complementary intrinsic trend tracking and extrinsic post-training evaluation. On DEV300, ADE raises the intrinsic win rate from 50% to 75.81% and the extrinsic win rate from 55.20% to 68.86%, consistent performance gains across diverse
benchmarks. Blind expert evaluation further confirms this, with a 66.11% preference for evolved answers. These gains extend across post-training methods, model scales, and tasks beyond the target weakly verifiable educational objectives. Resources are available at https://github.com/ZeroLoss-Lab/Agentic-Data-
Evolution.
Read the full abstract ▾
All authors Yang Yu, Yilin Jiang, Zexuan Fei, Yiming Luo, Xingkai Song, Kaiyi Huang, Aimin Zhou, Xin Lin, Fei Tan
Computation and Language
The Limits of Automatic Evaluation of Creativity in Large Language Models
Alessandro Tutone, Giorgio Franceschelli and Mirco Musolesi
Large
Language Models (LLMs) are increasingly capable of generating text that challenges human performance in domains requiring creativity, yet evaluating creativity in LLM-generated content remains a significant challenge. Here, we investigate whether current automatic evaluation methods can reliably capture human judgments of creativity. We collect human evaluations of human- and AI-generated short stories from the WritingPrompts
dataset across 11 dimensions of creativity, and compare these judgments with automated objective metrics and LLM-as-a-Judge evaluations. Our experiments reveal substantial misalignment between automatic evaluations and human assessments. In particular, LLM-based judges exhibit a systematic preference for AI-generated stories, consistently favoring their stylistic characteristics over the unpredictability and other qualities of human-authored texts. Furthermore, correlation analyses show that widely used automatic metrics exhibit near-zero
alignment with human judgments across both human- and AI-generated stories, suggesting that they fail to capture important dimensions of creativity. These findings highlight fundamental limitations in current approaches to the automatic evaluation of creative text and underscore the difficulty of reducing the multidimensional and subjective nature of creativity to computational metrics.
Read the full abstract ▾
Computation and Language · Cross-listed from cs.AI
Automata from Agent Traces: Failure and Next-Step Prediction
Seonglae Cho, Franklin Cardenoso Fernandez, Umar Mohammed et al. (+4 more)
LLM-based
agents execute multi-step tasks, but their behavioral structure remains opaque: long unstructured traces resist the safety
auditing and runtime monitoring that deployment requires. Existing approaches operate per-trace or success-only, so they miss the cross-run
topology that links next-step and failure prediction. To recover that shared structure, we collapse an entire trace corpus into a single, compact finite-state machine (FSM) that serves as a structural substrate for the otherwise unpredictable behavior of LLM
agents. Across twelve public
datasets, the FSMs are compact (7-43 states), replay held-out data at >=0.997 fitness with near-identical
topology across splits, and build in milliseconds. This substrate addresses both prediction goals. For next-step prediction, FSM-state context outperforms
Agent Workflow
Memory on every ground-truth-matched
dataset. For failure prediction, per-state behavioral features reach held-out AUROC up to 0.94, and an online monitor ranks failing runs above passing ones from a partial trace, triggering early stopping well before completion. Behavioral
topology thus appears shaped more by the deployment harness than by the LLM, providing a model-agnostic structural primitive for safety
auditing and runtime monitoring.
Read the full abstract ▾
All authors Seonglae Cho, Franklin Cardenoso Fernandez, Umar Mohammed, Zekun Wu, Kleyton Da Costa, Ilham Wicaksono, Adriano Koshiyama
Computation and Language · Cross-listed from cs.AI
Gated Activation Steering for Reducing Sycophancy & Hallucination in Medical Question Answering
Himanshu Tripathi, Subash Neupane, Shaswata Mitra et al. (+3 more)
Sycophancy and
hallucination are persistent failure modes of Large
Language Models (LLMs) across domains. However, it becomes particularly consequential in clinical question answering, where responses must remain grounded in the provided context and robust to user pressure.
Hallucination can introduce information that is unsupported by the context, while sycophancy can cause a model to abandon a previously correct answer when challenged by the user. Existing approaches, such as
prompt-based safeguards and always-on activation steering, often address these behaviors separately or apply interventions broadly across turns, which can unnecessarily deteriorate responses that were already correct. To address these limitations within a single framework, we employ Inference Time Intervention (ITI) to jointly control both behaviors by learning separate steering directions for
hallucination and sycophancy from contrastive clinical pairs and applying them to causally verified
attention heads. During runtime, behavior-specific gates then determine when intervention is needed: the
hallucination component mitigates unsupported claims, while the sycophancy component mitigates answer shifts caused by user pressure. We evaluate this framework on clinical questions grounded in EHR data while keeping the model weights frozen. Across all evaluation settings, we conducted 15,900 model-response runs. Across 600 pressure trajectories for the 4-billion-parameter model, the unsteered model caved in 570 cases. At the same time, gated steering helped it last longer in 551 of them. It held its ground under pressure at levels comparable to those of models with more than 100 billion parameters, showing that targeted inference-time steering can improve robustness without intervening at every turn.
Read the full abstract ▾
All authors Himanshu Tripathi, Subash Neupane, Shaswata Mitra, Sudip Mittal, Noorbakhsh Amiri Golilarz, Shahram Rahimi
Computation and Language
Contextual Embedding Evidence for Main–Light Verb Distinctions in Urdu
Farah Adeeba and Miriam Butt
Urdu light verbs contribute schematic event-structural meaning while remaining lexically related to corresponding main verbs. This study tests representational predictions derived from Butt's analysis using contextual
embeddings from UrduBERT, DunbaaBERT, and
multilingual BERT across 1,126 naturally occurring sentences containing seven Urdu verbs. Main and light uses show significant representational separation in all 21 verb–model comparisons. At the same time, same-lemma main and light centroids are consistently closer than mismatched main–light lemma pairs, supporting continued lexical relatedness. In a seven-way prediction task restricted to light uses, verb identity remains recoverable after the target is masked, with UrduBERT achieving 0.866 accuracy and 0.852 macro-F1. UrduBERT also retains 0.782 accuracy under a preceding-form-disjoint evaluation, indicating generalization beyond repeated local verb combinations. These findings provide computational evidence consistent with Butt's account that Urdu light verbs differ systematically from their main uses while retaining lemma-specific and verb-specific representational structure.
Read the full abstract ▾
Computation and Language · Cross-listed from cs.LG
Best Practice Critic Optimization
Penghui Qi, Xiangxin Zhou and Wee Sun Lee
Group-based reinforcement learning methods such as GRPO for large
language models avoid training a critic by sampling multiple responses for each
prompt. A reliable critic could instead estimate
token-level advantages from one response, but standard critic-based training recipes are often unstable. We study this instability and develop **Best Practice Critic Optimization (BPCO)**, a recipe that combines DPPO, value predictions bounded to the reward range, Monte Carlo value targets, unnormalized policy advantages, and length-adaptive generalized advantage estimation. Because the critic is used only during training, BPCO can also condition it on reward-defining information, such as a reference answer or grading rubric, that is hidden from the policy. Controlled experiments isolate the effect of each design choice. Across mathematical
reasoning tasks with models ranging from 1.5B parameters to 30B-A3B mixtures of experts, BPCO improves a strong critic-based baseline consistently, and matches or exceeds a group-based baseline while sampling one response per
prompt. The same recipe also improves learning with rubric-based rewards. These results show that a carefully designed critic provides a reliable alternative to group-relative advantage estimation. Code is available at https://github.com/QPHutu/golden_critic.
Read the full abstract ▾
Computation and Language
SWE Refactor Bench: Can Coding Agents Complete a Long-Horizon, Whole-Repository Stack Migration?
Deyao Hong, Yizhe Chi, Wenyi Li et al. (+7 more)
Modern software systems accumulate technical debt over decades of development, which makes migration expensive and largely manual. As coding
agents become increasingly capable at bug fixing, can they autonomously perform such migrations? Existing
benchmarks cannot answer this question because they evaluate only behavioural correctness, not whether the migration actually occurred. This leads an easy hack:
agents copy the original implementation to make tests pass. We call this Blindness. To address this problem, we introduce SWE Refactor Bench, a
benchmark comprising 20 whole-repository migrations, covering 4 kinds of technical debt. A three-stage evaluation protocol measures both migration completeness and behavioural correctness. (1) Migration Audit verifies that the migration occurred. (2) Behavioural Tests measure correctness with a fixed test suite. (3) Agentic Verification uses 6 independent coding
agents to generate targeted tests for hidden behavioural differences. Across 520 runs from 8 frontier models and 26 model-effort configurations, only 28 of 520 runs ($5.4\%$) pass all three stages, 13 of the 20 tasks receive no accepted solution, and the best model (claude-opus-5) scores $47.0/100$. Migration completeness and behavioural correctness are distinct abilities: a few runs preserve behaviour by skipping the migration and are stopped at Migration Audit; most attempt it and break behaviour, and are stopped at Behavioural Tests.
Agents cannot deliver a perfect migration: among the 340 runs that pass Migration Audit, $58\%$ reach $99\%$ of the fixed checks, yet only $26\%$ reach $100\%$.
Agent capability differs across migration categories:
agents score $31.4$ on build toolchain rewrites but only $5.6$ on
language rewrites. Together, these findings position SWE Refactor Bench as a rigorous testbed for developing coding
agents for reliable whole-repository migrations.
Read the full abstract ▾
All authors Deyao Hong, Yizhe Chi, Wenyi Li, Xiaoqiu Wang, Mingju Gao, Kaisen Yang, Bingxiang He, Youjie Zheng, Calvin Xiao, Qinhuai Na
Computation and Language · Cross-listed from cs.AI
Prime Agent: A Self-Improving RLM Harness
Seth Karten, Alex L. Zhang, Kevin Thomas et al. (+8 more)
Language models are sequential processors, but long-horizon agency requires external information and computation beyond model weights and active context.
Prime Agent is an open-source harness for long-horizon evaluation and coding-
agent workflows. A persistent IPython REPL follows the Recursive
Language Model abstraction for programmatic context processing and test-time compute, while Continual Harness preserves histories,
memories, skills,
prompts, and subagent specifications across trajectories. Recursive subagents coordinate through direct
agent-to-
agent communication, and the
Agents View lets humans inspect and manage daemon-backed sessions.
Prime Agent standardizes execution, recovery, verification, and resource accounting while leaving strategy construction to the model. This low-friction, expressive membrane prevents harness failures from becoming model failures and pushes measurement toward the model's true maximal underlying capability.
Prime Agent raises ARC-AGI-3 RHAE Best@1 from 30% to 95.5% and matches or exceeds native and popular harnesses across long-context coding, GPU-kernel generation, emulator construction, and autonomous nanoGPT speedruns. On Factorio, we find refinement allows for continuous technology progression and dedicated subagents enable parallelized work. Code is available at https://github.com/PrimeIntellect-ai/
prime-
agent.
Read the full abstract ▾
All authors Seth Karten, Alex L. Zhang, Kevin Thomas, Sebastian Müller, Elie Bakouch, Daniel Auras, Mika Senghaas, Fares Obeid, Konstantin Dunas, Johannes Hagemann, Sami Jaghouar
Computation and Language
ConvergeFlow: Language Flow with Provable Convergence to Token Embeddings
Na Li, Yuchen Jiao, Changxiao Cai et al. (+1 more)
Recent advances in continuous
diffusion and flow-based
language models (LMs) have achieved performance competitive with discrete LMs. However, existing continuous frameworks still rely on decoders supervised with cross
entropy (CE) because the flow trajectories are not guaranteed to terminate at valid
token embeddings. Motivated by this limitation, we introduce ConvergeFlow, an
embedding-space flow-based LM, which constrains the data predictor to the convex hull of
token embeddings and trains it solely with the mean squared error objective induced by flow matching. Under suitable regularity conditions, we prove that the resulting flow converges to valid
token embeddings despite errors in the data predictor, enabling direct
token prediction without a CE-supervised decoder. We further develop three sampling mechanisms for controlling the trade-off between the generative perplexity and
entropy. Experiments on OpenWebText demonstrate that ConvergeFlow achieves performance competitive with existing continuous and discrete
diffusion LMs. These findings demonstrate the potential of the flow-based paradigm for
language modeling. Our code is available at https://github.com/Na-Li66/ConvergeFlow.
Read the full abstract ▾
All authors Na Li, Yuchen Jiao, Changxiao Cai, Gen Li
Computation and Language
When Names Cross Scripts: A Source-Grounded Benchmark for Historical Entity Reconciliation in the Mongol World
Xiang Chen and Zeyu Zhang
Historical people may appear under different
languages, scripts, and transcription traditions, while distinct individuals may share highly similar or even identical names. This makes historical identity reconciliation more than a problem of string matching or transliteration. We introduce MHER, a provenance-controlled
benchmark for pairwise reconciliation of person-name attestations from the Mongol world. MHER contains a balanced 396-pair Name-only core over 84 primary historical persons and a stricter 160-pair Source-grounded subset constructed from mention-by-source evidence, with entity-disjoint development and test splits. Across five generative systems, correctly Source-grounded evidence improves paired TEST accuracy by 12.96 to 94.44 percentage points relative to Name-only input. On five identical-surface different-person cases, all models fail under names alone (0/25 model-item decisions), whereas Source-grounded evidence yields 24/25 correct resolutions, with the remaining output an abstention. Context-only ablations show that historical descriptions often carry substantial identity information, while explicitly signaled misgrounding controls produce substantially lower performance. We also find that names are not uniformly beneficial: for Qwen3-8B, restoring surface forms converts ten otherwise correct Context-only distinctions into false identity merges. These results show that historical entity reconciliation depends not only on surface correspondence, but on whether identity judgments respond appropriately to provenance-controlled historical evidence. MHER therefore provides a controlled framework for studying evidence use, abstention, and failure modes in historical NLP.
Read the full abstract ▾
Computation and Language · Cross-listed from cs.AI
Mitigating Reasoning-Induced Misalignment via Safety-Direction Penalty
Yipeng Zhao, Qishun Yang, Shenzhe Zhu et al. (+2 more)
Reasoning-Induced Misalignment, where fine-tuning on
reasoning data containing no harmful content, including mathematics, code, and problem-solving with chain-of-thought traces can induce harmful behaviors of LLM, posing a serious challenge to the safety of LLM
reasoning. Cross-architecture, cross-scale, and cross-
dataset checks show that RIM does not always emerge. Previous work attributed RIM to
neuron-level
entanglement, but did not identify the geometry of the representation space underlying this
entanglement or propose a training-time fix. We provide both: a representation-space analysis of RIM and the Safety-Direction Penalty (SDP), which penalizes movement along a learned safety direction during
reasoning fine-tuning. The analysis extracts two activation-space directions, one encoding
reasoning ability and the other safety behavior. These directions are coupled: fine-tuning that improves
reasoning shifts safety representations, and
prompts with larger shifts show larger safety degradation. CKA distance ratios and probes locate the safety-decision layers where this shift is most relevant. These findings guide the design of SDP: the coupling motivates penalizing displacement along the safety direction, and the layer localization sets the initial scope. When the initial scope leaves compensatory shifts beyond the penalized layers, the same diagnostics guide iterative expansion. On Qwen2.5-3B and 7B, SDP restores safety while preserving
benchmark reasoning performance.
Read the full abstract ▾
All authors Yipeng Zhao, Qishun Yang, Shenzhe Zhu, Shu Yang, Di Wang
Computation and Language
On the Threat Model of Weird Generalization and Emergent Misalignment
Miriam Wanner, Mark Dredze and William Walden
Narrow fine-tuning on small, domain-specific
datasets can produce broad and surprising changes in model behavior-a phenomenon called weird generalization (WG). Yet, it remains unclear what features of the fine-tuning data are necessary for WG to arise. Here, we address this question by investigating a range of plausibly relevant features, including
dataset size, composition,
language, presentation style, and novelty relative to a model's parametric knowledge. Further, since WG evaluations rely on small question sets that assess the extent of the generalization, we also analyze how sensitive this measurement is to the set of questions used. Experiments with three open-weight models on four
datasets show that the degree of WG (1) depends heavily on
dataset composition and
language (more than on size); (2) is greater for data familiar from pretraining than for novel data; and (3) is sensitive to the set of evaluation questions used. Collectively, these results indicate that WG is a product of quite fragile properties of both training and evaluation data. As such, we argue that WG is more plausible as an
adversarial threat-requiring careful data engineering-rather than as a significant hazard inherent to routine fine-tuning.
Read the full abstract ▾
Computation and Language
What's the Catch? Evaluating Temporal Consistency in Vision-Language Models
Marek Hradil and Danae Sánchez Villegas
Vision-
language models (VLMs) achieve strong performance on
video and image-sequence
benchmarks, yet it remains unclear whether they capture temporal structure. To study this question, we formulate temporal grounding as an anomaly detection problem, providing a simple and controlled evaluation that directly tests sensitivity to temporal consistency. We introduce TimeCatch, where temporal anomalies are created by swapping consecutive frames and frame-level anomalies by replacing a frame with Gaussian noise. Models are evaluated on anomaly detection and localization tasks across four synthetic and real-world
datasets, alongside a human study. Our evaluation reveals a substantial gap between frame-level and temporal anomaly detection. While VLMs consistently detect frame-level anomalies and often localize them accurately, under our main evaluation setting they generally perform near chance on temporal anomaly detection and show limited localization performance. Humans, in contrast, achieve near-ceiling performance on both tasks. Additional analyses across model scales, prompting strategies, sequence lengths, and visual similarity show that performance can improve under some conditions, while substantial gaps in temporal anomaly detection and localization remain. Together, these findings reveal a gap between frame-level and temporal anomaly detection. TimeCatch provides a controlled
benchmark for evaluating temporal consistency in
vision-
language models.
Read the full abstract ▾
Computation and Language
How Useful are LLMs for Grammar Engineering? Cantonese ParGram Resources and Controlled Experimental Evaluation with English Baselines
Chit-Fung Lam
This paper presents new Cantonese ParGram resources and evaluates LLMs for knowledge-driven grammar engineering within a controlled experimental paradigm. Using Cantonese ParGram resources as gold standards, with corresponding English baselines, we investigate whether OpenAI's gpt-oss-120b and GPT-5.4 can generate machine-processable grammars from sentences and target formal structures under systematically varied prompting conditions. GPT-5.4 outperformed gpt-oss-120b, while grammars generated from target formal structures generally outperformed those generated from sentences. Although both models could generate locally plausible phrase-structure rules, lexical entries, and templates, they often struggled to coordinate interacting formal constraints, especially in multi-construction settings. The results characterize both the capabilities and limitations of current LLMs for potential integration into AI-assisted expert workflows: LLMs may support intermediate stages of grammar development, but human linguistic expertise remains central to analysis, validation, and refinement. The study also contributes new Cantonese symbolic grammatical resources.
Read the full abstract ▾
Computation and Language
A Comprehensive Analysis of Arabic Natural Language Processing Research: Trends, Topic Evolution, and Research Gaps – A Bibliometric and Topic-Based Study
Mullosharaf K. Arabov
Arabic Natural
Language Processing (NLP) has grown rapidly over the past decade, driven by digital transformation in the Arab world, social media, and large
language models (LLMs). Despite this growth, a comprehensive quantitative meta-analysis remains absent. This study presents a bibliometric and topic-based analysis of 7,120 Arabic NLP papers published between 1960 and 2026, sourced from five platforms (arXiv, ACL Anthology, Semantic Scholar, Crossref, OpenAlex) plus an additional targeted OpenAlex subset. We employ BERTopic for topic modeling, regression analysis, social network analysis, and geographic mapping. Our findings show a significant publication surge after 2020, driven by
transformer models and LLMs. Topic modeling identifies 19 themes, the largest centered on text,
speech, translation, and recognition (2,942 papers). Citation analysis reveals a positive correlation between paper age and citations (r = 0.245, p < 0.001); regression (R^2 = 0.105) shows that indexing in OpenAlex or Semantic Scholar and institutional affiliation are associated with higher citations. Saudi Arabia, the United States, and Egypt lead in research output. A task-dialect gap
matrix identifies understudied areas, including summarization for Maghrebi, Iraqi, and Sudanese dialects. The largest topic has the highest H-index (90), followed by sentiment analysis (57). Our quantitative approach complements existing qualitative surveys and offers recommendations to prioritize under-resourced dialects and develop culturally aligned
benchmarks.
Read the full abstract ▾
Computation and Language · Cross-listed from cs.IR
Robustness of IR Models to Collection Growth
Emmanouil Georgios Lionis, Sean MacAvaney and Debasis Ganguly
Information
Retrieval (IR) systems seek to identify relevant documents within a collection. In practical applications, collections are dynamic, with documents frequently added. We argue that ideally, a retriever's effectiveness should not decrease when non-relevant documents are added to a collection. This study formalises this concept and empirically evaluates it by merging two collections with negligible topic overlap. We hypothesise that the way an IR model conditions its ranking on other documents in a collection (e.g., the IDF component in BM25 or contextual documents in listwise rerankers) plays an important role in its robustness to the addition of non-relevant documents. We broadly classify models as those that do not depend on other documents (Multi-Document-Agnostic, MDA) and those that do (Multi-Document-Dependent, MDD). Our results show that neither MDD nor MDA models are fully robust to the addition of non-relevant documents, as all models exhibit some performance degradation. Interestingly, among the models we test, MDA is more effective than MDD for
retrieval, whereas MDD and MDA rerankers are equally effective.
Read the full abstract ▾