Uber Implements Legal Redlining Agent with RAG and Rule-Based Logic
Uber's Legal Redlining Agent, a Microsoft Word add-in using React, TypeScript, and Python, reduces contract review time by 20% through RAG and deterministic rules.
Implementation and Integration of the Legal Redlining Agent
Uber’s Legal Redlining Agent is implemented as a Microsoft Word add-in, combining a React and TypeScript frontend with a Python backend managed via LangGraph. The agent uses retrieval-augmented generation (RAG) to pull from legal playbooks and historical lawyer feedback, enabling it to assess proposed contract changes and recommend policy-aligned responses. This integration streamlines the contract review process by applying deterministic rules alongside AI-generated insights. According to Uber’s blog post, the high-level workflow of the add-in ensures that legal teams receive consistent, risk-aware guidance without requiring manual intervention for routine contract adjustments. The system’s architecture allows for seamless deployment within existing workflows, reducing the time required for contract reviews by aligning AI outputs with organizational policies and legal standards.
Workflow and System Architecture
Uber’s Legal AI Agent operates through a parallel workflow architecture, with distinct nodes handling intent detection, risk assessment, and policy lookup. The system relies on OpenSearch to store vectorized legal rules and historical feedback, while Redis is used to maintain session state for follow-up questions. According to the Legal Redlining Agent system architecture described in an Uber Blog Post, a deterministic rules engine is employed to enforce non-negotiable legal requirements. This engine has the authority to override model recommendations when a matching rule applies, ensuring compliance with legal standards. This structured approach contributes to the reported 20% reduction in contract review time, as noted in the title.
Improvements and Feedback Loops
Uber’s Legal AI Agent has improved its contract review process through the addition of a feedback loop that captures lawyers’ decisions, reasoning, and final edited text, as noted in InfoQ. This enhancement allows the agent to retrieve examples of how similar clauses have been handled, moving beyond simple acceptance or rejection of previous recommendations, as described in InfoQ. To ensure relevance, the system applies exponential decay weighting with a configurable half-life of 365 days, prioritizing recent decisions while still retaining older examples, according to InfoQ. These improvements create a more dynamic and context-aware legal review process, enabling the AI to better align with evolving legal standards and internal practices.
Performance and Accuracy Metrics
Uber’s Legal Redlining Agent has reduced average contract review time by more than 20%, with 91% accuracy in AI-generated decisions, according to the company. The system leverages a combination of rule-based logic and Retrieval-Augmented Generation (RAG) to automate contract review tasks. However, the system struggled with semantic retrieval accuracy, negotiation tone, and scenarios not covered by existing examples, as noted in internal evaluations. A final verification step checks generated responses against retrieved rules, ensuring alignment with company policies and legal standards. These metrics highlight both the progress and the ongoing challenges in deploying AI for legal workflows, emphasizing the need for continuous refinement and human oversight.
Future Directions and Research
In future directions, Uber’s legal team is exploring agentic harnesses such as Claude Code and OpenCode to enhance automation and workflow structuring across its AI initiatives, as noted in InfoQ. Additionally, the team plans to investigate legal ontologies and knowledge graphs to better represent legal concepts and relationships, aiming to establish a semantic foundation that supports more consistent interpretation and reasoning, according to InfoQ. Collaboration between the legal and engineering teams remains central, with the legal team defining the desired tone and style, while engineers focus on maintaining prompt structure and application workflow, as stated in InfoQ. These efforts reflect a broader commitment to refining AI tools that align with legal standards and operational needs.
Sources and reporting notes
Based on published source material. No independent hands-on testing is claimed.