Giter Club home page Giter Club logo

neutbias's Introduction

Demo for neutralizing bias with NLP

This website demos the NLP model created from my artificial intelligence project class.

The model is trained on Stanford's Wikipedia Neutrality Corpus.

Find out more about the project here: https://aidenywl.github.io/neutbias/

Getting Started

Editor Set-up

  1. Obtain the extensions:
  • Prettier: Code formatter, configured via .prettierrc
  • TSLint: TS linter, configured via .tslint.json
  • Stylelint: CSS linter, configured via .stylelintrc
  • PostCSS syntax: Enable postCSS syntax to use Javascript variables inside CSS files.
  1. Update workspace's settings.json with this:

    "editor.formatOnSave": true,

  2. Reload your editor

Running the starter page

  1. Pull the repository
  2. Run yarn to install all packages.
  3. Run yarn start and go to your browser to see the starting website.

Deploying To Github Pages

  1. There are deployment scripts in package.json.
  2. Simply run yarn deploy to deploy to github pages with gh-pages.

The Website

Development

This website extends the typescript react boilerplate I've written here.

  • Typescript modules and all relevant react modules for development with typescript are installed.
  • Webpack is configured to build and serve Typescript and CSS files.
  • Babel is set up for ES6 syntax.
  • CSS Loader and POSTCSS Loader is used to shift away from global css and localized css for each component.
  • Further CSS set-up: autoprefixer and autoprefixer normalizes styles for each browser and takes away the trouble of writing specific css classes for each browser
  • Redux Saga and Redux is used to abstract away the data layer and api calls.

Testing Framework

Although Jest is set up, minimal tests have been written for this static page.

  • Jest is set up and ready to go via yarn test.
  • React Testing Library is used to write tests instead of enzyme for flexibility and being able to better simulate the DOM as seen by a user.
  • Using RTL allows us to move away from snapshot testing and test each component mocking components as required.

Backend

The backend is running on Flask on a GCP compute server serving the OpenNMT-py model trained on the corpus data.

neutbias's People

Contributors

aidenywl avatar dependabot[bot] avatar

Stargazers

 avatar

Watchers

James Cloos avatar  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.