Generative AI & Agents

Tamrena AI

Architected Tamrena, an AI-powered fitness platform that replaces static gym program templates with a personalized, multi-agent plan-generation pipeline. The system ingests a user's InBody body-composition scan through a computer-vision pipeline (image quality and authenticity checks, VLM-based structured extraction, and deterministic clinical flag computation in pure Python), then routes the user's goals and body-composition flags through a supervisor agent built on LangGraph/deepagents that decides a training split and per-day set budget. Specialist exercise-recommender agents prescribe exercises per muscle group using a hybrid dense+sparse RAG system with reranking over exercise-science literature, before a plan-assembler agent builds the final weekly schedule. Plans adapt over time from real workout feedback and monthly progress reviews, with the whole pipeline streamed live over SSE and every agent decision persisted to an append-only markdown audit trail.

July 29, 2026

Technologies Used

LangGraphdeepagentsLangChainAzure OpenAIQdrantOpenCVFastAPIMongoDBJWTDockerAWS ECR/ECSPython

Problem Statement

Generic gym programs and template-based workout apps ignore a user's actual physiology, injuries, and progress, forcing them into a handful of one-size-fits-all splits. Producing a truly individualized training plan traditionally requires a human coach to interpret body-composition data, choose appropriate exercises, and continuously adjust the plan as the client trains and reports feedback — a process that doesn't scale and that a naively-applied LLM can't be trusted to get numerically right.

Solution

Tamrena builds an individualized plan end-to-end: a vision pipeline extracts and validates real InBody scan data, deterministic Python code computes clinical flags so the LLM never gets to invent them, and a chain of specialist agents (supervisor, exercise recommender, plan assembler) turns those flags plus the user's goals into a concrete weekly schedule sourced from a hybrid RAG search over exercise-science literature. A deterministic post-processor hard-enforces the volume budget the LLM was only asked to respect, and dedicated adjustment and monthly-review agents keep the plan current as the user trains and reports feedback — keeping judgment and language with the LLM while anything that has to be numerically correct stays in plain Python.

Key Features

Computer-vision InBody scan pipeline: quality/authenticity checks, VLM extraction, deterministic clinical flagging

Supervisor agent that classifies training goals into a paradigm and allocates a per-day set budget

Specialist exercise-recommender agents using hybrid dense+sparse RAG with cross-encoder reranking

Deterministic post-processing that hard-enforces volume budgets the LLM was only asked to respect

Real-time SSE streaming of plan-generation progress

Feedback-driven plan adjustment agent and automated 30-day monthly progress reviews

Shared append-only markdown audit trail read by every agent instead of message-passing

JWT-authenticated FastAPI backend with MongoDB persistence, Dockerized for AWS ECR/ECS deployment

Engineering Challenges

01

Keeping LLM-generated training volume within hard clinical and time-budget constraints without over-constraining creativity

02

Building a reliable computer-vision pipeline to extract structured data from real-world InBody scan photos and PDFs

03

Coordinating multiple sequential specialist agents while avoiding context-sync bugs between them

04

Designing a feedback loop that turns free-form user complaints into structured, matchable plan adjustments

Results & Metrics

Produced fully personalized weekly training plans driven by real body-composition data rather than templates

Eliminated LLM-introduced numerical drift by backing every safety-critical value with a deterministic check

Shipped a production-structured, end-to-end platform spanning CV, RAG, multi-agent orchestration, and deployment infrastructure

Lessons Learned

💡

Deterministic Python checks are non-negotiable wherever an LLM's output could silently drift on a safety-relevant number

💡

A shared append-only markdown log between agents gives a built-in audit trail and avoids context-sync bugs cheaply

💡

Structured, matchable feedback records outperform free-form prose when an agent needs to reliably act on user complaints later