pinecallDocs
Key concepts / Personas

Personas

A caller a model plays: a goal, a manner, what it expects of the agent, how it acts on the line; Pinecall's library, and callers written for you.

A persona is a caller a model plays: a goal, a way of speaking, the facts they know about themselves, what they expect of the agent — and, on a spoken call, how they act on the line. It improvises every turn, so it finds the conversations you did not think to write as goldens.

What is a persona?#

A persona belongs to one agent and is kept by the gateway, the same in sandbox and production. Two agents of one org can each have a caller with the same name. Your repository holds none of them: you write them with pinecall personas or on the console's Evaluate ▸ Personas screen, and no deploy is needed. Pinecall's own library of callers comes first in every list, each one off until you switch it on.

Pinecall's library#

Every agent's list starts with Pinecall's personas, each off until pinecall personas on <name> — or the switch on the console — turns it on for that agent. The switch is per agent. It decides which of them the console's Evaluate ▸ Simulations screen offers to put on the line; pinecall simulate --persona <name> plays any of them, on or off. Pinecall plays none on a schedule. One of them is never written nor dropped: write your own under another name.

Each of them is written for every business, so before it phones yours it is briefed: the judge model reads what the agent does — an agent built in Studio off its definition (its instructions, how it opens, its tools), one written as a class off the prompt its last call ran on, its tools and what it knows — and gives the caller the one concrete thing it calls about, in the agent's own terms, keeping its manner, its facts and what it expects. One eval per simulation, as a generated caller is. Studio shows the briefing before the call, open to an edit, and pinecall simulate prints it before the first line; --goal (the MCP tool's goal) says what any caller phones about yourself, and nobody is briefed. A class agent nobody has called yet, with no tools, is nothing to brief on: the caller phones as written.

tag personas what they test
realism in-a-hurry, wrong-number, non-native, switches-language, interrupts, changes-mind, elderly-slow, angry-repeat-caller, asks-for-a-person the calls a real day brings: haste, confusion, a second language, a caller who changes language in the middle of the call, who talks over the agent, who changes their mind, who needs it twice, who is furious, who wants a person
red-team prompt-leak, data-leak, off-task, harmful, unauthorized-action the calls somebody makes on purpose: the prompt asked for, another customer's details, help with something else, something dangerous, an action the caller may not take

Each comes with what it expects of the agent, and some with how they act on a spoken line: interrupts talks over 60% of the agent's answers, in-a-hurry and angry-repeat-caller 30%, elderly-slow leaves 2.5 s before each line and non-native 1 s. pinecall personas show interrupts prints one whole.

Write one#

Terminal
pinecall personas add hurried \
  --about "Calls from the street, in a rush" \
  --goal "move the appointment to Tuesday afternoon without giving more details than needed" \
  --style "short sentences, interrupts, gives one fact at a time" \
  --fact "their name=Ana García" --fact "their phone=600 000 001" \
  --expect "The agent should offer a time on Tuesday afternoon." \
  --expect "The agent should confirm the new time before moving the appointment." \
  --interrupts 0.3 --pause 1
flag what it is
--goal what the caller wants from the call. Required
--style how they talk. Required
--about one line about who they are
--fact 'what=said' a fact they know about themselves, repeatable
--llm the model that plays them: vendor/model, a vendor, a model, or haiku, sonnet, opus
--tts, --voice the vendor and voice their lines are read in on a spoken call
--expect '…' one thing the agent should do, repeatable; see below
--tag x a word to find them by, repeatable
--interrupts 0–1, --pause s how they act on a spoken line; see below
--backchannels 0–1, --speed 0.5–2 whether they murmur while the agent talks, and how fast they speak; see below
--ambience x, --background-noise dB, --ambience-turns 0–1 what plays behind them, how loud, and behind which share of their lines; see below

A name is lower-case letters and digits joined by hyphens: hurried, price-shopper. A vendor or a voice Pinecall does not have is refused when you write it, and so is a vendor nobody keyed for your org (xai has no key: the org brought none and the box holds none, until you add yours with pinecall providers add): not in the middle of a run.

Terminal
pinecall personas                      # one line each: name, style, goal
pinecall personas show hurried         # the whole caller, what it expects and how it acts
pinecall personas edit hurried --llm haiku
pinecall personas rm hurried

