2026

BobbyUgbebor.com.

©All Rights Reserved

All projects

B-RAG

An agentic document intelligence and research platform built with LangGraph and LangChain, featuring multimodal processing, vector search, citation-aware AI chat, and a context-rich assistant for AI, solutions architecture, and full-stack development.

Next.jsNext.js
FastAPIFastAPI
Node.jsNode.js
LangChainLangChain
LangGraphLangGraph
PrismaPrisma
DrizzleDrizzle
BeBetter-Auth
shadcn/uishadcn/ui
ZustandZustand
NextAuthNextAuth
motionmotion
Tailwind CSS v4Tailwind CSS v4
PostgreSQL (Neon)PostgreSQL (Neon)
ChromaDBChromaDB
QdrantQdrant
MongoDBMongoDB
DockerDocker
AWSAWS
VercelVercel
CloudflareCloudflare
LangSmithLangSmith
SentrySentry
SourceLive demo
01 / System Architecture

Architecture Decision

Current architecture
Current

Why this architecture

  • Cloudflare handles WAF and DDoS at the edge — no extra infrastructure cost, no additional attack surface to manage.
  • HTTPS access is restricted to Cloudflare IPs only, so the origin server is never directly exposed to the public internet.
  • Frontend requests are only accepted from the single domain https://brag.bobbyugbebor.store/ — an extra layer of security that rejects any traffic from unauthorized origins.
  • The application layer is completely stateless and hosting-agnostic — it can run on a VPS, a container, or a bare-metal box with zero code changes.
  • Built for under 100 concurrent users, which means a single instance handles the load comfortably with room to spare.
  • As demand grows, the architecture can evolve incrementally — adding load balancers, auto-scaling, or migrating to serverless — without rewriting the application layer.
02 / Quality Assurance

Testing & Reliability

Performance
Acceptance
Performance
Acceptance
Test Cases
K6 by Grafana

Load test targeting the retrieval endpoint (/query/stream) with 10 concurrent virtual users over 5 minutes. Validates response times and error rates under normal operating conditions.

Retrieval Pipeline report 1

1 / 2

Workload Profile

1m10 VUs
3m10 VUs
1m0 VUs

Thresholds

http_req_duration p(95)< 5000ms
http_req_duration p(99)< 6000ms
http_req_failedrate < 0.05
checksrate > 0.95

Summary

Requests
515
1.69/s
Checks
1030
0 failed
Iterations
515
Virtual Users
1–10

Results

MetricAvgMinMedMaxP90P95P99Count
http_req_duration3772.472513.523701.318587.224594.374875.465698.71515
03 / Architecture Gallery

B-RAG

B-RAG architecture 1

Click image to expand · 1 / 7

04 / Deployment

CI/CD Pipeline

01

Branch to feature

development
02

Feature work & test

feature
03

Merge to development

feature
04

Test on development

development
05

Merge to main

development
06

Deploy to production

main
01

Branch to feature

development
02

Feature work & test

feature
03

Merge to development

feature
04

Test on development

development
05

Merge to main

development
06

Deploy to production

main

Branch from development to feature → develop & test → merge to development → run test suite → merge to main → GitHub Actions runs tests → deploy to AWS (backend), Vercel (frontend), Cloudflare (CDN/DNS).

05 / Updates

Features to be Implemented

Backlog

2

Worker with RQ

P1

Integrating workers for processing jobs with Redis Queue as a Broker.

backenddecoupling
3

Node.js backend for file-conversion/management

P1

Build a separate service for managing file conversion and management, decoupling from b-rag

backendnodejs
5
8 pts

To Do

1

Configure Loki

P0

Set up log aggregation pipeline

observability
5
5 pts

In Progress

1

Implement request metrics

P0

Add latency and request count metrics

observability
3
3 pts

Review

1

Set up Grafana dashboards

P1

Create monitoring dashboards

observability
5
5 pts

Done

2

Set up Prometheus endpoint

P0

Implement metrics collection in API routes

observability
5

Research best practices

P2

Study observability patterns and anti-patterns

observability
2
7 pts
06 / Technology Stack

Technologies

Frameworks
Next.jsFastAPINode.js
Libraries
LangChainLangGraphPrismaDrizzleBetter-Authshadcn/uiZustandNextAuthmotionTailwind CSS v4
DataBases
PostgreSQL (Neon)ChromaDBQdrantMongoDB
Infrastructures
DockerAWSVercelCloudflare
Observabilities
LangSmithSentry
B-Store