{"id":608,"date":"2018-04-20T10:41:08","date_gmt":"2018-04-20T10:41:08","guid":{"rendered":"http:\/\/munnecke.net\/?p=608"},"modified":"2022-01-24T20:33:36","modified_gmt":"2022-01-24T20:33:36","slug":"introducing-netml","status":"publish","type":"post","link":"http:\/\/munnecke.net\/blog\/introducing-netml\/","title":{"rendered":"Introducing NetML"},"content":{"rendered":"

NetML is a network markup language that makes it easy to write down information as a network of nodes with properties and links. <\/p>\n

Fig 1: With NetML it is easy to convert text to a network.<\/figcaption><\/figure>\n

Concept<\/h3>\n

Real-world issues are often complex and involve many stakeholders. Those dealing with the issues – such as engaged citizens, researchers and journalists – are therefore often struggling to manage and integrate the many fragments of information they find in the early phases of an investigation.<\/p>\n

NetML is conceived to make it quick and intuitive to write down information as a network of nodes with properties and links. The combination of a single text file and a compact format makes it possible to get an overview of the information in the NetML file itself. For a more comprehensive exploration of the network, NetML files can easily be converted to a number of file formats that are accepted by most network visualization and analysis software (e.g. https:\/\/graphcommons.com<\/a>, https:\/\/onodo.org<\/a> and https:\/\/gephi.org<\/a>).<\/p>\n

Fig 2: The process of transforming NetML to a network<\/figcaption><\/figure>\n

Because the NetML file is a simple text file, it can easily be shared or uploaded to a cloud service for collaboration (GitHub, Google Drive etc.)<\/p>\n

Join the project!<\/h3>\n

This is the first release of specifications for NetML, so there are lots of exciting work ahead. If you have any comments, recommendation or would like to contribute to the development of NetML, please go to https:\/\/github.com\/repmax\/netml<\/a>.<\/p>\n

In parallel, a suite of tools is being developed to convert NetML to standard network formats. You can download the tools and\/or contribute to their further development at the NetMaker GitHub repository: https:\/\/github.com\/repmax\/netmaker<\/a>.<\/p>\n

Specifications for NetML v0.1<\/h2>\n

Node, properties and links<\/h3>\n

Let’s start with an example of how to lines of text is converted into a network:<\/p>\n

Fig 3: Linking nodes by assigning a unique identifier.<\/figcaption><\/figure>\n

From the example above we can see that each node is defined in a single line of text and may consist of up to 3 parts separated by ‘|’:<\/p>\n

    \n
  1. Meta: name, type (optionally followed by a unique ID), text (optional description).<\/li>\n
  2. Props: properties that you define.<\/li>\n
  3. Links: each link will specify a type of relationship and a unique identifier of a target node.<\/li>\n<\/ol>\n
    Fig 4: The structure of defining a node.<\/figcaption><\/figure>\n

    To make a link between two nodes, the target node must have a unique identifier, so no other node is mistaken for the target. The unique ID must start with a capital letter but can otherwise be any combination of letters and numbers. Finally, the unique id is added to the type string. E.g. ‘Weng Tonghe; person ||’ may be assigned a unique identifier by adding ‘WenTon’ to the type => ‘Weng Tonghe; personWenTon ||’<\/p>\n

    Commenting and bulk linking<\/h3>\n

    You can write non-processed comments between lines starting with [--<\/code> and ]++<\/code>. To insert a non-processed comment in a single line you can prefix it with \/\/<\/code><\/p>\n

    It is also possible to assign a link to several nodes at a time with ##<\/code>. E.g. ## wrk:orgUN<\/code> will add a link to the United Nations node from all the following lines of nodes till it reaches a blank line or a comment section.<\/p>\n

    Fig 5: Batch linking nodes and commenting.<\/figcaption><\/figure>\n

    Abbreviated syntax<\/h3>\n

    A NetML may optionally be accompanied by a configuration file that specifies how an abbreviated syntax should be expanded while processing.<\/p>\n

    Example of YAML configuration file:<\/p>\n

    props: \n  ww: 'webpage'\n  lo: 'location'\n  tw: 'twitter'\n\nlinks: \n  wrk: 'work_for'\n  col: 'collaborate'\n  key: 'has_tag'\n\ntypes: \n  k: 'keyword'\n  o: 'organisation'\n  b: 'business'\n  p: 'person'\n\t<\/code><\/pre>\n

    With the convention above, the node Ana Smith; person; Manager | web:joesmith.net twitter:joesm1th |<\/code> can be abbreviated to Ana Smith; p; Manager | ww:joesmith.net tw:joesm1th |<\/code><\/p>\n

    Instructions<\/h2>\n
      \n
    1. Create a simple text file and write down information according to the specifications above.<\/li>\n
    2. Go to https:\/\/github.com\/repmax\/netmaker<\/a> and follow the instructions to convert your text file to a network file format.<\/li>\n
    3. Import the network file into your favourite network visualization and analysis software or service.<\/li>\n<\/ol>\n","protected":false},"excerpt":{"rendered":"

      NetML is a network markup language that makes it easy to write down information as a network of nodes with properties and links.<\/p>\n","protected":false},"author":1,"featured_media":708,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":[],"categories":[1],"tags":[15],"_links":{"self":[{"href":"http:\/\/munnecke.net\/wp-json\/wp\/v2\/posts\/608"}],"collection":[{"href":"http:\/\/munnecke.net\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/munnecke.net\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/munnecke.net\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/munnecke.net\/wp-json\/wp\/v2\/comments?post=608"}],"version-history":[{"count":13,"href":"http:\/\/munnecke.net\/wp-json\/wp\/v2\/posts\/608\/revisions"}],"predecessor-version":[{"id":707,"href":"http:\/\/munnecke.net\/wp-json\/wp\/v2\/posts\/608\/revisions\/707"}],"wp:featuredmedia":[{"embeddable":true,"href":"http:\/\/munnecke.net\/wp-json\/wp\/v2\/media\/708"}],"wp:attachment":[{"href":"http:\/\/munnecke.net\/wp-json\/wp\/v2\/media?parent=608"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/munnecke.net\/wp-json\/wp\/v2\/categories?post=608"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/munnecke.net\/wp-json\/wp\/v2\/tags?post=608"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}