In a project with several agents, add --agent <name> to say whose callers you mean.

What they expect of the agent#

--expect lines are the caller's own pass mark: one verifiable demand each, written "The agent should …", about something the agent's prompt or knowledge says it can do — never about how the call ends. At hang-up, the library's expected-outcome judge reads the whole call against them, each line graded yes, no, or blocked (the call never got that far). Like every judge of the library it is off until you switch it on (pinecall judges on expected-outcome); until then the lines are kept on the call and nothing reads them.

answer means
held every line is yes
broken a line is no
na every line is blocked

The reason gives each line its answer and the line of the call that decided it. The lines are never told to the model playing the caller: a caller that knows its pass mark plays to it. The judge is a separate model call, never the one that played the caller. They travel on the call itself (call.started.expects), so a call is judged by what it was made under even after you edit the persona. A persona that expects nothing gets na from expected-outcome without a model being asked.

How they act on a spoken line#

On a spoken call the caller does more than talk. --interrupts 0.3 makes it talk over that share of the agent's answers — a second or two in, as a person cutting in does, never at the first word — so the agent's barge-in is tested for real: did it stop, did it pick up what the caller said, did it lose the thread. The line it cuts in with was asked for as the agent began and comes with no pause, so the cut-in lands on the answer and not after it. --pause 2 leaves two seconds of silence before each of its lines: a caller who thinks, or looks for a paper.

--backchannels 0.3 makes it murmur an "mm-hmm" — in its language: ajá, uh-huh, uhum — into that share of the agent's answers, a few seconds in, without taking its turn: a listener's noise, which an agent must not mistake for a barge-in. An agent that stops talking at every "mm-hmm" is found out here. --speed 0.8 makes it a slower talker: its words come a little slower and the pauses between its phrases grow, as a person who takes their time speaks, never a recording played slowly. --speed 1.3 hurries its voice to that much of the vendor's tempo, the pitch kept. Either way you hear how the agent's ears cope.

Whatever it does, the caller waits for the agent's greeting before its first line — past the org's recording notice, when one is said — and when its turns are done it hangs up: the call ends caller_hung_up the moment it leaves, not when the room is deleted.

--ambience cafe says what plays behind it: a television (a real newscast in English, as a small speaker sounds from a couch across a living room), a cafe (chatter over a room), an office (a hum) or a street (traffic swelling and fading), each the same sound every run, at --background-noise 15 dB under the caller; without a level nothing plays. It is the room the caller is in, so it never stops: it plays under the agent's answers and through every silence. --ambience-turns 0.5 makes it a noise that comes and goes instead: it is heard behind that share of the caller's own lines, coming up as they start to speak and gone with their last word, and nowhere else. A television with voices that never stops is taken for the caller by ears with no filter; behind some lines it troubles the hearing of those lines and takes no turn of its own. The line may also lose packets (packet_loss). pinecall simulate --background-noise, --ambience and --packet-loss override all three for one call. A written call ignores everything in this section.

In the console, Personas ▸ New persona offers each of these as a choice in words — Murmurs while the agent talks, How fast they speak, Where they call from and how loud, The phone line — and the voice picker lets you listen before you choose.

Run it#

Terminal
pinecall simulate --persona hurried            # a written call, printed as it happens
pinecall simulate --persona hurried --judge    # ...then every judge's verdict
pinecall simulate --persona hurried --voice    # a spoken call on a real line
pinecall personas try hurried                  # the same as simulate, without --judge
flag what it does
--judge waits for the call to be judged and prints each verdict and what judging cost. Exits 1 when a judge answered broken, and 2, with the reason, when nobody judged the call — no judge is on, only n/a came back, the evals ran out, or no score came within a minute — because a call nobody looked at is no pass
--turns <n> how many lines the caller improvises before hanging up. Default 15
--voice a real spoken call: a room, the agent dispatched into it, the caller read out loud
--listen plays the call on this machine's speakers while it happens. Turns --voice on
--background-noise <dB> what plays behind the caller, that many dB under them: the persona's ambience, a television for one that names none. Spoken calls only
--ambience <x> which plays, for this call: television, cafe, office or street. Spoken calls only
--packet-loss <share> that share of the caller's packets never arrive, from 0 to 1 (0.02), as pinecall test --voice takes it. Spoken calls only
--llm <vendor/model> the model that plays the caller, for this call alone; the persona keeps its own
--tts <vendor>, --caller-voice <id> the vendor and the voice the caller is read in, for this call alone. A --tts with no --caller-voice picks one of that vendor's voices the agent does not have

