K  n  o  w  L  a  n  g
Framework for Knowledge Representation and Reasoning for Self-Adaptive Systems


U s e r    G u i d e

Home
Running KnowLang
Knowledge Model
Concepts
Objects
States
Metrics
Self-Adaptive Behavior
Goals
Situations
Policies
Reasoner
Contact Info
Description

Concepts are used to specify the basic terminology in KnowLang. Concepts are organized in special concept trees that semantically group related concepts. Every concept tree has a root concept and concepts may have parents and children connecting that concept in a concept tree. A concept descends from its parents and acts as a parent concept to its children. KnowLang defines two types of concepts:concepts and explicit concepts.

A concept must be specified with its properties and functions. Properties are specified with the PROP keyword and have a type specified as a concept in the KB. Any concept could be used to define a property in KnowLang. Functions are specified with the FUNC keyword and also have a type specified as an ACTION concept in the KB. Only KnowLang ACTION concepts may be used to define a function in KnowLang.

A concept may also be specified with intrinsic the STATES property. A STATE is specified as a Boolean expression and it is uniquely specified for the concept it belongs to. A state’s expression may involve properties, functions, states, entire concepts, and objects specified in the KB. Any property, function, or state is specified with a unique identifier that is used when specifying Boolean expressions.

Example
CONCEPT Route {
  PARENTS {eMobility.eCars.CONCEPT_TREES.Phenomenon}
  CHILDREN {}
  PROPS {
    PROP locationA {TYPE {eMobility.eCars.CONCEPT_TREES.Location} CARDINALITY {1}}
    PROP locationB {TYPE {eMobility.eCars.CONCEPT_TREES.Location} CARDINALITY {1}}
    PROP intermediateStops {TYPE {eMobility.eCars.CONCEPT_TREES.Location} CARDINALITY {*}}
    PROP currentRoad {TYPE {eMobility.eCars.CONCEPT_TREES.Road} CARDINALITY {1}}
    PROP alternativeRoads {TYPE {eMobility.eCars.CONCEPT_TREES.Road} CARDINALITY {*}}
  }
  FUNCS {
    FUNC getCurrentLocation {TYPE {eMobility.eCars.CONCEPT_TREES.GetCurrentLocation}}
    FUNC takeAlternativeRoad {TYPE {eMobility.eCars.CONCEPT_TREES.TakeAlternativeRoad}}
    FUNC recomputeRoads {TYPE {eMobility.eCars.CONCEPT_TREES.RecomputeRoads}}
  }
  STATES {
    STATE AtBeginning {eMobility.eCars.CONCEPT_TREES.Route.FUNCS.getCurrentLocation =
      eMobility.eCars.CONCEPT_TREES.Route.PROPS.locationA}
    STATE AtEnd {eMobility.eCars.CONCEPT_TREES.Route.FUNCS.getCurrentLocation =
      eMobility.eCars.CONCEPT_TREES.Route.PROPS.locationB}
    STATE OnRoute { NOT eMobility.eCars.CONCEPT_TREES.Route.STATES.AtBeginning AND
      NOT eMobility.eCars.CONCEPT_TREES.Route.STATES.AtEnd}
    STATE InHighTraffic {eMobility.eCars.CONCEPT_TREES.Route.PROPS.currentRoad.STATES.InHighTraffic}
    STATE InLowTraffic {eMobility.eCars.CONCEPT_TREES.Route.PROPS.currentRoad.STATES.InFluentTraffic}
  }
}

top
User Guide Curator - Emil Vassev
Last modified on January 28, 2014