Coder Social home page Coder Social logo

pdf-qna-mistral-7b's Introduction

Mistral-7B PDF Question Answering Application

This application uses the Mistral-7B model to generate Questions and Answers from PDF documents. Follow these steps to set up and run the application: Screenshot from 2024-08-09 17-20-59

Setup Instructions

1. Clone the Repository

First, clone the repository to your local machine:

git clone https://github.com/Rjaat/Pdf-QnA-Mistral-7b.git
cd Pdf-QnA-Mistral-7b

2. Create a Virtual Environment

Create a virtual environment to isolate your project’s dependencies:

python3 -m venv venv

Activate the virtual environment:

source venv/bin/activate

3. Install Dependencies

Install the required dependencies from requirements.txt:

pip3 install -r requirements.txt

Additionally, ensure you have any other necessary libraries installed. If not included in requirements.txt, you may need to install them manually

4. Configure Hugging Face Token

Replace the Hugging Face token in app.py with your own token. Open app.py and find the section where the token is used. Replace it with your token:

# Example placeholder
login(token="PLACE_YOUR_TOKEN_HERE")     line No. 27 in app.py

5. Run the Application

Start the application by running app.py:

python3 app.py

6. Access the Application

Open your web browser and navigate to:

http://0.0.0.0:8000/

You should see the application’s user interface, where you can upload PDF files and ask questions.

Troubleshooting

  • Dependency Issues: Ensure all dependencies listed in requirements.txt are installed. If you encounter errors, try reinstalling them or checking compatibility.
  • Token Errors: Make sure the Hugging Face token is valid and correctly placed in app.py.
  • Port Issues: If 8000 is already in use, you might need to specify a different port in app.py.

pdf-qna-mistral-7b's People

Contributors

rjaat avatar

Watchers

 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.