Inspiration
Confinement takes many forms: long hospital convalescence, chronic illness, or months trapped inside four walls during freezing blackouts. In prolonged isolation, the room shrinks and sensory deprivation sets in. You lose the horizon, natural light, and the physical texture of the world.
Inspired by historical resilience—like Frida Kahlo transforming her bedridden isolation into a canvas of vivid reality—Re:Horizon was created to prove that culture is an essential cognitive anchor. I wanted to build an agent that breaks through the walls and restores a person's lost perspective.
What it does
Re:Horizon is a sensory decompression and cultural discovery agent designed for people experiencing spatial or physical confinement:
- Low-Friction Input (Presets, Text, or Microphone): Users can select a one-tap preset, type a short description, or speak via continuous microphone recognition, and set their current Cognitive Energy Threshold (
minimal,low, ormoderate). - Multi-Step Qloo Taste Graph Pipeline: The agent translates the user's description into aesthetic tag concepts and cross-domain anchor creators, resolves them into validated Qloo URNs via
GET /v2/tagsandGET /search, and queriesGET /v2/insightsin parallel across four domains:- Acoustic Anchors (
urn:entity:artist) - Literary Companions (
urn:entity:book) - Visual Atmospheres (
urn:entity:movie) - Geographic Horizons (
urn:entity:destination)
- Acoustic Anchors (
- Multi-Sensory Horizon Window: Synthesizes a narrative sized to the user's energy threshold, paired with a full-screen Ambient Room Mode (color palette and target room light temperature in Kelvin), a two-layer procedural Web Audio API soundscape (
ocean,rain,wind,warm-drone), and an Eyes-Closed Voice Guide (calm male speech synthesis with automatic background audio ducking). - Interactive Qloo Signal Refinement & Provenance: Displays the full step-by-step HTTP request trace and lets users toggle individual resolved Qloo tags (
urn:tag:...) or entity UUIDs on/off to re-synthesize/v2/insightsresults in real time.
How I built it
- Frontend & Backend: Built with Next.js 16.4.3 (App Router), React 19.3.0, TypeScript, and Tailwind CSS 4.
- Cultural Intelligence (Qloo API v2): Following the
qloo-hackathon-kitworkflow (resolve signals -> refine -> recommend) and safe-use guidelines, I implemented a direct server-side Qloo REST client (src/lib/qloo.ts) calling/v2/tags,/search, and/v2/insightswith 1-hour server caching (revalidate: 3600) for serverless deployment on Vercel. - Agent Orchestration (Google Gemini): Used
@google/genaiwith structured JSON schemas to extract non-personal cultural signals from user input and synthesize grounded narratives strictly referencing the entities returned by Qloo. - Browser Sensory Engines: Built zero-dependency classes on the Web Audio API (
SoundscapeEnginecombining harmonic sine pads with LFO-filtered pink noise) and Web Speech API (SpeechNarratorandVoiceInputRecognizer).
Challenges I ran into
- Cross-Domain Signal Balance: Passing only a single-domain tag (such as a music-only tag) into
/v2/insightsfor books or destinations can return generic results. Solving this required extracting multi-domain anchor entities alongside aesthetic tags so Qloo's taste graph has rich cross-domain grounding across all four target categories. - Preserving Signal Provenance on Refinement: Allowing users to toggle specific Qloo tags and entity UUIDs required decoupling initial signal extraction from the
/v2/insightsrefinement step so users can test how individual Qloo signals change the output.
Accomplishments that I'm proud of
- Building an interface that requires minimal effort from a fatigued user while exposing complete technical transparency (
Request-to-Result Provenanceand live signal toggling) for verification. - Creating a self-contained browser audio and ambient lighting experience that works immediately without requiring external streaming subscriptions.
What I learned
- How Qloo's
/v2/tags,/search, and/v2/insightsendpoints interact when combiningsignal.interests.tagsandsignal.interests.entitiesacross distinct entity types. - How to structure explainable AI-to-API workflows where every recommendation is traceable to specific validated URN signals.
Known Limitations & Safe Use
- Aggregate Cultural Correlations: Qloo results describe aggregate taste affinities across public domains. Re:Horizon does not infer personal identity or medical traits and does not provide medical advice, diagnosis, or treatment.
- Responsible Data Handling: No personal, health, or identifying user data is transmitted to Qloo; only general aesthetic keywords and public creator/work queries are sent.
What's next for Re:Horizon
- Integration with smart home protocols to synchronize physical room lighting directly with the cultural horizon.
- Spatialized binaural soundscapes matching Qloo acoustic recommendations.
Built With
- gemini
- next.js
- node.js
- qloo
- react
- rest-api
- tailwindcss
- typescript
- web-audio-api
- web-speech-api
