PocketPharma AI

PocketPharma AI

"Your personal pharmacist, always in your pocket."

PocketPharma AI

PocketPharma AI

"Your personal pharmacist, always in your pocket."

The problem PocketPharma AI solves

Many patients struggle with the high costs of brand-name medications, often unaware of more affordable generic alternatives. The process of finding these alternatives can be time-consuming and confusing, leading many to overpay for their prescriptions.

What is PocketPharma AI

So we introduced, PocketPharma is an AI-driven web application that helps users find affordable generic alternatives to brand-name medications by simply uploading a photo of their medicine.

Features

  • Image-based Medicine Identification: Upload a photo of your medicine for instant recognition.
  • AI-powered Analysis: Utilizes cutting-edge AI models to analyze and identify medications.
  • Generic Alternative Suggestions: Provides a list of generic alternatives to brand-name medicines.
  • Price Comparison: Offers side-by-side price comparisons between brand-name and generic options.
  • User-friendly Interface: Intuitive design for easy navigation and use.

How It Works

  1. Upload: Users upload a photo of their medicine through the web interface.
  2. Analyze: Our AI models process the image to identify the medication.
  3. Search: The system searches for generic alternatives to the identified medicine.
  4. Compare: Users are presented with a list of generic options, including price comparisons.
  5. Choose: Armed with this information, users can make informed decisions about their medication purchases.

Technical Stack

Frontend

  • Next.js (React framework)
  • TypeScript
  • Tailwind CSS for styling

Backend

  • Hono.js (lightweight framework for edge computing eg:cloudflare workers)
  • Groq SDK for AI text generation ( removed due to inconsistency)
  • ChatGPT4o for Image Classification
  • Cloudflare Workers ( Serverless )
  • LLaVA (Large Language and Vision Assistant) model ( Removed Due to inconsistent results )

Future Enhancements

  • Integration with official pharmaceutical databases
  • Mobile app development
  • Personalized medicine reminders and tracking

Challenges we ran into

So we were trying to make it all work using Grok's LLaVA model but it failed to analyze the given image properly, so we had to use Google's Gemini 1.5 -flash for it.

But that again failed due to some Image Content Safety Bug, so we then finally used Google's Gemini 1.5 Pro which made it all work.

One more issue we found ourselves in, was Grok's llama model in JSON mode was not giving us consistent results so we had to programatically make it work like using String Methods to search object properties with String.include().

At the end, we settled for open ai's gpt4-0 model which worked really from the first go and we depreciated our other models in favour for chatgpt for generating medicines too.

Tracks Applied (1)

Live The Code 3.0 Winners

We developed PocketPharma as part of Live The Code 3.0 which we believe is a hackathon focused on innovative solutions i...Read More

Discussion