graph LR %% Define database and special shapes P[prompt] SG[(semantic graph)] VD[(vector database)] LLM[LLM] Z[response] %% Main flow paths P --> Q[generated query] P --> EM[embedding model] %% Upper path through graph elements Q --> SG SG --> W[semantic
random walk] T[thesaurus] --> W W --> GA[graph analytics] %% Lower path through vector elements EM --> SS[vector
similarity search] SS --> VD %% Node embeddings and chunk references SG -.-|chunk references| VD SS -->|node embeddings| SG %% Final convergence GA --> RI[ranked index] VD --> RI RI --> LLM LLM --> Z %% Styling classes classDef dataSource fill:#f4f4f4,stroke:#666,stroke-width:2px; classDef storage fill:#e6f3ff,stroke:#4a90e2,stroke-width:2px; classDef embedding fill:#fff3e6,stroke:#f5a623,stroke-width:2px; classDef lexical fill:#f0e6ff,stroke:#4a90e2,stroke-width:2px; classDef semantic fill:#f0e6ff,stroke:#9013fe,stroke-width:2px; classDef reference fill:#e6ffe6,stroke:#417505,stroke-width:2px; %% Apply styles by layer/type class SDS,UDS dataSource; class SG,VD storage; class EM embedding; class LG lexical; class SG semantic; class ONT,T reference;