Discussion List Archives

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[ddlm-group] Proposal to update dREL, ,part I

  • To: ddlm-group <ddlm-group@iucr.org>
  • Subject: [ddlm-group] Proposal to update dREL, ,part I
  • From: James Hester <jamesrhester@gmail.com>
  • Date: Tue, 28 Aug 2018 12:41:47 +1000
  • DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;h=mime-version:from:date:message-id:subject:to;bh=AoPWN+GTsZLRGofR4oXs3z5q6RH851ckmZhyWhm5AAs=;b=nNnFeLgrRZ9TxvzSfBpN5yFuXNk/Gff+la4tNZ9hjRdjyXVs8fNga/ILEm7aKaRRubxdl3jSkDQaQRV3FVoa2hQ9BCZB3llPK5S/6AAJITIiNQRzSUaPmusXqvXqWVSLe/Lpp7mmaUCTuBNBxi1VGH0QIzDDgH0a6PnuCk0T6HdjWgbiSM4IORK7ojjyNSECdWE20qx1JCASk+mm2neW2tHBKnYTwPQ04EvKsp+2ThL6tqEaabcoQR/Oe4My0CobBSoSzp0NfWURRMXgf4ENwj8jUyk0hvK6KX0yeJcQKFlSambQ1EmxkOWFuQvZ6w3KEjepTMXsDRE0jr55SnYpGw==
Dear DDLm group,

As part of working up dREL for Vol G and expanding it for use in validation contexts, I will be presenting a series of small proposals regarding dREL. The first one below simply clears up a few ambiguities in existing documents.  Please comment if you see any issues.  A marked-up version is available at https://github.com/COMCIFS/dREL/blob/master/drel_changes_1.rst


Proposed changes to dREL, part I


dREL is a machine-actionable language describing data relationships
and designed to be embedded in DDLm dictionaries. The language is
defined both explicitly in the dREL publication [1] and implicitly by
the dREL code appearing in the DDLm core CIF dictionary. Note that
the code in the core CIF dictionary significantly expands the language
presented in the paper, for example, by adding category methods.

The present changes are relatively trivial and intended to simplify
and clarify the syntax. Following proposals will be more substantial.

Proposal 1: underscores

The proposal: A leading underscore in front of a variable is optional,
and has no significance. Its use is deprecated.


The dREL paper states that the value of a data name from a Set
category can be accessed by using the form `<category>.<name>` in a
dREL script, for example `cell.volume` (p 1919, "Data References in
dREL").  However, the dREL methods in the current core CIF dictionary
and the dREL paper almost always use a form with a leading underscore,
i.e. `_<category>.<name>`.


The paper does not explain the appearance of the underscore in the
example methods presented there. It is possible that the underscore is
provided as a way to disambiguate ordinary variables from dictionary
items; however, as a period character must appear in a dictionary
reference, and may not appear in a variable, such disambiguation is
unnecessary.  It is also important to note that the period character
is an operator in dREL, so the construction `cell.volume` is formally
referring to the `volume` column in the current packet of the `cell`
category.  In this context, the leading underscore is potentially

The `with` statement is available to alias category names in any
situation where a category name may collide with a language keyword.

Proposal 2: newline is not significant

The proposal: newline should be treated as ordinary whitespace.


If newline is treated as ordinary whitespace it is not significant for
separating expressions.  However, the dREL paper Appendix, Section 4,
states that "dREL supports the following expression terminators:
... newline closes a line unless a balancing [bracket] is missing",
which may be construed as allowing newline to terminate an expression.


The draft dREL grammar at the COMCIFS/drel repository assumes that
newline is whitespace.  The example parser based on this grammar does
not identify any problems with the grammar.  Nick Spadaccini
has advised me that newline was not meant to be significant in the
dREL grammar.

[1] Spadaccini et. al,
(2012) *J. Chem. Inf. Model.* **52**(8) pp 1917-1925

T +61 (02) 9717 9907
F +61 (02) 9717 3145
M +61 (04) 0249 4148
ddlm-group mailing list

Reply to: [list | sender only]
International Union of Crystallography

Scientific Union Member of the International Science Council (admitted 1947). Member of CODATA, the ISC Committee on Data. Partner with UNESCO, the United Nations Educational, Scientific and Cultural Organization in the International Year of Crystallography 2014.

International Science Council Scientific Freedom Policy

The IUCr observes the basic policy of non-discrimination and affirms the right and freedom of scientists to associate in international scientific activity without regard to such factors as ethnic origin, religion, citizenship, language, political stance, gender, sex or age, in accordance with the Statutes of the International Council for Science.