Skip to main content
You have: Robin with state, a diary tool, a booking task, a handoff, prefetch, quiet-caller settings and a trace, from See every call. You built a phone agent that keeps a typed state, books only what the caller agreed to, hands off a complaint, knows the date, and shows up in Langfuse. The same salon/ package runs on LiveKit and Pipecat.

Your code and the example

The full example is examples/salon-concierge-unmute/. Its names are the ones you used, so you can read it next to your files. Its salon/ package keeps its code in salon/src/salon/.

What the example adds

  1. Knowledge. look_up_salon_info and look_up_refund_policy search the salon’s own documents, so Robin quotes the guide instead of guessing a price.
  2. Receipts and confirmations for every write. Booking, moving and cancelling each ask a question first and say a fixed line after. Most turns cost one model request.
  3. Held saves. A save made before the caller answered is held, and the call’s end settles it. Pipecat calls UnmuteFlows.settle. LiveKit does it on its own.
  4. A locked phone number. customer_phone is locked to the state on every diary tool, so the model never types it.
  5. Phone calls. sip_call_info and telephony_call_info read what a phone call carries into state.call. On a browser or console call, UNMUTE_CALL_START simulates a caller.
  6. A complaint mid-booking. manage_booking offers to_complaints too, so a complaint in the middle of a booking goes straight to the specialist.

Run the full example

Copy the .env.example in each project to .env, and fill the keys it lists. Langfuse keys are optional.
A call to try:
  1. “I’d like to book a haircut on Friday.” The agent checks your number, offers times, confirms and books.
  2. “How much is a full head colour?” It answers from the salon guide.
  3. “My last colour went wrong, I want to complain.” It hands you to the complaint specialist.
  4. “Can I also move my haircut to Saturday?” It hands you back to the concierge, who moves it.
  5. “That’s all, bye.” It says goodbye and hangs up.

Where to go next

State

Types, confirmation and prompt placeholders.

Tools

Typed tools, locked arguments and announce lines.

Tasks

Steps, groups and finish checks.

Handoffs

Pass the call between agents.

Prefetch

Read values before the greeting.

Turn taking

Pace, interruptions and quiet callers.

Knowledge

Answer from your own documents.

Telemetry

Langfuse, Logfire, Coval and more.

On LiveKit

How the library plugs into LiveKit Agents.

On Pipecat

How the library plugs into a Pipecat pipeline.