IRA

v0.2 alpha · open source · MIT

Hey Ira.

A self-hosted voice assistant over your own data and tools. It looks things up on its own, and changes nothing until the owner types a PIN.

Built in Python with FastAPI. You write the tools; Ira answers by text or voice on the web, on Telegram and over an HTTP API.

Ira Example
  1. You: find slots tomorrow
  2. Ira: date: 2026-10-13 weekday: Tuesday free: 09:00, 09:30, 10:30, 11:00, 11:30, 12:30, 14:00, 14:30, 15:30, 16:00, 16:30
  3. You: cancel appointment 3
  4. Ira: I've prepared this: Cancel appointment #3: Riley Demo on Tuesday 13 October at 15:00. Confirm it with your PIN to go ahead.
  5. Needs your PIN

    Cancel appointment #3: Riley Demo on Tuesday 13 October at 15:00

    Expires in 114s

Example. The fictional Sunrise Dental Clinic from examples/clinic, answered by the no-key demo router, which matches keywords. With a real model in the chain you can ask in your own words.

Why it exists

A small business does not need a chatbot that can do anything. It needs one that knows its calendar, stock or orders, answers when the owner's hands are busy, and cannot change anything without the owner saying so.

Hosted models go down, time out or say they are busy.

Fallback model chains

A tier is an ordered list of models: any OpenAI-compatible server (local ones too), the Anthropic API or Amazon Bedrock. On an error, a timeout or a capacity refusal the next model answers, and the one that failed cools down.

A general chatbot knows nothing about your business.

Tools over your own data

You write ordinary typed Python functions. The signature becomes both the JSON schema the model sees and the validation applied before your code runs.

A model can be wrong, confused or talked into things.

Actions only after a PIN

A tool that changes something only creates a proposal with a plain summary. It runs once, after the owner enters the PIN, and the PIN never reaches a model.

People speak the way they speak.

Hinglish and Indian English, in and out

The speech-to-text prompt asks for the words exactly as spoken, in the language spoken, and says plainly not to translate, because speech models sometimes turn a Hinglish sentence into English. A vocabulary list helps with names. For spoken replies, Amazon Polly's voice and language_code settings pick an Indian-English voice.

You cannot trust what you cannot see.

Every call logged, with latency and cost

Each model request writes a row: the model that answered, the ones tried, attempts, seconds, tokens and the cost from your own price table. Never a key or a prompt. A read-only admin API reports the day's p50 and p95 latency.

How a PIN-confirmed action works

Ira may look things up on its own. To change anything it can only propose, and the owner's PIN is what makes the change happen.

  1. 1 · Ask “cancel appointment 3” Text or voice, on any channel.
  2. 2 · Propose cancel_appointment(id=3) Stored as pending for 120 seconds. Nothing has run, and the model is told so.
  3. 3 · PIN From the owner straight to the action guard. Never in the chat history, never sent to a model.
  4. 4 · Run once Done: Cancel appointment #3 … Your function runs exactly once, and the outcome goes to the audit log.
Diagram: a request becomes a pending proposal; only the owner's PIN lets your code run it, once.

How the safety model works

Where you talk to it

One assistant, one conversation store, the same tools and the same PIN on every channel.

Run the example

Python 3.11 or newer. No API key needed: the example clinic runs on a keyword-routing demo provider, not a language model, so phrase things plainly.

Shell
git clone https://github.com/helloupendra/ira.git
cd ira
python3 -m venv .venv
source .venv/bin/activate
pip install -e .

cd examples/clinic
ira demo seed     # fictional appointments
ira setup         # owner email and password
ira pin set       # the PIN that releases actions
ira serve         # http://127.0.0.1:8765

Open http://127.0.0.1:8765, sign in, and try find slots tomorrow, then cancel appointment 3. To put a real model first in the chain, see Getting started.

Status: alpha

IRA is at v0.2: the Ira app, the admin console at /admin and the API behind them are in. It runs end to end; the configuration and API may still change before 1.0.