{"id":19431951,"url":"https://github.com/naskio/daar_project_3","last_synced_at":"2026-02-18T05:01:36.371Z","repository":{"id":81209420,"uuid":"319084555","full_name":"naskio/DAAR_project_3","owner":"naskio","description":"Project 03 (CV Catcher): indexing CVs (PDF, Word, PNG and JPEG) in ElasticSearch.","archived":false,"fork":false,"pushed_at":"2020-12-07T11:27:47.000Z","size":2367,"stargazers_count":3,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-10-11T02:36:06.524Z","etag":null,"topics":["cv","django","django-rest-framework","elasticsearch"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/naskio.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-12-06T16:57:52.000Z","updated_at":"2025-07-19T17:34:25.000Z","dependencies_parsed_at":null,"dependency_job_id":"ba789ad1-d793-4695-870c-7505f0359f9f","html_url":"https://github.com/naskio/DAAR_project_3","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/naskio/DAAR_project_3","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/naskio%2FDAAR_project_3","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/naskio%2FDAAR_project_3/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/naskio%2FDAAR_project_3/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/naskio%2FDAAR_project_3/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/naskio","download_url":"https://codeload.github.com/naskio/DAAR_project_3/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/naskio%2FDAAR_project_3/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29569853,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-18T04:18:28.490Z","status":"ssl_error","status_checked_at":"2026-02-18T04:13:49.018Z","response_time":162,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cv","django","django-rest-framework","elasticsearch"],"created_at":"2024-11-10T14:33:21.697Z","updated_at":"2026-02-18T05:01:36.279Z","avatar_url":"https://github.com/naskio.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# DAAR Project 3: CV Catcher\n\n![Alt text](django_app/static/logo/logo_text.png?raw=true \"CV Catcher\")\n\nIndexing CVs (PDF, Word, PNG and JPEG) in Elasticsearch and enabling search feature.\n\n* [Introduction](#Introduction)\n\n    * [Features](#Features)\n    * [Quick Links](#Quick-Links)\n    * [Search Queries](#Quick-Links)\n        * [Examples](#Examples)\n    * [DataSet](#dataset)\n\n* [Getting started](#getting-started) (Instructions to build and run the project)\n    * [Requirements](#requirements)\n    * [Configure](#configure)\n    * [build](#build)\n    * [Run](#run)\n    * [Test](#test)\n* [Elasticsearch](#elasticsearch)\n    * [Synchronization with the Database](#synchronization-with-the-database)\n    * [Re-building the index](#re-building-the-index)\n    * [Related Code](#related-code)\n* [User Interfaces](#user-interfaces)\n* [About](#about)\n\n## Introduction\n\nCV Catcher is a platform that enable people to share their CVs with Companies, and help companies to find quickly the\nperfect candidate by enabling search feature over millions of CVs in different formats (PDF, Word, PNG, JPEG, ...).\n\n### Features\n\n- Admin Panel to manage CVs.\n- Index and Search CVs (formats: PDF, Docx, PNG, JPEG, ...) throw the Admin Panel.\n- UI for candidates to upload their CV without log-in.\n- REST APIs that can be used with other clients.\n\n### Quick Links\n\nThese are a shortcuts to help you access the Application quickly.\n\n- [Admin Panel](http://localhost:8000/admin/cv/resume/) (username: admin, password: admin)\n- [Upload CV Page](http://localhost:8000/)\n- [REST APIs (Swagger Docs)](http://localhost:8000/api/swagger/)\n- [REST APIs](http://localhost:8000/api/)\n\n### Search Queries\n\nWe can perform a search with a list of keywords, and we can use the operators ```AND``` and ```OR```:\n\n- to use ```AND``` we separate the keywords by a comma ```,```.\n- to use ```OR``` we separate the keywords by a whitespace ``` ```.\n\n#### Examples\n\n- Example 00 (Simple Example):\n  Candidates who speak Arabic\n  ```\n  Arabic\n  ```\n\n- Example 01 (```AND``` Operator):\n  Candidates who code in JAVA AND Speak Arabic\n  ```\n  JAVA, Arabic\n  ```\n\n- Example 02 (```OR``` Operator):\n  Candidates who code in JAVA OR C++\n  ```\n  JAVA C++\n  ```\n- Example 03 (```AND``` and ```OR```):\n  Candidates who code in JAVA AND speak Arabic or English\n  ```\n  JAVA, Arabic English\n  ```\n\n### DataSet\n\nThe pre-loaded dataset contains 13 CVs with different formats (PDF, Word, PNG, JPG).\n\n## Getting started\n\nThese instructions will get you a copy of the project up and running on your local machine or in a production server.\n(Start by )\n\n### Requirements\n\nTo make the system independent of the environment and make it easier for you to run it, we are using Docker.\n\n1. [Docker or Docker Desktop](https://www.docker.com) (Docker engine 19+ with Docker compose).\n\n### Configure\n\nAfter cloning the repository, we start by configuring the environment:\n\n1. Rename ```.env_example``` to ```.env``` or create an ```.env``` file in the root folder (same folder as ```docker-compose.yaml``` file) and copy the content of ```.env_example``` to ```.env``` file.\n1. Optionally Customize the variables according to your preferences.\n\n### Build\n\n1. We start by building the images using the command\n    ```shell script\n    docker-compose build\n    ```\n1. Run the project\n    ```shell script\n    docker-compose up\n    ```\n1. Open a new tab in the terminal and run the migrations using the command\n    ```shell script\n    docker-compose run web python manage.py migrate\n    ```\n1. then create the index in ElasticSearch using the command\n    ```shell script\n    yes y | docker-compose run web python manage.py search_index --rebuild\n    ```\n1. Load the dataset (for the demo)\n    ```shell script\n    cat ./django_app/fixtures/backup.json | docker-compose run web python manage.py loaddata --format=json -\n    ```\n\n### Run\n\n- To run the system\n    ```shell script\n    docker-compose up\n    ```\n- To shut down the system (from another tab)\n    ```shell script\n    docker-compose down\n    ```\n\n### Test\n\nRun the system ```docker-compose up``` then\n\n- To run the Unit Test\n    ```shell script\n    docker-compose run web python manage.py test apps\n    ```\n\n- To run the Unit Test with Coverage\n    ```shell script\n    docker-compose run web coverage run --source='./' manage.py test apps\n    docker-compose run web coverage report\n    ```\n\n## Docker Architecture\n\nThe application consists of 3 containers:\n\n1. *db* where the PostgreSQL instance is running.\n1. *elasticsearch* where the ElasticSearch instance is running.\n1. *web* where the backend server is running.\n\n\u003e ElasticSearch will persist data on ```./elasticsearch_data/``` folder (mounted-host volume).\n\n\u003e db (postgreSQL) will persist data on ```./postgres_data/``` folder (mounted-host volume).\n\n## Elasticsearch\n\nTo use ElasticSearch with Django we are using the\npackage [https://github.com/django-es/django-elasticsearch-dsl](django-elasticsearch-dsl).\n\n### Synchronization with the Database\n\nTo synchronize the PostgreSQL database with ElasticSearch, we are using Django signals\n(events sent every time we Create, Update, Delete a model instance), and according to the received event we sync\nElasticSearch.\n\nOnce the event received we parse the CV file (PDF, Word or Image) to text, then we index it in ElasticSearch.\n\n### Re-building the index\n\nWe provide also a command that will delete the index and re-create it, then re-build it for the whole database (all\nexisting CVs).\n\n```bash\nyes y | docker-compose run web python manage.py search_index --rebuild\n```\n\n### Related Code\n\nCode related to ElasticSearch can be found at:\n\n- Configuration ```./django_app/CV_CATCHER/settings.py```\n- Indexing ```./django_app/apps/cv/documents.py```\n- Search ```./django_app/apps/cv/admin.py``` and ```./django_app/apps/cv/views.py```\n\n## User Interfaces\n\nWe can upload the CV throw the index page, or throw the Admin Panel\n\n![Alt text](UIs/upload_cv.png?raw=true \"Upload CV\")\n\n![Alt text](UIs/admin_upload_cv.png?raw=true \"Admin Upload CV\")\n\n![Alt text](UIs/search.png?raw=true \"Search\")\n\n![Alt text](UIs/search_res.png?raw=true \"Search\")\n\n## About\nBinome: Mehdi Nassim KHODJA, Qiwei XIAN\n\nDeveloped by students at Sorbonne University, just for learning purposes (part of DAAR lectures). Using Python with\nDjango, ElasticSearch and Docker.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnaskio%2Fdaar_project_3","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnaskio%2Fdaar_project_3","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnaskio%2Fdaar_project_3/lists"}