<?xml version="1.0" encoding="UTF-8"?>
<mxfile host="eli.ai" agent="eli.ai diagram exporter" version="1">
  <diagram id="ingestion-to-graph-f653cc71" name="Ingestion to graph">
    <mxGraphModel dx="1600" dy="1200" grid="1" gridSize="10" guides="1" tooltips="1" connect="1" arrows="1" fold="1" page="1" pageScale="1" pageWidth="1600" pageHeight="1200" math="0" shadow="0">
      <root>
        <mxCell id="0"/>
        <object id="1" label="Ingestion to graph" schemaVersion="1" diagramId="ingestion-to-graph-f653cc71" canonicalAppearanceKey="tsx:src/app/(docs)/docs/architecture/page.tsx:INGESTION_CHART#1" sourceSha256="f653cc712759ab5cc0c683725f9f57b99bb7d66a80802dfd9c1b0ff78d3edebf" metadataPayloadSha256="66bc3c4bc3d9085fb212ef955c3330c4a4c3be306b2a112089438769e34df86f" generationKey="43ef0426df9ed8eb0925b3eb67efee817f0416e1438e8ea73a58bb7defd90905" concepts="[&quot;Ingestion to graph&quot;,&quot;Public overview diagrams&quot;,&quot;Ingestion&quot;]" keywords="[&quot;Postgres FTS (tsvector)&quot;,&quot;Output.object → fallback&quot;,&quot;non-destructive merges → canonical_relations&quot;,&quot;chunk (heading-aware)&quot;,&quot;deterministic edges&quot;,&quot;embedChunks() (vector)&quot;,&quot;LLM per chunk&quot;,&quot;vault save or connector upsert&quot;,&quot;binary → installed extractors → markdown&quot;,&quot;zero-LLM entities + mentions&quot;,&quot;extractDocument() (worker)&quot;,&quot;schema-in-prompt + repair&quot;,&quot;typed entities + relations + evidence&quot;,&quot;the serve-time edge table&quot;,&quot;UI / API / import (text + binary) / connector&quot;,&quot;resolveWikilinks()&quot;,&quot;deriveCooccurrenceRelations()&quot;]" application="{&quot;name&quot;:&quot;eli-ai&quot;,&quot;version&quot;:&quot;0.1.0&quot;}" packages="{&quot;mermaid&quot;:&quot;11.16.0&quot;,&quot;mermaidCli&quot;:&quot;11.16.0&quot;,&quot;playwright&quot;:&quot;1.62.1&quot;,&quot;playwrightCore&quot;:&quot;1.62.1&quot;,&quot;puppeteer&quot;:&quot;25.6.0&quot;,&quot;puppeteerCore&quot;:&quot;25.6.0&quot;}" environment="{&quot;architecture&quot;:&quot;x64&quot;,&quot;containerImage&quot;:&quot;playwright:v1.62.1-noble@sha256:c091b21d9fae78c76e85cd4356431e9b018402f172a214fc7d7a5e9a7e29d8ac+node:26.3.1-bookworm-slim@sha256:209558c3e5e40e8adff68959d3c2ba7cd73723e716d89196878a0c362fa1e109&quot;,&quot;node&quot;:&quot;v26.3.1&quot;,&quot;platform&quot;:&quot;linux&quot;,&quot;yarn&quot;:&quot;4.17.1&quot;}" renderer="{&quot;browser&quot;:{&quot;executableSha256&quot;:&quot;0b20b130e7edd9dd51873be867761295fe0cfad490c2b9a64f95bd3cfc08fa71&quot;,&quot;name&quot;:&quot;chromium&quot;,&quot;revision&quot;:&quot;1234&quot;,&quot;version&quot;:&quot;151.0.7922.34&quot;},&quot;font&quot;:{&quot;family&quot;:&quot;Eli Diagram Inter Variable&quot;,&quot;fileSha256&quot;:&quot;3100e775e8616cd2611beecfa23a4263d7037586789b43f035236a2e6fbd4c62&quot;,&quot;licenseSha256&quot;:&quot;3b0a5fca3d17942cde889069889dedbbbd075e9b599968c82a95f4d944e9b345&quot;},&quot;mermaidConfigSha256&quot;:&quot;68c10966fe84406ee626034d58bfabd555df9f65f691204b7c46db24038da101&quot;,&quot;themeCssSha256&quot;:&quot;c80287a78d80ad63d27bd5ca348b2ef9a7e2f44da289e436be6484ea28a1b033&quot;}" adapterVersions="{&quot;diagramGenerator&quot;:&quot;2&quot;,&quot;drawioFlowchart&quot;:&quot;1&quot;,&quot;drawioGantt&quot;:&quot;1&quot;,&quot;drawioSequence&quot;:&quot;1&quot;,&quot;drawioState&quot;:&quot;1&quot;}" mermaidType="flowchart" direction="LR" generatedAt="2026-08-12T23:39:26.611Z" mermaidSource="flowchart LR&#10;  Caller[&quot;UI / API / import (text + binary) / connector&quot;] --&gt; Save[&quot;vault save or connector upsert&lt;br/&gt;binary → installed extractors → markdown&quot;]&#10;  Save --&gt; Chunk[&quot;chunk (heading-aware)&quot;]&#10;  Chunk --&gt; FTS[&quot;Postgres FTS (tsvector)&quot;]&#10;  Caller -. dispatch .-&gt; Wiki[&quot;resolveWikilinks()&lt;br/&gt;zero-LLM entities + mentions&quot;]&#10;  Wiki --&gt; Cooc[&quot;deriveCooccurrenceRelations()&lt;br/&gt;deterministic edges&quot;]&#10;  Caller -. direct / enqueue .-&gt; Embed[&quot;embedChunks() (vector)&quot;]&#10;  Caller -. enqueue .-&gt; Extract[&quot;extractDocument() (worker)&quot;]&#10;  Extract --&gt; LLM[&quot;LLM per chunk&lt;br/&gt;Output.object → fallback:&lt;br/&gt;schema-in-prompt + repair&quot;]&#10;  LLM --&gt; Apply[&quot;typed entities + relations + evidence&lt;br/&gt;non-destructive merges → canonical_relations&quot;]&#10;  Cooc --&gt; Canon[(&quot;canonical_relations&lt;br/&gt;(the serve-time edge table)&quot;)]&#10;  Apply --&gt; Canon">
          <mxCell parent="0"/>
        </object>
        <object id="n:Caller" label="UI / API / import (text + binary) / connector" mermaidId="Caller" mermaidShape="rectangle">
          <mxCell parent="1" vertex="1" style="fillColor=#ECECFF;fontColor=#333333;html=1;rounded=0;strokeColor=#9370DB;whiteSpace=wrap;">
            <mxGeometry x="8" y="206.5" width="256" height="76" as="geometry"/>
          </mxCell>
        </object>
        <object id="n:Save" label="vault save or connector upsertbinary → installed extractors → markdown" mermaidId="Save" mermaidShape="rectangle">
          <mxCell parent="1" vertex="1" style="fillColor=#ECECFF;fontColor=#333333;html=1;rounded=0;strokeColor=#9370DB;whiteSpace=wrap;">
            <mxGeometry x="438.0625" y="8" width="256" height="124" as="geometry"/>
          </mxCell>
        </object>
        <object id="n:Chunk" label="chunk (heading-aware)" mermaidId="Chunk" mermaidShape="rectangle">
          <mxCell parent="1" vertex="1" style="fillColor=#ECECFF;fontColor=#333333;html=1;rounded=0;strokeColor=#9370DB;whiteSpace=wrap;">
            <mxGeometry x="755.726563" y="44" width="232.671875" height="52" as="geometry"/>
          </mxCell>
        </object>
        <object id="n:FTS" label="Postgres FTS (tsvector)" mermaidId="FTS" mermaidShape="rectangle">
          <mxCell parent="1" vertex="1" style="fillColor=#ECECFF;fontColor=#333333;html=1;rounded=0;strokeColor=#9370DB;whiteSpace=wrap;">
            <mxGeometry x="1078.53125" y="44" width="234.671875" height="52" as="geometry"/>
          </mxCell>
        </object>
        <object id="n:Wiki" label="resolveWikilinks()zero-LLM entities + mentions" mermaidId="Wiki" mermaidShape="rectangle">
          <mxCell parent="1" vertex="1" style="fillColor=#ECECFF;fontColor=#333333;html=1;rounded=0;strokeColor=#9370DB;whiteSpace=wrap;">
            <mxGeometry x="744.0625" y="231" width="256" height="100" as="geometry"/>
          </mxCell>
        </object>
        <object id="n:Cooc" label="deriveCooccurrenceRelations()deterministic edges" mermaidId="Cooc" mermaidShape="rectangle">
          <mxCell parent="1" vertex="1" style="fillColor=#ECECFF;fontColor=#333333;html=1;rounded=0;strokeColor=#9370DB;whiteSpace=wrap;">
            <mxGeometry x="1050.0625" y="243" width="291.609375" height="76" as="geometry"/>
          </mxCell>
        </object>
        <object id="n:Embed" label="embedChunks() (vector)" mermaidId="Embed" mermaidShape="rectangle">
          <mxCell parent="1" vertex="1" style="fillColor=#ECECFF;fontColor=#333333;html=1;rounded=0;strokeColor=#9370DB;whiteSpace=wrap;">
            <mxGeometry x="445.4375" y="182" width="241.25" height="52" as="geometry"/>
          </mxCell>
        </object>
        <object id="n:Extract" label="extractDocument() (worker)" mermaidId="Extract" mermaidShape="rectangle">
          <mxCell parent="1" vertex="1" style="fillColor=#ECECFF;fontColor=#333333;html=1;rounded=0;strokeColor=#9370DB;whiteSpace=wrap;">
            <mxGeometry x="438.0625" y="405" width="256" height="76" as="geometry"/>
          </mxCell>
        </object>
        <object id="n:LLM" label="LLM per chunkOutput.object → fallback:schema-in-prompt + repair" mermaidId="LLM" mermaidShape="rectangle">
          <mxCell parent="1" vertex="1" style="fillColor=#ECECFF;fontColor=#333333;html=1;rounded=0;strokeColor=#9370DB;whiteSpace=wrap;">
            <mxGeometry x="744.0625" y="381" width="256" height="124" as="geometry"/>
          </mxCell>
        </object>
        <object id="n:Apply" label="typed entities + relations + evidencenon-destructive merges → canonical_relations" mermaidId="Apply" mermaidShape="rectangle">
          <mxCell parent="1" vertex="1" style="fillColor=#ECECFF;fontColor=#333333;html=1;rounded=0;strokeColor=#9370DB;whiteSpace=wrap;">
            <mxGeometry x="1067.867188" y="381" width="256" height="124" as="geometry"/>
          </mxCell>
        </object>
        <object id="n:Canon" label="canonical_relations(the serve-time edge table)" mermaidId="Canon" mermaidShape="cylinder">
          <mxCell parent="1" vertex="1" style="backgroundOutline=1;boundedLbl=1;fillColor=#ECECFF;fontColor=#333333;html=1;shape=cylinder3;size=15;strokeColor=#9370DB;whiteSpace=wrap;">
            <mxGeometry x="1391.671875" y="295.327434" width="214" height="133.345133" as="geometry"/>
          </mxCell>
        </object>
        <object id="e:L_Caller_Save_0" label="" mermaidId="L_Caller_Save_0" mermaidKind="relationship">
          <mxCell parent="1" source="n:Caller" target="n:Save" edge="1" style="edgeStyle=orthogonalEdgeStyle;endArrow=block;endFill=1;html=1;jettySize=auto;orthogonalLoop=1;rounded=0;strokeColor=#333333;">
            <mxGeometry relative="1" as="geometry">
              <mxPoint x="182.826289" y="206.5" as="sourcePoint"/>
              <mxPoint x="438.0625" y="70" as="targetPoint"/>
              <Array as="points">
                <mxPoint x="351.03125" y="70"/>
              </Array>
            </mxGeometry>
          </mxCell>
        </object>
        <object id="e:L_Save_Chunk_0" label="" mermaidId="L_Save_Chunk_0" mermaidKind="relationship">
          <mxCell parent="1" source="n:Save" target="n:Chunk" edge="1" style="edgeStyle=orthogonalEdgeStyle;endArrow=block;endFill=1;html=1;jettySize=auto;orthogonalLoop=1;rounded=0;strokeColor=#333333;">
            <mxGeometry relative="1" as="geometry">
              <mxPoint x="694.0625" y="70" as="sourcePoint"/>
              <mxPoint x="755.726563" y="70" as="targetPoint"/>
              <Array as="points">
                <mxPoint x="719.0625" y="70"/>
              </Array>
            </mxGeometry>
          </mxCell>
        </object>
        <object id="e:L_Chunk_FTS_0" label="" mermaidId="L_Chunk_FTS_0" mermaidKind="relationship">
          <mxCell parent="1" source="n:Chunk" target="n:FTS" edge="1" style="edgeStyle=orthogonalEdgeStyle;endArrow=block;endFill=1;html=1;jettySize=auto;orthogonalLoop=1;rounded=0;strokeColor=#333333;">
            <mxGeometry relative="1" as="geometry">
              <mxPoint x="988.398438" y="70" as="sourcePoint"/>
              <mxPoint x="1078.53125" y="70" as="targetPoint"/>
              <Array as="points">
                <mxPoint x="1025.0625" y="70"/>
              </Array>
            </mxGeometry>
          </mxCell>
        </object>
        <object id="e:L_Caller_Wiki_0" label="dispatch" mermaidId="L_Caller_Wiki_0" mermaidKind="relationship">
          <mxCell parent="1" source="n:Caller" target="n:Wiki" edge="1" style="edgeStyle=orthogonalEdgeStyle;endArrow=block;endFill=1;html=1;jettySize=auto;orthogonalLoop=1;rounded=0;strokeColor=#333333;">
            <mxGeometry relative="1" as="geometry">
              <mxPoint x="264" y="266.227075" as="sourcePoint"/>
              <mxPoint x="744.0625" y="281" as="targetPoint"/>
              <Array as="points">
                <mxPoint x="351.03125" y="281"/>
                <mxPoint x="566.0625" y="281"/>
                <mxPoint x="719.0625" y="281"/>
              </Array>
            </mxGeometry>
          </mxCell>
        </object>
        <object id="e:L_Wiki_Cooc_0" label="" mermaidId="L_Wiki_Cooc_0" mermaidKind="relationship">
          <mxCell parent="1" source="n:Wiki" target="n:Cooc" edge="1" style="edgeStyle=orthogonalEdgeStyle;endArrow=block;endFill=1;html=1;jettySize=auto;orthogonalLoop=1;rounded=0;strokeColor=#333333;">
            <mxGeometry relative="1" as="geometry">
              <mxPoint x="1000.0625" y="281" as="sourcePoint"/>
              <mxPoint x="1050.0625" y="281" as="targetPoint"/>
              <Array as="points">
                <mxPoint x="1025.0625" y="281"/>
              </Array>
            </mxGeometry>
          </mxCell>
        </object>
        <object id="e:L_Caller_Embed_0" label="direct / enqueue" mermaidId="L_Caller_Embed_0" mermaidKind="relationship">
          <mxCell parent="1" source="n:Caller" target="n:Embed" edge="1" style="edgeStyle=orthogonalEdgeStyle;endArrow=block;endFill=1;html=1;jettySize=auto;orthogonalLoop=1;rounded=0;strokeColor=#333333;">
            <mxGeometry relative="1" as="geometry">
              <mxPoint x="264" y="222.772925" as="sourcePoint"/>
              <mxPoint x="445.4375" y="208" as="targetPoint"/>
              <Array as="points">
                <mxPoint x="351.03125" y="208"/>
              </Array>
            </mxGeometry>
          </mxCell>
        </object>
        <object id="e:L_Caller_Extract_0" label="enqueue" mermaidId="L_Caller_Extract_0" mermaidKind="relationship">
          <mxCell parent="1" source="n:Caller" target="n:Extract" edge="1" style="edgeStyle=orthogonalEdgeStyle;endArrow=block;endFill=1;html=1;jettySize=auto;orthogonalLoop=1;rounded=0;strokeColor=#333333;">
            <mxGeometry relative="1" as="geometry">
              <mxPoint x="177.164673" y="282.5" as="sourcePoint"/>
              <mxPoint x="438.0625" y="443" as="targetPoint"/>
              <Array as="points">
                <mxPoint x="351.03125" y="443"/>
              </Array>
            </mxGeometry>
          </mxCell>
        </object>
        <object id="e:L_Extract_LLM_0" label="" mermaidId="L_Extract_LLM_0" mermaidKind="relationship">
          <mxCell parent="1" source="n:Extract" target="n:LLM" edge="1" style="edgeStyle=orthogonalEdgeStyle;endArrow=block;endFill=1;html=1;jettySize=auto;orthogonalLoop=1;rounded=0;strokeColor=#333333;">
            <mxGeometry relative="1" as="geometry">
              <mxPoint x="694.0625" y="443" as="sourcePoint"/>
              <mxPoint x="744.0625" y="443" as="targetPoint"/>
              <Array as="points">
                <mxPoint x="719.0625" y="443"/>
              </Array>
            </mxGeometry>
          </mxCell>
        </object>
        <object id="e:L_LLM_Apply_0" label="" mermaidId="L_LLM_Apply_0" mermaidKind="relationship">
          <mxCell parent="1" source="n:LLM" target="n:Apply" edge="1" style="edgeStyle=orthogonalEdgeStyle;endArrow=block;endFill=1;html=1;jettySize=auto;orthogonalLoop=1;rounded=0;strokeColor=#333333;">
            <mxGeometry relative="1" as="geometry">
              <mxPoint x="1000.0625" y="443" as="sourcePoint"/>
              <mxPoint x="1067.867188" y="443" as="targetPoint"/>
              <Array as="points">
                <mxPoint x="1025.0625" y="443"/>
              </Array>
            </mxGeometry>
          </mxCell>
        </object>
        <object id="e:L_Cooc_Canon_0" label="" mermaidId="L_Cooc_Canon_0" mermaidKind="relationship">
          <mxCell parent="1" source="n:Cooc" target="n:Canon" edge="1" style="edgeStyle=orthogonalEdgeStyle;endArrow=block;endFill=1;html=1;jettySize=auto;orthogonalLoop=1;rounded=0;strokeColor=#333333;">
            <mxGeometry relative="1" as="geometry">
              <mxPoint x="1341.671875" y="281" as="sourcePoint"/>
              <mxPoint x="1391.671875" y="312.12262" as="targetPoint"/>
              <Array as="points">
                <mxPoint x="1366.671875" y="281"/>
              </Array>
            </mxGeometry>
          </mxCell>
        </object>
        <object id="e:L_Apply_Canon_0" label="" mermaidId="L_Apply_Canon_0" mermaidKind="relationship">
          <mxCell parent="1" source="n:Apply" target="n:Canon" edge="1" style="edgeStyle=orthogonalEdgeStyle;endArrow=block;endFill=1;html=1;jettySize=auto;orthogonalLoop=1;rounded=0;strokeColor=#333333;">
            <mxGeometry relative="1" as="geometry">
              <mxPoint x="1323.867188" y="443" as="sourcePoint"/>
              <mxPoint x="1391.671875" y="411.87738" as="targetPoint"/>
              <Array as="points">
                <mxPoint x="1366.671875" y="443"/>
              </Array>
            </mxGeometry>
          </mxCell>
        </object>
      </root>
    </mxGraphModel>
  </diagram>
</mxfile>
