Evolving LLMOps Architecture for Enterprise Supplier Discovery

various · E-commerce · 2024 · source Agentic: yes · promotional bias: low · source-backed · extracted with prompt 0.5.6 (schema v2)

Generated from extraction.json — do not edit by hand. Every claim cites verbatim source evidence; stated means the quote directly asserts the claim, implied means it supports it indirectly.

Problem

Domain: Enterprise supplier discovery

Scoutbee needed to turn LLMs into a trustworthy supplier-discovery product for enterprise supply-chain teams, but early API-based chat suffered from hallucinated suppliers, weak domain understanding, privacy concerns, and hard-to-debug agent behavior.

Constraints:

Architecture

Scoutbee evolved from a ChatGPT API prototype into a layered supplier-discovery architecture. The system added self-hosted/open-source LLM serving for privacy, domain-adapted agents and Graphs-of-Thought guardrails, RAG with Chain-of-Thought query decomposition over knowledge-graph data, citation-backed answers, observability over conversations and results, LLM-assisted data expansion, human validation, third-party data integration, and Ray/Anyscale as a universal compute layer for ML, LLM, and data workloads.

Diagram confidence: reconstructed (reconstructed from prose).

flowchart LR
  supplier-discovery-user-interface["Supplier discovery user interface"] --> query-understanding-layer["Query understanding layer"]
  query-understanding-layer --> graph-of-thought-guardrails["Graph-of-Thought guardrails"]
  query-understanding-layer --> chain-of-thought-planner["Chain-of-Thought planner"]
  llm-api-layer["LLM API layer"] --> chain-of-thought-planner
  open-source-llm-serving["Open-source LLM serving"] --> llm-api-layer
  chain-of-thought-planner --> knowledge-graph["Knowledge graph"]
  data-expansion-pipeline["Data expansion pipeline"] --> knowledge-graph
  human-validation-loop["Human validation loop"] --> data-expansion-pipeline
  universal-compute-framework["Universal compute framework"] --> open-source-llm-serving
  universal-compute-framework --> data-expansion-pipeline
  knowledge-graph --> grounded-answer-composer["Grounded answer composer"]
  graph-of-thought-guardrails --> grounded-answer-composer
  grounded-answer-composer --> observability-and-product-metrics-store["Observability and product metrics store"]
  grounded-answer-composer --> supplier-discovery-user-interface
Drag to pan · scroll or use +/− to zoom · reconstructed from the source's described component topology

Components

Component Role Interacts with
Supplier discovery user interface Captures enterprise supplier requests and conversational follow-up questions. Query understanding layer, Grounded answer composer
Query understanding layer Transforms open-ended supplier stories into standard forms and multiple data queries. Chain-of-Thought planner, Graph-of-Thought guardrails
LLM API layer Hosts either provider-backed or open-source language models behind Scoutbee's application. Chain-of-Thought planner, Grounded answer composer
Open-source LLM serving Provides privacy-preserving model hosting through LLaMA-13B and FastChat API. LLM API layer, Universal compute framework
Graph-of-Thought guardrails Track business-process state and invoke guardrails appropriate to the user's point in the process. Query understanding layer, Grounded answer composer
Chain-of-Thought planner Breaks supplier requests into reasoning steps, query rewrites, and data retrieval calls. Knowledge graph, Grounded answer composer
Knowledge graph Serves as the system of record for supplier facts, domain relationships, and provenance. Chain-of-Thought planner, Data expansion pipeline, Grounded answer composer
Data expansion pipeline Uses superior LLMs, human validation, domain facts, synonyms, and third-party providers to expand data coverage. Knowledge graph, Human validation loop, Universal compute framework
Human validation loop Validates LLM-generated training data and gold-standard annotations. Data expansion pipeline
Observability and product metrics store Stores conversation data, shown results, metadata, and metrics for reliability improvement. Grounded answer composer, Chain-of-Thought planner
Universal compute framework Runs ML, LLM, and data workloads through Ray/Anyscale instead of separate Spark-heavy pipelines. Open-source LLM serving, Data expansion pipeline
Grounded answer composer Summarizes retrieved supplier facts and exposes citations or missing-data paths to users. Supplier discovery user interface, Knowledge graph, Graph-of-Thought guardrails, Observability and product metrics store

