veela4 commited on
Commit
487fce7
·
verified ·
1 Parent(s): 34197e9

Add files using upload-large-folder tool

Browse files
Files changed (7) hide show
  1. .gitattributes +5 -0
  2. HTMLDownload.png +3 -0
  3. LunaProcessing.png +3 -0
  4. PDFPreview.png +3 -0
  5. RAWMD.png +3 -0
  6. RAWText.png +3 -0
  7. README.md +189 -330
.gitattributes CHANGED
@@ -33,3 +33,8 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
33
  *.zip filter=lfs diff=lfs merge=lfs -text
34
  *.zst filter=lfs diff=lfs merge=lfs -text
35
  *tfevents* filter=lfs diff=lfs merge=lfs -text
 
 
 
 
 
 
33
  *.zip filter=lfs diff=lfs merge=lfs -text
34
  *.zst filter=lfs diff=lfs merge=lfs -text
35
  *tfevents* filter=lfs diff=lfs merge=lfs -text
36
+ RAWMD.png filter=lfs diff=lfs merge=lfs -text
37
+ HTMLDownload.png filter=lfs diff=lfs merge=lfs -text
38
+ PDFPreview.png filter=lfs diff=lfs merge=lfs -text
39
+ RAWText.png filter=lfs diff=lfs merge=lfs -text
40
+ LunaProcessing.png filter=lfs diff=lfs merge=lfs -text
HTMLDownload.png ADDED

Git LFS Details

  • SHA256: 866bf97f6595d3e5cc600457e6839a09676d3f2986960cdecb604b524e0e5c28
  • Pointer size: 131 Bytes
  • Size of remote file: 593 kB
LunaProcessing.png ADDED

Git LFS Details

  • SHA256: 7b230fb64ddf63a3d9162157fdf07137009016885c98c744680a07962d160dba
  • Pointer size: 131 Bytes
  • Size of remote file: 211 kB
PDFPreview.png ADDED

Git LFS Details

  • SHA256: 7c799fb218a6e50eb870004091441f0331f0be0dc7094117f9e0225862b797bb
  • Pointer size: 131 Bytes
  • Size of remote file: 614 kB
RAWMD.png ADDED

Git LFS Details

  • SHA256: 2d36eef38fec2b8630a4dcf15ed65d0cf5675ff8c3bb979ea512ce5fa47711e4
  • Pointer size: 131 Bytes
  • Size of remote file: 402 kB
RAWText.png ADDED

Git LFS Details

  • SHA256: ce261cd8ce4cd7cf8dbec58beab63e1d9e3ae4bc67cfa1d653469e9071e7d790
  • Pointer size: 131 Bytes
  • Size of remote file: 434 kB
README.md CHANGED
@@ -26,59 +26,92 @@ license: mit
26
 
27
  ## ✨ **What Makes Luna OCR Special**
28
 
29
- <div align="center">
30
-
31
- ### 🎯 **Core Capabilities**
32
-
33
- </div>
34
-
35
  <table>
36
  <tr>
37
  <td align="center" width="25%">
38
- <h3>🤖 AI-Powered</h3>
39
- <p><strong>Google Gemini 2.5</strong></p>
40
- <p>Flash & Pro models for optimal speed and accuracy</p>
 
 
41
  </td>
42
  <td align="center" width="25%">
43
- <h3>🇹🇭 Thai Optimized</h3>
44
- <p><strong>Perfect Word Spacing</strong></p>
45
- <p>Specialized prompts for Thai text processing</p>
 
 
46
  </td>
47
  <td align="center" width="25%">
48
- <h3>📊 Smart Tables</h3>
49
- <p><strong>Structure Preserved</strong></p>
50
- <p>Complex tables converted to markdown format</p>
 
 
51
  </td>
52
  <td align="center" width="25%">
53
- <h3>🔐 Secure Storage</h3>
54
- <p><strong>AES-256 Encryption</strong></p>
55
- <p>API keys encrypted with device salt</p>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
56
  </td>
57
  </tr>
58
  </table>
59
 
60
  ---
61
 
62
- ## 🚀 **Feature Highlights**
63
 
64
  <table>
65
  <tr>
66
  <td width="50%">
67
 
68
- ### 📝 **Document Processing**
69
- - 🖼️ **Images**: PNG, JPEG, WebP support
70
- - 📄 **PDF Files**: Multi-page processing with progress tracking
71
- - 🌐 **HTML Documents**: Interactive viewer with styling
72
- - ⚡ **Real-time**: Live progress updates and preview
73
 
74
  </td>
75
  <td width="50%">
76
 
77
- ### 🎨 **Output Formats**
78
- - 📝 **Markdown**: GitHub-compatible with tables
79
- - 📊 **JSON**: Structured data with metadata
80
- - 🌐 **HTML**: Styled output with glassmorphism theme
81
- - 📄 **Plain Text**: Clean, readable format
82
 
83
  </td>
84
  </tr>
@@ -86,123 +119,107 @@ license: mit
86
 
87
  ---
88
 
89
- ## 🛠️ **Technology Arsenal**
90
 
91
  <table>
92
  <tr>
93
  <td align="center" width="25%">
94
- <img src="https://img.shields.io/badge/React_19-61DAFB?style=for-the-badge&logo=react&logoColor=black" />
95
- <br><strong>Frontend Engine</strong>
96
- <br><em>Lightning-fast UI</em>
 
 
97
  </td>
98
  <td align="center" width="25%">
99
- <img src="https://img.shields.io/badge/Gemini_2.5-4285F4?style=for-the-badge&logo=google&logoColor=white" />
100
- <br><strong>AI Brain</strong>
101
- <br><em>Flash & Pro models</em>
 
 
102
  </td>
103
  <td align="center" width="25%">
104
- <img src="https://img.shields.io/badge/Node.js-339933?style=for-the-badge&logo=node.js&logoColor=white" />
105
- <br><strong>Backend Power</strong>
106
- <br><em>Express + Sharp</em>
 
 
107
  </td>
108
  <td align="center" width="25%">
109
- <img src="https://img.shields.io/badge/Three.js-000000?style=for-the-badge&logo=three.js&logoColor=white" />
110
- <br><strong>3D Graphics</strong>
111
- <br><em>Stunning visuals</em>
 
 
112
  </td>
113
  </tr>
114
  </table>
115
 
116
- ### 🎨 **UI/UX Stack**
 
117
  | Component | Technology | Purpose |
118
  |-----------|------------|---------|
119
  | 🎭 **Design System** | Glassmorphism + Radix UI | Modern, accessible interface |
120
  | ⚡ **Animations** | Framer Motion + GSAP | Smooth, professional transitions |
121
  | 📱 **Responsiveness** | CSS Grid + Flexbox | Perfect on all devices |
122
- | 🔐 **Security** | AES-256 + Salt encryption | Secure API key storage |
123
 
124
  ---
125
 
126
- ## 📦 **Installation & Setup**
127
-
128
- ### 🚀 **Quick Start (2 minutes)**
129
 
130
  ```bash
131
- # 1️⃣ Clone the repository
132
  git clone https://huggingface.co/veela4/luna_ocr
133
  cd luna_ocr
134
 
135
- # 2️⃣ Install dependencies
136
  npm install && cd server && npm install && cd ..
137
 
138
- # 3️⃣ Launch the application
139
  npm start
140
  ```
141
 
142
- > 🔐 **No .env file needed!** API keys are stored securely in encrypted local storage with device-specific salt protection.
143
 
144
  ### 🌐 **Access Points**
 
145
  | Service | URL | Purpose |
146
  |---------|-----|---------|
147
- | 🖥️ **Frontend** | `http://localhost:3000` | Main application interface |
148
- | 🔧 **Backend API** | `http://localhost:3002` | REST API endpoints |
149
- | 📊 **Health Check** | `http://localhost:3002/api/health` | System status monitoring |
150
 
151
  ---
152
 
153
- ## 🎯 **Supported File Types & Features**
154
 
155
  <table>
156
  <tr>
157
  <td width="33%">
158
 
159
- ### 📄 **Document Types**
160
- - 🖼️ **Images**
161
- - PNG, JPEG, WebP
162
- - High-resolution support
163
- - Auto-enhancement
164
- - 📋 **PDF Files**
165
- - Multi-page processing
166
- - Page-by-page extraction
167
- - Progress tracking
168
- - 🌐 **HTML Documents**
169
- - Styled content
170
- - Table preservation
171
- - Interactive viewer
172
 
173
  </td>