You can also run a persona from the console's Evaluate ▸ Simulations screen, where Played by changes the model and the voice for the calls you start, as the flags do.

How a persona is played#

Every caller line is one request to a model on the gateway: the persona's own --llm, or the caller model Pinecall sets for simulated callers. On a spoken call, the caller speaks in the persona's own --voice when it set one, else in a voice from the operator's list for the agent's language, never the voice the agent uses, so you can tell the two sides apart by ear. The caller waits for the agent's opening before its first line.

Who pays for the caller#

The caller's model and voice run on the platform's keys, unless your org brought its own key for that vendor: then they run on yours. Either way the call counts as one simulation of your org's simulations (pinecall limits shows how many are left); its minutes are not minutes. On Pinecall Cloud every plan includes a month of simulations, and the caller runs on Gemini.

Every simulation, written or spoken, from the terminal or the console, is checked before its call opens: it is refused with a 429 once none of your org's simulations is left, and credits.exhausted lands on the agent's log; a caller whose model or voice is on a vendor nobody keyed is refused with the vendor's sentence. A refused simulation opens no call and counts nothing; one that opens weighs on the limit from the moment its call begins, and pinecall limits adds it when the call ends.

A spoken call (--voice) and a call started from the console are at most three of your org's simulated calls on the line at once in each of sandbox and production: a fourth is refused with a 429 that says when to ask again. What their caller's lines and voice cost is kept with the call, beside what the agent's side cost, and the usage feed carries it as caller_cost_usd. Because the platform pays for the caller, each of them has a spending ceiling: the caller hangs up when the call reaches it, and the answer says so.

A written pinecall simulate takes no place among the three — it is a call like any other to the org's concurrent_calls, from when it opens until its score is written — has no spending ceiling, and keeps no caller_cost_usd; the model that played its caller is kept with the call, and pinecall runs and the console's Simulations name it.

Callers written for the agent#

Terminal
pinecall personas generate 3 --about "price questions"
pinecall personas generate --template in-a-hurry --save
pinecall personas generate --from-call call_29d7c7

The judge model reads what the agent is — its prompt as its newest call ran it, its tools, its knowledge — and writes callers for it, each with what it expects. --about steers them, --from-call makes them like a real call's caller, --template writes one of Pinecall's again for this agent, N times (say 1). They are printed and saved nowhere; --save keeps every one as the agent's own — as rows, or as code when the agent's code owns the roster (below) — and the console's Generate… lets you keep them one by one, the same way. Each caller written is one eval — none when your judges run on your own key.

In the code#

An agent's code can own its roster instead of the gateway. The callers live with its tests, in agents/<agent>/test/personas.ts (.py, .rb), beside the goldens: every caller the file holds is one of the agent's own, each what pinecall personas add sends, and its on names which of Pinecall's callers its runs play. The class does not name them and does not import the file; pinecall start and a deploy read it when they load the class. pinecall new writes it:

A wrong one is refused when the class loads, by a sentence that names it — a caller with no goal, a name that is not lower-case words joined by hyphens, two of one name — and a caller written as code is typed and reviewed in the same pull request as the class. With that file, the code is the roster: the console's Personas and pinecall personas show it locked, "Set in its code", and add, edit, rm, on and off are refused naming the file; a caller Generate… or generate --save keeps is appended to the file as code, where it plays from the next start, for you to commit. The callers travel with the code and deploy with it. An agent with no such file leaves the roster to the console and the CLI, as above. pinecall personas pull writes the roster the gateway keeps into the file as code, once: Pinecall's that are on as on, and every one of the agent's own.

Before, the class named its callers itself: @agent({ personas: ["in-a-hurry", hurried] }) in TypeScript, personas = personas(on=…, own=…) in Python, personas on:, own: in Ruby. That still plays for an agent with no personas file, and pinecall start says once where they moved: pinecall personas pull writes them into the file, and then personas comes out of the class. The two together are refused when the agent starts.

Next steps#