AI insights & chat
LineTrail can write summaries of your analytics and answer read-only questions about them with a language model you choose. AI output is never a measurement: every statement must cite the metric records it is based on, and a deterministic check removes anything it can’t support.
How it stays grounded
Section titled “How it stays grounded”Before a statement is kept, it is checked in this order:
- Characters. No invisible or look-alike characters.
- Links. No links, markup or host names.
- Wording. No productivity, ROI, time-saved, causal, speed-up or ranking claims.
- Human authorship. No claim that people wrote code. Unknown is never human, so statements about gaps stay in terms of unknown lines.
- Citations. At least one cited metric record from this request.
- Numbers. Every number must match a value or date of a cited record, within the shown rounding.
- Direction. Rises and falls must agree with the cited change.
Statements that fail are removed. If nothing supported is left, a summary is refused and a chat answer says This is not in the data.
It answers only from what you may see
Section titled “It answers only from what you may see”- Summaries and answers are built as the person asking. A viewer’s answers come from a viewer’s view of the data, with small groups hidden exactly as on the dashboard.
- Chat can only call read-only tools as the caller. Nothing the model writes changes anything.
- A question about another organization gets a fixed answer, without a model call.
- Service tokens can’t use AI features.
What is sent to the model
Section titled “What is sent to the model”Sent: only aggregated metric records the asking person can already read: counts, shares, denominators, durations, token and cost totals, organization, repository and team identifiers, team names, repository keys and the period.
Never sent: source code or diffs, capture-note content, prompts or transcripts, commit messages, pull-request titles, branch names, URLs and file paths, author names or emails, and secrets.
Stored:
| Data | Kept | Default retention |
|---|---|---|
| Summaries | Checked statements and the records they cite | 400 days |
| Chat | Checked answers per person; the question only as a SHA-256 hash | 24 hours |
| Call audit | Model, tokens, cost, outcome; prompt and response only as SHA-256 hashes | 400 days |
The text of a removed statement, a prompt and a raw model answer are never stored.
Bring your own model
Section titled “Bring your own model”LineTrail calls any OpenAI-compatible chat-completions endpoint with a key you provide, hosted or on-prem: for example an OpenAI or Azure-style gateway, OpenRouter, vLLM or Ollama. For chat, the model must support tools. Public endpoints must use https; an operator can allow specific on-prem hosts.
A simulated provider is also available for trials. It sends nothing, needs no key, and every statement it produces is labelled simulated.
Turning it on
Section titled “Turning it on”-
Operator: set
LINETRAIL_AI=onon the API and on the sync worker. Hosted or on-prem models need the server-side sync deployment, because only the sync worker can open the provider key; the API never does. -
Organization admin: in Settings → AI provider, choose the provider (base URL and model id), store the key (write-only), press Test (one fixed sentence, no organization data), then enable it.
-
Everyone signed in (admin, member, viewer) can then request summaries and ask questions.
Turning it off is immediate: an admin disables or deletes the provider, or the operator sets LINETRAIL_AI=off.
Limits and cost controls
Section titled “Limits and cost controls”| Setting | Default |
|---|---|
| Daily token cap (input + output, per organization) | 200,000 |
| Daily cost cap | Optional; applies when prices are set |
| Output tokens per call | 1,024 (summaries up to 4,096, chat rounds up to 2,000) |
Caps are reserved before anything is sent. A chat question uses at most 4 model rounds and 8 tool calls, within 100 seconds; a conversation has at most 20 turns. Quality depends on the model you choose, and hosted models can answer the same question differently from run to run: treat a summary as a reading aid, not a record.