GFL

Welcome to GFL Website


               
 

GFLML  (GFL Markup Language) DTD

 The language is under construction and it changes about every month. This DTD reflects late September 2003 version. The features which are not implement6ed, such as  queries, rules and graphic extensions are marked in red.

We use names "propertyValue" and "property"    instead of F-Logic terms "attribute" and "signature" just because those terms are more common in specification of ontologies .See real examples of GFLML at:

http://ecoinformatics.uvm.edu/dmaps/ob/eservice-ontology.xml

http://ecoinformatics.uvm.edu/dmaps/ob/demo.gfl

http://ecoinformatics.uvm.edu/dmaps/ob/cluster2.gfl

 

<?xml version="1.0" encoding="UCS-2"?>
<!-- Specification in top down order -->
<!ELEMENT gflml (ontology,(layout)?,(parameters)?)>

<!--this will change to something like->

<!ELEMENT gflml ((query|ontology), (graphicMaps)?, (layout)?,(parameters)?)>
<!ATTLIST gflml version CDATA #REQUIRED>
 

<!-- Ontology is the top element that specify logical relations -->
<!ELEMENT ontology ((class)+,(instance)*,
(rule)*,(module)*)>

 <!ATTLIST ontology
                 ID CDATA #IMPLIED
                 name CDATA #IMPLIED>

<!-- Elements of ontology -->
<!ELEMENT instance ((isSameAs)?,(instanceOf)?,(propertyValue)*)>
<!ATTLIST instance
            ID ID #REQUIRED
            name CDATA #REQUIRED
            variable CDATA #REQUIRED>

<!ELEMENT class ((subclassOf)?,(constraint)?,(isSameAs)?,(instanceOf)?,(property)*,(propertyValue)*,(constraint)?)>
<!ATTLIST class
            ID ID #REQUIRED
            name CDATA #REQUIRED
            variable CDATA #REQUIRED>


<!ELEMENT module ((class)*,(instance)*,
(rule)*,(module)*)>
<!ATTLIST module
             ID ID #REQUIRED
             name CDATA #REQUIRED>

 

<!--specification of non implemented things. first rules, then graphic extensions-->

 

<!--RULES.  -->

 

<!ELEMENT rule (define , conditions, (match)+)>

<!--The specification of the variable matching in the body and in the head can be done -->

<!--via elements isSameAs from classes, instances of the head, alternatively it can be done via special element match-->

<!ELEMENT  match  EMPTY>

<!ATTLIST match

              IDSRC IDREF #REQUIRED

              IDTRG IDREF #REQUIRED>

 

<!--HEAD and BODY that is "define" and "conditions" elements We may need to say that there must be one either class or instance in rule body and head. But the following preliminary declaration   are simplified-->

<!ELEMENT  define  ((class)*,(instance)*) >

 

<!--here is a simple specification of rule body -sufficient for most of the problems. Here AND is a default connective--->

<!ELEMENT  conditions ((class)*,(instance)*, (not)*)>

<!--in this  simple case NOT is declared as follows-->

<!ELEMENT  not ((class)*,(instance)*, (not)*)>

 

<!--I do not know if we need this much of expressive power, but here is alternative, more complex declaration which can use all connectives. Here we can use either simple or tree structured description of rule body--the issue is described at  http://ecoinformatics.uvm.edu/dmaps/tut31.html --->

<!ELEMENT  conditions (((class)*,(instance)*, (not)*| ((and)*| (or)*|(not)*)))>

<!--plain tree structure made of and , or, not nodes. Constraints on cardinality are still wanted-->

<!ELEMENT  and (((class)*,(instance)*, (not)*| ((and)*| (or)*|(not)*)))>

<!ELEMENT  or (((class)*,(instance)*, (not)*| ((and)*| (or)*|(not)*)))>

<!ELEMENT  not (((class)*,(instance)*, (not)*| ((and)*| (or)*|(not)*)))>


<!--QUERY- not to different from rules-->

<!ELEMENT  query  ((class)*,(instance)*,(not)*) >

 

 

 

<!--GRAPHIC MAPS-->

<!ELEMENT graphicMaps ((propertyMap)*,(propertyValueMap)*, (objectMap)*)>

<!--propertyMap and propertyValueMap allow to paint attributes and signatures as simple arrows  http://ecoinformatics.uvm.edu/dmaps/tut43.html-->

<!ELEMENT propertyMap EMPTY >

<!ATTLIST  propertyMap

                            name       CDDATA #REQUIRED

                            color       CDDATA #REQUIRED

                            shape      CDDATA #REQUIRED  

                            direction  CDDATA #REQUIRED

                            bulletStyle  CDDATA #REQUIRED>  

 

          

<!ELEMENT  propertyValueMap EMPTY >

<!ATTLIST  propertyValueMap

                            name       CDDATA #REQUIRED

                            color       CDDATA #REQUIRED

                            shape      CDDATA #REQUIRED  

                            direction  CDDATA #REQUIRED

                            bulletStyle  CDDATA #REQUIRED>

