Git Product home page Git Product logo

twitter-cyberthreat-detection's Introduction

twitter-cyberthreat-detection

This repository holds the dataset used to conduct experiments for the "Cyberthreat Detection from Twitter using Deep Neural Networks" accepted to the IJCNN 2019.

Please check the more recent Pytorch version which included a Multi-Task component: https://github.com/ndionysus/multitask-cyberthreat-detection.

Data:

Due to Twitter's policy, we can only publish IDs. Some of these tweets can longer be retrieved, either because the tweet was deleted or the user no longer exists.

To obtain the tweets, you will need a valid Twitter developer account, and to install the Tweepy library (https://github.com/tweepy/tweepy). The steps required to obtain the developer status, and the corresponding consumer key, consumer secret, acess token, and access token secret are described in this link (https://developer.twitter.com/en/docs/basics/authentication/guides/access-tokens). Once you have the tokens, place them in the corresponding places in the provided "prepare_data.py" script. The script may take a while to download all tweets, however some tweets may no longer be available. The output of this script will provide 3 main csv files and 9 txt files.

Pre-trained model

The models can be used through the class_eval.py and ner_eval.py scripts.

Example:

class_eval.py -model checkpoints/CNN_A_1812972722/ -pos data/d3_A_pos.txt -neg data/d3_A_neg.txt

This will output a TPR and TNR score for the datasets provided.

Alternatively, a txt file with only text and the output file will provide a prediciton for each line

class_eval.py -model checkpoints/CNN_A_1812972722/ -input input.txt -output output.txt

Training models

The models can be trained with the class_train.py and ner_train.py scripts. The configurations for these models are set in the class_config.py file.

twitter-cyberthreat-detection's People

Contributors

ndionysus 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.