Skip to content

Commit a9e105a

Browse files
docs: restore original voice and humor in README intro
1 parent ce895d4 commit a9e105a

1 file changed

Lines changed: 105 additions & 126 deletions

File tree

README.md

Lines changed: 105 additions & 126 deletions
Original file line numberDiff line numberDiff line change
@@ -2,213 +2,192 @@
22

33
> *"Because even ChatGPT forgets sometimes..."*
44
5+
[![Deploy with Vercel](https://vercel.com/button)](https://vercel.com/new/clone?repository-url=https://github.com/aboderinsamuel/closedNote)
6+
57
---
68

7-
### 👋 What is closedNote?
9+
## 👋 What is closedNote?
810

9-
closedNote is a simple web app for **saving, organizing, and re-using your best prompts**, built for *students, teachers, engineers, prompt engineers, prompt tutors, and even regular folks like my mum 😅.*
11+
closedNote is a simple web app for saving, organizing, and re-using your best prompts, built for students, teachers, engineers, prompt engineers, prompt tutors, and even parents like my mum 😅.
1012

11-
It's the one place you can finally dump all your fire prompts without digging through old chats or screenshots.
12-
A calm home for all your creativity.
13+
It's the one place you can finally dump all your fire prompts without digging through old chats or screenshots. A calm home for all your creativity.
1314

1415
---
1516

16-
### 💡 The Story
17+
## 💡 The Story
1718

18-
I got tired of re-engineering my "perfect ChatGPT prompts" every time I needed a particular kind of answer.
19-
Then my mum started doing the same thing (don't ask how she got into it 😭).
20-
Then my grandma.
21-
Then my classmates.
19+
I got tired of re-engineering my "perfect ChatGPT prompts" every time I needed a particular kind of answer. Then my mum started doing the same thing (don't ask how she got into it 😭). Then my grandma. Then my classmates.
2220

2321
Meanwhile, prompt engineers were dropping crazy tips on X (Twitter) and Stack Overflow, but I had nowhere to store them neatly.
2422

25-
So, I built one.
26-
That's what **closedNote** is all about, a small home to make **prompt saving easier for everyone**. 🙂🙂
23+
So, I built one. That's what closedNote is all about, a small home to make prompt saving easier for everyone. 🙂🙂
2724

2825
Completely open source, open to contributions, and continuously improving.
2926

3027
---
3128

32-
### ⚙️ Tech Stack
33-
34-
<div align="center">
35-
36-
| Frontend | Backend | AI/OCR | Database | Deployment |
37-
|:--------:|:-------:|:------:|:--------:|:----------:|
38-
| <img src="https://cdn.jsdelivr.net/gh/devicons/devicon/icons/nextjs/nextjs-original.svg" width="40" height="40" alt="Next.js"/><br/>**Next.js 14** | <img src="https://avatars.githubusercontent.com/u/54469796?s=200&v=4" width="40" height="40" alt="Supabase"/><br/>**Supabase** | <img src="https://huggingface.co/front/assets/huggingface_logo-noborder.svg" width="40" height="40" alt="Hugging Face"/><br/>**Hugging Face** | <img src="https://cdn.jsdelivr.net/gh/devicons/devicon/icons/postgresql/postgresql-original.svg" width="40" height="40" alt="PostgreSQL"/><br/>**PostgreSQL** | <img src="https://cdn.jsdelivr.net/gh/devicons/devicon/icons/vercel/vercel-original.svg" width="40" height="40" alt="Vercel"/><br/>**Vercel** |
39-
| <img src="https://cdn.jsdelivr.net/gh/devicons/devicon/icons/react/react-original.svg" width="40" height="40" alt="React"/><br/>**React 18** | JWT Auth | TrOCR Models | RLS Policies | Auto Deploy |
40-
| <img src="https://cdn.jsdelivr.net/gh/devicons/devicon/icons/typescript/typescript-original.svg" width="40" height="40" alt="TypeScript"/><br/>**TypeScript** | API Routes | Zephyr Chat | Real-time Sync | Edge Functions |
41-
| <img src="https://cdn.jsdelivr.net/gh/devicons/devicon/icons/tailwindcss/tailwindcss-original.svg" width="40" height="40" alt="Tailwind"/><br/>**Tailwind CSS** | Storage | Tesseract.js | Migrations | Preview URLs |
42-
43-
</div>
44-
45-
---
29+
## 🖥️ Demo
4630

47-
### 🖥️ Desktop View
31+
### Dashboard
4832

4933
![Desktop Screenshot 1](./screenshots/desktop1.png)
5034

5135
![Desktop Screenshot 2](./screenshots/desktop2.png)
5236

37+
### Prompt Editor
38+
5339
![Desktop Screenshot 3](./screenshots/desktop3.png)
5440

55-
> clean, minimal, and distraction-free, because prompts deserve peace too 😌
41+
> clean, minimal, distraction-free because prompts deserve peace too 😌
5642
57-
---
43+
### Image to Text (OCR)
44+
45+
![OCR Feature](./screenshots/OCR.png)
5846

59-
### 📱 Mobile View
47+
> Upload a screenshot, get the text out. No retyping. Ever.
48+
49+
### 📱 Mobile
6050

6151
| | |
6252
| ------------------------------------------------- | ------------------------------------------------- |
6353
| ![Mobile Screenshot 1](./screenshots/mobile1.png) | ![Mobile Screenshot 2](./screenshots/mobile2.png) |
6454

65-
> fully responsive, works smoothly on mobile for on-the-go creativity
55+
> Fully responsive. Works on the go.
6656
6757
---
6858

69-
### 🗄️ Database Setup (Supabase + PostgreSQL)
70-
71-
closedNote runs on **Supabase**, which provides both authentication and secure cloud storage using **Row Level Security (RLS)**, meaning no one can see your notes but you.
59+
## 🏗️ Architecture
7260

73-
#### 🧾 Example Schema Snippets
61+
```
62+
User Browser
63+
64+
├── Next.js 14 App Router (client-side pages)
65+
│ ├── / .............. Dashboard (prompt list + search + collections)
66+
│ ├── /prompts/[id] .. View / Edit a prompt
67+
│ ├── /ocr ........... Image → Text → Refine → Save
68+
│ ├── /settings ...... API keys, theme, account
69+
│ └── /home .......... Marketing landing page
70+
71+
├── API Routes (server-side, Next.js edge)
72+
│ ├── /api/ocr ....... Vision OCR (OpenAI GPT-4o-mini if user key provided)
73+
│ └── /api/chat ...... AI text refinement (OpenAI or HuggingFace user key)
74+
75+
├── Supabase (PostgreSQL + Auth)
76+
│ ├── Auth: PKCE flow, email/password
77+
│ ├── Tables: users · prompts · (RLS on everything)
78+
│ └── RPC: delete_user()
79+
80+
└── Tesseract.js (offline OCR fallback, runs in browser, no API needed)
81+
```
7482

75-
![SQL Screenshot 1](./screenshots/sql1.png)
83+
**AI Provider Chain:**
84+
- OCR: `OpenAI GPT-4o-mini (user key)``Tesseract.js (offline fallback)`
85+
- Refinement: `OpenAI (user key)``HuggingFace Zephyr (user key)` → error with Settings link
7686

77-
![SQL Screenshot 2](./screenshots/sql2.png)
87+
Users without API keys still get full prompt management + offline OCR. AI features unlock when they add a key in Settings.
7888

79-
#### 🏛️ Public Schema
89+
### 🗄️ Database Schema
8090

8191
![Public schema diagram](./screenshots/postgresSchema.png)
8292

83-
_Public schema diagram showing tables and relationships used by closedNote._
84-
85-
> Every user's data is tied to their `auth.uid()`. No mix-ups, no leaks.
93+
Every user's data is tied to their `auth.uid()`. No mix-ups, no leaks. Row Level Security enforced on every table.
8694

8795
---
8896

89-
### 🧠 Features
97+
## 🧠 Features
9098

91-
* 🏠 **Local + Cloud Storage**, works offline, syncs later
92-
* 🔍 **Search & Filter**, find prompts in seconds
93-
* 🏷️ **Tag System**, group prompts by category or mood
94-
* 💾 **One-Click Copy**, paste straight into ChatGPT, Claude, Cursor, etc.
95-
* 🔒 **Private by Default**, RLS ensures your data stays yours
96-
* 🖼️ **Image to Text (OCR)**, turn screenshots into prompts instantly
97-
* 🌍 **Open Source Forever**, fork it, remix it, teach with it
99+
- 🔍 **Instant Search** — command palette (`⌘K`) across all prompts and pages
100+
- 📁 **Collections** — group prompts by topic, project, or vibe
101+
- 🖼️ **Image to Text (OCR)** — upload screenshots → extract text → save as prompt
102+
-**AI Refinement** — clean up extracted text into a polished, reusable prompt
103+
- 💾 **One-Click Copy** — paste straight into ChatGPT, Claude, Cursor, whatever
104+
- 🌗 **Dark Mode** — because your eyes matter
105+
- 📱 **Fully Responsive** — works on mobile without crying
106+
- 🔒 **Private by Default** — RLS ensures your data stays yours
107+
-**Instant UI Updates** — add, edit, delete — no page refresh needed
98108

99109
---
100110

101-
### 🖼️ Image to Text (OCR)
102-
103-
closedNote lets you turn screenshots, photos, and handwritten notes into prompts without retyping everything.
104-
105-
**How it works:**
106-
107-
1. You upload an image (screenshot, photo of notes, whatever)
108-
2. The app tries to send it to **Hugging Face OCR API** (our planned primary engine)
109-
3. If that fails or isn't set up yet, it falls back to **Tesseract.js** running right in your browser
110-
4. The extracted text shows up, you can edit it if needed
111-
5. One click saves it as a prompt in your library
111+
## ⚙️ Tech Stack
112112

113-
![OCR Feature](./screenshots/OCR.png)
114-
115-
**Current Status:**
116-
117-
Right now, Tesseract is the stable workhorse while we finalize the Hugging Face integration (API hiccups, you know how it goes). The code is structured so swapping between both or combining them later is super easy.
118-
119-
**Why This Matters:**
120-
121-
Ever find yourself screenshotting a great prompt from Twitter or a Discord server, then having to manually retype the whole thing? Yeah, me too. That's done now.
122-
123-
**The Details:**
124-
125-
When you upload an image:
126-
* **Online Mode**: Sends to Hugging Face TrOCR (Microsoft's printed/handwritten models)
127-
* **Offline Mode**: Falls back to Tesseract.js (runs locally, no internet needed)
128-
* **AI Refinement**: After extraction, you can clean up the text with Zephyr or Mixtral chat models
129-
* **Auto-Save**: Tagged with "ocr" so you can find all your screenshot-based prompts later
130-
131-
![Console Debug View](./screenshots/console1.png)
132-
*Debug console showing OCR processing flow and state management*
113+
<div align="center">
133114

134-
**What's Cool:**
115+
| Frontend | Backend | AI/OCR | Database | Deployment |
116+
|:--------:|:-------:|:------:|:--------:|:----------:|
117+
| <img src="https://cdn.jsdelivr.net/gh/devicons/devicon/icons/nextjs/nextjs-original.svg" width="40" height="40" alt="Next.js"/><br/>**Next.js 14** | <img src="https://avatars.githubusercontent.com/u/54469796?s=200&v=4" width="40" height="40" alt="Supabase"/><br/>**Supabase** | <img src="https://cdn.jsdelivr.net/gh/devicons/devicon/icons/openai/openai-original.svg" width="40" height="40" alt="OpenAI"/><br/>**OpenAI** | <img src="https://cdn.jsdelivr.net/gh/devicons/devicon/icons/postgresql/postgresql-original.svg" width="40" height="40" alt="PostgreSQL"/><br/>**PostgreSQL** | <img src="https://cdn.jsdelivr.net/gh/devicons/devicon/icons/vercel/vercel-original.svg" width="40" height="40" alt="Vercel"/><br/>**Vercel** |
118+
| <img src="https://cdn.jsdelivr.net/gh/devicons/devicon/icons/react/react-original.svg" width="40" height="40" alt="React"/><br/>**React 18** | PKCE Auth | GPT-4o-mini Vision | RLS Policies | Auto Deploy |
119+
| <img src="https://cdn.jsdelivr.net/gh/devicons/devicon/icons/typescript/typescript-original.svg" width="40" height="40" alt="TypeScript"/><br/>**TypeScript** | API Routes | HuggingFace Zephyr | Real-time Sync | Preview URLs |
120+
| <img src="https://cdn.jsdelivr.net/gh/devicons/devicon/icons/tailwindcss/tailwindcss-original.svg" width="40" height="40" alt="Tailwind"/><br/>**Tailwind CSS** | Edge Functions | Tesseract.js (offline) | Migrations | CDN |
135121

136-
The architecture is built with a **primary + fallback** mindset. Even if Hugging Face is down, you're not blocked. Even if you're offline on a train, Tesseract still works. No single point of failure.
122+
</div>
137123

138124
---
139125

140-
### 🧪 How to Run Locally
126+
## 🧪 Run Locally
141127

142128
```bash
143129
git clone https://github.com/aboderinsamuel/closedNote.git
144130
cd closedNote
145131
npm install
146132
cp .env.example .env.local
147-
# Add your Supabase keys inside .env.local
148-
# (Optional) Add HUGGINGFACE_API_KEY for online OCR
133+
# Fill in your Supabase keys in .env.local
149134
npm run dev
150135
```
151136

152-
Then visit 👉 **[http://localhost:3000](http://localhost:3000)**
137+
Visit 👉 **[http://localhost:3000](http://localhost:3000)**
153138

154-
**OCR Setup (Optional):**
155-
- Get a free Hugging Face token from [huggingface.co/settings/tokens](https://huggingface.co/settings/tokens)
156-
- Add `HUGGINGFACE_API_KEY=hf_yourtoken` to `.env.local`
157-
- That's it! OCR will automatically use Hugging Face when available, or fall back to Tesseract
139+
**.env.local variables:**
158140

159-
---
141+
```env
142+
NEXT_PUBLIC_SUPABASE_URL=your_supabase_url
143+
NEXT_PUBLIC_SUPABASE_ANON_KEY=your_supabase_anon_key
144+
```
160145

161-
### 🚀 Deploy to Production
146+
**AI features (optional):**
162147

163-
#### Quick Deploy with Vercel (Recommended)
148+
Users can add their own API keys in the Settings page — no server key needed:
149+
- **OpenAI key** → unlocks AI-powered OCR (GPT-4o-mini vision) + AI refinement
150+
- **HuggingFace key** → unlocks AI refinement (Zephyr-7b)
151+
- **No key** → OCR still works via Tesseract.js (offline, in-browser)
164152

165-
[![Deploy with Vercel](https://vercel.com/button)](https://vercel.com/new/clone?repository-url=https://github.com/aboderinsamuel/closedNote)
153+
---
154+
155+
## 🚀 Deploy to Production
156+
157+
#### Vercel (Recommended)
166158

167-
**Important Steps:**
168-
1. Click the button above or go to [Vercel](https://vercel.com)
169-
2. Import your forked repository
159+
1. Fork this repo
160+
2. Import to [Vercel](https://vercel.com)
170161
3. Add environment variables:
171162
- `NEXT_PUBLIC_SUPABASE_URL`
172163
- `NEXT_PUBLIC_SUPABASE_ANON_KEY`
173-
4. Deploy!
164+
4. Deploy
174165

175166
**After Deployment:**
176-
- Go to your Supabase Dashboard → Authentication → URL Configuration
167+
- Go to Supabase Dashboard → Authentication → URL Configuration
177168
- Add your Vercel domain to **Redirect URLs**: `https://your-app.vercel.app/**`
178169
- Update **Site URL** to: `https://your-app.vercel.app`
179170

180171
---
181172

182-
### 🧰 Developer Notes
183-
184-
closedNote is **developer-friendly**:
185-
186-
* Uses clean React hooks and modular components
187-
* Minimal Tailwind classes (no spaghetti CSS)
188-
* Supabase client handles all Auth + DB calls
189-
* Easy to self-host or extend
190-
191-
---
192-
193-
### 🔒 Security Highlights
173+
## 🔒 Security
194174

195-
* ✅ Row Level Security (RLS) enabled on all tables
196-
* ✅ Auth via Supabase (JWT-secured)
197-
*`.env.local` excluded from Git (already in `.gitignore`)
198-
*HTTPS enforced on production (Vercel)
199-
*Minimal data collection - only email + prompts
175+
- ✅ Row Level Security (RLS) on all tables
176+
- ✅ Auth via Supabase (PKCE + JWT)
177+
-User API keys stored in `localStorage` only — never persisted server-side
178+
-`.env.local` excluded from Git
179+
-HTTPS enforced on Vercel
200180

201181
---
202182

203-
### 🧑🏽‍💻 Contributing
183+
## 🧑🏽‍💻 Contributing
204184

205-
closedNote is **completely open source** and **open for amendments**.
185+
closedNote is **completely open source** and open to contributions.
206186
The goal is to make prompt saving easier for *everyone*, not just developers.
207187

208-
If you've got ideas, dark mode, AI tag suggestions, team sharing, prompt history, whatever, you're welcome to hop in!
188+
Got ideas? Dark mode themes, AI tag suggestions, team sharing, prompt history hop in!
209189

210190
```bash
211-
# Steps to contribute
212191
1. Fork this repo 🍴
213192
2. Create a branch (feature/my-new-idea)
214193
3. Commit & push
@@ -217,21 +196,21 @@ If you've got ideas, dark mode, AI tag suggestions, team sharing, prompt history
217196

218197
---
219198

220-
### 👨🏽‍🎓 About the Developer
199+
## 👨🏽‍🎓 About
221200

222201
Built by [**Samuel Aboderin**](https://github.com/aboderinsamuel),
223202
Computer Engineering student at **UNILAG 🇳🇬**,
224-
who just got tired of losing his prompts (and decided to fix it for everyone else too).
203+
who got tired of losing his prompts and decided to fix it for everyone else too.
225204

226-
Reach me on [LinkedIn](https://www.linkedin.com/in/samuelaboderin).
205+
[LinkedIn](https://www.linkedin.com/in/samuelaboderin) · [GitHub](https://github.com/aboderinsamuel)
227206

228207
---
229208

230-
### 🧾 License
209+
## 🧾 License
231210

232-
MIT License, use it, remix it, or improve it.
233-
Just don't lock it behind a paywall. 🙏🏽
211+
MIT -
212+
use it, remix it, improve it. Just don't lock it behind a paywall. 🙏🏽
234213

235214
---
236215

237-
**closedNote**, *because your prompts deserve better than browser history.*
216+
*closedNote - because your prompts deserve better than browser history.*

0 commit comments

Comments
 (0)