Skip to content

VinayakGawade009/EzNotes

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

16 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

EzNotes

EzNotes Logo

EzNotes

A smart note-taking app that allows you to "talk" to your data.

Live Demo

Next.js Convex Google Gemini Convex Auth


๐Ÿš€ Introduction

EzNotes is an AI-powered note-taking assistant that goes beyond simple text storage. Instead of manually searching through folders, you can use the AI Chat Assistant to ask questions about your notes, summarize information, or find connections between different topics.

I built this project to explore RAG (Retrieval-Augmented Generation) and Vector Search in a real-world application. It demonstrates how modern AI can be integrated into full-stack applications to make personal data more accessible and interactive.

โœจ Key Features

AI & RAG Capabilities

  • Context-Aware AI Chat: An intelligent assistant powered by Google Gemini 1.5 Flash that can answer questions based strictly on your personal notes. It uses "Tool Calling" to decide when to search your database.
  • Semantic Vector Search: Unlike traditional keyword search, this app understands meaning. For example, searching for "what should I eat?" will find your note titled "Favorite Foods" even if the word "eat" isn't in it.
  • Automated Embedding Pipeline: The app automatically manages the AI lifecycle. When you create or edit a note, the system seamlessly regenerates the vector embeddings in the background, ensuring the AI always has the latest information.

Note Management

  • Markdown Editor: A clean, distraction-free interface for writing and organizing your thoughts.
  • Real-time Updates: Notes are saved and synced instantly across devices using Convex's real-time WebSocket protocol.
  • Secure Authentication: Full sign-up/sign-in flow powered by Convex Auth, supporting magic links and secure session management.

User Experience (UX)

  • Responsive Design: Fully optimized for all screen sizes using Tailwind CSS.
  • Dark/Light Mode: Built-in theme switching support using next-themes.

๐Ÿ› ๏ธ Tech Stack

This project uses a modern, edge-ready tech stack focused on performance and developer experience.

Category Technology Description
Frontend Next.js 15 The latest React framework with Server Components and App Router.
React 19 The latest version of the UI library.
Tailwind CSS Utility-first CSS framework for rapid styling.
Shadcn UI Accessible, reusable UI components built on Radix UI.
Backend Convex A backend-as-a-service platform that handles the Database, Real-time Subscriptions, and Vector Storage.
AI / LLM Google Gemini The LLM used for reasoning and generating responses (Model: gemini-2.5-flash).
Vercel AI SDK The standard library for building AI-powered user interfaces in React.
Auth Convex Auth Integrated authentication solution for secure user sessions.
Language TypeScript For type-safe code and better developer tooling.

โš™๏ธ How it Works

The core of EzNotes is the RAG (Retrieval-Augmented Generation) pipeline, which allows the AI to "read" your personal notes before answering.

The Pipeline Flow

  1. ๐Ÿ“ Ingestion: When you create or edit a note, the text is sent to Google's embedding model to create a "vector" (a mathematical representation of the meaning). This vector is stored in Convex.
  2. ๐Ÿ” Retrieval: When you ask a question, your query is also converted into a vector. Convex performs a "Vector Search" to find notes that are mathematically similar to your question.
  3. ๐Ÿค– Generation: The relevant notes are retrieved and fed into Google Gemini along with your original question. Gemini then generates an answer using only that context.
graph TD
    A[User Creates Note] -->|Text| B(Google Embedding Model)
    B -->|Vector| C[Convex Vector DB]
    D[User Asks Question] -->|Text| E(Google Embedding Model)
    E -->|Query Vector| F{Vector Search}
    C --> F
    F -->|Relevant Notes| G[Google Gemini LLM]
    D --> G
    G -->|Answer| H[User Chat Interface]
Loading

๐Ÿš€ Getting Started

Follow these steps to set up the project locally on your machine.

Prerequisites

  • Node.js (v18 or higher)
  • npm (comes with Node.js)
  • Git

Installation

  1. Clone the repository

    git clone https://github.com/VinayakGawade009/EzNotes.git
    cd EzNotes
  2. Install dependencies

    npm install
  3. Set up the Database & Auth This project uses Convex. Run the development command to set up your backend:

    npx convex dev

    This will prompt you to log in to Convex and automatically create a new project and deployment for you.

  4. Configure Environment Variables Create a .env.local file in the root directory and add the keys listed below.

  5. Run the development server

    npm run dev
  6. Open the app Visit http://localhost:3000 in your browser.


๐Ÿ”‘ Environment Variables

To run this project, you will need to add the following environment variables to your .env.local file.

Variable Description How to get it
CONVEX_DEPLOYMENT The deployment ID for your Convex backend. Automatically set by npx convex dev.
NEXT_PUBLIC_CONVEX_URL The public URL of your Convex backend. Automatically set by npx convex dev.
GOOGLE_GENERATIVE_AI_API_KEY API Key for Google Gemini. Get it from Google AI Studio.

๐Ÿ“‚ Project Structure

Here is a quick overview of the project's file structure.

EzNotes/
โ”œโ”€โ”€ convex/                  # ๐ŸŸข Backend & Database
โ”‚   โ”œโ”€โ”€ auth.ts              # Authentication configuration
โ”‚   โ”œโ”€โ”€ http.ts              # HTTP Actions (API endpoints)
โ”‚   โ”œโ”€โ”€ notes.ts             # Database Mutations & Queries
โ”‚   โ”œโ”€โ”€ notesActions.ts      # AI Actions (Gemini integration)
โ”‚   โ””โ”€โ”€ schema.ts            # Database Schema definition
โ”œโ”€โ”€ src/
โ”‚   โ”œโ”€โ”€ app/                 # ๐Ÿ”ต Frontend (Next.js App Router)
โ”‚   โ”‚   โ”œโ”€โ”€ (auth)/          # Authentication pages (Signin)
โ”‚   โ”‚   โ”œโ”€โ”€ (main)/          # Protected application routes (Notes dashboard)
โ”‚   โ”‚   โ””โ”€โ”€ layout.tsx       # Root layout configuration
โ”‚   โ”œโ”€โ”€ components/          # Reusable UI components (Shadcn UI)
โ”‚   โ””โ”€โ”€ lib/                 # Utility functions & hooks
โ”œโ”€โ”€ public/                  # Static assets
โ””โ”€โ”€ package.json             # Project dependencies

๐Ÿ”ฎ Future Roadmap

I plan to continue improving EzNotes with these features:

  • Voice Notes: Record audio notes and have the AI transcribe and embed them automatically.

  • Image Attachments: Upload images to notes and use Gemini's vision capabilities to "chat" with your images.

  • Mobile App: A React Native version for iOS and Android.

  • Collaborative Notes: Share notes with other users and edit them in real-time.

  • Tagging System: Organize notes with custom tags for better filtering.

๐Ÿ‘ค Acknowledgement

This project was built following a tutorial by Coding in Flow

Built with โค๏ธ using Next.js and Convex

About

An AI-powered note-taking app built with Next.js 15, Convex, and Google Gemini. Features RAG-based chat, vector search, and Markdown editing.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors