All Projects → ni9elf → 3HAN

ni9elf / 3HAN

Licence: other
An original implementation of "3HAN: A Deep Neural Network for Fake News Detection" (ICONIP 2017)

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to 3HAN

fake-news-detection
This repo is a collection of AWESOME things about fake news detection, including papers, code, etc.
Stars: ✭ 34 (+17.24%)
Mutual labels:  text-classification, fake-news-detection
Text classification
all kinds of text classification models and more with deep learning
Stars: ✭ 7,179 (+24655.17%)
Mutual labels:  text-classification, attention-mechanism
automatic-personality-prediction
[AAAI 2020] Modeling Personality with Attentive Networks and Contextual Embeddings
Stars: ✭ 43 (+48.28%)
Mutual labels:  text-classification, attention-mechanism
Textclassifier
Text classifier for Hierarchical Attention Networks for Document Classification
Stars: ✭ 985 (+3296.55%)
Mutual labels:  text-classification, attention-mechanism
Hierarchical Multi Label Text Classification
The code of CIKM'19 paper《Hierarchical Multi-label Text Classification: An Attention-based Recurrent Network Approach》
Stars: ✭ 133 (+358.62%)
Mutual labels:  text-classification, attention-mechanism
A Pytorch Tutorial To Text Classification
Hierarchical Attention Networks | a PyTorch Tutorial to Text Classification
Stars: ✭ 184 (+534.48%)
Mutual labels:  text-classification, attention-mechanism
Chatbot cn
基于金融-司法领域(兼有闲聊性质)的聊天机器人,其中的主要模块有信息抽取、NLU、NLG、知识图谱等,并且利用Django整合了前端展示,目前已经封装了nlp和kg的restful接口
Stars: ✭ 791 (+2627.59%)
Mutual labels:  text-classification, attention-mechanism
Sarcasm Detection
Detecting Sarcasm on Twitter using both traditonal machine learning and deep learning techniques.
Stars: ✭ 73 (+151.72%)
Mutual labels:  text-classification, attention-mechanism
Hierarchical Attention Networks
TensorFlow implementation of the paper "Hierarchical Attention Networks for Document Classification"
Stars: ✭ 75 (+158.62%)
Mutual labels:  text-classification, attention-mechanism
Document Classifier Lstm
A bidirectional LSTM with attention for multiclass/multilabel text classification.
Stars: ✭ 136 (+368.97%)
Mutual labels:  text-classification, attention-mechanism
rnn-text-classification-tf
Tensorflow implementation of Attention-based Bidirectional RNN text classification.
Stars: ✭ 26 (-10.34%)
Mutual labels:  text-classification, attention-mechanism
ml-with-text
[Tutorial] Demystifying Natural Language Processing with Python
Stars: ✭ 18 (-37.93%)
Mutual labels:  text-classification
kaggle redefining cancer treatment
Personalized Medicine: Redefining Cancer Treatment with deep learning
Stars: ✭ 21 (-27.59%)
Mutual labels:  text-classification
Research-Paper-Categorization
Research paper classification using machine learning and NLP
Stars: ✭ 23 (-20.69%)
Mutual labels:  text-classification
deep-learning
Deep Learning Bootcamp
Stars: ✭ 60 (+106.9%)
Mutual labels:  text-classification
ML4K-AI-Extension
Use machine learning in AppInventor, with easy training using text, images, or numbers through the Machine Learning for Kids website.
Stars: ✭ 18 (-37.93%)
Mutual labels:  text-classification
minimal-nmt
A minimal nmt example to serve as an seq2seq+attention reference.
Stars: ✭ 36 (+24.14%)
Mutual labels:  attention-mechanism
Text tone analyzer
Система, анализирующая тональность текстов и высказываний.
Stars: ✭ 15 (-48.28%)
Mutual labels:  text-classification
clfzoo
A deep text classifiers library.
Stars: ✭ 37 (+27.59%)
Mutual labels:  text-classification
trove
Weakly supervised medical named entity classification
Stars: ✭ 55 (+89.66%)
Mutual labels:  text-classification

3HAN: A Deep Neural Network for Fake News Detection

This repository contains code in Keras for the models, baselines and visualizations used in the paper 3HAN: A Deep Neural Network for Fake News Detection.

Abstract

The proliferation of fake news has possibly led to a mis-informed public opinion. We propose 3HAN, a three level hierarchical attention network, which creates a news vector, a representation of news articles to detect fake news. Our model (i) interprets the structure of an article as a three level hierarchy of words, sentences and headline, (ii) treats the headline as a distinctive feature and (iii) uses attention to differentiate elements of an hierarchy consistent with their interactions when constructing the news vector. Experiments on our large real world data set demonstrate the effectiveness of news vector in giving state-of- the-art performance. Visualizing the attention layers provides important parts of an article which is helpful in further human fact-checking.

Models

The models folder contains code for:

  • 3HAN-Ave: Vectors are composed using global average pooling
  • 3HAN-Max: Vectors are composed using global max pooling
  • 3HAN: Our proposed model with attention mechanism
  • 3HAN+PT: Variant of 3HAN to include pre-training

Baselines

The baselines folder contains code for:

  • Word Count Based Models:

    • Majority uses the heuristic of taking the majority label in the training set as the assigning label to every point in the test set.
    • Bag-of-words and its TF-IDF constructs a vocabulary of the most frequent 50,000 words. The count of these words is used as features. The TF-IDF count is used as features in the other model variant.
    • Bag-of-ngrams and its TF-IDF uses the count of the 50,000 most frequent ngrams (n <= 5). The features are formed in the same way as above.
    • SVM+Bigrams uses the count of the 50,000 most frequent bigrams as features with an SVM classifier.
  • Neural Network Models:

    • GloVe-Avg flattens the article text to a word level granularity as a sequence of words. The GloVe embeddings of all words are averaged to form the feature vector.
    • GRU treats the article text as a sequence of words. A GRU with an annotation dimension of 300 is run on the sequence of GloVe word embeddings. The hidden annotation after the last time step is used as the feature vector.
    • GRU-Avg runs a GRU on the sequence of word embeddings and returns all hidden annotations at each time step. The average of these hidden annotations is used as the feature vector.
    • HAN and Variants include HAN-Ave, Han-Max and HAN. HAN uses a two level hierarchical attention network. HAN-Ave and Han-Max replaces the attention mechanism with average and max pooling for composition respectively. Since the code is not officially released we use our own implementation.

Requirements

  • Keras 2.0.4
  • Theano 0.9.0
  • Python 3.4.3

Reference

Singhania S., Fernandez N., Rao S. (2017) 3HAN: A Deep Neural Network for Fake News Detection. In: Liu D., Xie S., Li Y., Zhao D., El-Alfy ES. (eds) Neural Information Processing. ICONIP 2017. Lecture Notes in Computer Science, vol 10635. Springer, Cham

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].