This is a basic demo about how to use and compile multiple packages into the same knowledge base. The basic scenario is described [here|Doc Package#Using multiple Packages for the same knowledge base or ontology]. The common package {{lifeExpectancy}} and more specifics for this demo are described [here|Multi-Package Demo].
\\
\\
To see the source code of this page, go to the drop down "''More...''" and select "''View Page Source''".


!Defining the package

As mentioned, we add this page to the package {{germany}}

%%Package germany


!Adding knowledge

First we define the current life expectancy in germany using the {{~%~%Constant}} markup.

%%Constant 
"Life expectancy in Germany" = 79.85
%

Let's calculate our remaining life expectancy based on our age using the {{~%~%Variable}} markup.

%%Variable
"Years to life according to life expectancy" = "Life expectancy in Germany" - Age
%


!Compiling and testing the resulting knowledge base

Here we define a knowledge base using/compiling our two of our three packages:

%%KnowledgeBase 
Life expectancy calculator (germany)

@uses: lifeExpectancy
@uses: germany
%


!Quick Interview

If not specified otherwise (by using the @package annotation), the {{ ~%~%QuickInterview }} markup will show the content of the first knowledge base, which uses/compiles the package of this page, in this case package {{germany}}.

%%QuickInterview 
  
%