Skip to main content

Recovered Project

The Recovered project provides AI-powered analysis of wellbeing check-in data through a three-phase architecture that transforms raw user data into actionable insights.

warning

This is a TAP-owned transitional workflow. packages/domain-tap/src/loader.ts registers recoveredAnalysisWorkflow, but the current TAP agent builder does not register the required recovered-business-logic-agent. Phase 3 therefore fails unless that agent is supplied by the running Mastra instance. A seeded Core.AgentProfiles row configures an agent; it does not create a live agent by itself.

What is Recovered?

Recovered is a wellbeing tracking application that captures:

  • Emotional check-ins (mood, feelings, notes)
  • Stress levels (daily stress ratings)
  • Sleep quality (sleep patterns, disturbances)
  • Energy levels (0-10 scale)
  • Cycle tracking (physical, emotional, behavioral symptoms)
  • Habits & routines (water intake, reading, exercise, etc.)

Architecture

The Recovered analysis pipeline uses a three-phase workflow:

Phase 1: Normalize    Phase 2: Reasoning Engine    Phase 3: Business Logic
Raw Export Data → Canonical Format → Analysis Results → Dashboard Output
(Small/Large) (series, datasets) (insights, trends) (formatted JSON)

Phase 1: Normalization (Intake Adapters)

Transforms raw Recovered exports into a canonical format that the reasoning engine understands.

Phase 2: Reasoning Engine

Executes multi-agent analysis pipeline (temporal, pattern, correlation, domain knowledge, explanation, validation).

Phase 3: Business Logic (Output Adapters)

Applies Recovered-specific formatting for dashboard consumption, including headline generation and confidence scoring.

Key Features

  • Format-agnostic input: Accepts both raw exports (Small/Large format) and preprocessed canonical JSON
  • Multi-agent analysis: the optional Reasoning Engine loader builds 10 agents; the committed sub-workflow uses the agents/tools needed by its seven-step pipeline
  • Domain-aware insights: Incorporates health knowledge about stress, sleep, cycles, and energy
  • Adaptive narratives: Generates explanations tailored to the user's question
  • Confidence scoring: Validates findings and flags low-confidence results

Quick Start

Using the source-backed runtime route

The generated TAP route is POST /tap/workflows/recoveredAnalysisWorkflow for a synchronous run. The async family also exposes start-async, create-run, start, and runs/{runId} paths. Check /tap/routes.json on the running target before invoking it and resolve the Phase 3 agent-registration gap above first.

Mastra Studio may expose a local graph UI in development, but that UI URL is not the deployment API contract.

Supported Input Formats

Raw Small Format (from Recovered export):

[
{
"Created At": "2025-12-12T08:32",
"Label": "emotion-checkin",
"Value": "{\"options\":[\"depressed\"],\"date\":\"2025-12-12T08:32\"}",
"Kind": "emotion-checkin"
}
]

Preprocessed Canonical Format:

{
"objective": "Analyze my stress patterns",
"series": [...],
"datasets": [...],
"compactedRows": [...]
}

Documentation Structure