Data flow

A user describes a supplier need, the system standardizes and may split the request, Chain-of-Thought prompting plans data calls, retrieval queries the knowledge graph and data partners, guardrails follow the user's business-process state, the LLM summarizes grounded supplier results with citations, and conversation/result telemetry feeds observability and product metrics.

“we break down the problem into a, b, and c, and we need to make data calls to fetch data for these problems. Using this data and using this problem, we can find an answer.”article, stated
“we force it to use data, and we force it to provide citations with data provenance”article, stated

Why this architecture

Scoutbee layered privacy, domain adaptation, guardrails, RAG, knowledge graphs, and scalable compute because each stage exposed a different production failure: generic models lacked domain knowledge, self-hosting increased complexity, agents were hard to debug, RAG reduced hallucinations, and knowledge graphs preserved provenance better than opaque embeddings for enterprise users.

“every time you want to make your system a little bit more robust, a little bit more reliable, there's probably a new part of this new service or new piece of technology that you need to add”article, stated
“we wanted to bring data from different places, and wanted to use our knowledge graph as a system of record”article, stated

Models used: ChatGPT API · LLaMA-13B · FastChat API · LangChain · Chain-of-Thought prompting · Graphs of Thought guardrails · Ragas · Knowledge graph · Ray · Anyscale

Scale

Alternatives considered (roads not taken)

Use a simple ChatGPT API integration in production.

Rejected because: Generic models lacked supplier-domain knowledge, hallucinated suppliers, became too chatty, and raised privacy concerns for customers.

“We did the API. We did some prompt engineering with LangChain. We connected it to ChatGPT's API.”article, stated

Fine-tune or retrain a foundational model for domain adaptation.

Rejected because: Full model training was too expensive and data-intensive compared with in-context/few-shot/agent-based adaptation.

“it took OpenAI about $63 million to ship GPT-4. That's not including the cost of people and infrastructure and everything else.”article, stated

Use open-ended agents as the main planner.

Rejected because: Agent behavior was difficult to test and debug, and agents sometimes skipped APIs or made up answers.

“testing agents was a nightmare. We had absolutely no idea what the agents were trying to do.”article, stated

Represent supplier data primarily with embeddings.

Rejected because: Embeddings were faster for some questions but hard to explain and correct for enterprise users.

“The challenge was explaining embeddings to an enterprise user, when you are working with a very big demographic, and also correcting them was a bit of a challenge.”article, stated

Build all compute-management infrastructure internally.

Rejected because: Ray/Anyscale was faster to operate, supported privacy on Scoutbee infrastructure, and avoided a long build path.

“We chose the path of buy rather than build, because build, at this point, was going to take us a very long time.”article, stated

Patterns

rag-retrieval (hallucination reduction)

Scoutbee forced answers to use retrieved supplier data and citations from its knowledge graph rather than letting the foundational model invent suppliers.

“instead of getting the foundational model to answer the question, we give it data, and we give it context of the conversation, and we force it to use that context”article, stated

guardrails-io-filtering (business-process safety)

Scoutbee modeled the supplier-discovery process as a graph and invoked guardrails depending on the user's process state.

“At any given point in time, we knew where the user was, and we invoked different sorts of guardrails to make sure that LLM is not misleading the user.”article, stated

query-rewriting (retrieval planning)

The system rewrote and split user stories into multiple retrieval queries before summarization.

“we need to maybe understand what the user wants to do, and transform it into a standard form. At some points we might have to actually split this into several queries”article, stated

synthetic-data-generation (data expansion)

Scoutbee used a superior LLM to generate high-quality training data for smaller models, with humans validating the result.

“we took a much superior LLM and we generated high-quality training data to fine-tune a smaller LLM model”article, stated

observability-tracing (product metrics)

Scoutbee stored conversations, shown results, and metadata so the team could inspect behavior and product metrics.

“We basically stored everything. We stored all the data that the users were chatting, the results that we were showing to the users in order to power our observability and product metrics.”article, stated

Tradeoffs

