Multi-Agent AI Platform for Interior Design, Product Data, and Project Workflows

By Amar Kumar

A proposed multi-agent interior design AI platform for a product team building customer-facing experiences in 3D modeling, interior design, architecture, and procurement. The architecture would use Mastra orchestration with TypeScript services, Python data pipelines, and PostgreSQL — three specialized agents (SKU ingestion, design selection, project coordination) sharing memory, tool registries, and eval gates so outputs are reliable enough for production workflows, not demo chat.

Proposed outcome: Observable Mastra agents that reason over structured product catalogs, call internal APIs with retries and handoffs, and ship measurable quality improvements through traces, evals, and regression suites.

Scenario

This brief describes a proposed solution — not a delivered engagement. It maps a pattern common to design-tech products: an existing codebase, a growing SKU catalog, and a need for agents that integrate with real systems rather than generic chat wrappers.

Problem

Generic LLM chat does not survive contact with structured product data, budget constraints, or procurement handoffs:

Requirements

Functional

Non-functional

Architecture

Three layers: customer surfaces (web/voice) call a Mastra orchestration plane that routes to specialized agents; agents read/write PostgreSQL shared memory and call internal product/design/project APIs via typed tools. Python workers handle heavy SKU normalization off the hot path.

flowchart TB classDef surface fill:#dbeafe,stroke:#2563eb,color:#1e3a8a classDef orch fill:#ede9fe,stroke:#7c3aed,color:#5b21b6 classDef agent fill:#f1f5f9,stroke:#64748b,color:#334155 classDef data fill:#ccfbf1,stroke:#0d9488,color:#115e59 classDef ext fill:#f8fafc,stroke:#475569,color:#334155 WEB["Web app\n3D + design UI"]:::surface VOICE["Voice / SMS\nTwilio"]:::surface API["Agent API\nHono / Next.js"]:::surface WEB --> API VOICE --> API ROUTER["Mastra router\nworkflow + handoffs"]:::orch API --> ROUTER SKU["SKU Ingestion Agent\nvalidate · enrich · stage"]:::agent DES["Design Agent\ncatalog · constraints"]:::agent PRJ["Project Agent\nscope · budget · notify"]:::agent ROUTER --> SKU ROUTER --> DES ROUTER --> PRJ SKU -.->|"handoff"| DES DES -.->|"handoff"| PRJ PRJ -.->|"handoff"| SKU PG[("PostgreSQL\nprojects · staging · selections\nagent_runs · memory")]:::data SKU --> PG DES --> PG PRJ --> PG PY["Python worker\nvendor normalization"]:::ext CAT["Catalog API"]:::ext PROC["Procurement API"]:::ext PY --> PG PG --> CAT PG --> PROC

Platform architecture — customer surfaces, Mastra router, three agents, shared PostgreSQL memory, and internal APIs

sequenceDiagram autonumber participant U as User participant API as Agent API participant R as Mastra Router participant D as Design Agent participant PG as PostgreSQL participant CAT as Catalog API participant E as Eval Gate U->>API: room brief + budget API->>R: start design workflow R->>PG: load project memory R->>D: design turn D->>CAT: search_catalog(filters) CAT-->>D: SKU candidates D->>D: check_dimensions_fit D->>PG: save_selections D-->>R: shortlist + rationale R->>E: constraint rubric alt eval pass E-->>API: stream response API-->>U: ranked products else eval fail E-->>R: retry with feedback R->>D: refine selection end

Design session sequence — grounded catalog search, constraint checks, and eval gate before user response

Component map by layer (count of major services)

End-to-end flow

Happy-path flow from customer or ops trigger through eval-gated tool execution

Illustrative build effort split across agent domains (% of engineering time)

Recommendation: Mastra in TypeScript for agent orchestration and customer APIs, Python for vendor feed normalization, PostgreSQL for durable memory, and AWS (ECS, SQS, RDS) for production deploy.

LayerTechnologyWhy
Agent orchestrationMastra (TypeScript)Native tool calling, workflows, memory, observability hooks; fits existing TS codebase
Customer APINode.js / Hono or Next.js route handlersLow-latency streaming for design sessions
Data processingPython 3.11 (Pandas, Pydantic)Vendor feed parsing, attribute normalization, bulk validation
State & memoryPostgreSQL + pgvectorRelational project/SKU state; optional embeddings for semantic catalog search
QueueAWS SQS + Lambda or BullMQ on ECSAsync SKU ingestion batches, retry with backoff
LLMClaude / GPT-4.1 (configurable per agent)Strong tool use; swap via Mastra model config
ObservabilityOpenTelemetry → CloudWatch / LangfuseTraces per tool call, eval score trends
Voice / SMSTwilio + optional VapiProject status updates and procurement confirmations
DeployAWS ECS Fargate or EKSCo-locate TS API and Python workers in VPC

