Files
OSIT-AE-App-Svelte/GEMINI.md
Scott Idem f35a1a10d0 Stabilize Journal Entry view and perform initial comment audit
- Cleaned up redundant imports, legacy script stubs, and dead code.
- Removed extensive legacy comments from history and AI summary template sections.
- Verified stability of core decryption and data sync logic.
- Standardized file structure to serve as a better template for other Aether modules.
2026-01-08 17:31:08 -05:00

4.1 KiB

Aether (AE) SvelteKit Application

This project is the frontend UI/UX for the Aether (AE) system, built with Svelte 5 (SvelteKit), Tailwind CSS, and Skeleton. It interfaces with a Python FastAPI backend.

🎯 Core Mandates (Safety & Efficiency)

  • Fast is slow. Slow is fast. Deliberate, careful progress is better than rushed, error-prone actions.
  • Fail fast. If a change breaks the system, revert immediately to the last known working version before attempting a new fix.
  • Commit early and often. Working changes MUST be committed before starting major new modifications. Always test before committing.
  • Verify. Perform syntax checks and basic compile verification before finalizing any code change.
  • Trust but verify. Always verify tool outputs, assumptions, and system state before proceeding.

🏗️ Architecture & Standards

Svelte v5 (Runes)

  • State Management: Use $state and $derived. Props are passed via $props() and can be $bindable.
  • Event Handling: Use lowercase onevent attributes (e.g., onclick). Handle preventDefault inside functions.
  • Dexie Integration: liveQuery results are observables and require the $ prefix (e.g., $lq__obj) in templates. Subscribe in onMount to avoid SSR issues.

ID Convention (Triple-ID Pattern)

  • Standard: Use id, [obj_type]_id, and [obj_type]_id_random consistently.
  • Primary Key: Always use _id_random (string) for routing, data fetching, and local storage.
  • Local Storage: Alias id_random to both id (PK) and [obj_type]_id when saving to Dexie.

API V3 Implementation

  • Robustness: Use the standardized primary helpers (get, post, patch, delete) in src/lib/ae_api/.
  • SSR Parity: Helpers support custom fetch injection for SvelteKit server-side execution.
  • Bootstrap Paradox: Use the unauthenticated bypass (x-no-account-id: "Nothing to See Here") for site/domain lookups.
  • Envelopes: Helpers automatically handle the {data: ...} envelope returned by the backend.

Data Pattern

  1. Fetch: API Function calls the V3 endpoint.
  2. Process: Dedicated process_ae_obj__*_props function handles data shaping, parent ID injection, and computed fields.
  3. Cache: Save cleaned data to IndexedDB via db_save_ae_obj_li__ae_obj.

🛠️ Tooling & Orchestration

Aether Ops (MCP Extension)

  • verify_api_integrity: Headless verification of the FastAPI stack.
  • schema_sync: Syncs Pydantic models to TypeScript interfaces in src/lib/types/ae_types.ts.
  • ae_obj_info: Metadata lookup for Aether objects.
  • UE-AE-01 Vision: Moving towards a unified agent with total system awareness across MariaDB, FastAPI, SvelteKit, and Nginx.

📂 Modules Overview

Core Modules

  • Identity: accounts, people, users.
  • Infrastructure: sites, site_domains.
  • Storage: hosted_files.

Feature Modules

  • Events: Presentation management, Badge printing, QR tracking.
  • Journals: Documentation, notes, and AI-assisted summarization.
  • IDAA: Client-specific logistics and video conferencing (Jitsi).

📝 Development History (Consolidated)

Journals Module Refactor (2026-01-08)

  • Modularization: Extracted JournalEntry_AITools and JournalEntry_Metadata from the 3000+ line main view.
  • UI/UX: Standardized on Lucide icons. Implemented 3-state header toggle (View/Eye/Save).
  • CodeMirror: Migrated to CM6 with updateListener pattern for Svelte 5 compatibility.

Jitsi God Mode (2025-12-15)

  • Architecture: Hybrid XMPP bot for server-side stats collection, pushing real-time meeting metadata to MariaDB.

Build & Library Health (2025-12-08)

  • Upgrades: Successfully updated to SkeletonLabs v4.7.4 and Flowbite-Svelte v4.0.1.
  • Staging: npm run build:staging verified and clean of import/export errors.

🔗 Resources