Briefly - AI Wealth-Management CRM
Rescued a stalled AI-generated prototype and turned it into a multi-tenant, production-grade LLM product on AWS.
- Client
- Briefly
- Industry
- Fintech · wealth management
- Role
- Senior full-stack engineer & solution architect
- Timeline
- 2026
8sections
structured brief per client meeting
8modules
NestJS domain modules, tenant-scoped
8tf modules
Terraform, across two environments
~19kLOC
type-aligned end to end from OpenAPI
Context & challenge
Context
Briefly helps financial advisors prepare for client meetings by turning PDF statements, meeting notes and synced emails into a structured, 8-section brief - portfolio summary, action items, tax considerations, client sentiment and more.
Challenge
The client’s AI-generated prototype had stalled: the core generation pipeline was broken, multi-file upload failed, and much of the UI was placeholders.
Architecture · fig. 02
fig. 02 - brief-generation pipeline
Inputs - uploaded PDF statements, meeting notes, and email and calendar synced through Nylas - go to a NestJS 11 API on Prisma 7 and PostgreSQL 18, scoped to the tenant by Cognito. The LLM pipeline calls models through OpenRouter, with versioned prompts and tracing in Langfuse. A Zod schema checks the model output before it is saved, and the result is an 8-section brief in a React 19 client using RTK Query. Supporting it: AWS in Terraform across 2 environments - VPC, RDS, ECS Fargate, ALB, S3, CloudFront, Cognito and CloudWatch; tenant isolation scoped by Cognito on every query, across 8 domain modules; and type safety from RTK Query generated from the OpenAPI spec, about 19k lines aligned.
- 01 Inputs
- PDF statementsupload
- Meeting notes
- Email + calendarNylas
- 02 APINestJS 11Prisma 7 · PostgreSQL 18 · Cognito tenant scope
- 03 LLM pipelineOpenRouterLangfuse - versioned prompts, tracing
- 04 ValidateZod schemamodel output checked before save
- 05 Output8-section briefReact 19 client · RTK Query
- AWS · Terraform · 2 environmentsVPC · RDS · ECS Fargate · ALB · S3 · CloudFront · Cognito · CloudWatch
- Tenant isolationCognito-scoped on every query, across 8 domain modules
- Type safetyRTK Query generated from the OpenAPI spec - ~19k lines aligned
- 01 InputsPDF statements · meeting notesemail + calendar via Nylas
- 02 APINestJS 11Prisma 7 · PostgreSQL 18 · Cognito tenant scope
- 03 LLM pipelineOpenRouterLangfuse - versioned prompts, tracing
- 04 ValidateZod schemamodel output checked before save
- 05 Output8-section briefReact 19 client · RTK Query
What I built
- End-to-end audit; fixed the broken LLM pipeline, multi-file uploads and mock-data leaks.
- LLM brief-generation pipeline: NestJS + OpenRouter + Langfuse, with model output validated against a Zod schema.
- Multi-tenant NestJS 11 + Prisma 7 + PostgreSQL 18 API across 8 domain modules, with Cognito-scoped tenant isolation on every query.
- AWS as code: 8 Terraform modules across two environments, deployed via GitHub Actions.
- Nylas OAuth email/calendar sync, OpenRouter and Langfuse behind clean services with config-driven fallbacks.
- React 19 + Vite + Tailwind 4 + shadcn client with OIDC auth and an RTK Query layer generated from OpenAPI.
Outcomes & role
- A working end-to-end product that real advisors can use, on hardened infrastructure.
- A stalled prototype turned into a working advisor demo.
Senior full-stack engineer and solution architect - audit, back-end LLM pipeline, multi-tenant API, infrastructure and client.
- NestJS
- Prisma
- PostgreSQL
- OpenRouter
- Langfuse
- Zod
- Nylas
- React 19
- Vite
- Tailwind
- shadcn
- RTK Query
- AWS
- Terraform
- GitHub Actions
Stack
- NestJS
- Prisma
- PostgreSQL
- OpenRouter
- Langfuse
- Zod
- Nylas
- React 19
- Vite
- Tailwind
- shadcn
- RTK Query
- AWS
- Terraform
- GitHub Actions