GithubHelp home page GithubHelp logo

rachitavya / pdf-parser Goto Github PK

View Code? Open in Web Editor NEW

This project forked from samagrax-labs/pdf-parser

0.0 0.0 0.0 172.94 MB

A toolkit to parse PDFs for RAGs.

Jupyter Notebook 99.84% Python 0.16%

pdf-parser's Introduction

PDF-Parser

A toolkit to parse PDFs for RAGs.

Setup

Clone the repo and cd to project root.

Environment

  1. Create and activate venv. Ex:
python -m venv venv
.\venv\Scripts\activate
  1. This project uses poetry.
pip install poetry
poetry install

Parser

Context:

  1. The process has two steps: PDF -> MD -> CSV
  2. PDF and MD files are in input/{language} folder
  3. PDF -> MD is done by external repo
  4. The repo contains code for MD -> CSV conversion.

Step 1: python src/markdown_parser.py This will convert all the md files (from input/md/ folder) to csv files (saved in output/ folder). Step 2: python src/csv_preprocessing.py This performs further processing on the csv files in output/ folder and saves the output there only.

API Under development

The idea is to create a single function for both the above steps and after combining them wiht PDF -> MD conversion, we can create a celery function for the API.

Setup steps would be:

Step 1:

docker run -d -p 6379:6379 --name my-redis redis

Step 2:

celery -A worker worker --loglevel=info

Step 1:

uvicorn main:app --reload

pdf-parser's People

Contributors

rachitavya avatar chakshugautam avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.