
Add new functionality to an existing React.js application, serving B2B customers, but do not re-engineer the application:
Constraints: No desire for a rebuild. Easy Integration.


Rather than retrofitting a chatbot or plugging in something generic, we started with the business workflow and use case — not the tech.
Our goal: identify where AI could actually solve a real problem without overwhelming the stack or user.
We started with user behavior analytics and feedback. Three use cases stood out:
These were pain points where automation could enhance, not distract.
We kept the frontend lean by using:
fetch() and axios to call backend routes securelydebounce and async/await for optimal UX timingOn the backend, we created middleware with Laravel (could be Node as well) that handled:
We routed requests to OpenAI and Anthropic based on function — OpenAI for summaries, Claude for broader answers.
We didn’t use base LLMs directly. Instead, we created our own prompt templates using:
Each prompt was dynamically assembled server-side. This kept the agent both smart and safe.
The client didn’t just get AI — they got intelligent UX improvements that users actually appreciated.
Here’s what we’d recommend for any team considering AI in React apps: