No description
Find a file
hailt 1cb1543260 fix: transfer CD bundle over ssh pipes instead of scp
sftp/scp bi chan tren duong bastion (Connection closed) trong khi exec channel chay tot. Day compose bang tar pipe, image stream thang vao docker load, bo file tarball trung gian.
2026-11-02 11:32:20 +07:00
.github/workflows fix: transfer CD bundle over ssh pipes instead of scp 2026-11-02 11:32:20 +07:00
img-plan feat: scaffold complete danable frontend architecture with all pages, layouts, stores, and 3 annotator modes 2026-10-30 00:33:07 +07:00
public feat: publish danable frontend updates 2026-10-31 18:09:52 +07:00
src feat: publish danable frontend updates 2026-10-31 18:09:52 +07:00
.env.example feat: scaffold complete danable frontend architecture with all pages, layouts, stores, and 3 annotator modes 2026-10-30 00:33:07 +07:00
.gitignore feat: publish danable frontend updates 2026-10-31 18:09:52 +07:00
docker-compose.yml fix: transfer CD bundle over ssh pipes instead of scp 2026-11-02 11:32:20 +07:00
Dockerfile feat: push-based CD via bastion (build image, scp, compose up) 2026-11-02 11:02:35 +07:00
index.html feat: publish danable frontend updates 2026-10-31 18:09:52 +07:00
package-lock.json feat: scaffold complete danable frontend architecture with all pages, layouts, stores, and 3 annotator modes 2026-10-30 00:33:07 +07:00
package.json feat: scaffold complete danable frontend architecture with all pages, layouts, stores, and 3 annotator modes 2026-10-30 00:33:07 +07:00
postcss.config.js feat: scaffold complete danable frontend architecture with all pages, layouts, stores, and 3 annotator modes 2026-10-30 00:33:07 +07:00
README.md feat: scaffold complete danable frontend architecture with all pages, layouts, stores, and 3 annotator modes 2026-10-30 00:33:07 +07:00
tailwind.config.js feat: publish danable frontend updates 2026-10-31 18:09:52 +07:00
tsconfig.json feat: scaffold complete danable frontend architecture with all pages, layouts, stores, and 3 annotator modes 2026-10-30 00:33:07 +07:00
vite.config.ts feat: publish danable frontend updates 2026-10-31 18:09:52 +07:00

danable · Nền tảng dữ liệu gán nhãn cho AI (Frontend)

Dự án frontend cho nền tảng gán nhãn dữ liệu hình ảnh danable (hỗ trợ 3 bài toán: Classification, Object Detection, và Segmentation), được thiết kế theo kiến trúc phân lớp rõ ràng để sẵn sàng tích hợp với Backend / Orchestrator.


1. Khởi chạy dự án

# Cài đặt dependencies
npm install

# Chạy môi trường phát triển (http://localhost:3000)
npm run dev

# Kiểm tra TypeScript & build production
npm run build

2. Cấu trúc thư mục

  • public/ — Tài nguyên tĩnh (favicon.svg, ảnh minh họa...)
  • src/app/ — Cấu hình cấp ứng dụng (router.tsx, providers.tsx, constants.ts)
  • src/layouts/ — 3 Layout chính (AuthLayout, DashboardLayout, AnnotatorLayout) cùng Sidebar & Header
  • src/pages/ — Mỗi trang được tách thành folder riêng kèm components/ nội bộ:
    • auth/ — Đăng nhập (/login), Quên mật khẩu (/forgot-password)
    • projects/ — Danh sách dự án (/projects), Modal tạo dự án, Tổng quan dự án (/projects/:id)
    • users/ — Quản lý người dùng & phân quyền (/users)
    • annotator/ — Giao diện gán nhãn 3-panel (/projects/:id/annotate) tự động chuyển đổi theo bài toán (Classification, Object Detection, Segmentation)
  • src/components/ — Thư viện UI dùng chung (ui/, feedback/, data-display/)
  • src/services/ — Tầng giao tiếp API duy nhất (api.ts, projectService.ts, annotationService.ts...)
  • src/stores/ — Quản lý state với Zustand (authStore, projectStore, annotationStore, canvasStore, uiStore)
  • src/hooks/ — Custom hooks tách biệt business logic khỏi giao diện
  • src/types/ — Định nghĩa TypeScript interfaces/types dùng chung
  • src/utils/ — Hàm tiện ích (chuyển đổi tọa độ canvas, xuất LabelMe JSON, xuất mask PNG, định dạng số...)

3. Hướng dẫn nối vào Backend / Orchestrator

  1. Mở file .env và cập nhật địa chỉ API Gateway / Orchestrator:
    VITE_API_URL=https://orchestrator.your-domain.com/api/v1
    VITE_USE_MOCK_DATA=false
    
  2. Toàn bộ HTTP client được cấu hình tập trung tại src/services/api.ts (đã gắn sẵn Bearer Token interceptor).
  3. Các hàm trong src/services/*Service.ts đã định nghĩa đầy đủ chữ ký hàm và kiểu trả về chuẩn theo src/types/.