Name | Profile |
---|---|
Phạm Khánh Trình | @phkhanhtrinh23 |
Nguyễn Bảo Tín | @nbtin |
Yang Tuấn Anh | @YangTuanAnh |
Nguyễn Hoàng Ngọc Hà | @ngochafromdn |
Nguyễn Minh Lý | @lynguyenminh |
- 1. Table of Contents
- 2. About The Project
- 3. Technical Overview
- 4. Repo Structure
- 5. How to Install
- 6. Usage
- 7 References
Translation with Layout Recovery is a cutting-edge approach in the field of natural language processing that goes beyond traditional machine translation methods. While conventional translation models focus solely on converting text from one language to another, 5tasy takes into account the visual layout and formatting of the text. This approach aims to preserve not only the linguistic content but also the spatial arrangement, font styles, and other visual elements present in the source text. Some detailed information can be found in this slide and our YouTube presentation.
- Frontend: NextJS, TailwindCSS, NodeJS, Yarn.
- Backend: Django REST Framework.
- Database: PostgreSQL.
- Storage: Firebase Cloud Storage.
- Deployment: Docker (Docker-compose).
- AI Core:
- NMT: envit5-translation.
- Layout Recovery: MaskRCNN.
- OCR: EasyOCR.
- Spelling Correction (Japanese): JGEC
.
├── Backend
│ ├── account
│ ├── services
│ └── translation
├── Frontend
│ ├── app
│ │ ├── api
│ │ ├── components
│ │ ├── history
│ │ │ └── api
│ │ ├── login
│ │ │ └── api
│ │ ├── profile
│ │ │ └── api
│ │ └── register
│ │ └── api
│ └── public
└── Model
└── utils
└── main.py
To install and run the 5tasy web app, please follow the steps below:
-
Ensure that Docker is installed on your system. You can download and install Docker from the official website: Docker Engine for Ubuntu or Docker Desktop.
-
Clone this repository to your local machine using the following command:
git clone https://github.com/phkhanhtrinh23/translation_layoutrecovery.git
-
Navigate to the project directory:
cd translation_layoutrecovery
Important: Then, put the necessary environment files (.env) in this folder.
-
Build the Docker image and run the container using the following command:
docker compose up --build
-
Wait for the installation process to complete. Once the downloading is done, the web app will be ready to use.
-
To stop the web app, press
Ctrl + C
in the terminal and run the following command:docker compose down
To use the web app, follow the steps below:
-
Open your web browser and navigate to http://localhost:3000.
-
You first need to register the account and sign in to use the web functions.
-
In the web app, you can browse and upload an English PDF file using the provided interface.
-
Click to choose the target language and Hit the Translate button to start the translation process.
-
The model will then process your file and return the translated PDF file with the same layout as the original one. Hit the
Translated
linklabel or open theHistory
bar to view the result. Here you can open to view and download your files. -
You can also search for your files in the
History
bar by entering the keywords in the search box.
- MaskRCNN - phamquiluan - PubLayNet
- EasyOCR - JadedAI - jaded.ai
- envit5-translation - Chinh Ngo, Trieu H. Trinh, Long Phan, Hieu Tran, Tai Dang, Hieu Nguyen, Minh Nguyen, Minh-Thang Luong - huggingface.co.
- opus-mt-en-jap - Helsinki-NLP - huggingface.co.
- GECToR - Kostiantyn Omelianchuk, Vitaliy Atrasevych, Artem Chernodub, Oleksandr Skurzhanskyi - aclanthology.org
- Guides on using Docker for Python application - Docker docs.
- Install Docker Engine on Ubuntu - Docker docs.
Contributions are what make GitHub such an amazing place to be learn, inspire, and create. Any contributions you make are greatly appreciated.
- Fork the project
- Create your Contribute branch:
git checkout -b contribute/Contribute
- Commit your changes:
git commit -m 'add your messages'
- Push to the branch:
git push origin contribute/Contribute
- Open a pull request