How to satisfy enterprise privacy while using LLMs.

Chose Self-hosted open-source LLM serving over A provider-only ChatGPT API path.

Rationale: Self-hosting increased cost and complexity, but it answered customer privacy concerns before the team over-invested in the product.

“our cost and complexity just went up. We were now responsible for a new piece of software in our stack that we really didn't want to be”article, stated

How to reduce hallucinations in supplier recommendations.

Chose RAG with Chain-of-Thought over knowledge-graph data over Open-ended agents answering from model knowledge.

Rationale: RAG reduced hallucinations and made testing easier because the team could inspect what the LLM was trying to do.

“With introduction of RAGs, hallucinations drastically reduced. We're using knowledge graphs as our data source, and not vector database.”article, stated

How to represent enterprise supplier data.

Chose Knowledge graph as system of record over Primarily vectorizing and embedding all data.

Rationale: The knowledge graph preserved domain relationships and provenance that enterprise users could understand and correct.

“you still had the challenge of understanding, how is this data even related? On top of that, we built a knowledge graph”article, stated

How to scale heterogeneous ML, LLM, and data workloads.

Chose Ray/Anyscale universal compute framework over Continuing separately with Spark-heavy pipelines and custom infrastructure.

Rationale: Ray gave data scientists Python-friendly scaling and reduced maintenance complexity while preserving on-infrastructure privacy.

“we introduced a universal compute framework for ML, LLM, as well as data workloads. We started using this framework called Ray”article, stated

Gotchas (what bit them)

Generic LLMs fabricated realistic-looking suppliers.

Root cause: The foundational model lacked supplier-discovery domain knowledge and was allowed to answer without grounding.

Resolution: Move to RAG over knowledge-graph data with citations and provenance.

“They were results that were being fabricated by the large language model.”article, stated

Privacy concerns could invalidate the whole development path.

Root cause: Enterprise customers did not want production supplier-discovery workloads integrated with external provider APIs.

Resolution: Test whether open-source LLMs could be hosted by Scoutbee before proceeding further.

“if we did all the development and then realized that data privacy and security was a big concern, all of our work would just go down the drain”article, stated

Agent debugging became a production blocker.

Root cause: The team could not inspect why agents called or skipped data APIs and sometimes made up answers.

Resolution: Replace open-ended agents with Chain-of-Thought/RAG flows that made the reasoning and retrieval path more visible.

“They invoke data APIs at some point. They didn't invoke data APIs at some point. They decided to make up their own answer.”article, stated

Embedding-only approaches were hard to explain to enterprise users.

Root cause: Vector similarity could find answers but did not expose relationships and corrections as clearly as the knowledge graph.

Resolution: Use the knowledge graph as the system of record while continuing some embedding experiments.

“At the moment, everything that we are powering through our product is based on knowledge graphs.”article, stated

Spark-based data pipelines were difficult for the data-science team to operate.

Root cause: Spark's Java/Scala ecosystem and cluster behavior were far from the Python scientific stack the team used.

Resolution: Introduce Ray as a universal compute framework for ML, LLM, and data workloads.

“Spark is written predominantly with Java and Scala, and our data scientists are very much away from that world.”article, stated

Evaluation

Scoutbee evaluated each architecture stage through customer feedback, hallucination behavior, agent debuggability, Ragas-style generation/retrieval scoring, stored conversation/result telemetry, and human validation of generated data.

Metrics: Customer feedback on usefulness and privacy · Hallucination reduction · Generation-vs-retrieval scores from Ragas · Stored conversations, result data, and product metrics · Human validation of generated training data

“We came across the Ragas framework. It's an open-source framework that helps you generate a score between generation and retrieval.”article, stated
“Measure everything, because it can look very cool. You can be allured by the technology. Store all the data, metadata, everything.”article, stated

Outcomes

The architecture supports enterprise supplier discovery for large customers after an 18-month production journey, but the talk does not provide quantitative production traffic numbers.

“it actually tells the user that this calmcoffee supplier who produces coffee beans, they're based out of Brazil, and we found this information from this place”article, stated
“By eliminating agents, testing became a whole lot easier, because we could see exactly what the LLMs were trying to do”article, stated