A structured-memory harness lets an LLM agent learn to search over reaction graphs for retrosynthesis planning
摘要
Multi-step retrosynthesis planning seeks to decompose a target molecule into commercially available building blocks through a sequence of feasible reactions. The vast combinatorial search space makes this task challenging even for expert chemists. Traditional methods combine tree search with offline-trained value networks that score candidates in isolation, without reasoning about complete multi-step routes. Recent work leverages Large Language Models (LLMs) for this task, but relies on simple interfaces that limit exploration of the full search space. We introduce RetroAgent, an LLM agent that bridges symbolic search and neural reasoning through a harness with structured memory. Through memory and chemistry tools, the agent observes the full search state, including explored routes, available alternatives, and properties of intermediates, enabling informed decisions grounded in both global progress and domain knowledge. Experiments on in-distribution and out-of-distribution benchmarks demonstrate that RETROAGENT delivers strong performance and generalization.
Grounding LLM-based materials search in executable crystal operators and hierarchical reflection doubles hit rate over prior methods on tightly constrained discovery tasks.
摘要
This paper studies the problem of constrained novel crystal discovery, which aims to identify a set of physical feasible and property-aligned material candidates within a complicated search space. Existing approaches typically integrate large language models (LLMs) with domain knowledge of material properties and constraints for material discovery. However, these approaches usually adopt shallow memory mechanisms or unstructured toolsets, leading to suboptimal performance. Towards this end, we propose a novel approach named Structured Action Orchestration with Trio-Reflection (CrystalSTAR) for constrained novel crystal discovery. The core of our CrystalSTAR is to incorporate hierarchical memories into a structured action orchestration from modification scopes and dominant components, facilitating a smooth and efficient crystal discovery procedure. In particular, our CrystalSTAR first formulates the toolset as a structured action space along two orthogonal dimensions, resulting in four complementary tools for material exploration. More importantly, we adopt a trio-reflection mechanism to guide the trial process in a hierarchical manner. Here, our bottom-up memory records local anomalies, stuck trajectories, and cross-run knowledge, enabling effective strategy planning with grounding evidence. Extensive experiments across multiple benchmark datasets validate the effectiveness of our proposed CrystalSTAR in comparison to extensive state-of-the-art approaches. Our codebase
is open-sourced at https://github.com/oldwizard7/CrystalSTAR
We investigate the mechanisms underlying representation steering and find it can be isolated into a select number of components writing in specific dimensions in the residual stream.
摘要
Activation steering manipulates large language model behavior by intervening on internal activations, but the mechanistic basis of these interventions remains poorly understood. We decompose refusal steering into component-level interventions across four open-weight models, identifying which attention and MLP components can reproduce the full steering effect. We find that the refusal direction is concentrated in sparse mechanisms comprising 28--48\% of upstream components while retaining 88--101\% of full steering effectiveness, with complement experiments confirming that excluded components largely fail to elicit refusal when steered in isolation. Within these mechanisms, effective steering further concentrates in approximately 50\% of residual stream dimensions, consistent with a privileged basis structure, and this coordinate-level sparsity persists when steering is restricted to the identified component set. Decomposing each component's contribution to the refusal direction reveals that attention sublayers provide the dominant discriminative signal between harmful and harmless content, while MLP contributions are more distributed and in some cases suppressive. The high-magnitude writes of individual components do not concentrate in the same coordinate subspace as the refusal direction, suggesting that the refusal direction basis emerges as an aggregate of component-specific sparse signals rather than a shared subspace. Together these findings show that the refusal direction is not diffusely encoded across a transformer but assembled by a structured, identifiable mechanism, providing a foundation for mechanistic understanding of how safety-relevant behaviors are represented and steered.
The evolution of morality presents a puzzle: natural selection should favor self-interest, yet humans developed moral systems promoting altruism. Traditional approaches must abstract away cognitive processes, leaving open how cognitive factors shape moral evolution. We introduce an LLM-based agen...
The efficiency of multi-agent systems driven by large language models (LLMs) largely hinges on their communication topology. However, designing an optimal topology is a non-trivial challenge, as it requires balancing competing objectives such as task performance, communication cost, and robustnes...