
Explore how a Gitbook functions as an ebook to support learning, offering copyable code, organized concepts, and a library view to streamline study.
Meet a pre-trained TensorFlow.js insult-detection bot built with Angular and Angular Material, demonstrating how a deep learning model detects direct insults in short comments.
Navigate our GitHub repository for the insultbot course, with a two-part structure: master background and a user-friendly interface, and a link to GitHub, ready for exploration.
Build an insult bot that detects insults in blog comments, and set up the project with Angular, NodeJS, and NPM in VS Code using a GitBook workflow.
Install and verify the tensorflow.js toxicity package to use a pre-trained neural network for toxicity detection, avoiding training from scratch and understanding bias, normalization, and deployment considerations.
Learn to integrate the toxicity package with an angular app, handle typescript typing for TensorFlow.js, and apply a parameterized sensitivity and threshold for classifying content.
Learn how toxicity classification works in TensorFlow.js, estimate probabilities, and set thresholds, then design a simple interface to test insults in your insultbot.
Learn to build an Angular interface that uses the TensorFlow.js toxicity library with TypeScript, balancing typed and untyped code and implementing a user-friendly UI with Angular Material.
Learn to build the insultbot interface using Angular Material, set up lazy load to keep the app light, and structure TypeScript from the interface onward, including simple html div usage.
Learn to use Angular Material's mat-card by installing the API, importing the module, testing example code, and troubleshooting common integration issues.
Explore adding a button to a material card using Angular Material directives, headers, and styling, and learn how imports, directives, and color options affect appearance and behavior.
Learn to add a moderation input to our card by selecting an input or textarea, wiring the API, and organizing the card into head, content, and action sections.
Connect the button to your Angular logic using reactive forms and form control, establishing a clear interface-to-logic communication, and validate interactions with console logs and test-driven development.
Connect the interface to the moderation logic by predicting insults with a future, identifying toxic, obscene, and other categories, and adjusting results with a tolerance threshold.
Discover how to finalize an insult moderation feature by handling strings and special characters, enabling button-driven activation, collecting insults with a for-each loop, and displaying results in Angular.
Develop closing lines for an insultbot and test how the system flags identity-based insults and toxic language, exploring moderation scales and a centered interface card.
Explore how online content moderation balances type I and type II errors, distinguishing false positives and false negatives, and decide which error to prioritize when tuning moderation models.
Explore how racial slurs function as identity attacks and how an insultbot flags them in online discourse, using Obama-era examples and social media tolerance scales.
Explore content moderation with Tensorflow.js and practical approaches from an independent researcher. George Pierce shares his study, online courses, and private lessons to guide you in building an insultbot.
Explore the exponential growth of artificial intelligence from deep learning to modern neural networks. See its biomedical and imaging applications, and learn about collaboration with humans and data bias.
Discover how computers think, decide, and learn through computational thinking, and separate Hollywood myth from reality in artificial intelligence, using examples from chess, Go, medicine, and optimization.
"even the prime minister of Norway herself, reposted the photo to Facebook, only to have it quickly removed." Custodians of the Internet (Tarleton Gillespie)
A very nice application of artificial intelligence is on content moderation. Our goal is spotting whether a content has something that should not be shown on a conversation. On this course, we use TensorFlow.js (machine learning in JavaScript), a pretrained model, for content moderation. It is very easy to use: just call the model and get a reply, a list of types of contents to be blocked and their respective flags.
Online Content moderation is the process by which one must decide what stays online vs. what should be moderated or even eliminated; no one is happy to be moderated, I was not when I was the target of several online moderations on YouTube, Facebook and Twitter. The “Napalm girl” was a famous case in which Facebook classified as nudity, which is a historical picture.
What is the best and most efficient way to safely moderate content online?
Several programming savvies are doing their best. Like in String Theory, they gather the best, but no practical answer came out yet. Recently, we had chatGPT that can make sentiment analysis in an advance approach, this course shows an alternative, which is free. chatGPT has a small chart per API call. Furthermore, chatGPT requires much less coding expertise
On this course, I want to share a trivial case, which was not also easy to solve for a scientists, but now easily implemented as public library: direct insult (i.e., calling people names).
The bot is a classical pattern recognition: it gives out a number, and you must decide your tolerance for insults. This number, already standard on deep learning, is a sort of probability, loosely speaking.
We are going to use two MIT license Google public tools: TensorFlow.js and Angular. The former is a deep learning tool for freely creating smart web application, whereas the latter is a free framework for creating frontend application, no need to create servers.