Skip to main content

Story Clustering Bot for Taranis-NG

Project description

Story Clustering

This code takes newsitems in the format as provided by Taranis-NG and clusters them into Stories.

Description and Use

The approach supports the following functionalities:

  1. Automatically detect Events.
  2. News items are clustered based on the detected Events.
  3. Documents belonging to related Events are then clustered into Stories.

Initial clustering

The method initial_clustering in clustering.py takes as input a dictionary of news_items_aggregate (see tests/testdapa.py for the actual input format) and outputs a dictionary containing two keys: ("event_clusters" : list of list of documents ids) and ("story_clusters" : list of list of documents ids)

Incremental clustering

The incremental clustering method takes as input a dictionary of news_items_aggregate, containing new news items to be clustered, and clustered_news_items_aggregate, containing already clustered items, and tries to cluster the new documents to the existing clusters or create new ones. See tests/testdata.py for the actual input formats. This method also outputs a dictionary containing two keys: ("event_clusters" : list of list of documents ids) and ("story_clusters" : list of list of documents ids)

Installation

The requirements.txt file should list all Python libraries that the story-clustering depends on, and they will be installed using:

pip install .

Development

pip install .[dev]

Use

See notebook\test_story_clustering.ipynb for examples on how to use the clustering methods.

License

EUROPEAN UNION PUBLIC LICENCE v. 1.2

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

taranis_story_clustering-0.4.8.tar.gz (32.8 kB view details)

Uploaded Source

Built Distribution

taranis_story_clustering-0.4.8-py3-none-any.whl (32.5 kB view details)

Uploaded Python 3

File details

Details for the file taranis_story_clustering-0.4.8.tar.gz.

File metadata

File hashes

Hashes for taranis_story_clustering-0.4.8.tar.gz
Algorithm Hash digest
SHA256 f314e7a273d110f63c0fd4737d2cc5d05d22d0e2182de816b45e88d2acc2f6bd
MD5 cbf47bd2588f7150af86efeeb28ed3e4
BLAKE2b-256 78a0cf07b3789815b986e31b0ac46c91c74e1e484cae1c36c9eafd80f6978ea2

See more details on using hashes here.

File details

Details for the file taranis_story_clustering-0.4.8-py3-none-any.whl.

File metadata

File hashes

Hashes for taranis_story_clustering-0.4.8-py3-none-any.whl
Algorithm Hash digest
SHA256 aac1d65b647ae50480d5a99efe09bf0277914a20bf06cc19400f5eb331b92012
MD5 07a120fad9b3c09a5f168ff43e2fe5f9
BLAKE2b-256 73bdae2f8b1e91f3965ea2c28c0db200d3cfb5cdedde419d5556a8d0e99655c0

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page