Supply Chain KG NL Query System Architecture
About This Architecture
Supply chain knowledge graph NL query system combining Azure-hosted Streamlit UI with multi-agent LLM orchestration via OpenRouter, routing natural language questions through Nemotron 120B primary agent with StepFun Flash fallback to generate Cypher queries. The architecture layers user interaction, AI reasoning, query generation, and Neo4j data access, with schema.py providing multi-hop reasoning rules and db.py managing bolt:// connections to Neo4j Desktop. This pattern demonstrates enterprise-grade LLM-to-graph integration, enabling supply chain analysts to query complex supplier-product-distributor-retailer networks without SQL expertise. Fork this diagram on Diagrams.so to customize agent models, add additional fallback chains, or adapt the schema for your domain knowledge graph. The config.py and .env separation ensures secure API key management while maintaining reproducible model selection across environments.
People also ask
How do you build a natural language query interface for a Neo4j knowledge graph using LLM agents with fallback handling?
This diagram shows a production pattern: Streamlit UI captures user questions, routes them through OpenRouter to Nemotron 120B agent which generates Cypher using schema.py rules, with automatic fallback to StepFun Flash on failure. The db.py connector executes validated Cypher against Neo4j, returning results to the analyst without requiring graph query expertise.
- Domain:
- Ml Pipeline
- Audience:
- Data engineers and AI architects building knowledge graph query systems with LLMs
Generated by Diagrams.so — AI architecture diagram generator with native Draw.io output. Fork this diagram, remix it, or download as .drawio, PNG, or SVG.