1. StructureClassifier (محلي): يكتشف الجداول والمو

← العودة
Blog Post

عنوان المحادثة: 1. StructureClassifier (محلي): يكتشف الجداول والمواصفات والرسومات2. LL...

التاريخ: 01.05.2026

التصنيف: 💻 البرمجة وتطوير البرمجيات

إجمالي الرسائل: 11 | ياسر: 7 | M: 4

Yasser
1. StructureClassifier (محلي): يكتشف الجداول والمواصفات والرسومات2. LLMExtractor (GPT-4o): يُرسل Prompts مخصصة حسب نوع المحتوى3. VisionExtractor (GPT-4o Vision): يحلل الرسومات الممسوحة صورياً4. Smart Deduplication: يُزيل التكرار ويوحّد الأسماءنتائج التحسين:- TAKEOFF-50: من 4 بنود → 22 بند (5.5x تحسن)- TAKEOFF-36: من 0 → 48 بند- TAKEOFF-31: من 0 → 3 بنود### 3.3 نظام OCR متكامل- 29 اختبار ناجح لنظام OCR- خط معالجة كامل للصور (Grayscale → Contrast → Sharpen → Denoise → Threshold → Deskew)- تكامل تلقائي مع PDFExtractor (OCR fallback للصفحات الممسوحة)- دعم PSM/OEM modes قابلة للتكوين### 3.4 واجهة مستخدم رسومية (GUI)5 صفحات كاملة:- Dashboard: إحصائيات المشاريع، حالة API، سجل المهام، إدارة البيانات- Projects: إدارة المشاريع، إضافة مجلدات مخصصة، إخفاء/استعادة- Pipeline: تشغيل الاستخراج مع تتبع مباشر للتقدم والسجلات- Results: عرض النتائج، تصفية حسب التجارة، تقارير التقييم- Settings: إعدادات LLM، OCR، Pipeline، Evaluation، Output### 3.5 نشر الإنتاج (Production Deployment)- ✅ Docker Compose متكامل (Backend + Frontend + Nginx)- ✅ HTTPS على https://assign.jobotai.site- ✅ Let's Encrypt SSL تلقائي- ✅ Caddy reverse proxy- ✅ Healthchecks للخدمات### 3.6 السجل الديناميكي للمشاريع- لا يوجد مسح تلقائي hardcoded- المستخدم يُضيف المجلدات يدوياً عبر POST /projects/from-folder- السجل يُحفظ في registered_projects.json- إخفاء/استعادة المشاريع مع الحفاظ على الملفات المصدرية---## 4. سجل القرارات (Decision Log)| القرار | التاريخ | الملخص ||--------|---------|--------|| DEC-001 | 2026-04-29 | إنشاء .kimi/ مع 7 ملفات ذاكرة || DEC-002 | 2026-04-29 | اختيار Python 3.12 || DEC-003 | 2026-04-29 | استراتيجية PDF ثنائية: Text + OCR fallback || DEC-004 | 2026-04-29 | فصل LLM عن الحسابات التحديدية || DEC-005 | 2026-04-29 | بدءاً من Output Template المُقدم || DEC-006 | 2026-04-29 | تقييم مخصص بـ rapidfuzz || DEC-007 | 2026-04-29 | عدم استخدام Expected Output أثناء الاستخراج || DEC-008 | 2026-04-29 | معالجة 3 Sample أولاً ثم 3-5 Challenge || DEC-011 | 2026-04-30 | بناء React + FastAPI GUI || DEC-012 | 2026-04-30 | تكامل كامل مع Tesseract OCR || DEC-013 | 2026-04-30 | Docker Compose containerization || DEC-014 | 2026-04-30 | HTTPS بـ Caddy + Let's Encrypt || DEC-015 | 2026-04-30 | السجل الديناميكي للمشاريع (لا hardcoded scanning) || DEC-016 | 2026-04-30 | تحسين TAKEOFF-28 بنسبة 88.4% || DEC-017 | 2026-04-30 | بناء HybridExtractor (LLM + Vision) |---## 5. الدروس المستفادة (Lessons Learned)| الدرس | التاريخ | الفئة | التأثير ||-------|---------|-------|---------|| L-001 | 2026-04-29 | عملية | فصل Gold Output عن AI Inputs إلزامي || L-002 | 2026-04-29 | تقني | Windows path length (~260 chars) || L-003 | 2026-04-29 | مجال | مفاهيم Takeoff: Trade, Scope, Line Item, UOM || L-004 | 2026-04-30 | تقني | OCR يحتاج Preprocessing (grayscale, contrast, threshold) || L-005 | 2026-04-30 | تقني | OCR fallback داخل PDFExtractor أنظف || L-006 | 2026-04-30 | تقني | Docker bind mounts: bind as file لا directory || L-007 | 2026-04-30 | تقني | FastAPI route ordering: static قبل dynamic || L-008 | 2026-04-30 | عملية | السجل الديناميكي أفضل من hardcoded scanning || L-009 | 2026-04-30 | مجال | Text-only extraction ceiling ~89% (الـ 11% graphics-only) || L-010 | 2026-04-30 | تقني | تكرار البنود للـ variants يحسن Match Rate || L-011 | 2026-04-30 | تقني | Programmatic filtering > LLM filtering || L-012 | 2026-04-30 | تقني | Finish legend filtering يقلل Extras |---## 6. المخرجات والملفات### 6.1 الملفات التقنية| المجلد/الملف | الوصف | LOC/الحجم ||--------------|-------|-----------|| src/ingestion/ | استخراج PDF + OCR + Classification | ~3,000 LOC || src/extraction/ | LLM + Vision + Rule-Based | ~5,000 LOC || src/evaluation/ | المقارنة والتقييم | ~1,500 LOC || src/output/ | توليد JSON | ~500 LOC || api/ | FastAPI backend | ~2,000 LOC || frontend/src/ | React GUI | ~3,000 LOC || tests/ | 29 اختبار OCR | ~500 LOC || المجموع | | ~12,000+ LOC |### 6.2 المخرجات المُنتجة
Yasser
الأوامر الأساسية:# تشغيل المشروعdocker compose up -d# تشغيل project مع evaluationsource venv/bin/activatepython run.py --project-id TAKEOFF-28 \ --input-dir "client_files/01_Sample_Projects_With_Expected_Output/TAKEOFF-28 - Maryland Vision Institute/Project Files" \ --evaluate \ --expected-dir "client_files/01_Sample_Projects_With_Expected_Output/TAKEOFF-28 - Maryland Vision Institute/Expected Manual Output"# تشغيل challenge projectpython run.py --project-id TAKEOFF-36 \ --input-dir "client_files/02_Challenge_Projects_Project_Files_Only/TAKEOFF-36 - Gucci Perm - Cherry Creek Shopping Center/Project Files/2. Drawings"
Yasser
الملف اضيف واترفع على GitHub. الريبو دلوقتي نظيف وخفيف.
Yasser
https://github.com/yasser-saker/assignment1/commit/d0e26143e3351b5ac1c07b125568d483de3d6002
Yasser
https://github.com/yasser-saker/assignment1
المحادثة الكاملة - 01.05.2026
ياسر
1. StructureClassifier (محلي): يكتشف الجداول والمواصفات والرسومات2. LLMExtractor (GPT-4o): يُرسل Prompts مخصصة حسب نوع المحتوى3. VisionExtractor (GPT-4o Vision): يحلل الرسومات الممسوحة صورياً4. Smart Deduplication: يُزيل التكرار ويوحّد الأسماءنتائج التحسين:- TAKEOFF-50: من 4 بنود → 22 بند (5.5x تحسن)- TAKEOFF-36: من 0 → 48 بند- TAKEOFF-31: من 0 → 3 بنود### 3.3 نظام OCR متكامل- 29 اختبار ناجح لنظام OCR- خط معالجة كامل للصور (Grayscale → Contrast → Sharpen → Denoise → Threshold → Deskew)- تكامل تلقائي مع PDFExtractor (OCR fallback للصفحات الممسوحة)- دعم PSM/OEM modes قابلة للتكوين### 3.4 واجهة مستخدم رسومية (GUI)5 صفحات كاملة:- Dashboard: إحصائيات المشاريع، حالة API، سجل المهام، إدارة البيانات- Projects: إدارة المشاريع، إضافة مجلدات مخصصة، إخفاء/استعادة- Pipeline: تشغيل الاستخراج مع تتبع مباشر للتقدم والسجلات- Results: عرض النتائج، تصفية حسب التجارة، تقارير التقييم- Settings: إعدادات LLM، OCR، Pipeline، Evaluation، Output### 3.5 نشر الإنتاج (Production Deployment)- ✅ Docker Compose متكامل (Backend + Frontend + Nginx)- ✅ HTTPS على https://assign.jobotai.site- ✅ Let's Encrypt SSL تلقائي- ✅ Caddy reverse proxy- ✅ Healthchecks للخدمات### 3.6 السجل الديناميكي للمشاريع- لا يوجد مسح تلقائي hardcoded- المستخدم يُضيف المجلدات يدوياً عبر POST /projects/from-folder- السجل يُحفظ في registered_projects.json- إخفاء/استعادة المشاريع مع الحفاظ على الملفات المصدرية---## 4. سجل القرارات (Decision Log)| القرار | التاريخ | الملخص ||--------|---------|--------|| DEC-001 | 2026-04-29 | إنشاء .kimi/ مع 7 ملفات ذاكرة || DEC-002 | 2026-04-29 | اختيار Python 3.12 || DEC-003 | 2026-04-29 | استراتيجية PDF ثنائية: Text + OCR fallback || DEC-004 | 2026-04-29 | فصل LLM عن الحسابات التحديدية || DEC-005 | 2026-04-29 | بدءاً من Output Template المُقدم || DEC-006 | 2026-04-29 | تقييم مخصص بـ rapidfuzz || DEC-007 | 2026-04-29 | عدم استخدام Expected Output أثناء الاستخراج || DEC-008 | 2026-04-29 | معالجة 3 Sample أولاً ثم 3-5 Challenge || DEC-011 | 2026-04-30 | بناء React + FastAPI GUI || DEC-012 | 2026-04-30 | تكامل كامل مع Tesseract OCR || DEC-013 | 2026-04-30 | Docker Compose containerization || DEC-014 | 2026-04-30 | HTTPS بـ Caddy + Let's Encrypt || DEC-015 | 2026-04-30 | السجل الديناميكي للمشاريع (لا hardcoded scanning) || DEC-016 | 2026-04-30 | تحسين TAKEOFF-28 بنسبة 88.4% || DEC-017 | 2026-04-30 | بناء HybridExtractor (LLM + Vision) |---## 5. الدروس المستفادة (Lessons Learned)| الدرس | التاريخ | الفئة | التأثير ||-------|---------|-------|---------|| L-001 | 2026-04-29 | عملية | فصل Gold Output عن AI Inputs إلزامي || L-002 | 2026-04-29 | تقني | Windows path length (~260 chars) || L-003 | 2026-04-29 | مجال | مفاهيم Takeoff: Trade, Scope, Line Item, UOM || L-004 | 2026-04-30 | تقني | OCR يحتاج Preprocessing (grayscale, contrast, threshold) || L-005 | 2026-04-30 | تقني | OCR fallback داخل PDFExtractor أنظف || L-006 | 2026-04-30 | تقني | Docker bind mounts: bind as file لا directory || L-007 | 2026-04-30 | تقني | FastAPI route ordering: static قبل dynamic || L-008 | 2026-04-30 | عملية | السجل الديناميكي أفضل من hardcoded scanning || L-009 | 2026-04-30 | مجال | Text-only extraction ceiling ~89% (الـ 11% graphics-only) || L-010 | 2026-04-30 | تقني | تكرار البنود للـ variants يحسن Match Rate || L-011 | 2026-04-30 | تقني | Programmatic filtering > LLM filtering || L-012 | 2026-04-30 | تقني | Finish legend filtering يقلل Extras |---## 6. المخرجات والملفات### 6.1 الملفات التقنية| المجلد/الملف | الوصف | LOC/الحجم ||--------------|-------|-----------|| src/ingestion/ | استخراج PDF + OCR + Classification | ~3,000 LOC || src/extraction/ | LLM + Vision + Rule-Based | ~5,000 LOC || src/evaluation/ | المقارنة والتقييم | ~1,500 LOC || src/output/ | توليد JSON | ~500 LOC || api/ | FastAPI backend | ~2,000 LOC || frontend/src/ | React GUI | ~3,000 LOC || tests/ | 29 اختبار OCR | ~500 LOC || المجموع | | ~12,000+ LOC |### 6.2 المخرجات المُنتجة
01.05.2026 13:36
ياسر
الأوامر الأساسية:# تشغيل المشروعdocker compose up -d# تشغيل project مع evaluationsource venv/bin/activatepython run.py --project-id TAKEOFF-28 \ --input-dir "client_files/01_Sample_Projects_With_Expected_Output/TAKEOFF-28 - Maryland Vision Institute/Project Files" \ --evaluate \ --expected-dir "client_files/01_Sample_Projects_With_Expected_Output/TAKEOFF-28 - Maryland Vision Institute/Expected Manual Output"# تشغيل challenge projectpython run.py --project-id TAKEOFF-36 \ --input-dir "client_files/02_Challenge_Projects_Project_Files_Only/TAKEOFF-36 - Gucci Perm - Cherry Creek Shopping Center/Project Files/2. Drawings"
01.05.2026 13:40
ياسر
الملف اضيف واترفع على GitHub. الريبو دلوقتي نظيف وخفيف.
01.05.2026 13:46
ياسر
https://github.com/yasser-saker/assignment1/commit/d0e26143e3351b5ac1c07b125568d483de3d6002
01.05.2026 14:06
M
Hi,The repo is accessible through : https://github.com/yasser-saker/assignment1 with full GUI, Docker, and HTTPSThe full technical breakdown can be accessed here: https://github.com/yasser-saker/assignment1/tree/main/.kimiLet me know if you need anything else.
01.05.2026 14:20
ياسر
https://github.com/yasser-saker/assignment1
01.05.2026 14:21
M
مليانة ال api تاعتنا
01.05.2026 14:29
ياسر
هاد github
01.05.2026 14:29
M
عمل ديسيبل لل api
01.05.2026 14:29
ياسر
مفاتيح API مكشوفة
01.05.2026 14:44
M
I'll examine both links thoroughly — the assignment requirements and the GitHub submission — to give you a comprehensive assessment. Let me start by opening both.Now let me explore the GitHub repository to see all the submitted work.Let me now dive into the key deliverable files to deeply understand the submission.Now I have a thorough understanding of both the requirements and the submission. Let me compile a comprehensive assessment.Here's my comprehensive assessment of the submission against the Notion assignment requirements:---## Final Score: 7 / 10---### What Was Done Well (Strengths)1. System Architecture — Strong ✅- Clean 4-stage pipeline: Ingestion → Extraction → Output → Evaluation- Multiple extraction strategies (rule-based, LLM GPT-4o/mini, hybrid, context fusion)- Smart cost-control: 30K-character chunking reduces API calls by ~60%- Docker Compose setup with FastAPI backend + React frontend- Well-organized modular codebase (src/evaluation/, src/extraction/, src/ingestion/)2. Evaluation Engine — Impressive ✅- 333-line evaluator.py with 25+ equipment tag pattern matching- Critical keyword validation (e.g., "occupancy sensor" must contain "occupancy")- Fuzzy matching via rapidfuzz with spelling normalization- Quantity difference tracking with percentage deviation3. Transparency & Honesty — Excellent ✅- Coverage metrics openly reported: 64.5%, 45.5%, 57.1% across sample projects- Clear documentation of limitations (OCR ceiling, scanned floor plan failures)- Explicitly states what's deterministic vs AI reasoning — exactly what assessors want4. Dynamic Extraction — Exactly What Was Asked ✅- No hardcoded project-specific items (removed per commit history)- Generic pattern matching for finish codes, equipment tags, trade classification- Architecture supports any project type without code changes5. Documentation Complete ✅- CANDIDATE_REVIEW_PACKET.md — all required sections covered- docs/ARCHITECTURE.md — system design with pipeline diagrams- docs/30_DAY_PLAN.md — concrete weekly plan with success metrics- README.md — clear run instructions with tools/models disclosed---### Where It Falls Short (Weaknesses)| Gap | Severity | Details ||-----|----------|---------|| Only 2 challenge projects processed | 🔴 Critical | Minimum asked was 3-5; only TAKEOFF-31 and TAKEOFF-36 done || Challenge output files missing | 🔴 Critical | Only 1 output file in outputs/ (TAKEOFF-50 is a *sample*, not challenge) || Loom walkthrough not in repo | 🟡 Significant | Required deliverable; may have been submitted separately || Human correction loop = architecture-only | 🟡 Significant | Described in docs but no working implementation or reviewer UI || No database persistence | 🟡 Moderate | Uses JSON files instead of PostgreSQL; 30-day plan mentions adding it later || Quantity accuracy is low | 🟡 Moderate | Many items have null quantities; LLM reads general text but doesn't integrate drawing dimensions + finish schedules || Scanned drawing support fails | 🟡 Moderate | Tesseract misses 30-40% of floor plan text; GPT-4o Vision tested but didn't work || Test coverage minimal | 🟢 Minor | Only 3 test files, all for ingestion layer; no tests for evaluation or API || Arabic documentation mix | 🟢 Minor | PROJECT_REPORT.md and IMPROVEMENTS.md in Arabic — creates friction for English reviewers |---### Deliverables Scorecard| Deliverable | Status | Grade ||-------------|--------|-------|| Architecture Plan | ✅ docs/ARCHITECTURE.md | B+ || Working Prototype | ✅ Dockerized, runnable | C+ || README | ✅ Clear & complete | B+ || Loom Walkthrough | ❌ Not in repo | F || 30-Day Plan | ✅ docs/30_DAY_PLAN.md | B+ || Candidate Review Packet | ✅ Comprehensive | A- || Evaluation/Scoring | ✅ Working evaluator | B || 3-5 Challenge Projects | ⚠️ Only 2 done | C- || Structured Outputs | ✅ Pydantic models | B || Data Discipline | ✅ hidden_projects.json | B+ |---### The Bottom Line
01.05.2026 14:52
← العودة إلى الرئيسية