174
  <td width="33%">
175
 
176
- ### 🇹🇭 **Language Support**
177
- - 🇹🇭 **Thai Language**
178
- - Optimized word spacing
179
- - Context-aware processing
180
- - Cultural text understanding
181
- - 🇺🇸 **English**
182
- - High accuracy
183
- - Technical terminology
184
- - Mixed language support
185
- - 🌍 **Multi-language**
186
- - Auto-detection
187
- - Preserve original language
188
- - Mixed content handling
189
 
190
  </td>
191
  <td width="33%">
192
 
193
- ### 🎨 **Processing Modes**
194
- - **Standard Mode**
195
- - Gemini 2.5 Flash
196
- - Fast processing
197
- - Same features as Pro
198
- - 🧠 **Structured Mode**
199
- - Gemini 2.5 Pro
200
- - Maximum accuracy
201
- - Advanced formatting
202
- - 📊 **Smart Tables**
203
- - Auto-detection
204
- - Structure preservation
205
- - Sortable output
206
 
207
  </td>
208
  </tr>
@@ -210,99 +227,66 @@ npm start
210
 
211
  ---
212
 
213
- ## 🔧 **Output Format Showcase**
 
 
 
 
214
 
215
- ### 📊 **Format Comparison Table**
 
 
 
 
216
 
217
- | Format | 🎯 Best For | � Fceatures | � Uase Cases |
218
- |--------|-------------|-------------|---------------|
219
- | **📝 Markdown** | Documentation | Tables, headers, formatting | GitHub, wikis, blogs |
220
- | **📊 JSON** | Data processing | Structured, queryable | APIs, databases, analytics |
221
- | **🌐 HTML** | Web publishing | Styled, interactive | Websites, reports, presentations |
222
- | **📄 Plain Text** | Quick reading | Clean, readable | Notes, emails, drafts |
223
 
224
- ### 💻 **Real Output Examples**
 
 
 
 
225
 
226
- #### 📝 **Markdown Output**
227
- ```markdown
228
- ## รายงานการขาย Q4 2024
229
 
230
- | รายการ | จำนวน | ราคา |
231
- |--------|--------|------|
232
- | กาแฟ อเมริกาโน่ | 2 แก้ว | 120 บาท |
233
- | ขนมปังโฮลวีท | 1 ชิ้น | 45 บาท |
234
 
235
- **รวมทั้งสิ้น:** 165 บาท
236
- ```
237
 
238
- #### 📊 **JSON Output**
239
- ```json
240
- {
241
- "metadata": {
242
- "fileName": "receipt.jpg",
243
- "characterCount": 1247,
244
- "processingMode": "structured",
245
- "confidence": 0.98
246
- },
247
- "content": {
248
- "title": "รายงานการขาย Q4 2024",
249
- "tables": [
250
- {
251
- "headers": ["รายการ", "จำนวน", "ราคา"],
252
- "rows": [
253
- ["กาแฟ อเมริกาโน่", "2 แก้ว", "120 บาท"],
254
- ["ขนมปังโฮลวีท", "1 ชิ้น", "45 บาท"]
255
- ]
256
- }
257
- ]
258
- }
259
- }
260
- ```
261
 
262
  ---
263
 
264
- ## 🎨 **Advanced AI Features**
265
-
266
- ### 🧠 **Intelligence Matrix**
267
-
268
- | Feature | Description | Implementation |
269
- |---------|-------------|----------------|
270
- | 🇹🇭 **Thai Text Processing** | Optimized word spacing and context | Custom prompts for Thai language |
271
- | 📊 **Table Intelligence** | Preserves complex table structures | Markdown table generation |
272
- | ✨ **Format Preservation** | Maintains original styling and layout | AI-powered structure detection |
273
- | 🔧 **Error Correction** | Fixes OCR mistakes using AI context | Context-aware processing |
274
- | 📈 **Data Categorization** | Auto-sorts and labels extracted data | Smart content organization |
275
- | 🎯 **Smart Extraction** | Identifies key information automatically | Pattern recognition |
276
-
277
- ### 🚀 **Processing Pipeline**
278
-
279
- ```mermaid
280
- graph LR
281
- A[📤 Upload] --> B[🔍 Analysis]
282
- B --> C[🤖 AI Processing]
283
- C --> D[✨ Enhancement]
284
- D --> E[📊 Formatting]
285
- E --> F[📋 Output]
286
-
287
- style A fill:#e1f5fe
288
- style C fill:#f3e5f5
289
- style F fill:#e8f5e8
290
- ```
291
 
