Inspiration

Eastern Palmistry has guided people for thousands of years, offering insight into the past, present, and future while helping individuals navigate their life paths. We wanted to bring this ancient wisdom into the modern age—making it accessible, instant, and deeply personalized.

Palmystic was born from a desire to blend mystical tradition with modern AI. By combining palmistry with state-of-the-art Vision-Language Models, we aim to help users reflect on themselves through a magical yet thoughtful digital experience.


What it does

Palmystic is an AI-powered palm reading web application that analyzes users’ palms to provide personalized insights about destiny, personality traits, and future paths.

Users can:

  • Upload a palm image or capture one using their device camera
  • Receive a structured palm reading that includes:
    • Analysis of major palm lines (Heart, Head, Life, Fate)
    • A mystical summary and destiny archetype
    • Lucky colors, numbers, power animals, and actionable guidance
  • Ask follow-up questions through an interactive chatbot that references their specific reading

The entire experience is wrapped in an immersive “ancient grimoire” themed interface, making palm reading feel magical, engaging, and intuitive.


How we built it

Back-end & AI Architecture

  • Gemini Vision-Language Model (VLM) for palm image understanding and structured interpretation
  • Prompt-driven schema enforcement to ensure consistent, machine-parseable JSON output
  • Stateless chatbot design that reuses structured reading context for follow-up questions

Front-end & UX

  • MediaDevices API for live camera capture
  • Canvas API for image preview, processing, and conversion
  • Multipart form submission to backend services
  • UI state management for seamless transitions between upload, analysis, and chat

Challenges we ran into

Gender-based palm interpretation

Traditional palmistry assigns different meanings to different hands based on gender. This introduced both UX and system-level constraints.

We designed a gender-aware but non-restrictive flow:

  • Female → guided to upload the left palm
  • Male → guided to upload the right palm
  • Non-binary / undisclosed → allowed either palm

This logic had to remain consistent across:

  • UI guidance
  • Backend request handling
  • AI prompt construction

Ensuring alignment across these layers required careful coordination.

RAG exploration under free-tier constraints (for the expansion!!)

We explored extending Palmystic with retrieval-augmented generation (RAG) by embedding classical palmistry texts and storing them in a vector database (pgvector). This approach showed strong potential for grounding interpretations and reducing hallucinations.

However, during experimentation we reached the practical limits of embedding usage within the free-tier constraints. Given the hackathon timeframe, we made a deliberate decision to prioritize a prompt-enforced, schema-driven VLM pipeline for reliability and performance.

This exploration directly informed our future roadmap, where RAG will be reintroduced with optimized chunking strategies, selective embeddings, and cost-aware retrieval.


Invalid image handling

Palm images are highly sensitive to:

  • Orientation (front vs back of hand)
  • Framing (wrist or arm included)
  • Lighting and clarity

Early versions suffered from hallucinated readings when invalid images were provided.
Instead of brittle image heuristics, we solved this at the prompt level, forcing the VLM to explicitly reject invalid inputs and return a structured error JSON. This dramatically improved reliability.


Media and multipart debugging

Transmitting camera-captured images from the browser to the backend introduced subtle bugs related to:

  • Canvas → Blob conversion
  • Multipart boundaries
  • Server-side request parsing

Debugging required end-to-end tracing across browser APIs and backend controllers under tight time constraints.


Accomplishments that we're proud of

  • Successfully integrated Gemini VLM for structured palm analysis
  • Built a dual-input system (file upload + live camera) that works across devices
  • Designed a thematic UI that transforms a technical pipeline into a mystical experience
  • Implemented a stateless, contextual chatbot(ft. Gemini) grounded in each user’s reading
  • Delivered a fully functional MVP within the hackathon timeframe

What we learned

  • Vision-Language Model limitations: Input quality and rejection paths are as important as generation
  • Prompt engineering as system design: Prompts served as executable specifications enforcing schema, safety, and tone
  • Stateless AI architecture: Passing structured context enables scalable follow-up interactions without session memory
  • Human-AI UX alignment: Balancing theatrical language with strict JSON output requirements
  • Full-stack debugging: From browser media pipelines to backend multipart handling

What's next for Palmystic

  • Hallucination-safe insights using retrieval-augmented generation (RAG) grounded in classical palmistry texts
  • Real-time AR overlays that visualize palm lines
  • 3D hand mapping for depth-aware analysis
  • Holistic readings combining palm front and back
  • Multi-language and culturally adaptive interpretations

Built With

Share this project:

Updates