> For the complete documentation index, see [llms.txt](https://docs.riff.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.riff.ai/concepts/what-is-a-riff-agent.md).

# What is a Riff agent?

The simplest mental model: **a Riff agent is like a new hire.**

You define the job. You give the agent a name, tell it what triggers it to start, what it's supposed to do, and what "done" looks like. Then it runs — handling the routine, escalating the exceptions, and reporting back. You don't babysit it. You review its work.

This is the frame that consistently lands with procurement and operations teams. If you can write a job description for the role, you can build the agent.

## What an agent looks like in practice

A Riff agent has:

* **A trigger** — a schedule (every morning at 7am), an email arriving in its inbox, a webhook from your ERP, or a manual kick-off.
* **A task** — the job it's been configured to do. "Check all open POs in Infor LN. For any line due for delivery in the next 5 days with no supplier confirmation, send a chase email."
* **A done state** — when the agent considers the job complete. "All lines either confirmed by the supplier or escalated to the buyer."
* **An escalation path** — what happens when it encounters something it can't decide. It routes to a human — via email, Slack, or the task board — rather than guessing.
* **An audit trail** — every action logged, with what it did, when, and why.

Agents in Riff have their own email address and Slack handle. Suppliers and colleagues can reply to them directly. Replies feed back into the agent's context for its next action.

## What a Riff agent is not

**Not a chatbot.** A chatbot answers questions. A Riff agent takes action. It creates records, sends emails, updates ERP fields, matches invoices. You don't have a conversation with it — you define its job once and it runs.

**Not a rigid automation.** A traditional automation follows a fixed sequence of steps — if A then B, always. A Riff agent reasons about its task. It reads what's in front of it, decides what to do, and adapts if the situation is different from usual. It can handle variation in supplier email formats, partial confirmations, and edge cases that would break a hard-coded workflow.

**Not a black box.** Every step the agent takes is logged. You can see what it did, what it read, what it decided, and why. If it escalated something to you, you can see exactly what triggered that decision.

## The escalation-first design principle

Riff agents are built to escalate before they act in uncertain situations — not after they've already made a mistake.

You configure the thresholds. For a confirmation-chasing agent, you might tell it: "If the supplier's reply is ambiguous or the confirmed quantity differs from the PO by more than 5%, don't update the ERP — escalate to the buyer." For an invoice-matching agent: "If the invoice total is within £50 of the PO, auto-match. Otherwise, flag for review."

The agent follows those rules consistently. Routine cases run without human input. Edge cases land in the right person's queue with the context they need to decide.

## What agents run on

Agents connect to your ERP and the systems around it — Infor LN/M3, SAP S/4HANA, Oracle ERP Cloud, Microsoft Dynamics 365 — through Riff's native integrations. They read data from those systems and, where you've authorised it, write back. Every write action is pre-declared and permissioned before the agent ever runs.

See [How agents act on ERPs](/concepts/how-agents-act-on-erps.md) for the detail on how that works.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.riff.ai/concepts/what-is-a-riff-agent.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
