Skip to content

Team-Glare/CELT2

CELT2.0: Sentiment Analyzer

License: MIT GitHub issues codecov DOI

Build and Publish CELTAPI to Azure Web App Build and Publish Server to Digital Ocean

CELT2_0.mp4

INTRODUCTION

Sentiment analysis is among the most rapidly increasing research areas in computer science. It is usually quite difficult to keep up with all of the development taking place in the area. By analyzing the data provided in different methods, we expect to achieve our goal of accurately predicting a user's sentiment in our project. Although it is still in its early phases of development, this project has the potential for application to a variety of sectors that could be beneficial to society. This report offers users a broad overview of the project, allowing individuals to understand it as open-source software and add improvements. The report also helps developers in comprehending the code and serves as a starting point for the project.

The following technologies were used to complete the development, and it is recommended that the next group of developers who take on this project have these technologies installed and running before proceeding:

  • FrontEnd:
    • HTML
    • CSS
    • Javascript
  • API
    • ASP.NET Core Web API 3.1
    • Nunit and Moq (Test Framework)
  • Server
    • Flask Server & Dockerfile for Containerization
    • Pytest (Test Framework)
  • Model
    • Flair
    • Torch

Although we have used HTML and CSS for the FrontEnd, the users can merge the backend logic with any of the front-end frameworks they wish to use such as React, angularJS, etc.

CELT2.0 Architecture

In our repo, we have separate directories of frontend, API, server, and model.

  • Frontend: If any code is committed into the frontend directory, then the frontend gets published to GitHub pages using the Github actions. Our published frontend URL: https://team-glare.github.io/CELT2/
  • API: If any code is committed into the API directory, then the API gets published to Azure Webapp using the Github actions. Our published API URL: https://celtapi.azurewebsites.net/
  • Model & Server: If any code is committed into the model and server directory, then the model & server gets published to Digital Ocean using the Github actions.

The advantages of CELT2.0 architecture:

  • Easily maintainable.
  • Can be easily swapped out any submodule with a different module.
  • Each sub-module can be tested separately.
  • Each sub-module change can be published separately.

WEBSITE

Capture1

An example of the analysis of a negative sample text:

Capture2

An example of the analysis of a positive sample text:

Capture3

An example of the analysis of an uploaded file: Capture4

Setup

Prerequisites:

Strongly recommended:

  • Environment capable of using a UNIX-based terminal - Ubuntu, WSL/2, etc.

Dependencies:

  • Within the context of the root folder, run setup.sh. This will acquire the requirements from the API, Model, and Server, and download them for you from the appropriate sources.

If the script says "command not found" or something similar, either run chmod +x ./setup.sh. This grants the script execution privileges. Depending on your setup, this may occur for the boot_dockerless files, amongst others. The same command will fix the issue.

Running the Server:

  • Locally:
    • Within the server subdirectory, you can run ./boot_dockerless.sh, which will run Flask for you (after checking all of the require depedencies exist). This will only allow for local connections and testing. The server will be listening on 'http://localhost:8000'
  • Containerized:

Running the API:

  • Locally:
    • Within the API/CELTAPI subdirectory, change ServerBaseURL of the appsettings.json to 'http://localhost:8000'.
    • Then, within the API subdirectory, run the run.sh, then the API will be listening on 'https://localhost:5001'.
    • You can run the API manually as well by moving into the subdirectory API/CELTAPI and run this command dotnet run CELTAPI.csproj

Running the Frontend:

  • Locally:
    • In the main.js file, replace the apiBaseURL with the above API url 'https://localhost:5001'.
    • Open the index.html file to access the main page.

INSPIRATION AND IMPROVEMENTS

Our Sentiment Analyzer is based on work done by a previous group: C.E.L.T: The Sentimental Analyser

The central function of our sentiment analyzer is similar, and the inputs that are supported in Phase 1 are available in the original Sentiment Analyzer.

CELT2.0 offers certain improvements over the original that make it easier to use and develop:

  • Deployed on a server instead of locally
  • Easier install process - central setup script setup.sh
  • Line by line analysis - unfinished but supported by the analyzer

FUTURE SCOPE

View the CELT2.0 Project in the Projects Tab to see issues that need attention.

Core functionality to be added:

  • Video and audio file analysis
  • Sentiment comparison of 2+ inputs
  • Optionally show line by line analysis
  • Create a separate DEV server for code integration.
  • Add integration tests.
  • Implement style and code checkers
  • Allow server/model to analyze larger amounts of data

LICENSE

This project is licensed under the MIT License

How to Contribute?

Please see our CONTRIBUTING.md for instructions on how to contribute to the repo and assist us in improving this analyzer.

VERSION

Initial release version 1.0.0

Team Members

About

No description, website, or topics provided.

Resources

License

Code of conduct

Contributing

Stars

Watchers

Forks

Packages

No packages published

Contributors 5