Building Trustworthy LLM Agents for Automated Expense Management

ramp · Finance · 2025 · source Agentic: yes · promotional bias: med · source-backed · extracted with prompt 0.5.5 (schema v2)

Generated from extraction.json — do not edit by hand. Every claim cites verbatim source evidence; stated means the quote directly asserts the claim, implied means it supports it indirectly.

Problem

Domain: expense-management agents

Ramp needed LLM agents for finance workflows that could make ambiguous policy decisions at high volume while remaining explainable, controllable, and safe enough for users to trust.

Constraints:

Architecture

Ramp's policy agent combines retrieved expense-policy context, LLM reasoning, source citations, categorical decisions, an uncertainty escape hatch, workflow-builder autonomy controls, deterministic guardrails, collaborative policy editing, and eval datasets built from edge cases and user-flagged failures.

Diagram confidence: reconstructed (reconstructed from prose).

flowchart LR
  expense-approval-workflow["expense approval workflow"] --> policy-agent["policy agent"]
  policy-agent --> policy-context["policy context"]
  policy-context --> policy-editor["policy editor"]
  policy-agent --> citation-renderer["citation renderer"]
  citation-renderer --> finance-users["finance users"]
  policy-agent --> uncertainty-router["uncertainty router"]
  uncertainty-router --> human-review["human review"]
  human-review --> finance-users
  policy-agent --> workflow-builder["workflow builder"]
  workflow-builder --> deterministic-rules["deterministic rules"]
  workflow-builder --> finance-users
  finance-users --> feedback-loop["feedback loop"]
  feedback-loop --> policy-editor
  feedback-loop --> eval-suite["eval suite"]
  eval-suite --> policy-agent
Drag to pan · scroll or use +/− to zoom · reconstructed from the source's described component topology

Components

Component Role Interacts with
expense approval workflow Receives expense decisions that previously required manager review. policy agent
policy agent Interprets expenses against policy context and emits categorical decisions with reasoning. policy context, citation renderer, uncertainty router, workflow builder, eval suite
policy context Stores and retrieves customer expense policies used directly in LLM decisions. policy editor, policy agent
policy editor Lets users update policy language when agent outputs reveal ambiguity. policy context, feedback loop
citation renderer Displays reasoning with links to the policy sections that support it. finance users
uncertainty router Sends unsure cases to the familiar human escalation path. human review
workflow builder Configures where agents can act autonomously and where hard stops apply. deterministic rules, finance users
deterministic rules Enforce dollar limits, vendor blocklists, and category restrictions outside the LLM. workflow builder
human review Reviews uncertain or restricted expenses. finance users
feedback loop Turns user errors, policy edits, and uncertainty reasons into future improvements. eval suite, policy editor
eval suite Uses edge cases, user-flagged failures, and golden datasets to prevent regressions. policy agent
finance users Validate explanations, set autonomy, edit context, and perform review. citation renderer, workflow builder, human review, feedback loop

Data flow

An expense is evaluated against relevant policy sections; the LLM emits reasoning and an Approve/Reject/Needs review decision; citations point users to the policy context; workflow rules and guardrails define where action is allowed; uncertain cases go to human review; feedback and policy edits feed evals and context improvements.

3 supporting quotes
“we’re now applying a “policy agent” that finance teams can trust to match or exceed human judgment. Since enabling the policy agent at Ramp, we’ve seen more than 65% of approvals be fully handled by the agent. ## Show your work How you communicate an LLM’s”article, stated
“For example, the policy agent links directly to sections of the user’s expense policy that its reasoning references.”article, stated
“let customers promote the agent to take real action. The progression is deliberate: suggestions → acting on subsets → full autonomy. Each step validates the previous one, creating a natural trust curve that matches each customer's level of comfort. ## Evals are the new unit tests Just as unit”article, stated

Why this architecture

The system is built around trust rather than raw autonomy: reasoning and citations make decisions auditable, escape hatches prevent forced hallucination, collaborative policy editing improves context, and workflow controls let customers decide how much autonomy fits their risk tolerance.

