File size: 1,542 Bytes
29232e0
 
 
8cf01e0
 
29232e0
 
 
 
 
 
60848a7
29232e0
8cf01e0
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
---
title: PDFSummarization
emoji: 
colorFrom: purple
colorTo: green
sdk: gradio
sdk_version: 4.8.0
app_file: app.py
pinned: false
license: mit
---
# PDF Summarization & Audio Tool

## Description

This Gradio app summarizes the abstract of a PDF in one sentence and generates an audio file. It uses the "ArtifactAI/led_large_16384_arxiv_summarization" model to generate summaries.

## How to Use

1. **Upload PDF:** Click on the "Upload PDF" button to upload a PDF file. Ensure that the PDF contains an abstract or introduction section.

2. **View Summary:** The app will display a one-sentence summary of the abstract.

3. **Listen to Summary:** Click on the "Listen" button to hear an audio summary of the abstract.

## Examples

To test the app, you can use the provided example PDF's in the `examples` directory. Follow these steps:

1. Upload one of the example PDFs.
2. Check the generated summary and listen to the audio.

### Example PDFs

- [Example 1](https://drive.google.com/file/d/159MEhJuP4UpSCTYTn2ACLqNfAhLVVePx/view?usp=sharing)
- [Example 2](https://drive.google.com/file/d/1_q7mf2PDVTGRKCDvmcvoBHsV6z1-5Tv2/view?usp=sharing)

## Notes

- Ensure that the uploaded PDF contains an abstract or introduction section for accurate results.
- For the best experience, use the provided examples first to understand how the app works.

## Development

To run the app locally:

```bash
pip install -r requirements.txt
python app.py

Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference