logo Netzschleuder network catalog, repository, and centrifuge

History of w3c_email

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] New entry: w3c_email by Tiago de Paula Peixoto 8e0d602
diff --git a/entries/w3c_email/__init__.py b/entries/w3c_email/__init__.py
new file mode 100644
index 0000000..051ec15
--- /dev/null
+++ b/entries/w3c_email/__init__.py
@@ -0,0 +1,85 @@
+#! /usr/bin/env python
+# -*- coding: utf-8 -*-
+#
+# Copyright (C) 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
+# 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 Affero General Public License for more
+# details.
+#
+# 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 *
+
+
+title = "W3C mailing list emails (1995-2004)"
+description = """A directed network of emails sent to the public mailing lists of the World Wide Web Consortium (W3C), from the W3C corpus crawled in 2004 for the Enterprise track of TREC 2005, as processed by Benson and Kleinberg (the `pvc-email-W3C` dataset) to study networks whose edges were "found" from the activity of a set of core nodes. Each node is an email address, and a directed edge from address A to address B with a timestamp is an email sent by A to B; an email with several recipients gives several edges. The core nodes are the addresses of the domain w3.org (e.g. W3C staff and the mailing lists themselves); every email is sent from or to a core address.
+
+The emails date mostly from 1995 to 2004; a few dates outside this range (from 1988 to 2009) are likely erroneous. There are 328 emails from an address to itself.
+
+The network has the following properties:
+
+- `address`: the email address.
+- `is_core`: whether the address is in the domain w3.org.
+- Edge `time`: the time the email was sent, in Unix time. The source data give the times in seconds since the start of year 1 (as in the Julia language); they were converted by subtracting 62,135,683,200 seconds."""
+tags = ['Social', 'Communication', 'Online', 'Unweighted', 'Multigraph', 'Timestamps', 'Metadata']
+url = ['https://www.cs.cornell.edu/~arb/data/pvc-email-W3C/',
+       'https://tides.umiacs.umd.edu/webtrec/trecent/parsed_w3c_corpus.html']
+citation = [('A. R. Benson, J. Kleinberg, "Found Graph Data and Planted Vertex Covers." Advances in Neural Information Processing Systems 31 (2018)', 'https://doi.org/10.48550/arXiv.1805.01209'),
+            ('N. Craswell, A. P. de Vries, I. Soboroff, "Overview of the TREC 2005 Enterprise Track." Proceedings of the Fourteenth Text REtrieval Conference (TREC 2005) (2005)', 'https://trec.nist.gov/pubs/trec14/papers/ENTERPRISE.OVERVIEW.pdf')]
+icon_hash = None
+upstream_license = None
+upstream_prefix = 'gdrive://'
+_a = "1rfCRqS_AbezCP1ngh7eYrIogJxe2DkxG:tar.gz:email-W3C"
+files = [((f"{_a}/email-W3C.txt", f"{_a}/addresses-email-W3C.txt",
+           f"{_a}/core-email-W3C.txt"), None, None)]
+
+# seconds from 0001-01-01 (Julia's epoch for DateTime values, "Rata Die" day 1)
+# to 1970-01-01
+_unix_epoch = 62135683200
+
+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
+        with ExitStack() as stack:
+            fs = [stack.enter_context(open_upstream_file(name, fn, "r")) for fn in fnames]
+            # "<sender> <recipient> <time>", ids from 1
+            emails = [l.split() for l in fs[0] if l.strip()]
+            # "<id> <address>"
+            addresses = {}
+            for l in fs[1]:
+                if l.strip():
+                    i, a = l.split()
+                    addresses[int(i)] = a
+            core = [int(l) for l in fs[2] if l.strip()]
+        N = len(addresses)
+        assert sorted(addresses) == list(range(1, N + 1))
+        g = Graph(directed=True)
+        g.add_vertex(N)
+        g.vp.address = g.new_vp("string", vals=[addresses[i + 1] for i in range(N)])
+        g.vp.is_core = g.new_vp("bool")
+        for i in core:
+            g.vp.is_core[i - 1] = True
+        g.ep.time = g.new_ep("int64_t")
+        g.add_edge_list([(int(s) - 1, int(t) - 1, int(float(x)) - _unix_epoch)
+                         for s, t, x in emails], eprops=[g.ep.time])
+        yield alt, g