Skip to main content
For technical teams

How it works under the hood

The full TENGWAR architecture: how your documents are processed, how every question is answered, what the operator controls, and the technology it is built on.

From Document to Knowledge

Every step traceable. Every chunk tied back to its source. Section-aware. Multilingual. Audit-ready.

Parsing

Layout, text, assets and fusion, the document is read and structured.

  1. 1Structure detection
    Docling
  2. 2Text extraction
    Docling + OCR model
  3. 3Asset extraction
    OCR model + MinIO
  4. 4Content fusion
    -

Structure & Translation

Section hierarchy, cross-references and language alignment.

  1. 5Context enrichment
    LLM
  2. 6Structure extraction
    Docling
  3. 7Translation
    Translation model
  4. 8Asset description translation
    Translation model

Chunking & Vectorization

Globally optimal boundaries, hybrid index, security-stamped storage.

  1. 9Chunking
    Semantic chunking
  2. 10Contextual retrieval
    LLM
  3. 11Asset linking
    -
  4. 12Structure linking
    -
  5. 13Tokenization
    Tokenizer model
  6. 14Embedding
    Embedding model
  7. 15Storing
    Qdrant
  8. 16Summary generation
    LLM + Qdrant
  9. 17Acceptance
    -

Restart-safe

Heartbeat from the ingester to the backend lets the document workflow state machine detect stuck documents and recover them.

Security baked into the index

Clearance level and department IDs stamped onto every Qdrant point at storage time. The query layer participates in the search, not on top of it.

Structure detection

Structural analysis with Docling: section hierarchy, tables, and cross-references are preserved across all 18 supported formats, native or scanned.

Semantic OCR

For scanned documents we use a state-of-the-art vision-language model instead of classic OCR, capturing meaning and context, not just characters.

Figures and tables

Every figure and table is extracted as an image and described with type-specific prompts, so visual content becomes retrievable through its description.

Structural translation

Per-element translation preserves the original document's structure; content stays aligned across languages without collapsing the hierarchy.

Semantic chunking

Instead of splitting by paragraphs, fixed length, or sliding windows, we cluster content by semantic similarity so each fragment represents a coherent idea; section-aware, so fragments never cross headings.

Contextual retrieval

Each fragment can be enriched with LLM-generated context before indexing, improving relevance when retrieved standalone.

Hybrid index

Each fragment is indexed in parallel with a state-of-the-art embedding model for meaning and with BM25 for exact lexical matching. Searches combine both signals.

Hierarchical retrieval

Searches can filter at the document level first, then section, then fragment, using optional summaries at each level to speed up and focus queries.

Document detail, knowledge tab: extracted facts, entities and conflicts per document

Document detail, knowledge tab: extracted facts, entities and conflicts per document

Inside the Engine

How a question becomes an answer, every step traceable, every claim cited.

Retrieval and answering flow

  1. User query
    What the user types in the chat.
  2. Smart routing
    The system reads the question and picks the right path, most questions never need an LLM.
  3. Question preparation
    The system clarifies pronouns, translates if needed, identifies the intent and rewrites the query into useful variants.
  4. Multi-channel search
    Four searches run in parallel against your documents, every angle covered at the same time.
  5. Smart re-ranking
    A re-ranker model re-orders the candidates by how well each one really answers the original question.
  6. Self-correction
    Three independent checks catch low-confidence or empty answers and re-run the search with a corrected query before responding.
  7. Context preparation
    Picks the highest-value fragments, places them where the LLM reads them best, and attaches the citations.
  8. One agent, many tools
    A single agent grounds the answer in the retrieved context and calls tools, web search, document generation, when the question needs them.
  9. Agent response
    Streamed back token-by-token, with every citation linked to the exact source document and page.

Two-path routing

Simple, unambiguous questions take the fast deterministic path with zero LLM cost. Only the genuinely complex ones spin up the full reasoning pipeline.

Hybrid search

Combines semantic search ("what does it mean?"), classic keyword search ("these exact words") and a knowledge-graph walk ("how does this connect?"), and weights them based on what kind of question you asked.

Three-layer self-correction

If the system can't find a confident answer, it re-runs retrieval with a corrected query before responding. It catches its own bad answers before you do.

Graph-powered search

The fourth channel walks the knowledge graph: it connects entities across documents and brings back facts that neither semantic nor keyword search can reach on their own.

Multi-part questions

Ask several things at once and the system splits them, answers each independently, and tells the LLM how confident it is in each piece.

Live activity & citations

You see what the agent is doing, which tool it is calling and which documents it is citing, in real time, while the answer is still forming.

Security inside the search

Permission checks happen inside the search query itself, not on top of it. Users only see fragments their clearance and department allow.

Full audit trail

Every tool call, every search, every answer, logged with user, department, status and timing. Filterable for compliance reviews and incident response.

Jobs that outlive the chat

Deep investigations, bulk analysis, scheduled digests and document generation run as durable jobs with their own inbox: enqueue, disconnect, and collect the results when they're done.