292
  ---
293
 
294
- ## 📡 **API Documentation**
295
 
296
- ### 🔌 **Endpoints Overview**
297
 
298
- | Method | Endpoint | Purpose | Response Time |
299
- |--------|----------|---------|---------------|
300
- | `POST` | `/api/ocr` | 📤 Process documents | Variable |
301
- | `GET` | `/api/health` | 💚 System status | < 100ms |
302
- | `GET` | `/api/progress/:id` | 📊 Processing status | Real-time |
303
- | `POST` | `/api/cleanup` | 🧹 Clear temp files | < 500ms |
 
 
304
 
305
- ### 📤 **OCR Processing Request**
306
  ```bash
307
  curl -X POST http://localhost:3002/api/ocr \
308
  -H "Content-Type: multipart/form-data" \
@@ -311,24 +295,22 @@ curl -X POST http://localhost:3002/api/ocr \
311
  -F "mode=structured"
312
  ```
313
 
314
- ### 📥 **Response Structure**
 
315
  ```json
316
  {
317
  "success": true,
318
- "sessionId": "1704067200000",
319
  "data": {
320
  "fileName": "document.pdf",
321
- "processingMode": "structured",
322
  "extractedText": "## Document Title\n\n...",
323
  "formats": {
324
- "txt": "Plain text version...",
325
- "md": "## Markdown version...",
326
- "json": { /* structured data */ }
327
  },
328
  "metadata": {
329
  "characterCount": 1247,
330
- "wordCount": 234,
331
- "confidence": 0.98
332
  }
333
  }
334
  }
@@ -336,66 +318,6 @@ curl -X POST http://localhost:3002/api/ocr \
336
 
337
  ---
338
 
339
- ## 🏆 **What You Get**
340
-
341
- <div align="center">
342
-
343
- ### 🎯 **Processing Capabilities**
344
-
345
- </div>
346
-
347
- <table>
348
- <tr>
349
- <td align="center" width="25%">
350
- <h3>🇹�* Thai Text</h3>
351
- <p><strong>Optimized Processing</strong></p>
352
- <p>Perfect word spacing and context understanding</p>
353
- </td>
354
- <td align="center" width="25%">
355
- <h3>📊 Tables</h3>
356
- <p><strong>Structure Preserved</strong></p>
357
- <p>Complex tables converted to markdown format</p>
358
- </td>
359
- <td align="center" width="25%">
360
- <h3>� Englissh Text</h3>
361
- <p><strong>High Accuracy</strong></p>
362
- <p>Clean character recognition and formatting</p>
363
- </td>
364
- <td align="center" width="25%">
365
- <h3>🎨 Formatting</h3>
366
- <p><strong>Style Retention</strong></p>
367
- <p>Original layout and styling preserved</p>
368
- </td>
369
- </tr>
370
- </table>
371
-
372
- ### ⚡ **Performance Features**
373
-
374
- <table>
375
- <tr>
376
- <td width="50%">
377
-
378
- #### 🚀 **Speed & Efficiency**
379
- - **Fast Processing**: Optimized for daily use
380
- - **Real-time Updates**: Live progress tracking
381
- - **Auto Cleanup**: Temporary files managed automatically
382
- - **Memory Efficient**: Optimized resource usage
383
-
384
- </td>
385
- <td width="50%">
386
-
387
- #### 🎯 **Quality & Accuracy**
388
- - **AI Enhancement**: Gemini 2.5 models for best results
389
- - **Context Aware**: Understands document types
390
- - **Error Correction**: Fixes common OCR mistakes
391
- - **Multi-language**: Thai and English support
392
-
393
- </td>
394
- </tr>
395
- </table>
396
-
397
- ---
398
-
399
  ## 🛡️ **Security & Privacy**
400
 
401
  ### 🔐 **Security Features**
@@ -404,111 +326,57 @@ curl -X POST http://localhost:3002/api/ocr \
404
  |---------|----------------|---------|
405
  | 🔑 **API Key Encryption** | AES-256 + Device Salt | Secure local storage |
406
  | 🗑️ **Auto Cleanup** | 15-minute intervals | No data persistence |
407
- | 🚫 **No Cloud Storage** | Local processing only | Complete privacy |
408
- | 🔒 **HTTPS Only** | TLS 1.3 encryption | Secure transmission |
409
- | 🛡️ **Input Validation** | Comprehensive sanitization | Prevent attacks |
410
-
411
- ### 🔐 **Encryption Details**
412
- ```javascript
413
- // Multi-layer encryption with device fingerprinting
414
- const encryptedKey = encrypt(apiKey, deviceSalt + additionalSalt);
415
- localStorage.setItem('luna_secure_config_v2', encryptedKey);
416
- ```
417
 
418
  ---
419
 
420
- ## 🎮 **User Interface Features**
421
 
422
- ### 🎭 **Interactive Elements**
 
 
 
 
423
 
424
- <table>
425
- <tr>
426
- <td width="50%">
427
-
428
- #### 🌟 **Visual Features**
429
- - **Glassmorphism Design**: Modern blur effects
430
- - **3D Orb Animation**: Interactive WebGL orb
431
- - **Smooth Transitions**: Framer Motion animations
432
- - **Responsive Layout**: Perfect on all devices
433
- - **Dark Theme**: Eye-friendly interface
434
- - **Progress Tracking**: Real-time visual feedback
435
-
436
- </td>
437
- <td width="50%">
438
-
439
- #### ⚡ **Interaction Features**
440
- - **Drag & Drop**: Intuitive file upload
441
- - **Paste Support**: Direct image pasting
442
- - **Live Preview**: See results as processed
443
- - **Format Switching**: Toggle between outputs
444
- - **Copy to Clipboard**: One-click copying
445
- - **Download Options**: Multiple export formats
446
-
447
- </td>
448
- </tr>
449
- </table>
450
-
451
- ### 📱 **Mobile Optimization**
452
- - Touch-friendly interface
453
- - Responsive design
454
- - Optimized performance
455
- - Gesture support
456
 
457
  ---
458
 
459
- ## 🤝 **Contributing & Community**
460
 
461
- ### 🌟 **Ways to Contribute**
462
 
463
  <table>
464
  <tr>
465
  <td width="50%">
466
 
467
- #### 🐛 **Bug Reports**
468
- - Detailed issue descriptions
469
  - Reproduction steps
470
- - Environment information
471
- - Expected vs actual behavior
472
-
473
- #### 💡 **Feature Requests**
474
- - Use case descriptions
475
- - Implementation suggestions
476
- - Priority justification
477
- - Community voting
478
 
479
  </td>
480
  <td width="50%">
481
 
482
- #### 🔧 **Code Contributions**
483
- - Fork the repository
484
- - Create feature branches
485
- - Write comprehensive tests
486
- - Submit pull requests
487
-
488
- #### 📖 **Documentation**
489
- - API documentation
490
- - Tutorial creation
491
- - Example projects
492
- - Translation support
493
 
494
  </td>
495
  </tr>
496
  </table>
497
 
498
- ### 🌟 **Project Highlights**
499
-
500
- <div align="center">
501
-
502
- [![🌙 Luna OCR](https://img.shields.io/badge/🌙_Luna_OCR-v1.0.0-blue?style=for-the-badge)](https://huggingface.co/veela4/luna_ocr)
503
- [![🔧 React 19](https://img.shields.io/badge/⚛️_React-19.1.1-61DAFB?style=for-the-badge&logo=react)](https://huggingface.co/veela4/luna_ocr)
504
- [![🤖 Gemini AI](https://img.shields.io/badge/🤖_Gemini-2.5_Flash_&_Pro-4285F4?style=for-the-badge)](https://huggingface.co/veela4/luna_ocr)
505
- [![📜 MIT License](https://img.shields.io/badge/📜_License-MIT-green?style=for-the-badge)](https://huggingface.co/veela4/luna_ocr)
506
-
507
- </div>
508
-
509
  ---
510
 
511
- ## 📄 **License & Legal**
512
 
513
  <div align="center">
514
 
@@ -517,23 +385,14 @@ localStorage.setItem('luna_secure_config_v2', encryptedKey);
517
 
518
  [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg?style=for-the-badge)](https://opensource.org/licenses/MIT)
519
 
520
- *Use, modify, distribute, and sell without restrictions*
521
-
522
  ---
523
 
524
- <table>
525
- <tr>
526
- <td align="center">
527
- <strong>🚀 Ready to transform your document workflow?</strong>
528
- <br><br>
529
  <a href="https://huggingface.co/veela4/luna_ocr">
530
  <img src="https://img.shields.io/badge/🌙_Try_Luna_OCR-Now_Free-blue?style=for-the-badge&logo=rocket" />
531
  </a>
532
- </td>
533
- </tr>
534
- </table>
535
 
536
- **Built with ❤️ by developers, for developers**
537
- *Making document processing intelligent, fast, and beautiful*
538
 
539
  </div>
 
26
 
27
  ## ✨ **What Makes Luna OCR Special**
28
 
 
 
 
 
 
 
29
  <table>
30
  <tr>
31
  <td align="center" width="25%">
32
+
33
+ ### 🤖 **AI-Powered**
34
+ **Google Gemini 2.5**
35
+ Flash & Pro models for optimal speed and accuracy
36
+
37
  </td>
38
  <td align="center" width="25%">
39
+
40
+ ### 🇹🇭 **Thai Optimized**
41
+ **Perfect Word Spacing**
42
+ Specialized prompts for Thai text processing
43
+
44
  </td>
45
  <td align="center" width="25%">
46
+
47
+ ### 📊 **Smart Tables**
48
+ **Structure Preserved**
49
+ Complex tables converted to markdown format
50
+
51
  </td>
52
  <td align="center" width="25%">
53
+
54
+ ### 🔐 **Secure Storage**
55
+ **AES-256 Encryption**
56
+ API keys encrypted with device salt
57
+
58
+ </td>
59
+ </tr>
60
+ </table>
61
+
62
+ ---
63
+
64
+ ## 🎯 **Live Processing Demo**
65
+
66
+ <div align="center">
67
+
68
+ ### � **Reaul-time Progress Tracking**
69
+ ![Luna Processing](LunaProcessing.png)
70
+ *Live processing with detailed logs, character counts, and progress tracking*
71
+
72
+ </div>
73
+
74
+ ---
75
+
76
+ ## 📝 **Output Format Examples**
77
+
78
+ <table>
79
+ <tr>
80
+ <td width="50%">
81
+
82
+ ### 📄 **Raw Text Output**
83
+ ![Raw Text](RawText.png)
84
+ *Clean, readable plain text extraction*
85
+
86
+ </td>
87
+ <td width="50%">
88
+
89
+ ### � **Marhkdown Format**
90
+ ![Raw Markdown](RawMD.png)
91
+ *Structured markdown with tables and formatting*
92
+
93
  </td>
94
  </tr>
95
  </table>
96
 
97
  ---
98
 
99
+ ## 🌐 **Document Viewer & Export**
100
 
101
  <table>
102
  <tr>
103
  <td width="50%">
104
 
105
+ ### 📋 **PDF Preview**
106
+ ![PDF Preview](PDFPreview.png)
107
+ *Interactive PDF viewer with page navigation*
 
 
108
 
109
  </td>
110
  <td width="50%">
111
 
112
+ ### 🎨 **HTML Export**
113
+ ![HTML Download](HTMLDownload.png)
114
+ *Beautiful glassmorphism-styled HTML output*
 
 
115
 
116
  </td>
117
  </tr>
 
119
 
120
  ---
121
 
122
+ ## �️ S**Technology Stack**
123
 
124
  <table>
125
  <tr>
126
  <td align="center" width="25%">
127
+
128
+ ![React](https://img.shields.io/badge/React_19-61DAFB?style=for-the-badge&logo=react&logoColor=black)
129
+ **Frontend Engine**
130
+ Lightning-fast UI
131
+
132
  </td>
133
  <td align="center" width="25%">
134
+
135
+ ![Gemini](https://img.shields.io/badge/Gemini_2.5-4285F4?style=for-the-badge&logo=google&logoColor=white)
136
+ **AI Brain**
137
+ Flash & Pro models
138
+
139
  </td>
140
  <td align="center" width="25%">
141
+
142
+ ![Node.js](https://img.shields.io/badge/Node.js-339933?style=for-the-badge&logo=node.js&logoColor=white)
143
+ **Backend Power**
144
+ Express + Sharp
145
+
146
  </td>
147
  <td align="center" width="25%">
148
+
149
+ ![Three.js](https://img.shields.io/badge/Three.js-000000?style=for-the-badge&logo=three.js&logoColor=white)
150
+ **3D Graphics**
151
+ Stunning visuals
152
+
153
  </td>
154
  </tr>
155
  </table>
156
 
157
+ ### 🎨 **UI/UX Components**
158
+
159
  | Component | Technology | Purpose |
160
  |-----------|------------|---------|
161
  | 🎭 **Design System** | Glassmorphism + Radix UI | Modern, accessible interface |
162
  | ⚡ **Animations** | Framer Motion + GSAP | Smooth, professional transitions |
163
  | 📱 **Responsiveness** | CSS Grid + Flexbox | Perfect on all devices |
164
+ | **SecuFrity** | AES-256 + Salt encryption | Secure API key storage |
165
 
166
  ---
167
 
168
+ ## 📦 **Quick Start**
 
 
169
 
170
  ```bash
