Appearance
AI setup
AI in Rangefront Waste is optional, small and checked by a person. It tidies a technician's rough notes, drafts a customer email or text from a short instruction, writes the plain-English summary on a service report, drafts quote lines, and powers the phone agent. Nothing it writes is sent without someone reading it, except the phone agent, which speaks to callers on its own.
What each helper does for staff is in AI. This page is about switching it on and controlling it.
Server setup
AI calls go to Anthropic's Claude API with one key for the whole installation. A developer sets these in .env:
| Variable | Meaning | Default |
|---|---|---|
ANTHROPIC_API_KEY | The API key. Without it, every AI feature says "AI is not set up on this server yet." | none |
ANTHROPIC_MODEL_FAST | Model for note tidy-up, message drafts and the phone agent | claude-haiku-5-5 |
ANTHROPIC_MODEL_SMART | Model for report summaries and quote drafts | claude-sonnet-5-5 |
ANTHROPIC_FALLBACKS | Whether to fall back to another model if one fails | true |
ANTHROPIC_TIMEOUT | Seconds to wait for a reply | 40 |
AI_MONTHLY_REQUEST_CAP | Requests each business may make a month | 3000 |
AI_MAX_INPUT_CHARS | Longest input sent in one request | 6000 |
The text a helper works on, such as job notes or a customer's name and address in a draft, is sent to Anthropic to produce the result. Tell your staff and, if your privacy policy needs it, your customers.
Turn it on for a business
Open Admin > AI. You need ai.manage to change settings.
| Setting | What it does |
|---|---|
| AI switch | Turns every AI helper and the phone agent on or off for this business. It's on by default |
| Tone | Friendly (warm and plain-spoken), Professional (courteous and concise), Formal (precise, like a letter from a firm) or Casual (relaxed, short sentences) |
| Style notes | Your own guidance, such as "Never use exclamation marks. Say 'pump-out', not 'desludge'." |
| Sign-off | How drafts end, for example "Cheers, the team at Smith Septic" |
If the server has no API key, the page says "AI is not set up on this server yet, so nothing below will run until it is."
People need ai.use to use the helpers.
Caps and usage
Every AI request is logged. "This month" shows requests used out of the cap (with a percentage), the input and output tokens, and a table by feature: requests, input and output.
When a business reaches its cap, helpers say "This company has used its AI requests for the month" until the next month. The phone agent counts every turn of a call against the same cap, so a busy month of calls uses it faster than note tidying does. If calls matter, raise AI_MONTHLY_REQUEST_CAP.
If Claude can't be reached, a helper says so and the person writes it by hand. The phone agent transfers the caller to your transfer number or takes their number for a call back.
Phone agent
The phone agent answers calls on a Twilio number. See phone agent for what callers and staff experience.
Before you start
- A Twilio account with a voice-capable number.
- Twilio set as the SMS service for the business (Admin > Email and SMS), with its account SID and auth token. Or the server's own
TWILIO_*account if the built-in SMS service is in use. Voice only works with Twilio. Texts to on-call staff go through the business's SMS service. The Phone agent page says "The phone agent needs Twilio" when it can't find one. - The AI switch on, an API key on the server, and
ai.managefor you.
Set it up
Open Admin > Phone agent.
Set "Answers" to After hours, Business hours or Always. For hours-based modes, choose the open days and the Opens and Closes times.
Write an optional Greeting. Callers are always told it's an automated assistant and that the call may be recorded, whatever you write.
Fill in "Business info" (what you do, where, who to ask for) and "Services and prices". Prices are given as guidance and the office confirms the final price.
Add "On-call numbers", one per line. They're texted straight away when a caller reports an emergency such as an overflowing tank.
Optionally add a "Transfer number" to put callers through to a person.
Tick the phone agent on and Save.
Copy the two addresses shown under Twilio into the number's settings in Twilio:
- Incoming call goes in the voice webhook, HTTP POST.
- Call status goes in the status callback.
The addresses look like
https://your-domain/api/v1/webhooks/voice/<secret>/incomingand.../status. The secret identifies your business. If it leaks, or the number moves, choose "New addresses" and update Twilio.Ring the number from a mobile outside your set hours (or set Answers to Always for the test) and check the call appears under Admin > Calls.
Twilio's requests are checked by signature with your auth token. Requests that fail the check are refused.
Server settings for calls
| Variable | Meaning | Default |
|---|---|---|
TWILIO_VOICE | The voice Twilio reads with | Twilio's default |
TWILIO_VOICE_WEBHOOK_BASE_URL | Public address for the voice webhooks if it differs from APP_URL, such as when you sit behind a proxy | APP_URL |
PHONE_AGENT_MAX_TURNS | Longest call in exchanges | 14 |
PHONE_AGENT_MAX_CALL_SECONDS | Longest call in seconds | 480 |
PHONE_AGENT_MAX_TOOL_ROUNDS | Look-ups it may do in one reply | 4 |
PHONE_AGENT_JOBS_PER_TECH_PER_DAY | Used to work out which days have room | 6 |
Calls cost what Twilio charges for voice minutes plus AI requests. Check both after the first week.
Limits to know about
- It records a booking request or a message. It never books a visit or quotes a firm price.
- It follows what you wrote in Business info. It can still get things wrong, so read transcripts in Admin > Calls for the first few weeks.
- It only runs on Twilio.