***************************************************************************

program information ( directory: AMIS2)
by: Keiko Hasegawa

***************************************************************************
  1. Purpose
        This directory contains all programs and data files for AMIS medical scenario.
    

  2. Files and Functions
    	README.AMIS2.html	program information file (this file)
    	TAOML			*.taoml and *.tpl files
    	source			source directory to make secm.cgi.
    

  3. How to make secm.cgi

    a. go to "source" directory

    b. run IC Compiler

    	../../IC_Compiler/icc ic.dat
    

    c. compile the program

    	make -f Makefile.secmcgi  
    	(NOTE: Because the LAMSTAR functions are contained
    		in ~jung/private/lamstar/lamunx/lam.c, you need to eliminate
    		lam.o when you change them.)
    

  4. How to run the test program
    a. start server(the same server as AMIS) on TAO
    	server 
    

    b. execute program through WWW(client)

    	You can copy medical.tpl as index.html.
    You need the following files:

    nsto* (nsto, nstocrr,..) userprofile

    c. kill the server

    	kill -9 (process number) 
    

    d. remove RPC number

    	rpcinfo -d 805306368 1 
    

  5. LAMSTAR interface
    	There are three LAMSTAR functions. They are as follows.
    
    	findDiagno
    		To perform diagnosis. Called from diag_exe.c
    	
    	saveInput
    		To save a data set into the training data file.
    		Called from diag_save.c
    	
    	acceptDiag
    		To accept the diagnosis result as training data.
    		Called from diag_accept.c
     
    	
    	These three functions have similar function interface.
    
    	function_name(char* pname, float Input[][MAXEI], int* decision,
    			int* action)
    		pname	problem name
    		Input	input data set
    			Each row contains one category.
    			The first element of each row is a category number.
    			If this category number is zero, that means the end
    			of the data set.
    		decision the decision provided by LAMSTAR.(currently dummy)
    		action	the action suggested by LAMSTAR. (currently dummy)
    
    	(NOTE: diag_exe.c, diag_save.c and diag_accept.c are
    		action functions for IC Manager, and they are under
    		"source" directory.)
    

  6. Internal files
    	There are four internal files for AMIS2. They are created at
    	running time.
    
    	problem		contains the specified problem name.
    	result		contains diagnosis result.
    	diag_result.par	contains parameters for TAO interpreter.
    	diagnosis.par	contains parameters for TAO interpreter.
    
    	When the problem form is opened and the name of the problem is
    	specified by the user, this name will be put into "problem" file
    	and passed to the diagnosis data form.
    
    	The diagnosis data form uses this name to invoke LAMSTAR.
    
    	After LAMSTAR is called to perform diagnosis, the result values
    	are stored into "result" file and "diag_result.par" file.
    	"diag_result.par" file is read by the TAO interpreter to fill in
    	the diagnosis result form, then it is automatically deleted.
    	"result" file is read by diag_accept.c and diag_rediagnose.c.