Five stages, and you can check every one.

Everything hiy does runs on one five-stage cycle: the Honest Loop. Your material goes in, answers come out with the passage they came from, and the questions it couldn’t answer come back to you, where answering one teaches it permanently.

01 · Sources

Your material goes in. Nothing else does.

Pages, posts, docs, and the lists you keep: that is the whole well. It answers from material you added, and nothing else — no general-knowledge filler, no confident guess dressed as an answer. And from the first source, a plain reading of where your agent stands tells you the single most useful thing to add next.

  • Answers drawn only from material you added
  • Test privately before anyone sees it
  • Guidance that keeps going after launch
Where this agent stands

02 · Cited answer

Every answer carries the passage it stands on.

Every grounded answer carries the passage it came from. Open the citation and you read the actual source text — not a title, the evidence — and it links back to where it lives on your own page.

  • Passage-level citations a visitor can open
  • Links back to where it lives on your page
  • Grounded in what you actually made
Why answers show sources

03 · Honest gap

Two refusals, and neither one guesses.

Two refusals, both deliberate. Off your topics, it declines in your tone — you say what you cover and how firmly everything else is turned away. And when your own material runs out, it admits the gap and shows how many searches it ran before giving up, instead of inventing an answer. No plan can remove this.

  • Strict, balanced, or loose — your call
  • Declines trivia, coding help, homework
  • Gaps admitted, not papered over
What it answers

04 · Teach

The gap becomes a question in your queue.

The question it couldn’t answer doesn’t vanish — it queues for you, tied to the conversation that raised it. Answer it one time and the gap closes permanently; your agent uses your words from then on.

  • Unanswered questions queue for you
  • One answer teaches it permanently
A note on gaps

05 · Reindex

It gets better because it was used.

Your answer becomes a cited source like any other, and the numbers show it: the topics your audience repeats, and how many of the week’s questions raised nothing for you to teach.

  • Most-asked topics and recent conversations
  • Questions that raised nothing to teach
  • A daily or weekly summary by email
Questions that raised nothing to teach

The same five stages, in the words the code uses.

The loop above is what a visitor experiences. Underneath it there is one path through six objects, and they have names — the retrieval index, the grounding check, the knowledge gap. The path is drawn stage by stage in the docs, where you can follow it against the code rather than take the claim.

How one question becomes an answer

What holds the whole thing up

  1. 01organizations

    Organisation

    Belongs to nothing: it is the top

    One per account, made with it. It is the billing subject and the owner of a twin’s signing secret. A team agent’s conversations carry no per-person trail: api/twin/conversation refuses a transcript for an internal twin outright, so an admin sees the topics and the gaps and not who asked.

  2. 02twins

    Twin

    Belongs to an organisation — org_id

    One per slug: every agent is one. Its variant — public_personal, internal or support — decides which model answers, how long an answer may run, and how firmly it declines.

  3. 03sources

    Source

    Belongs to an organisation — org_id; twins subscribe via twin_sources

    One per thing you added: a page, a file, an interview, a correction you wrote. Its type records which. It belongs to the organisation, and one source can feed several twins — each still builds its own index.

  4. 04chunks

    Chunk

    Belongs to a twin — twin_id

    A 180-word window of that text, overlapping the one before it by 30 words. Its origin is source or summary, and a summary chunk’s source_id is null — which is how it is kept from claiming a source it never had.

  5. 05messages

    Answer

    Belongs to a conversation — session_id

    One reply. It may search the index up to 3 times, rewording as it goes, before it either answers or says it has no material.

  6. 06messages.cited_sources

    Citation

    Belongs to an answer

    Built from the passages that answer actually retrieved: at most 3, one per source, none below a 0.25 cosine-similarity floor. Nothing else can be added to the list later.

Every card is a table or a column, not a metaphor for one. The chunk window and its overlap are read out of lib/rag/chunk.ts when this page is built, so they cannot drift from the chunker.

The boundaries are explicit.

The API limits request size, caller volume, answer length, and the lifetime of a signed demo grant. These are enforced boundaries, not performance claims.

Request shape
Message, history, and agent identifier bounds.
Caller rate
Burst, daily visitor, and monthly account allowances.
Answer ceiling
A product-specific maximum response length.
Demo grant
A short-lived signed credential for the public demo.
Read every limit and error shape

One invariant, stated flat: who may talk to a twin is decided in one pure function, and it fails closed.

An audience value nobody taught it about denies rather than defaulting to public, and every denial returns 404 rather than 403 — because a 403 confirms the twin exists, which for a company’s internal twin leaks the one bit an attacker wants.

canAccessTwin lib/twin-access.ts

And when a conversation should become a person.

Optionally let visitors leave their details so you can reply personally — after a few messages, or exactly when your twin couldn’t answer. A new twin asks after a few messages, for an email only, and one tap turns it off. The card is always dismissible; the People list shows what each person asked about, exports as CSV, and deletes anyone any time.

Support Agents and Team Agents never ask. A Support Agent hands the question to your Inbox instead.

Follow-up requests

Run the loop on your own material. Free for 14 days.

Start free
  • 14-day free trial
  • No card needed
  • Paste a URL to start