Skip to content

An API that provides paper summarization services in both English and German.

License

Notifications You must be signed in to change notification settings

vadis-project/vadis_summarization_api

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Issues MIT License


VADIS Summarization API

An API that provides text summarization services in both English and German.

Report Bug · Request Feature

Table of Contents
  1. About The Project
  2. Getting Started
  3. Usage
  4. Roadmap
  5. License
  6. Contact
  7. Citation

About The Project

vadis_summarization_api

VADIS Summarization API is an easy-to-use API that provides automatic text summarization services in both English and German. It processes individual documents, detects their language, and summarizes them accordingly. If the input document is in German, it will first translate it to English before summarizing.

  • Input: A text document that can be in either English or German.
  • Output: A summarized version of the input document, available in English (if the input is German, it will be translated first).
  • Noteworthy Feature: The API automatically detects the language of the input text and, if necessary, translates German input into English for summarization.
  • Demo: You can interact with the API by visiting http://127.0.0.1:8000/docs.

For more information on the underlying summarization models and translation mechanisms, check the documentation at VADIS GitHub Repository.

Getting Started

Follow these steps to get a local copy of the VADIS Summarization API up and running on your machine.

Prerequisites

Before you begin, ensure that you have the following installed:

Installation

  1. Clone the repository:
    git clone [email protected]:vadis-project/vadis_summarization_api.git
  2. Navigate into the project directory:
    cd vadis_summarization_api
  3. Install the project dependencies using Poetry:
    poetry install

Usage

Configure

The API loads its configuration from a .env file. You can start by copying the sample configuration file:

cp ./sample.env ./.env

You can customize the following settings:

  • AUTH_KEY: Set this to any string. You will need this key when accessing the API.
  • LANGUAGE: Set this to either en (English) or de (German). This determines the language of the summaries. If you choose de, the API will summarize in English, even if the input is in German.

Run the API

Start the API within the virtual environment created by Poetry:

poetry run uvicorn vadis_summarization_api.main:app

This will start the API, and it may take some time for the first run as models need to be downloaded.

Try

Once the API is running, you can access the automatically generated documentation and interact with the API directly at http://127.0.0.1:8000/docs.

You can call it to generate summaries. Following is one example which uses curl command.

curl -X 'POST' \
  'http://127.0.0.1:8000/summarize' \
  -H 'accept: application/json' \
  -H 'auth-key: YOUR-AUTH-KEY' \
  -H 'Content-Type: application/json' \
  -d '{
  "documents": [
    "TEXT OF THE PAPER TO BE SUMMARIZED",
    "YOU CAN SUMMARIZE MORE THAN ONE PAPER IN ONE API CALL"
  ]
}'

The /summarize endpoint detects the language of the input document. If the document is in German, it will first translate the text to English before summarizing it.

Roadmap

  • Improve summarization models for better accuracy

License

Distributed under the MIT License. See LICENSE for more information.

Contact

For any questions or inquiries, please feel free to raise an issue in this repository or contact me at

Sotaro Takeshita - [email protected]

About

An API that provides paper summarization services in both English and German.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages