Skip to content

Repository files navigation

IrishPulse — Multi-Agent EU AI Act Compliance & Market Intelligence

A LangGraph-powered multi-agent system helping Irish SMEs navigate EU AI Act compliance. Built as a portfolio project demonstrating multi-agent orchestration, hybrid RAG, and LLM evaluation patterns.

Architecture

Three specialist agents coordinated by a LangGraph orchestrator:

Agent Role Reasoning Pattern
Compliance Analyst Classifies AI systems by EU AI Act risk category ReAct (step-by-step reasoning + knowledge retrieval)
Document Intelligence Answers questions from EU AI Act regulatory text Hybrid RAG (ChromaDB vector search + BM25 reranking)
Market Intelligence Summarises Irish AI/regulatory news Tree-of-Thought (multi-branch synthesis)

The orchestrator uses an LLM classifier to route each query to the correct agent automatically.

Stack

Component Tool
Agent orchestration LangGraph
LLM Groq (Llama 3.3-70b-versatile)
Vector store ChromaDB
Embeddings sentence-transformers/all-MiniLM-L6-v2 (local, no API key)
Hybrid retrieval ChromaDB dense search + BM25 reranking
Evaluation RAGAS (faithfulness, answer relevancy, context precision)
Experiment tracking MLflow (R/A/G release gates)
Observability Langfuse (per-request LLM call tracing)
Streaming news Kafka (Docker)
MCP server FastAPI-based Model Context Protocol server
API FastAPI
Containerisation Docker Compose (local), Kubernetes manifests (k8s/)
Structured outputs Pydantic

Knowledge Base

EU AI Act source documents ingested into ChromaDB:

  • Article 5 — Prohibited AI Practices
  • Article 6 — High-Risk AI Classification
  • Articles 9 & 10 — Risk Management & Data Governance Obligations
  • Article 50 — Transparency Obligations (chatbots, deepfakes)

Project Structure

agents/
  orchestrator.py      # LangGraph graph + query routing
  compliance_agent.py  # ReAct reasoning → structured risk classification
  document_agent.py    # Hybrid RAG retrieval + answer generation
  market_agent.py      # Tree-of-Thought news summarisation
  schemas.py           # Pydantic output schemas
ingest/
  ingest_docs.py       # CLI: load documents into ChromaDB
  vector_store.py      # ChromaDB upsert + hybrid retrieval
  embedder.py          # sentence-transformers singleton
evaluation/
  ragas_eval.py        # RAGAS pipeline + R/A/G gate + MLflow logging
streaming/
  news_consumer.py     # Kafka consumer → ChromaDB ingestion
mcp_server/server.py   # MCP-compatible tool server
frontend/app.py        # Streamlit demo UI
api/app.py             # FastAPI REST API
k8s/deployment.yml     # Kubernetes manifests (API + news consumer sidecar)

Quick Start

# 1. Install dependencies
pip install -r requirements.txt

# 2. Copy and fill in environment variables
cp .env.example .env
# Add your GROQ_API_KEY from https://console.groq.com (free, no billing)

# 3. Start infrastructure
docker compose up -d

# 4. Ingest EU AI Act documents
python ingest/ingest_docs.py

# 5. Run the Streamlit demo
python -m streamlit run frontend/app.py

# 6. Or run the CLI
python main.py

Example Queries

  • "We use AI to screen CVs for our Dublin hiring team — what risk category is this under the EU AI Act?" → Compliance agent classifies as High Risk (Annex III, Point 4), cites Article 6, lists conformity assessment obligations

  • "What AI practices are absolutely prohibited under Article 5?" → Document agent retrieves Article 5 chunks, lists all 7 prohibited practices with citations

  • "What transparency obligations apply to our customer service chatbot?" → Document agent retrieves Article 50, explains limited-risk disclosure requirements

Evaluation

Run RAGAS evaluation against ground-truth QA pairs:

python evaluation/sample_eval_set.py

Produces faithfulness, answer relevancy, and context precision scores with an R/A/G release gate logged to MLflow.

Status

Working locally with Docker Compose. Kubernetes manifests written for production deployment (k8s/deployment.yml).

About

Multi-agent EU AI Act compliance system for Irish SMEs. LangGraph orchestrator routes queries across 3 specialist agents (ReAct, RAG, Tree-of-Thought). ChromaDB + BM25 hybrid retrieval, RAGAS eval gates, Langfuse tracing, Kafka news pipeline, MCP server.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages