logo Netzschleuder network catalog, repository, and centrifuge

History of wiki_talk

The changes to the source code of this entry in the repository, newest first, each with the differences it made to the entry's files. They are also listed on GitLab.

[entries] Merge duplicate entries and add cross-references between related ones by Tiago de Paula Peixoto 9bc6033
- Removed duplicates, merged into the entries holding the same data:
  dblp_coauthor_snap (soc_net_comms), cattle and bison (dom; bison's
  breeding data move there, as do the wolves' age and sex),
  football_tsevans (football, with both conference assignments),
  eu_procurements_alt (eu_procurements), foursquare_friendships
  (foursquare_global).
- software_dependencies: colt and scolt are one network; ambassador: the
  duplicate 2001 network is dropped and the three same-edge networks
  combined; dom: the dataset count corrected (436).
- macaque_neural: Young's 71-area network added (young71; the 47-area one
  is now cocomac47), both from archived copies.
- collins_yeast, celegans_interactomes: from archived copies of the dead
  CCSB site (byte-identical files).
- Cross-references between entries holding versions of the same data
  (food webs, Wikipedia, Slashdot, physicians, SNAP/Mislove, CCSB).
- ICON ids of duplicate records added; macaque_neural's corrected.
- prosper, dbpedia_all: string properties given in edge-index order (needs
  graph-tool with the fixed vals ordering).
diff --git a/entries/wiki_talk/__init__.py b/entries/wiki_talk/__init__.py
index 9b67eeb..fb77525 100644
--- a/entries/wiki_talk/__init__.py
+++ b/entries/wiki_talk/__init__.py
@@ -21,7 +21,7 @@ from .. import *
 title = "Wikipedia talk networks"
 description = """Networks of messages written on user talk pages of the Wikipedias in 28 languages, extracted by J. Sun and J. Kunegis from the Wikipedia dumps at the end of 2015. On Wikipedia, each registered user has a talk page that can be used for discussion with other users. The 28 languages were those with the most articles at the time: Arabic (`ar`), Bengali (`bn`), Breton (`br`), Catalan (`ca`), Welsh (`cy`), German (`de`), Greek (`el`), English (`en`), Esperanto (`eo`), Spanish (`es`), Basque (`eu`), French (`fr`), Galician (`gl`), Haitian Creole (`ht`), Italian (`it`), Japanese (`ja`), Latvian (`lv`), Low German (`nds`), Dutch (`nl`), Occitan (`oc`), Polish (`pl`), Portuguese (`pt`), Russian (`ru`), Slovak (`sk`), Serbian (`sr`), Swedish (`sv`), Vietnamese (`vi`) and Chinese (`zh`), with one network per language.
 
-Nodes are registered users and a directed edge $(i,j)$ indicates that user $i$ wrote a message on the talk page of user $j$, at a given time. The messages range from March 2001 to December 2015. Each message is a separate edge, so a pair of users can be connected by multiple edges, and messages on one's own talk page appear as self-loops. Each user is assigned a role according to their access level in that Wikipedia: administrators (users in the "sysop", "bureaucrat" or "founder" groups), bots (users in a group whose name contains "bot") and normal users (all others).
+Nodes are registered users and a directed edge $(i,j)$ indicates that user $i$ wrote a message on the talk page of user $j$, at a given time. The messages range from March 2001 to December 2015. Each message is a separate edge, so a pair of users can be connected by multiple edges, and messages on one's own talk page appear as self-loops. The English network overlaps with the earlier SNAP extractions of the edit history until January 2008, the static `wikipedia-en-talk` and the timestamped `wiki_talk_temporal`. Each user is assigned a role according to their access level in that Wikipedia: administrators (users in the "sysop", "bureaucrat" or "founder" groups), bots (users in a group whose name contains "bot") and normal users (all others).
 
 The networks have the following properties:
 
[entries] Move KONECT-derived entries to their original sources by Tiago de Paula Peixoto 45943ea
The entries now download the data from where KONECT obtained them (live
or via the Wayback Machine), gaining the metadata KONECT dropped (names,
identifiers, timestamps, attributes), with descriptions and citations
rewritten from the original sources:

- Ma'ayan lab collection: faa_routes, foodweb_little_rock (taxon names
  were assigned to the wrong nodes), interactome_pdz, interactome_figeys,
  interactome_stelzl, interactome_vidal
- Pajek collection and primary sources: word_assoc (from the Edinburgh
  Associative Thesaurus; KONECT dropped all counts >= 10), foldoc,
  new_guinea_tribes
- bitriad: elite, ceo_club (adds the CEO KONECT's copy lacked)
- Lovro Subelj: cora, euroroad (adds isolated cities and parallel roads)
- SNAP: elec (all votes, with elections and nominators)
- Zenodo: wiki_talk (user ids and roles)
- MPI-SWS: flickr_growth, facebook_wall (edges now point from poster to
  wall owner, as documented), wikipedia_growth (full timestamps)
- Other sources: prosper, jester, reactome (the 2014
  release KONECT used), unicodelang (CLDR 27), wordnet (WordNet 3.1),
  chicago_road (TNTP ChicagoRegional)
diff --git a/entries/wiki_talk/__init__.py b/entries/wiki_talk/__init__.py
index b9b099f..9b67eeb 100644
--- a/entries/wiki_talk/__init__.py
+++ b/entries/wiki_talk/__init__.py
@@ -19,31 +19,87 @@
 from .. import *
 
 title = "Wikipedia talk networks"
-description = """Interactions among users of 10 language-specific Wikipedias: Arabic, Chinese, Dutch, English, French, German, Italian, Portuguese, Russian, and Spanish. Nodes are registered wiki editors, and an edge represents a user i having written a message on user j's talk page. Edges are timestamped. The precise dates of the snapshots are uncertain.[^icon]
-[^icon]: Description obtained from the [ICON](https://icon.colorado.edu) project."""
-tags = ['Social', 'Communication', 'Unweighted', 'Multigraph', 'Timestamps']
-url = 'http://konect.cc/networks/wiki_talk_ar'
-citation = [('J. Kunegis "Wikipedia talk networks" KONECT (2016)', 'https://doi.org/10.1145/2487788.2488173')]
+description = """Networks of messages written on user talk pages of the Wikipedias in 28 languages, extracted by J. Sun and J. Kunegis from the Wikipedia dumps at the end of 2015. On Wikipedia, each registered user has a talk page that can be used for discussion with other users. The 28 languages were those with the most articles at the time: Arabic (`ar`), Bengali (`bn`), Breton (`br`), Catalan (`ca`), Welsh (`cy`), German (`de`), Greek (`el`), English (`en`), Esperanto (`eo`), Spanish (`es`), Basque (`eu`), French (`fr`), Galician (`gl`), Haitian Creole (`ht`), Italian (`it`), Japanese (`ja`), Latvian (`lv`), Low German (`nds`), Dutch (`nl`), Occitan (`oc`), Polish (`pl`), Portuguese (`pt`), Russian (`ru`), Slovak (`sk`), Serbian (`sr`), Swedish (`sv`), Vietnamese (`vi`) and Chinese (`zh`), with one network per language.
+
+Nodes are registered users and a directed edge $(i,j)$ indicates that user $i$ wrote a message on the talk page of user $j$, at a given time. The messages range from March 2001 to December 2015. Each message is a separate edge, so a pair of users can be connected by multiple edges, and messages on one's own talk page appear as self-loops. Each user is assigned a role according to their access level in that Wikipedia: administrators (users in the "sysop", "bureaucrat" or "founder" groups), bots (users in a group whose name contains "bot") and normal users (all others).
+
+The networks have the following properties:
+
+- `user_id`: the user ID in that Wikipedia.
+- `role`: the role of the user, 0 (normal user), 1 (bot) or 2 (administrator); if a user is in groups of several roles, the highest number is given.
+- `time`: the time of the message, in Unix time."""
+tags = ['Social', 'Communication', 'Online', 'Unweighted', 'Multigraph', 'Timestamps', 'Metadata']
+url = 'https://zenodo.org/records/49561'
+citation = [('J. Sun, J. Kunegis, "Wiki-Talk Datasets." Zenodo (2016)', 'https://doi.org/10.5281/zenodo.49561')]
 icon_hash = '57575c6dbd3e93b53c69557f'
-upstream_prefix = 'http://konect.cc/files'
-files = [('download.tsv.wiki_talk_ar.tar.bz2', 'ar', 'konect'), ('download.tsv.wiki_talk_bn.tar.bz2', 'bn', 'konect'), ('download.tsv.wiki_talk_br.tar.bz2', 'br', 'konect'), ('download.tsv.wiki_talk_ca.tar.bz2', 'ca', 'konect'), ('download.tsv.wiki_talk_cy.tar.bz2', 'cy', 'konect'), ('download.tsv.wiki_talk_de.tar.bz2', 'de', 'konect'), ('download.tsv.wiki_talk_el.tar.bz2', 'el', 'konect'), ('download.tsv.wiki_talk_en.tar.bz2', 'en', 'konect'), ('download.tsv.wiki_talk_eo.tar.bz2', 'eo', 'konect'), ('download.tsv.wiki_talk_es.tar.bz2', 'es', 'konect'), ('download.tsv.wiki_talk_eu.tar.bz2', 'eu', 'konect'), ('download.tsv.wiki_talk_fr.tar.bz2', 'fr', 'konect'), ('download.tsv.wiki_talk_gl.tar.bz2', 'gl', 'konect'), ('download.tsv.wiki_talk_ht.tar.bz2', 'ht', 'konect'), ('download.tsv.wiki_talk_it.tar.bz2', 'it', 'konect'), ('download.tsv.wiki_talk_ja.tar.bz2', 'ja', 'konect'), ('download.tsv.wiki_talk_lv.tar.bz2', 'lv', 'konect'), ('download.tsv.wiki_talk_nds.tar.bz2', 'nds', 'konect'), ('download.tsv.wiki_talk_nl.tar.bz2', 'nl', 'konect'), ('download.tsv.wiki_talk_oc.tar.bz2', 'oc', 'konect'), ('download.tsv.wiki_talk_pl.tar.bz2', 'pl', 'konect'), ('download.tsv.wiki_talk_pt.tar.bz2', 'pt', 'konect'), ('download.tsv.wiki_talk_ru.tar.bz2', 'ru', 'konect'), ('download.tsv.wiki_talk_sk.tar.bz2', 'sk', 'konect'), ('download.tsv.wiki_talk_sr.tar.bz2', 'sr', 'konect'), ('download.tsv.wiki_talk_sv.tar.bz2', 'sv', 'konect'), ('download.tsv.wiki_talk_vi.tar.bz2', 'vi', 'konect'), ('download.tsv.wiki_talk_zh.tar.bz2', 'zh', 'konect')]
+upstream_license = ('CC BY-SA 4.0', 'https://creativecommons.org/licenses/by-sa/4.0/')
+upstream_prefix = 'https://zenodo.org/records/49561/files'
+
+langs = ['ar', 'bn', 'br', 'ca', 'cy', 'de', 'el', 'en', 'eo', 'es', 'eu', 'fr',
+         'gl', 'ht', 'it', 'ja', 'lv', 'nds', 'nl', 'oc', 'pl', 'pt', 'ru', 'sk',
+         'sr', 'sv', 'vi', 'zh']
+
+# Each network is read from the members data/<lang>-wiki-talk and
+# data/<lang>-user-group of the archive
+files = [('wiki-talk-dataset.tar.gz', lang, None) for lang in langs]
 
 def fetch_upstream(force=False):
     return fetch_upstream_files(__name__.split(".")[-1], upstream_prefix, files,
                                 force)
 
 @cache_network()
-@coerce_props()
+@coerce_props(vforce={"role": "int16_t"})
 @annotate()
 def parse(alts=None):
+    import pandas
+    import tarfile
     global files
     name = __name__.split(".")[-1]
     for fnames, alt, fmt in files:
         if alts is not None and alt not in alts:
             continue
-        if isinstance(fnames, str):
-            fnames = [fnames]
-        with ExitStack() as stack:
-            fs = [stack.enter_context(open_upstream_file(name, fn, "rb")) for fn in fnames]
-            g = parse_graph(fs, fmt, directed=True)
+        members = {f"data/{alt}-wiki-talk": None, f"data/{alt}-user-group": None}
+        # the members are read in the order of the archive, so the
+        # decompressed stream is only seeked forward
+        with open_upstream_file(name, fnames, "rb") as fa:
+            with tarfile.open(fileobj=fa, mode="r:") as tf:
+                for ti in tf:
+                    if ti.name not in members:
+                        continue
+                    with tf.extractfile(ti) as f:
+                        if ti.name.endswith("-wiki-talk"):
+                            # Lines 'user_a user_b time': user_a wrote a
+                            # message on the talk page of user_b
+                            members[ti.name] = pandas.read_csv(
+                                f, sep="\t", header=None, names=["u", "v", "t"],
+                                dtype={"u": numpy.int64, "v": numpy.int64,
+                                       "t": str})
+                        else:
+                            # Lines 'user role' (0: normal user, 1: bot,
+                            # 2: administrator)
+                            members[ti.name] = pandas.read_csv(
+                                f, sep="\t", header=None,
+                                dtype=numpy.int64).values
+                    if all(x is not None for x in members.values()):
+                        break
+        df = members[f"data/{alt}-wiki-talk"]
+        roles = members[f"data/{alt}-user-group"]
+        del members
+        t = pandas.to_datetime(df["t"], format="%Y-%m-%dT%H:%M:%SZ").values
+        m = numpy.empty((len(df), 3), dtype=numpy.int64)
+        m[:, 0] = df["u"].values
+        m[:, 1] = df["v"].values
+        m[:, 2] = t.astype("datetime64[s]").astype(numpy.int64)
+        del df, t
+        g = Graph(directed=True)
+        g.ep.time = g.new_ep("int64_t")
+        g.vp.user_id = g.add_edge_list(m, hashed=True, eprops=[g.ep.time])
+        del m
+        g.vp.role = g.new_vp("int")
+        vids = g.vp.user_id.fa
+        idx = numpy.argsort(vids)
+        pos = numpy.searchsorted(vids, roles[:, 0], sorter=idx)
+        pos[pos == len(vids)] = 0
+        found = vids[idx[pos]] == roles[:, 0]
+        g.vp.role.fa[idx[pos[found]]] = roles[found, 1]
         yield alt, g
Update copyright information by Tiago de Paula Peixoto 73a4f0d
diff --git a/entries/wiki_talk/__init__.py b/entries/wiki_talk/__init__.py
index 611861b..b9b099f 100644
--- a/entries/wiki_talk/__init__.py
+++ b/entries/wiki_talk/__init__.py
@@ -1,7 +1,7 @@
 #! /usr/bin/env python
 # -*- coding: utf-8 -*-
 #
-# Copyright (C) 2020-2024 Tiago de Paula Peixoto <tiago@skewed.de>
+# Copyright (C) 2020-2026 Tiago de Paula Peixoto <tiago@skewed.de>
 #
 # This program is free software: you can redistribute it and/or modify it under
 # the terms of the GNU Affero General Public License as published by the Free
Update copyright information by Tiago de Paula Peixoto 3d288ea
diff --git a/entries/wiki_talk/__init__.py b/entries/wiki_talk/__init__.py
index ae6e64b..611861b 100644
--- a/entries/wiki_talk/__init__.py
+++ b/entries/wiki_talk/__init__.py
@@ -1,7 +1,7 @@
 #! /usr/bin/env python
 # -*- coding: utf-8 -*-
 #
-# Copyright (C) 2020-2023 Tiago de Paula Peixoto <tiago@skewed.de>
+# Copyright (C) 2020-2024 Tiago de Paula Peixoto <tiago@skewed.de>
 #
 # This program is free software: you can redistribute it and/or modify it under
 # the terms of the GNU Affero General Public License as published by the Free
Update copyright information by Tiago de Paula Peixoto 8d005ae
diff --git a/entries/wiki_talk/__init__.py b/entries/wiki_talk/__init__.py
index 1d073f4..ae6e64b 100644
--- a/entries/wiki_talk/__init__.py
+++ b/entries/wiki_talk/__init__.py
@@ -1,7 +1,7 @@
 #! /usr/bin/env python
 # -*- coding: utf-8 -*-
 #
-# Copyright (C) 2021 Tiago de Paula Peixoto <tiago@skewed.de>
+# Copyright (C) 2020-2023 Tiago de Paula Peixoto <tiago@skewed.de>
 #
 # This program is free software: you can redistribute it and/or modify it under
 # the terms of the GNU Affero General Public License as published by the Free
Update copyright info by Tiago de Paula Peixoto db2efcc
diff --git a/entries/wiki_talk/__init__.py b/entries/wiki_talk/__init__.py
index bb5d68c..1d073f4 100644
--- a/entries/wiki_talk/__init__.py
+++ b/entries/wiki_talk/__init__.py
@@ -1,7 +1,7 @@
 #! /usr/bin/env python
 # -*- coding: utf-8 -*-
 #
-# Copyright (C) 2020 Tiago de Paula Peixoto <tiago@skewed.de>
+# Copyright (C) 2021 Tiago de Paula Peixoto <tiago@skewed.de>
 #
 # This program is free software: you can redistribute it and/or modify it under
 # the terms of the GNU Affero General Public License as published by the Free
Un-orphan KONECT datasets by Tiago de Paula Peixoto 894eba5
KONECT has been brought back from the dead for the time being.
diff --git a/entries/wiki_talk/__init__.py b/entries/wiki_talk/__init__.py
index 8b6f6ba..bb5d68c 100644
--- a/entries/wiki_talk/__init__.py
+++ b/entries/wiki_talk/__init__.py
@@ -26,7 +26,6 @@ url = 'http://konect.cc/networks/wiki_talk_ar'
 citation = [('J. Kunegis "Wikipedia talk networks" KONECT (2016)', 'https://doi.org/10.1145/2487788.2488173')]
 icon_hash = '57575c6dbd3e93b53c69557f'
 upstream_prefix = 'http://konect.cc/files'
-orphan = True
 files = [('download.tsv.wiki_talk_ar.tar.bz2', 'ar', 'konect'), ('download.tsv.wiki_talk_bn.tar.bz2', 'bn', 'konect'), ('download.tsv.wiki_talk_br.tar.bz2', 'br', 'konect'), ('download.tsv.wiki_talk_ca.tar.bz2', 'ca', 'konect'), ('download.tsv.wiki_talk_cy.tar.bz2', 'cy', 'konect'), ('download.tsv.wiki_talk_de.tar.bz2', 'de', 'konect'), ('download.tsv.wiki_talk_el.tar.bz2', 'el', 'konect'), ('download.tsv.wiki_talk_en.tar.bz2', 'en', 'konect'), ('download.tsv.wiki_talk_eo.tar.bz2', 'eo', 'konect'), ('download.tsv.wiki_talk_es.tar.bz2', 'es', 'konect'), ('download.tsv.wiki_talk_eu.tar.bz2', 'eu', 'konect'), ('download.tsv.wiki_talk_fr.tar.bz2', 'fr', 'konect'), ('download.tsv.wiki_talk_gl.tar.bz2', 'gl', 'konect'), ('download.tsv.wiki_talk_ht.tar.bz2', 'ht', 'konect'), ('download.tsv.wiki_talk_it.tar.bz2', 'it', 'konect'), ('download.tsv.wiki_talk_ja.tar.bz2', 'ja', 'konect'), ('download.tsv.wiki_talk_lv.tar.bz2', 'lv', 'konect'), ('download.tsv.wiki_talk_nds.tar.bz2', 'nds', 'konect'), ('download.tsv.wiki_talk_nl.tar.bz2', 'nl', 'konect'), ('download.tsv.wiki_talk_oc.tar.bz2', 'oc', 'konect'), ('download.tsv.wiki_talk_pl.tar.bz2', 'pl', 'konect'), ('download.tsv.wiki_talk_pt.tar.bz2', 'pt', 'konect'), ('download.tsv.wiki_talk_ru.tar.bz2', 'ru', 'konect'), ('download.tsv.wiki_talk_sk.tar.bz2', 'sk', 'konect'), ('download.tsv.wiki_talk_sr.tar.bz2', 'sr', 'konect'), ('download.tsv.wiki_talk_sv.tar.bz2', 'sv', 'konect'), ('download.tsv.wiki_talk_vi.tar.bz2', 'vi', 'konect'), ('download.tsv.wiki_talk_zh.tar.bz2', 'zh', 'konect')]
 
 def fetch_upstream(force=False):
Update citations to use DOIs by Tiago de Paula Peixoto e878874
diff --git a/entries/wiki_talk/__init__.py b/entries/wiki_talk/__init__.py
index f146097..8b6f6ba 100644
--- a/entries/wiki_talk/__init__.py
+++ b/entries/wiki_talk/__init__.py
@@ -23,7 +23,7 @@ description = """Interactions among users of 10 language-specific Wikipedias: Ar
 [^icon]: Description obtained from the [ICON](https://icon.colorado.edu) project."""
 tags = ['Social', 'Communication', 'Unweighted', 'Multigraph', 'Timestamps']
 url = 'http://konect.cc/networks/wiki_talk_ar'
-citation = [('J. Kunegis "Wikipedia talk networks" KONECT (2016)', 'http://konect.cc/')]
+citation = [('J. Kunegis "Wikipedia talk networks" KONECT (2016)', 'https://doi.org/10.1145/2487788.2488173')]
 icon_hash = '57575c6dbd3e93b53c69557f'
 upstream_prefix = 'http://konect.cc/files'
 orphan = True
Add support for 'orphan' datasets and tag konect entries by Tiago de Paula Peixoto e330b80
diff --git a/entries/wiki_talk/__init__.py b/entries/wiki_talk/__init__.py
index b6f8c2c..f146097 100644
--- a/entries/wiki_talk/__init__.py
+++ b/entries/wiki_talk/__init__.py
@@ -26,6 +26,7 @@ url = 'http://konect.cc/networks/wiki_talk_ar'
 citation = [('J. Kunegis "Wikipedia talk networks" KONECT (2016)', 'http://konect.cc/')]
 icon_hash = '57575c6dbd3e93b53c69557f'
 upstream_prefix = 'http://konect.cc/files'
+orphan = True
 files = [('download.tsv.wiki_talk_ar.tar.bz2', 'ar', 'konect'), ('download.tsv.wiki_talk_bn.tar.bz2', 'bn', 'konect'), ('download.tsv.wiki_talk_br.tar.bz2', 'br', 'konect'), ('download.tsv.wiki_talk_ca.tar.bz2', 'ca', 'konect'), ('download.tsv.wiki_talk_cy.tar.bz2', 'cy', 'konect'), ('download.tsv.wiki_talk_de.tar.bz2', 'de', 'konect'), ('download.tsv.wiki_talk_el.tar.bz2', 'el', 'konect'), ('download.tsv.wiki_talk_en.tar.bz2', 'en', 'konect'), ('download.tsv.wiki_talk_eo.tar.bz2', 'eo', 'konect'), ('download.tsv.wiki_talk_es.tar.bz2', 'es', 'konect'), ('download.tsv.wiki_talk_eu.tar.bz2', 'eu', 'konect'), ('download.tsv.wiki_talk_fr.tar.bz2', 'fr', 'konect'), ('download.tsv.wiki_talk_gl.tar.bz2', 'gl', 'konect'), ('download.tsv.wiki_talk_ht.tar.bz2', 'ht', 'konect'), ('download.tsv.wiki_talk_it.tar.bz2', 'it', 'konect'), ('download.tsv.wiki_talk_ja.tar.bz2', 'ja', 'konect'), ('download.tsv.wiki_talk_lv.tar.bz2', 'lv', 'konect'), ('download.tsv.wiki_talk_nds.tar.bz2', 'nds', 'konect'), ('download.tsv.wiki_talk_nl.tar.bz2', 'nl', 'konect'), ('download.tsv.wiki_talk_oc.tar.bz2', 'oc', 'konect'), ('download.tsv.wiki_talk_pl.tar.bz2', 'pl', 'konect'), ('download.tsv.wiki_talk_pt.tar.bz2', 'pt', 'konect'), ('download.tsv.wiki_talk_ru.tar.bz2', 'ru', 'konect'), ('download.tsv.wiki_talk_sk.tar.bz2', 'sk', 'konect'), ('download.tsv.wiki_talk_sr.tar.bz2', 'sr', 'konect'), ('download.tsv.wiki_talk_sv.tar.bz2', 'sv', 'konect'), ('download.tsv.wiki_talk_vi.tar.bz2', 'vi', 'konect'), ('download.tsv.wiki_talk_zh.tar.bz2', 'zh', 'konect')]
 
 def fetch_upstream(force=False):
Change license from GPLv3 to AGPLv3 by Tiago de Paula Peixoto d754be5
diff --git a/entries/wiki_talk/__init__.py b/entries/wiki_talk/__init__.py
index 3aa68b0..b6f8c2c 100644
--- a/entries/wiki_talk/__init__.py
+++ b/entries/wiki_talk/__init__.py
@@ -3,18 +3,18 @@
 #
 # Copyright (C) 2020 Tiago de Paula Peixoto <tiago@skewed.de>
 #
-# This program is free software: you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation, either version 3 of the License, or
-# (at your option) any later version.
+# This program is free software: you can redistribute it and/or modify it under
+# the terms of the GNU Affero General Public License as published by the Free
+# Software Foundation, either version 3 of the License, or (at your option) any
+# later version.
 #
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-# GNU General Public License for more details.
+# This program is distributed in the hope that it will be useful, but WITHOUT
+# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
+# FOR A PARTICULAR PURPOSE.  See the GNU Affero General Public License for more
+# details.
 #
-# You should have received a copy of the GNU General Public License
-# along with this program.  If not, see <http://www.gnu.org/licenses/>.
+# You should have received a copy of the GNU Affero General Public License along
+# with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 from .. import *
 
Add explicit attribution to descriptions obtained from ICON by Tiago de Paula Peixoto 1645314
diff --git a/entries/wiki_talk/__init__.py b/entries/wiki_talk/__init__.py
index f459b07..3aa68b0 100644
--- a/entries/wiki_talk/__init__.py
+++ b/entries/wiki_talk/__init__.py
@@ -19,7 +19,8 @@
 from .. import *
 
 title = "Wikipedia talk networks"
-description = "Interactions among users of 10 language-specific Wikipedias: Arabic, Chinese, Dutch, English, French, German, Italian, Portuguese, Russian, and Spanish. Nodes are registered wiki editors, and an edge represents a user i having written a message on user j's talk page. Edges are timestamped. The precise dates of the snapshots are uncertain."
+description = """Interactions among users of 10 language-specific Wikipedias: Arabic, Chinese, Dutch, English, French, German, Italian, Portuguese, Russian, and Spanish. Nodes are registered wiki editors, and an edge represents a user i having written a message on user j's talk page. Edges are timestamped. The precise dates of the snapshots are uncertain.[^icon]
+[^icon]: Description obtained from the [ICON](https://icon.colorado.edu) project."""
 tags = ['Social', 'Communication', 'Unweighted', 'Multigraph', 'Timestamps']
 url = 'http://konect.cc/networks/wiki_talk_ar'
 citation = [('J. Kunegis "Wikipedia talk networks" KONECT (2016)', 'http://konect.cc/')]
Initial commit by Tiago de Paula Peixoto cc85872
diff --git a/entries/wiki_talk/__init__.py b/entries/wiki_talk/__init__.py
new file mode 100644
index 0000000..f459b07
--- /dev/null
+++ b/entries/wiki_talk/__init__.py
@@ -0,0 +1,48 @@
+#! /usr/bin/env python
+# -*- coding: utf-8 -*-
+#
+# Copyright (C) 2020 Tiago de Paula Peixoto <tiago@skewed.de>
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program.  If not, see <http://www.gnu.org/licenses/>.
+
+from .. import *
+
+title = "Wikipedia talk networks"
+description = "Interactions among users of 10 language-specific Wikipedias: Arabic, Chinese, Dutch, English, French, German, Italian, Portuguese, Russian, and Spanish. Nodes are registered wiki editors, and an edge represents a user i having written a message on user j's talk page. Edges are timestamped. The precise dates of the snapshots are uncertain."
+tags = ['Social', 'Communication', 'Unweighted', 'Multigraph', 'Timestamps']
+url = 'http://konect.cc/networks/wiki_talk_ar'
+citation = [('J. Kunegis "Wikipedia talk networks" KONECT (2016)', 'http://konect.cc/')]
+icon_hash = '57575c6dbd3e93b53c69557f'
+upstream_prefix = 'http://konect.cc/files'
+files = [('download.tsv.wiki_talk_ar.tar.bz2', 'ar', 'konect'), ('download.tsv.wiki_talk_bn.tar.bz2', 'bn', 'konect'), ('download.tsv.wiki_talk_br.tar.bz2', 'br', 'konect'), ('download.tsv.wiki_talk_ca.tar.bz2', 'ca', 'konect'), ('download.tsv.wiki_talk_cy.tar.bz2', 'cy', 'konect'), ('download.tsv.wiki_talk_de.tar.bz2', 'de', 'konect'), ('download.tsv.wiki_talk_el.tar.bz2', 'el', 'konect'), ('download.tsv.wiki_talk_en.tar.bz2', 'en', 'konect'), ('download.tsv.wiki_talk_eo.tar.bz2', 'eo', 'konect'), ('download.tsv.wiki_talk_es.tar.bz2', 'es', 'konect'), ('download.tsv.wiki_talk_eu.tar.bz2', 'eu', 'konect'), ('download.tsv.wiki_talk_fr.tar.bz2', 'fr', 'konect'), ('download.tsv.wiki_talk_gl.tar.bz2', 'gl', 'konect'), ('download.tsv.wiki_talk_ht.tar.bz2', 'ht', 'konect'), ('download.tsv.wiki_talk_it.tar.bz2', 'it', 'konect'), ('download.tsv.wiki_talk_ja.tar.bz2', 'ja', 'konect'), ('download.tsv.wiki_talk_lv.tar.bz2', 'lv', 'konect'), ('download.tsv.wiki_talk_nds.tar.bz2', 'nds', 'konect'), ('download.tsv.wiki_talk_nl.tar.bz2', 'nl', 'konect'), ('download.tsv.wiki_talk_oc.tar.bz2', 'oc', 'konect'), ('download.tsv.wiki_talk_pl.tar.bz2', 'pl', 'konect'), ('download.tsv.wiki_talk_pt.tar.bz2', 'pt', 'konect'), ('download.tsv.wiki_talk_ru.tar.bz2', 'ru', 'konect'), ('download.tsv.wiki_talk_sk.tar.bz2', 'sk', 'konect'), ('download.tsv.wiki_talk_sr.tar.bz2', 'sr', 'konect'), ('download.tsv.wiki_talk_sv.tar.bz2', 'sv', 'konect'), ('download.tsv.wiki_talk_vi.tar.bz2', 'vi', 'konect'), ('download.tsv.wiki_talk_zh.tar.bz2', 'zh', 'konect')]
+
+def fetch_upstream(force=False):
+    return fetch_upstream_files(__name__.split(".")[-1], upstream_prefix, files,
+                                force)
+
+@cache_network()
+@coerce_props()
+@annotate()
+def parse(alts=None):
+    global files
+    name = __name__.split(".")[-1]
+    for fnames, alt, fmt in files:
+        if alts is not None and alt not in alts:
+            continue
+        if isinstance(fnames, str):
+            fnames = [fnames]
+        with ExitStack() as stack:
+            fs = [stack.enter_context(open_upstream_file(name, fn, "rb")) for fn in fnames]
+            g = parse_graph(fs, fmt, directed=True)
+        yield alt, g