01 / AI Workspace · FastAPI & React

Nuvora

Intelligence Unfold — AI Knowledge Workspace

Role

Full-Stack Architecture & UI Engineering

System Direction

Computational precision · Deterministic token accounting

Nuvora was built to replace fragile, fire-and-forget AI chat wrappers with deterministic request accounting, strict single-turn concurrency locks, and transparent token quota visibility across desktop and mobile viewports.

Nuvora desktop AI chat workspace with conversation sidebar and prompt composer
Nuvora mobile AI chat workspace showing responsive navigation and thread view

Interactive Exhibition

Product Surfaces & Interface States

1/6
nuvora.workspace / thread
Nuvora desktop AI chat workspace with conversation sidebar and prompt composer
Nuvora mobile AI chat workspace showing responsive navigation and thread view

01 · Synchronized AI Workspace

Desktop and mobile chat surfaces aligned around shared Redux/RTK Query session state and Redis lock discipline.

Capabilities

Core Features

  1. 01

    Explicit RequestState lifecycle (INITIATED → QUOTA_RESERVED → TURN_PERSISTED → PROVIDER_IN_FLIGHT → PROVIDER_SUCCEEDED → COMPLETED).

  2. 02

    Redis NX PX per-conversation lock with 90s recovery lease and 409 lock conflict protection.

  3. 03

    50,000 daily and 500,000 monthly token quota ledger with pre-flight reservation and post-response reconciliation.

  4. 04

    8,000-token context window with a 5,000-token summarization trigger to preserve long-thread coherence.

  5. 05

    Responsive desktop and mobile chat workspace with clean structured markdown rendering and usage telemetry.

Infrastructure

Technology Stack

ReactRedux Toolkit / RTK QueryFastAPIMongoDBRedisGroq LLM

System Design

System Architecture Overview

React and RTK Query dispatch validated prompt payloads to FastAPI, which coordinates Redis conversation locks and quota reservations before persisting turns in MongoDB and streaming responses from Groq LLM.

Client State

React + Redux Toolkit (RTK Query)

Manages optimistic thread state, structured markdown rendering, and quota meter synchronization.

API & Orchestration

FastAPI

Validates session claims, hashes payloads, enforces quota reservation, and drives the RequestState machine.

Concurrency & Cache

Redis (NX PX)

Serializes active conversation turns with a 90-second recovery lease to prevent overlapping provider requests.

Persistence & Inference

MongoDB + Groq LLM

Stores conversation turns, context summaries, and reconciled token usage records.

Engineering Tradeoffs

Technical Decisions

Pre-Flight Quota Reservation & Reconciliation

Reserving an estimated token budget prior to provider dispatch prevents quota overruns, then reconciles actual consumption once Groq responds.

5,000-Token Summarization Threshold

Triggering background context condensation before hitting the 8,000-token ceiling keeps multi-turn reasoning accurate without abrupt truncation.

Problem Solving

Challenges & Solutions

Challenge

Rapid duplicate submissions or concurrent tab requests could corrupt turn ordering and double-charge token quotas.

Resolution

Enforced Redis NX PX conversation locking with explicit 409 conflict responses and 90-second lease recovery.

Challenge

Earlier AI response renders leaked raw HTML markup in complex formatting blocks.

Resolution

Hardened the response sanitizer and markdown renderer across both desktop and mobile viewports.

Evidence

Verified Implementation Results

  1. 01

    Source-verified RequestState machine and Redis NX PX locking implemented in commit 38487c0e.

  2. 02

    Documented 50k daily / 500k monthly quota ledger and 8,000-token / 5,000-token context policy.

  3. 03

    Live workspace deployed and accessible for direct end-to-end verification.