3 supporting quotes
“Every decision needs a "why." It’s not enough to tell users "You should approve this expense.” This helps users verify the outcome, spot errors quickly, and understand how your LLM thinks. This last point is also important to both developers and users: *”article, stated
“All facts and figures should be grounded in easily verifiable context coming from your product or the user. For example, the policy agent links directly to sections of the user’s expense policy that its reasoning references. Putting this together, here’s an”article, stated
“Every customer will have a different level of comfort letting AI act on their behalf. When giving your systems agency it’s important you’re not removing agency from your users. Our solution was to reuse the [workflow”article, stated

Models used: LLMs

Scale

Alternatives considered (roads not taken)

Ask the LLM for numerical confidence.

Rejected because: Ramp rejects this because LLM confidence scores are not numerically meaningful or reproducible.

“Asking LLMs to output confidence scores is like asking a human to give a number off the top of their head. It’s usually reasonable, but not numerically relevant and certainly not reproducible. This can be especially misleading because: 1. Confidence scores”article, stated
“human to give a number off the top of their head. It’s usually reasonable, but not numerically relevant and certainly not reproducible. This can be especially misleading because: 1. Confidence scores are a strength of traditional statistical models. 2. LLMs will eagerly give you a confidence of”article, stated

Force an answer when the model is unsure.

Rejected because: Ramp treats uncertainty as a valid product state and routes to human escalation.

“Build escape hatches Not every question has an answer. Forcing your LLM to come up with one and act on it is a recipe for hallucinations. Early on, we gave our LLMs the ability to say “I’m not sure” and explain why. When the agent isn’t sure, we fall back to the pre-agent escalation process users”article, stated
“When the agent isn’t sure, we fall back to the pre-agent escalation process users are accustomed to. We can then use that explanation to: 1. Tell the user what made the AI unsure, to help them focus on what may need additional review 2. Track how the unsure”article, stated

Keep policies outside the platform as static PDFs.

Rejected because: Ramp brought policies into the platform and built an editor so context stays current and user-correctable.

“or reasoning Applying this to our product, we: 1. Brought the user’s expense policy (typically a PDF) onto Ramp so it’s always up to date 2. Use that context to drive the agent’s decisioning 3. Built a full editor for users to update their policy on Ramp when they disagree with the LLM output This”article, stated
“Built a full editor for users to update their policy on Ramp when they disagree with the LLM output This feedback loop not only reduces the amount of work humans need to do over time, but also improves policy accuracy. After all, if an LLM is getting tripped”article, stated

Use user actions directly as ground truth.

Rejected because: Finance teams can be lenient, so Ramp created reviewed golden datasets to avoid teaching the agent excessive leniency.

“If we always took the user’s action as the ground truth , the LLM could have been too lenient. To address this, we created several golden datasets, each carefully reviewed by our team to define the correct decision based solely on information available”article, stated
“user’s action as the ground truth , the LLM could have been too lenient. To address this, we created several golden datasets, each carefully reviewed by our team to define the correct decision based solely on information available within our system. This enables us to make more objective”article, stated

Patterns

structured-output-contract (decisioning)

The policy agent uses predefined categories for decisions rather than numerical confidence.

3 supporting quotes
“* Approve - Clear match between expense and policy * Reject - Clear conflict between expense and policy * Needs review - Edge case when the model is unsure This forces the model to bucket uncertainty into actionable states:”article, stated
“* Approve - Clear match between expense and policy * Reject - Clear conflict between expense and policy * Needs review - Edge case when the model is unsure This forces the model to bucket uncertainty into actionable states:”article, stated
“* Approve - Clear match between expense and policy * Reject - Clear conflict between expense and policy * Needs review - Edge case when the model is unsure This forces the model to bucket uncertainty into actionable states:”article, stated

human-in-the-loop-gate (control)

The system escalates uncertain or policy-restricted expenses to humans.

“When the agent isn’t sure, we fall back to the pre-agent escalation process users are accustomed to.”article, stated

guardrails-io-filtering (safety)

Ramp layers deterministic limits and blocklists over the agent so some actions are categorically unavailable.

“We layer deterministic rules on top: dollar limits, vendor blocklists, category restrictions.”article, stated

eval-driven-development (evaluation)

Ramp uses evals as regression tests, especially around ambiguous edge cases and production failures.

“evals are needed to responsibly evolve your LLM systems over time.”article, stated
“* Turn failures into test cases - Every user-flagged error should be a candidate for your evals. This is especially useful for building your datasets early on.”article, stated

Tradeoffs

Use categorical uncertainty instead of confidence scores.

Chose Approve/Reject/Needs review over Numerical confidence.

Rationale: The categories are more actionable and avoid false precision.

“Instead, we use predefined categories which are not only easier to explain but also more accurate:”article, stated

Use the existing workflow builder for autonomy.

Chose Workflow-builder controls over A separate one-size-fits-all AI control surface.

Rationale: Customers already customize processes there, and it can define exactly where agents may act.

“Our solution was to reuse the workflow builder that’s already used across the product to customize and define processes.”article, stated
“That same workflow builder defines exactly where and when agents can act.”article, stated

Introduce autonomy gradually.

Chose Suggestions before autonomous actions over Immediate full-agent behavior.

Rationale: Progressive rollout let users learn the agent's patterns and build confidence.

“This builds confidence. Users learned the agent's patterns, caught its mistakes, and most importantly saw it getting things right.”article, stated

Gotchas (what bit them)

Confidence numbers from LLMs are misleading.

Root cause: LLMs provide plausible-looking percentages without calibration or reproducibility.

Resolution: Use categorical outcomes that map directly to user actions.

“LLMs will eagerly give you a confidence of 70-80% with no indication that they will almost always give that same score.”article, stated
“users don't need a confidence score, they need to know what action to take.”article, stated

Reasoning can build trust only if users can audit it.

Root cause: LLM reasoning alone can be flawed or hallucinated.

Resolution: Cite product or user-provided policy context for facts and figures.

“LLM reasoning on its own can be flawed or filled with hallucinations.”article, stated
“All facts and figures should be grounded in easily verifiable context coming from your product or the user.”article, stated

Production feedback can encode human leniency.

Root cause: Finance teams sometimes approve reasonable but technically noncompliant expenses.

Resolution: Use curated golden datasets rather than raw user actions as objective labels.

“finance teams are nicer than you might expect: they’re frequently lenient and will approve reasonable but not totally in-policy expenses.”article, stated
“This enables us to make more objective judgments, free from the affinity bias that can influence finance teams' decisions.”article, stated

Evaluation

Ramp runs evals like unit tests: start small, focus on edge cases, turn user failures into tests, and verify feedback labels through curated golden datasets.

Metrics: More than 65% autonomous approval handling · Unsure reasons tracked over time · User-flagged failures become eval candidates · Golden datasets reviewed by Ramp's team

3 supporting quotes
“Since enabling the policy agent at Ramp, we’ve seen more than 65% of approvals be fully handled by the agent.”article, stated
“Turn failures into test cases - Every user-flagged error should be a candidate for your evals.”article, stated
“we created several golden datasets, each carefully reviewed by our team”article, stated

Outcomes

The article discloses the 65% approval automation figure and a $50 conservative review threshold, but not error rates, costs, or latency.

“Since enabling the policy agent at Ramp, we’ve seen more than 65% of approvals be fully handled by the agent.”article, stated
“We’re committed to building LLM-powered agents that create value while staying trustworthy.”article, stated