171
+ # Clone the repository
172
  git clone https://huggingface.co/veela4/luna_ocr
173
  cd luna_ocr
174
 
175
+ # Install dependencies
176
  npm install && cd server && npm install && cd ..
177
 
178
+ # Launch the application
179
  npm start
180
  ```
181
 
182
+ > 🔐 **No .env file needed!** API keys are stored securely in encrypted local storage.
183
 
184
  ### 🌐 **Access Points**
185
+
186
  | Service | URL | Purpose |
187
  |---------|-----|---------|
188
+ | 🖥️ **Frontend** | `http://localhost:3000` | Main application |
189
+ | 🔧 **Backend** | `http://localhost:3002` | REST API |
190
+ | 📊 **Health Check** | `http://localhost:3002/api/health` | System status |
191
 
192
  ---
193
 
194
+ ## 📄 **Supported File Types**
195
 
196
  <table>
197
  <tr>
198
  <td width="33%">
199
 
200
+ ### 🖼️ **Images**
201
+ - PNG, JPEG, WebP
202
+ - High-resolution support
203
+ - Auto-enhancement
204
+ - Drag & drop upload
 
 
 
 
 
 
 
 
205
 
206
  </td>
207
  <td width="33%">
208
 
209
+ ### 📋 **PDF Files**
210
+ - Multi-page processing
211
+ - Page-by-page extraction
212
+ - Progress tracking
213
+ - Interactive viewer
 
 
 
 
 
 
 
 
214
 
