This tutorial covers the steps needed to giving HUGIN model a user friendly interface and deploying it online.
Using the HUGIN tool to interact with the model requires knowledge of the technology and experience with the tool. This may be a confusing experience for users with no knowledge on Bayesian networks or the specific domain of the model - and because ''excessive´´ information is presented on the screen. An example of this confusing scenario can be seen Figure 1 where a simple Bayesian model for the tracing of food contamination has been loaded in the HUGIN tool. This is the model the Simple Bio Tracability Example - check out the example for more information on the workings of the model.
To reduce the requirements on the user and to ease user interaction with the model, it may be better to deploy the model on a web page.
The HUGIN Web Solution allows the knowledge engineer to deploy a model as a web form such that the user can interact with the model through the web interface shown above. The deployment of a model as a web form on a web page requires a number of easy steps to be performed:
Using the HUGIN BIOTRACER tool, the model is constructed. In brief this procedure covers defining variables, dependencies and parameters.
The next step is to design the web form which will act as the interface to the model when embedded on the web page. The web form designer is activated by clicking on the 'Web Form' button (see Figure 3).
The web form is designed by adding labels to provide feedback and fields for entering input. The labels and fields are tied to specific variables in the model. The web form designer can be seen in Figure 4.
Once the web form has been designed the model is ready to be uploaded to the HUGIN BIOTRACER Web Solution model repository. This is done by connecting to the Web Solution by clicking on the connect button (see Figure 5).
A connection dialog appears where one should specify the url for a HUGIN BIOTRACER Web Solution server (default url biotracer.hugin.com is pre-entered). See Figure 6.
Once connected, the user must identify himself to the system using user name and password (see Figure 7).
Brose to a folder, right click and select the option 'Upload from Hugin' (see Figure 8).
In the next dialog that appears one must choose from the models currently loaded in the HUGIN BIOTRACER tool and specify a log message (see Figure 9).
The model is now online and running in the Web Solution server!
The final step is to publish the model on the web page. To do this one must embed some code that tell the browser to load the HUGIN applet and parameters for the applet specifying which model to display. This block of code can be generated after uploading a model by right clicking the model and selecting 'Generate HTML' (see Figure 10).
This generates a sample html-file which contains the relevant code for embedding the applet on a web page. The code can be copy-pasted to the web page source. Figure 11 displayes the important portions of the generated code.