Your Documents Become a Knowledge Graph

TENGWAR distills your corpus into verified facts, who, what, and how they relate, and turns them into a graph that answers questions plain search can't.

"How much do we spend with the supplier of the Valencia plant?"
€120,000 — found by connecting a contract and an invoice.
  1. 1

    Fact extraction

    During the processing window, the chat model reads every chunk of the corpus and extracts subject–relation–object facts with a confidence level. A support check discards facts the text doesn't actually back.

  2. 2

    Ontology promotion

    Entity and relation types aren't hand-defined: they are promoted from the corpus itself into a stable ontology that every new fact is normalized against.

  3. 3

    Conflicts & bitemporality

    Contradicting facts are detected and resolved with their evidence. Every fact records when it became true and when it stopped being true, bitemporal validity, and nothing is silently overwritten.

  4. 4

    Graph projection

    Entities and facts live in relational tables, no graph database, and are projected into an in-memory, permission-maskable snapshot at query time. Each fact's vectors are indexed in Qdrant.

  5. 5

    PPR retrieval channel

    On every question, a Personalized PageRank walk runs in parallel with dense and lexical search; fusion weights each channel by the question's intent, with the same ACL applied to the facts.

  6. 6

    Cited answers

    Every fact keeps the chunk and document it came from, so graph-backed answers cite the exact source, just like every other channel.

One store, two spaces: corpus facts and per-user memory share the same engine, separated by design.

Facts, not fragments

Every entry in the graph is a subject–relation–object fact extracted by the AI and tied back to the exact passage it came from.

A fourth search channel

Alongside hierarchy, meaning and keywords, a graph walk connects entities across documents, answering questions no single fragment contains.

Knows when facts change

Each fact records when it became true and when it stopped being true, so answers never mix yesterday's reality with today's.

Contradictions get resolved

When two documents disagree, the conflict engine surfaces both facts with their evidence and records the resolution, nothing is silently overwritten.

Explore it visually

An interactive graph of the whole corpus: filter by entity type, zoom from the big picture to a single fact, and jump from any claim to its source document.

Permissions carry over

The graph enforces the same department-level access control as every other channel, nobody reaches facts from documents they can't open.

The real corpus graph: 227 entities, filterable by type, every node traceable to its source

The real corpus graph: 227 entities, filterable by type, every node traceable to its source

Adapts to You, Privately

TENGWAR adapts to each user without sending anything to a third party. The implicit (what it learns) and the explicit (your personal prompt), both feeding the same private workspace.

How TENGWAR adapts to youA circular feedback loop with five steps, interaction, fact extraction, your personal graph, better retrieval and routing, answers tuned to you, wrapped inside a private workspace, with a parallel Personal Prompt callout feeding into the interaction step.your private workspacePersonal PromptDeclared instructions youcontrol, they join everyinteraction.1You interact2Factextraction3Your personalgraph4Betterretrieval &routing5Answers tunedto you

Two ways to adapt

TENGWAR learns from how you work, and you can also tell it directly with a personal prompt. Both stay inside your private workspace.

A knowledge graph of your own

What TENGWAR learns about you is stored as structured facts, each weighted by confidence, forming a personal graph you can explore visually at any time.

You confirm what it learns

New facts arrive as candidates you confirm or dismiss. When two facts contradict each other, TENGWAR shows both with their evidence and you decide which one wins.

You stay in control

Edit or delete any fact, backed by a full decision history. Erase everything in one action, with a 24-hour window to undo it.

Your prompt is yours

The instructions you give TENGWAR about yourself are never logged in telemetry, redacted at the source.

Strict isolation

Your personal knowledge is yours alone. By design, no other user's session can see it, search it, or leak into your context.

Admin & Operations

  • Turnkey doesn't mean opaque. Here's what the operator runs.
  • Every agent action, every tool call, every login, auditable.
  • Tune the agents. Schedule the ingestion. Watch the GPUs.

Technology Stack

Built with enterprise-grade technologies for reliability and performance.

Frontend
.NET 10 Blazor
.NET MAUI
MudBlazor
Backend
.NET 10 REST API
Agent FrameworkAgent Framework
AI Models
QwenQwen3.6-35B-A3B
BGE-M3 Embeddings
BGE-Reranker-v2-m3
GLMGLM-OCR 0.9B
M2M-100 1.2B
vLLM
Documents & Rendering
DoclingDocling
Gotenberg
Mermaid
Flint Charts
Infrastructure
PostgreSQL
MinIO
Qdrant
RabbitMQ
Thorondor Web Search
Docker
Docker
Powered by
NVIDIA DGX Spark
128GB LPDDR5X RAM
Grace ARM64 CPU
Blackwell GB10 GPU
TENGWAR

Enterprise AI Without Compromise

See how TENGWAR works with your documents. We'll set up a private demo with your real use case.

100%
Private
18
Formats
100+
Languages

Contact Us