Why Mastra over LangGraph-only? The product context expects TypeScript-first agent code alongside existing apps. Mastra provides agent primitives, memory, and workflow composition in TS without splitting orchestration into a separate Python service. Python remains for data-heavy SKU pipelines where the ecosystem is stronger.

Why not a single mega-agent? SKU validation, design selection, and project coordination have different tools, eval rubrics, and blast radii. Separate agents with explicit handoffs keep prompts smaller and failures isolated.

Agent design

1 — SKU Ingestion Agent

2 — Design Agent

3 — Project Agent

Shared memory model

Example Mastra tool registration for catalog search — typed schema keeps the design agent grounded to real SKUs:

import { createTool } from "@mastra/core";
import { z } from "zod";

export const searchCatalogTool = createTool({
  id: "search_catalog",
  description: "Query published SKUs by room, style, and budget ceiling",
  inputSchema: z.object({
    roomType: z.enum(["living", "bedroom", "kitchen", "bath"]),
    styleTags: z.array(z.string()).max(5),
    maxBudgetCents: z.number().int().positive(),
    minWidthCm: z.number().optional(),
    maxWidthCm: z.number().optional(),
  }),
  execute: async ({ context, input }) => {
    const rows = await context.catalog.search({
      ...input,
      status: "published",
    });
    return { candidates: rows.slice(0, 12), total: rows.length };
  },
});

Suggested phase timeline (weeks) for initial production build

Implementation plan

Phase 1 — Foundation (week 1–2)

Postgres schemas (projects, product_staging, design_selections, agent_runs), Mastra project scaffold, OpenTelemetry wiring, catalog read API client with mocked responses.

Risk: Undocumented internal APIs — start with read-only stubs and contract tests. Rollback: feature-flag agents off; existing product flows unchanged.

Phase 2 — SKU ingestion pipeline (week 3–4)

Python normalization worker, staging tables, SKU agent with validation tools, ops review UI or CSV export, eval set for schema edge cases.

Risk: Vendor format drift — adapter pattern per supplier. Rollback: manual CSV import path remains available.

Phase 3 — Design agent + catalog retrieval (week 5–6)

pgvector index or filtered SQL search, design agent tools, constraint checker, streaming customer endpoint, golden-room eval scenarios.

Risk: Retrieval quality on sparse attributes — hybrid keyword + vector search. Rollback: rule-based fallback shortlist from category filters.

Phase 4 — Project agent + notifications (week 7–8)

Project state machine, Twilio SMS integration, voice webhook stub, handoff protocol between agents, permission matrix on tools.

Risk: SMS deliverability — verify Twilio sender registration early. Rollback: in-app notifications only until SMS verified.

Phase 5 — Evals, tracing, regression CI (week 9–10)

Langfuse or OTEL dashboards, nightly eval job, PR gate on critical eval suites, dead-letter replay tooling.

Risk: Flaky evals from model variance — pin model version in CI. Rollback: manual QA sign-off on deploy until eval stability proven.

Phase 6 — Production hardening (week 11–12)

Load testing on design sessions, rate limits, runbooks, on-call alerts, documentation for prompt and tool versioning.

Risk: Latency under concurrent 3D sessions — cache hot catalog queries. Rollback: queue non-interactive SKU jobs during peak.

Reporting & ops

MetricSourceCadence
Tool call success / latencyOpenTelemetry tracesReal-time dashboard
SKU validation pass rateagent_runs + staging tableDaily
Design constraint satisfactionEval suite scoresPer deploy + nightly
Catalog publish cycle timeStaging → published timestampsWeekly
Project notification deliveryTwilio logsDaily
Agent handoff failuresMastra workflow dead-letterAlert on threshold

Weekly engineering digest: eval regressions, top tool errors, SKU backlog age, P95 design session latency.

Target eval case coverage by agent domain (illustrative counts for regression suite)

Proposed deliverables

Following the phased plan above, a build would ship these artifacts:

Effort estimate

Indicative engineering effort for the phased plan (assumes existing product APIs are documented or discoverable, one staging AWS environment, human-in-the-loop for catalog publish until eval thresholds are trusted):

ScopeHours (range)
Initial production build (phases 1–6)320–480 hrs
Ongoing eval tuning, catalog rule updates20–40 hrs/month

Scope assumes three agents at production quality, not proof-of-concept demos. Parallel work on Python ingestion and TypeScript orchestration can compress calendar time with two engineers.

Glossary

TermMeaning
MastraTypeScript framework for building agents with tools, memory, and workflows
SKUStock keeping unit — smallest sellable product variant in the catalog
HandoffExplicit transfer of control and context from one agent to another
StagingPre-production product records awaiting validation and approval
EvalAutomated test of agent output against expected constraints or golden answers
pgvectorPostgreSQL extension for vector similarity search over embeddings
HITLHuman-in-the-loop — required approval before high-impact tool calls