CRMWeaver: Building Powerful Business Agent via Agentic RL and Shared Memories

Yilong Lai, Yipin Yang, Jialong Wu, Fengran Mo, Zhenglin Wang, Ting Liang, Jianguo Lin, Keping Yang · OpenReview

Abstract

Recent years have witnessed the rapid development of LLM-based agents, which shed light on using language agents to solve complex real-world problems. A prominent application lies in business agents, which interact with databases and internal knowledge bases via tool calls to fulfill diverse user requirements. However, this domain is characterized by intricate data relationships and a wide range of heterogeneous tasks, from statistical data queries to knowledge-based question-answering. To address these challenges, we propose CRMWeaver, a novel approach that enhances business agents in such complex settings. To acclimate the agentic model to intricate business environments, we employ a synthesis data generation and RL-based paradigm during training, which significantly improves the model's ability to handle complex data and varied tasks. During inference, a shared memories mechanism is introduced, prompting the agent to learn from task guidelines in similar problems, thereby further boosting its effectiveness and generalization, especially in unseen scenarios. We validate the efficacy of our approach on the CRMArena-Pro dataset, where our lightweight model achieves competitive results in both B2B and B2C business scenarios, underscoring its practical value for real-world applications.

1. Introduction

While Large Language Models (LLMs) have demonstrated remarkable capabilities in general tasks, their application in specialized business environments remains challenging. Enterprise tasks often require navigating complex, interconnected databases (e.g., Salesforce) and adhering to strict corporate policies. A typical query might involve joining multiple tables, performing temporal calculations, and synthesizing information from both structured SQL data and unstructured knowledge bases.

Existing agents often struggle in these scenarios due to two primary factors: the scarcity of high-quality, multi-turn business tool-use training data and the difficulty of generalizing across evolving database schemas. CRMWeaver addresses these hurdles through a combination of graph-based synthetic data generation, a two-stage reinforcement learning (RL) pipeline, and a novel "shared memory" mechanism.

2. Methodology

CRMWeaver employs a three-pronged approach to build robust business agents capable of handling heterogeneous tasks.

2.1 Graph-Based Synthetic Data Generation

To overcome data scarcity, we treat the target database as a graph where records are nodes and relationships are edges. By performing random walks on this graph, we generate multi-relational queries grounded in actual data. These queries are then iteratively refined by an LLM to increase their complexity and linguistic naturalness, resulting in high-quality training pairs.

2.2 Two-Stage Training Recipe

The training process consists of two distinct phases:

  1. SFT for Cold Start: We utilize rejection sampling and trajectory distillation from a powerful teacher model (e.g., GPT-4) to fine-tune the base model on successful solution paths.
  2. RL for Generalization: We employ Decoupled Clip and Dynamic Sampling Policy Optimization (DAPO). This reinforcement learning stage allows the model to explore the environment and receive rewards based on answer accuracy and format adherence, which is particularly effective for mastering complex workflow sequences.

2.3 Shared Memories

During inference, the agent utilizes a "Shared Memory" module. For any given query, the agent retrieves high-level workflow guidelines from similar past successful tasks. If the task is entirely new, an advanced reasoning model generates a new guideline offline, which is then indexed for future use. This "playbook" approach allows the agent to generalize effectively to unseen scenarios without needing to store every individual trajectory.

Overview of the CRMWeaver framework, illustrating synthetic data generation, the two-stage training recipe, and the shared memory mechanism.

3. Experimental Setup

We evaluated CRMWeaver on CRMArena-Pro, a comprehensive benchmark modeling 25 Salesforce objects with over 80,000 records. The benchmark covers 19 distinct task types across B2B and B2C scenarios, testing four core competencies: Database Querying, Textual Reasoning, Workflow Execution, and Policy Compliance.

4. Results and Discussion

Experimental results demonstrate that CRMWeaver, built upon a lightweight 4B-parameter model (Qwen3-4B), achieves performance competitive with models nearly 60 times its size, such as Gemini 2.5 Pro and Qwen-235B.

Comparative performance of CRMWeaver and various state-of-the-art models on the CRMArena-Pro benchmark.

4.1 Key Findings

  • Superior Database Reasoning: CRMWeaver excels in structured data tasks, achieving a score of 73.0 in B2B Database queries, significantly outperforming OpenAI-o1 (56.3) and Gemini 2.5 Pro (57.6).
  • Impact of RL and Memory: Ablation studies show that RL provides the most significant boost in Workflow Execution tasks by teaching the model the correct sequence of actions. The Shared Memory module adds a consistent 1–2 point improvement to the overall average, proving vital for generalization.
  • Efficiency: The shared memory only requires updates for approximately 3% of queries, indicating that the agent rapidly builds a comprehensive playbook for most business needs.

5. Conclusion

CRMWeaver demonstrates that high-quality procedural training and strategic memory retrieval can enable lightweight models to master complex business data tasks. Future work will focus on enhancing multi-turn user interactions for clarification dialogues and addressing context window limitations to improve reasoning over larger data samples.

Summary updated

Abstract

Recent years have witnessed the rapid development of LLM-based agents, which shed light on using language agents to solve complex real-world problems. A prominent application lies in business agents, which interact with databases and internal knowledge bases via tool calls to fulfill diverse user requirements. However, this domain is characterized by intricate data relationships and a wide range of heterogeneous tasks, from statistical data queries to knowledge-based question-answering. To address these challenges, we propose CRMWeaver, a novel approach that enhances business agents in such complex settings. To acclimate the agentic model to intricate business environments, we employ a synthesis data generation and RL-based paradigm during training, which significantly improves the model's ability to handle complex data and varied tasks. During inference, a shared memories mechanism is introduced, prompting the agent to learn from task guidelines in similar problems, thereby further boosting its effectiveness and generalization, especially in unseen scenarios. We validate the efficacy of our approach on the CRMArena-Pro dataset, where our lightweight model achieves competitive results in both B2B and B2C business scenarios, underscoring its practical value for real-world applications.
BibTeX
@inproceedings{lai2025crmweaver,
  author = {Yilong Lai and Yipin Yang and Jialong Wu and Fengran Mo and Zhenglin Wang and Ting Liang and Jianguo Lin and Keping Yang},
  title = {{CRMWeaver: Building Powerful Business Agent via Agentic RL and Shared Memories}},
  booktitle = {MTI-LLM @ NeurIPS},
  year = {2025},
  url = {https://openreview.net/forum?id=uqMPNWvMkp},
}
Figure