Scope of the Project

  • Unified Data Access: Consolidate disparate RAG applications across HR, Finance, and General CCS Information into a single, intelligent entry point.
  • Intelligent Query Handling: Automatically decompose complex, compound user prompts into targeted sub-queries for precise context retrieval.
  • Service & Framework Recommendations: Intelligently evaluate user requirements to return tailored top-10 ranked lists for G-Cloud services and procurement frameworks.
  • Iterative Loop Synthesis & Memory: Store intermediate agent results in memory, re-evaluating sub-queries iteratively until a comprehensive final response is compiled.

Frameworks and Technologies Used

  • Agentic Orchestration: LangGraph (graph-based state management, agent looping, and conditional routing)
  • Large Language Models: OpenAI Models (used for agent reasoning, query decomposition, and final answer synthesis)
  • Embeddings: OpenAI text-embedding-ada-002 (for semantic vector search)
  • Vector Store & Retrieval: Azure AI Search (enterprise document retrieval and indexing)
  • Application Framework: Flask (backend API and demonstration interface)

Technical Workflow & Process

The system operates through a state-driven multi-stage pipeline powered by LangGraph:

Multi Agent RAG architecture diagram

Process Steps:

  1. Query Decomposition Stage: Upon receiving a user prompt, the Query Decomposition Agent analyzes the request. If the input is multifaceted (e.g., asking about an HR policy and a G-Cloud vendor simultaneously), it breaks the prompt into a structured list of targeted sub-queries.

  2. Supervisor Routing & Orchestration: The Supervisor Agent initializes an execution loop ($x = 0$). It evaluates each decomposed sub-query and routes it to the relevant specialized downstream agent: * Finance Agent: Retrieves internal financial records and context via Azure AI Search. * HR Agent: Queries internal HR manuals, guidelines, and policy documentation. * G-Cloud Product Agent: Evaluates cloud service requests and outputs a ranked Top-10 list of matching G-Cloud services. * Framework Agent: Processes procurement requirements to generate a ranked Top-10 list of CCS procurement frameworks. * CCS Information Agent: Answers general administrative and organizational inquiries.

  3. Sub-Context Aggregation & Memory: Outputs from all active specialized agents are gathered by an intermediate LLM Summary step and saved to Memory. This maintains execution state and preserves raw context alongside the sub-queries.

  4. Iterative Evaluation ($x = n$ Check): The system evaluates whether all sub-queries in the decomposed list have been resolved ($x = n$). If pending sub-queries remain, the process loops back to the Supervisor Agent ($x = x + 1$) for the next iteration.

  5. Final Synthesis & Response: Once all sub-queries are completed, the Final LLM Summary Agent retrieves the accumulated state from Memory, resolves overlapping information, and formats a single response delivered to the user.

Ask about my work

Ask about my career, education, projects, or blog posts.