Tracing Agentic Failure from the Flow of Success [arXiv:2607.12747]
OAT
OAT proposes an unsupervised failure attribution method that trains a model only on successful trajectories without step annotations and identifies erroneous steps in failed trajectories at inference time. The key idea is to characterize the dynamic pattern in successful trajectories, and at inference time, assign each step in a failed trajectory an anomaly score based on its deviation from the learned normal flow. Specifically, OAT first collects successful trajectories for training, representing each action step by aggregating the token representations (e.g., hidden states from a particular LLM layer) within that step. Then it models the sequence of action representations as a continuous latent state path using Neural Controlled Differential Equations (Neural CDEs). The model is trained to minimize the reconstruction error between the original action representations and those recovered from the corresponding latent states. At inference time, this reconstruction loss serves as the anomaly score for identifying potentially erroneous steps in a failed trajectory.
Contrastive Language Models
Contrastive Language Models
Contrastive Language Models (CLMs) is a new class of System One model trained with a contrastive learning objective that connects states and actions. Each state is pulled toward the ground-truth action that was taken and pushed away from all others. A CLM consists of a state encoder and an action encoder, both of which map their respective inputs into a shared embedding space, where the score of a state–action pair is computed as the cosine similarity between their embeddings. Each encoder consists of a frozen LLM backbone followed by a trainable projection head. CLM takes the hidden state of the final token, normalize it, and pass it through a MLP projection head. At inference time, given the current state and a set of candidate actions, CLM scores each action by how well its embedding aligns with the state embedding and selects the highest-scoring action.
CLM is pretrained on a large-scale question–answer dataset containing ~60M pairs from Nemotron DQA, where each question is treated as a state and its corresponding answer as an action. In other words, question-answer relation is a one-to-one mapping. A bidirectional InfoNCE loss is leveraged at this stage to simutaneously maximize (1) the probabiltiy of selecting the correct answer ai given a question si, and (2) the probability of identifying the corresponding question si given its answer ai. The pre-trained checkpoint is then mid-trained on ~30M synthetic hard negatives generated by Gemini 2.5 Flash-Lite for a subset of Nemotron DQA questions. These incorrect answers, denoted as hi,k, turn the original question si into a multi-choice question and their cosine similarities with the corresponding questions are minimized. Finally, CLM is post-trained on ~1M agent trajectories from the Agent Data Protocol (ADP) dataset, Endless-Terminals, and LiteCoder-Terminal-SFT. Each trajectory step is represented as a state–action pair, where the state contains the agent’s current context and the action corresponds to the decision taken at that step.
BibTeX citation
@misc{jiajun2026vdmfa,
title = {Verification, Decision-Making, and Failure Attribution},
author = {Hu, Jiajun},
year = {2026},
month = {November},
journal = {richardhooooo.github.io},
url = {https://richardhooooo.github.io/blog/2026/11/11/notes/}
}