<!--objectMap allows to introduce simplified icons for complex objects,

This is the main innovation of GFL see

http://ecoinformatics.uvm.edu/dmaps/tut41.html

http://ecoinformatics.uvm.edu/dmaps/tut42.html-->

<!--How to consistently map variables, ie how to say that math element connects instance and class from head and body of the rule??  -->

<!--the default /main from and too arrows should be demarcated-->

<!--it should be clear from the final specification how to derive a dialog box for a class. -->

<!ELEMENT objectMap   (symbol, (relationMap)+)    >

<!ATTLIST objectMap   

                                ID      ID            #REQUIRED

                                name CDDATA #REQURED >

 <!ELEMENT symbol  (  className, (icon | (color, shape, decoration, decorationColor))) >

 

 

<!ELEMENT  relationMap (relationName,  arrow)    >

 

 

<!ELEMENT  arrow EMPTY>

<!--instance should be referred by name--->

<!ATTLIST  arrow

                            color         CDDATA #REQUIRED

                            type          CDDATA #REQUIRED  

                            style          CDDATA #REQUIRED

                            tile            CDDATA #REQUIRED

                           direction    CDDATA #REQUIRED  >


<!--  Elements related to instance and class elements -->
<!ELEMENT subclassOf (resource)>
<!ATTLIST subclassOf ID ID #REQUIRED>

<!ELEMENT isIntersectionOf (resource)+>
<!ATTLIST isIntersectionOf ID ID #REQUIRED>

<!ELEMENT isOneOf (resource)+>
<!ATTLIST isOneOf ID ID #REQUIRED>

<!ELEMENT isSameAs (resource)>
<!ATTLIST isSameAs ID ID #REQUIRED>

<!ELEMENT instanceOf (resource)>
<!ATTLIST instanceOf ID ID #REQUIRED>

<!ELEMENT value EMPTY>
<!ATTLIST value ID IDREF #REQUIRED>


<!ELEMENT propertyValue (value)>
<!ATTLIST propertyValue
              ID ID #REQUIRED
              name CDATA #REQUIRED
              variable CDATA #REQUIRED
              inheritable CDATA #REQUIRED
              multi CDATA #REQUIRED>


<!ELEMENT isDisjointWith (resource)>
<!ATTLIST isDisjointWith ID ID #REQUIRED>


<!ELEMENT isDisjointUnionOf (resource)+>
<!ATTLIST isDisjointUnionOf ID ID #REQUIRED>


<!ELEMENT resource EMPTY>
<!ATTLIST resource ID IDREF #REQUIRED>

<!ELEMENT isUnionOf (resource)+>
<!ATTLIST isUnionOf ID ID #REQUIRED>

<!ELEMENT valueType EMPTY>
<!ATTLIST valueType ID IDREF #REQUIRED>

<!ELEMENT property (valueType)>
<!ATTLIST property
          ID ID #REQUIRED
          name CDATA #REQUIRED
          variable CDATA #REQUIRED
          inheritable CDATA #REQUIRED 
          multi CDATA #REQUIRED
          minCardinality CDATA #REQUIRED
          maxCardinality CDATA #REQUIRED>




<!ELEMENT constraint ((isIntersectionOf)?,(isOneOf)?,(isDisjointWith)?,(isDisjointUnionOf)?,(isUnionOf)?)>
<!--each constraint will be associated with a set of rules declared in a specific module->

<!--so that inference engine can know how to validate this constraint->

<!ATTLIST constraint
          moduleID CDATA #REQUIRED>

 

<!ELEMENT layout ((node)+,(cluster)+)>

<!ELEMENT parameters (param)+>

<!--elements of layout. nodes are objects and relations- whatever they are. clusters are modules rules, and fragmentsof rules and object maps-->
<!ELEMENT node EMPTY>
<!ATTLIST node
            ID IDREF #REQUIRED
            x CDATA #REQUIRED
            y CDATA #REQUIRED
            visible CDATA #REQUIRED>

<!ELEMENT cluster EMPTY>
<!ATTLIST cluster
             ID IDREF #REQUIRED
             x CDATA #REQUIRED
             y CDATA #REQUIRED
             toprightX CDATA #REQUIRED
             toprightY CDATA #REQUIRED
             visible CDATA #REQUIRED>


<!ELEMENT param EMPTY>
<!ATTLIST param
name CDATA #REQUIRED
value CDATA #REQUIRED>

 

 

 See real examples of GFLML at

http://ecoinformatics.uvm.edu/dmaps/ob/eservice-ontology.xml

http://ecoinformatics.uvm.edu/dmaps/ob/demo.gfl

http://ecoinformatics.uvm.edu/dmaps/ob/cluster2.gfl

 

 


 Send your comments to skrivov@uvm.edu