215
  </td>
216
  <td width="33%">
217
 
218
+ ### 🌐 **HTML Documents**
219
+ - Styled content
220
+ - Table preservation
221
+ - Interactive viewer
222
+ - Glassmorphism theme
 
 
 
 
 
 
 
 
223
 
224
  </td>
225
  </tr>
 
227
 
228
  ---
229
 
230
+ ## 🇹🇭 **Language Support**
231
+
232
+ <table>
233
+ <tr>
234
+ <td width="50%">
235
 
236
+ ### 🇹🇭 **Thai Language**
237
+ - **Optimized word spacing**
238
+ - **Context-aware processing**
239
+ - **Cultural text understanding**
240
+ - **Mixed language support**
241
 
242
+ </td>
243
+ <td width="50%">
 
 
 
 
244
 
245
+ ### 🇺🇸 **English & Others**
246
+ - **High accuracy recognition**
247
+ - **Technical terminology**
248
+ - **Auto-language detection**
249
+ - **Preserve original formatting**
250
 
251
+ </td>
252
+ </tr>
253
+ </table>
254
 
255
+ ---
 
 
 
256
 
257
+ ## 🎨 **Processing Modes**
 
258
 
259
+ | Mode | Model | Speed | Best For |
260
+ |------|-------|-------|----------|
261
+ | ⚡ **Standard** | Gemini 2.5 Flash | Fast | Quick processing |
262
+ | 🧠 **Structured** | Gemini 2.5 Pro | Slower | Maximum accuracy |
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
263
 
