Skip to content

GangOfThreeWMD/PJN-Backend

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

76 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ClipSum

Project contain 4 module:

  1. PythonModule - contain python code for summarize text
  2. SummarizeAlgorith - Java code use Python algorithm and return summarize text
  3. Scraper - Program for Scrapping news from web
  4. Summarizer - Main program to get news

Instruction installation with Intellij intellij logo:

  1. Install plugin Python plugin install , Python support

  2. Go to "File -> Project Structure -> Project Settings -> Modules"

  3. Click Add symbol "+"

  4. Select New Module

  5. Type Name as PythonModule - ignore warning about dirrectory is not empty

  6. Select Language as Python

  7. Select Inherit global site-packages

  8. Select *Base interpreter" the same as your default Python from console. For check which Python interpreter use as default, run this command from terminal/console:

    python -c "import os, sys; print(os.path.dirname(sys.executable))"

    This instruction print a path of directory where is python executable file.

  9. Set environment to dist-packages (or site-packages) folder. Go to "Run -> Edit Configurations -> select Spring Boot configuration -> Modify options -> in a section Operating system select Environment variables -> In a new textbox provide:

    • For Windows:
      LD_LIBRARY_PATH=C:\Users\<user name>\AppData\Roaming\Python\<python version>\site-packages        
    • For Linux:
      LD_LIBRARY_PATH="/usr/local/lib/python<python version>/dist-packages"

    For display your path to this file, should run this command:

    python -m site

    More info: How do I fix Unsatisfied Link Error: no jep in java.library.path?

  10. Next step you should install all neccessary library for Python script:

    pip install jep
    pip install nltk
    pip install numpy
    pip install networkx
    pip install scipy
  11. Now you can run Spring Boot project

For run project without Intellij:

  1. You should set environment:
export LD_LIBRARY_PATH="/usr/local/lib/python<python version>/dist-packages"$LD_LIBRARY_PATH
  1. install library for Python (step 10 for Intellij instruction)

Status

Project is: finite.

The project was built to test natural language processing methods. The additional purpose of this project was to test the connection between Python code and Java code within one project. This test has been successful, and the project has been completed.

Materials

Documentations:

Releases

No releases published

Packages

No packages published