alm

XML Gender Description

XML Gender Description (XGD) is an application of the W3C XML stack to represent human gender identity and sexuality.

XML Namespaces

XGD uses the XML namespace https://www.alm.website/misc/specs/xgd (the URI of this document), usually with the abbreviation gd.

XML Schema

XGD has an XML schema which may be found at https://www.alm.website/misc/specs/xgd.xsd.

Elements

The root XGD element is gd:gender, which represents an entire person’s gender and sexual identity. It contains two child elements: gd:identity, which represents the personal identification, and gd:attractions, which represents the person’s attractions to others.

gd:state represents an abstract gender-state. The most stereotypical gender-states are “male” and “female”. It has zero or more child elements, each a gd:aspect. A gd:aspect has two attributes, gd:name and gd:intensity. gd:name is a string , while gd:intensity is a decimal number between 0.0 and 1.0. It may also contain a gd:variance. gd:variance represents the properties of a gd:aspect’s variation from the given value. It has three attributes, gd:plus, which is the amount the gd:aspect may increase by, gd:minus, which is the amount it may decrease by, and gd:rate, which is the typical rate of change per day as an absolute value.

gd:identity represents a person’s gender identification. It contains several elements, each of which is a gd:state (under a different name). These are gd:psych, which represents the internal psychological identity, gd:visible, which represents the chosen external presentation, and gd:physical, which represents the relevant biological traits. gd:physical may also contain one or more gd:genetic elements, which contain a representation of a set of sex chromosomes, such as XX, XY, or XXY.

gd:attraction represents a person’s attractions to other people based on their gd:identity. It consists of an ordered sequence of gd:rule elements, each of which has the attributes gd:path, which contains an XPath expression relative to a gd:identity element, and gd:effect, which contains either a + character or a - character. gd:rule contains a label, which identifies the type of attraction. A + gd:effect indicates that the given attraction is applied, while a - gd:effect indicates that the attraction is removed if present. A rule’s affect is evaluated if the gd:path matches.

Examples

The following is an example representing the stereotypical “heterosexual male” identity.

<?xml version="1.0" ?>

<gd:gender xmlns:gd="https://www.alm.website/misc/specs/xgd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="https://www.alm.website/misc/specs/xgd https://www.alm.website/misc/specs/xgd.xsd">
  <gd:identity>
    <gd:psych>
      <gd:aspect name="male" intensity="1.0" />
    </gd:psych>
    <gd:visible>
      <gd:aspect name="male" intensity="1.0" />
    </gd:visible>
    <gd:physical>
      <gd:aspect name="male" intensity="1.0" />
      <gd:genetic>XY</gd:genetic>
    </gd:physical>
  </gd:identity>
  <gd:attraction>
    <gd:rule path="/gd:psych/gd:aspect[@gd:name='female']" effect="+">romantic</gd:rule>
    <gd:rule path="/gd:visible/gd:aspect[@gd:name='female']" effect="+">aesthetic</gd:rule>
    <gd:rule path="/gd:physical/gd:aspect[@gd:name='female']" effect="+">sexual</gd:rule>
  </gd:attraction>
</gd:gender>

The following is an example representing an agender, asexual, aromantic, neuter, genetically-mixed identity.

<?xml version="1.0" ?>

<gd:gender xmlns:gd="https://www.alm.website/misc/specs/xgd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="https://www.alm.website/misc/specs/xgd https://www.alm.website/misc/specs/xgd.xsd">
  <gd:identity>
    <gd:psych />
    <gd:visible />
    <gd:physical>
      <gd:genetic>XX</gd:genetic>
      <gd:genetic>XY</gd:genetic>
    </gd:physical>
  </gd:identity>
  <gd:attraction />
</gd:gender>