264
  ---
265
 
266
+ ## 📊 **Output Formats**
267
+
268
+ | Format | Best For | Features |
269
+ |--------|----------|----------|
270
+ | 📝 **Markdown** | Documentation | Tables, headers, GitHub-compatible |
271
+ | 📊 **JSON** | Data processing | Structured, queryable, metadata |
272
+ | 🌐 **HTML** | Web publishing | Styled, glassmorphism theme |
273
+ | **Plain Text** | Quick reading | Clean, readable format |
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
274
 
275
  ---
276
 
277
+ ## ***API Reference**
278
 
279
+ ### 🔌 **Main Endpoints**
280
 
281
+ | Method | Endpoint | Purpose |
282
+ |--------|----------|---------|
283
+ | `POST` | `/api/ocr` | Process documents |
284
+ | `GET` | `/api/health` | System status |
285
+ | `GET` | `/api/progress/:id` | Processing status |
286
+ | `POST` | `/api/cleanup` | Clear temp files |
287
+
288
+ ### 📤 **Example Request**
289
 
 
290
  ```bash
291
  curl -X POST http://localhost:3002/api/ocr \
292
  -H "Content-Type: multipart/form-data" \
 
295
  -F "mode=structured"
296
  ```
297
 
298
+ ### 📥 **Example Response**
299
+
300
  ```json
301
  {
302
  "success": true,
 
303
  "data": {
304
  "fileName": "document.pdf",
 
305
  "extractedText": "## Document Title\n\n...",
306
  "formats": {
307
+ "txt": "Plain text...",
308
+ "md": "## Markdown...",
309
+ "json": { "structured": "data" }
310
  },
311
  "metadata": {
312
  "characterCount": 1247,
313
+ "wordCount": 234
 
314
  }
315
  }
316
  }
 
318
 
319
  ---
320
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
321
  ## 🛡️ **Security & Privacy**
322
 
323
  ### 🔐 **Security Features**
 
326
  |---------|----------------|---------|
327
  | 🔑 **API Key Encryption** | AES-256 + Device Salt | Secure local storage |
328
  | 🗑️ **Auto Cleanup** | 15-minute intervals | No data persistence |
329
+ | 🚫 **Local Processing** | No cloud storage | Complete privacy |
330
+ | 🔒 **HTTPS Only** | TLS encryption | Secure transmission |
 
 
 
 
 
 
 
 
331
 
332
  ---
333
 
334
+ ## 🎮 **User Interface**
335
 
336
+ ### 🌟 **Visual Features**
337
+ - **Glassmorphism Design** - Modern blur effects
338
+ - **3D Orb Animation** - Interactive WebGL orb
339
+ - **Smooth Transitions** - Framer Motion animations
340
+ - **Dark Theme** - Eye-friendly interface
341
 
342
+ ### ⚡ **Interaction Features**
343
+ - **Drag & Drop** - Intuitive file upload
344
+ - **Paste Support** - Direct image pasting
345
+ - **Live Preview** - Real-time results
346
+ - **Format Switching** - Toggle between outputs
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
347
 
348
  ---
349
 
350
+ ## 🤝 **Contributing**
351
 
352
+ ### 🌟 **How to Help**
353
 
354
  <table>
355
  <tr>
356
  <td width="50%">
357
 
358
+ #### 🐛 **Report Issues**
359
+ - Detailed descriptions
360
  - Reproduction steps
361
+ - Environment info
362
+ - Expected behavior
 
 
 
 
 
 
363
 
364
  </td>
365
  <td width="50%">
366
 
367
+ #### 💡 **Suggest Features**
368
+ - Use case descriptions
369
+ - Implementation ideas
370
+ - Priority justification
371
+ - Community feedback
 
 
 
 
 
 
372
 
373
  </td>
374
  </tr>
375
  </table>
376
 
 
 
 
 
 
 
 
 
 
 
 
377
  ---
378
 
379
+ ## 📄 **License**
380
 
381
  <div align="center">
382
 
 
385
 
386
  [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg?style=for-the-badge)](https://opensource.org/licenses/MIT)
387
 
 
 
388
  ---
389
 
390
+ ### 🚀 **Ready to Get Started?**
391
+
 
 
 
392
  <a href="https://huggingface.co/veela4/luna_ocr">
393
  <img src="https://img.shields.io/badge/🌙_Try_Luna_OCR-Now_Free-blue?style=for-the-badge&logo=rocket" />
394
  </a>
 
 
 
395
 
396
+ **Built with ❤️ for developers who demand accuracy**
 
397
 
398
  </div>