INTELLIGENT USER ASSISTANCE FACILITY

Abstract: A general event composing and monitoring system that allows high-level events to be created from combinations of low-level events. An event specification tool allows for rapid development of a general event processor that creates high-level events from combinations of user actions. The event system, in combination with a reasoning system, is able to monitor and perform inference about several classes of events for a variety of purposes. The various classes of events include the current context, the state of key data structures in a program, general sequences of user inputs, including actions with a mouse-controlled cursor while interacting with a graphical user interface, words typed in free-text queries for assistance, visual information about users, such as gaze and gesture information, and speech information. Additionally, a method is provided for building an intelligent user interface system by constructing a reasoning model to compute the probability of alternative user's intentions, goals, or informational needs through analysis of information about a user's actions, program state, and words. The intelligent user interface system monitors user interaction with a software application and applies probabilistic reasoning to sense that the user may need assistance in using a particular feature or to accomplish a specific task. The intelligent user interface also accepts a free-text query from the user asking for help and combines the inference analysis of user actions and program state with an inference analysis of the free-text query. The inference system accesses a rich, updatable user profile system to continually check for competencies and changes assistance that is given based on user competence.

Description: Description INTELLIGENT USER ASSISTANCE FACILITY Technical Field This invention relates to expert systems in data processing. In particular, this invention relates to a system and method for automated machine reasoning to provide assistance to software users and to optimize the functionality of computer systems and software by performing inference about users needs and preferences in the operation of software systems or applications. Background of the Invention Although significant advances in graphical user interfaces have made software applications more accessible and productive for personal computer users, the increased ease of use has fostered a demand to include more and more sophisticated features. When first exposed to a complicated software application, a new user can be confused by die overwhelming number and complexity of features accessible through the menus and toolbars of the user interface. It is not uncommon for a user unfamiliar with the software features to resort to menu surfing, rapidly switching from menu item to menu item, in the hope of discovering how to effect the desired feature. Even when users know one or more ways to perform a task in a software application, they may not realize an efficient approach. Also, user's may know how to perform tasks, yet instead of performing the task themselves, they would rather have a system proactively determine their needs and perform or offer to perform operations, such as launching applications that will soon be needed, exiting applications, and prefetching files or information from distant servers to make them available more efficiently when they are requested. Determining in an automated manner the best actions to perform or the best information to provide users while they work with software requires the development of computational methods that operate in conjunction with software programs and that have the ability to identify a user's needs, intentions, or goals from aspects of a user's background and actions. Such methods may be derived from the construction and use of models that explicitly links the users' needs to their backgrounds and actions. There have been several studies of the use of models for reasoning about the intentions of people performing a variety of tasks, and for making available advice or assistance based on these models. Researchers studying d e use of computers in education have attempted to construct programs that use models of users to determine the source of misunderstanding and me best way to tutor a student. These models can look at the answers users give to questions and other challenges. The Strategic Computing Initiative of the 1980s focused in part on methods for doing reasoning about a pilot's intentions from a diverse set of inputs, and for providing diem with the best assistance witii piloting and warfighting witfi fighter jets. Within the many such "pilot associates" projects, engineers attempted to design systems that could reason about die intentions of users. Typically, rule-based or logical approaches were used for determining or prioritizing options. There has also been some work in die use of probabilistic models in me modeling of user's needs for such tasks as monitoring complex, time-critical applications. Some of the earliest discussion of probabilistic dependency models, with applications to enhancing the display of information, were in projects experimenting with the modeling of users for controlling die information displayed to aircraft pilots. Probabilistic inference was explored as a means for controlling the information being displayed to pilots. Other work included using decision-theoretic metiiods to reason about the most important information to display to flight engineers at NASA Mission Control Center. The methods consider context, user expertise level, and telemetry from the Space Shuttle to make these decisions, and take advantage of time-criticality and probabilistic models of user beliefs and intentions. Other related work has explored the best kind of information and explanations to display to pilots given various tradeoffs in display. In otiier work, researchers have explored the use of probabilistic models in assisting computer users working with command line input systems of a computer operating system. There have been several projects focusing on me use of sets of logical rules and heuristics based on logical rules for providing users with assistance based on die context and activity. For instance, the common context-sensitive help that is made available in applications written for me Microsoft Windows operating system is accessed by selecting a graphical object and clicking a standard help command (e.g., a function key on the keyboard). Help information is men provided which describes die functionality of the graphical object such a toolbar. Anotiier example is the Tip Wizard system in Microsoft Excel products which employs a large set of logical rules that continue to scan for sequences of user events and provide assistance to users on performing tasks more efficiently. In work at Apple Computer described by U.S. Patent No. 5,390,281 to Luciw et al., sets of rules are used for providing assistance to users on tasks by employing the heuristic of comparing the number of conditions for a rule to fire witii the specific number of conditions mat are seen in a particular situation and for interpreting tiiis fraction as a strength associated with die action indicated by die rule. There has also been work on more sophisticated probabilistic models mat consider die uncertainty in user goals and needs for software assistance. The Answer Wizard feature of Microsoft Office products on die use of probabilistic models for interpreting me words in a user's free-text query witii a focus on assisting users with using computer software applications. In tiiis work, the uncertain relationship between sets of related words mat might be seen in a query and various kinds of assistance are modeled with probability. This work has been described in U.S. Patent Application No. 08400797. However, none of tiiese former efforts have employed sophisticated metiiods for reasoning under uncertainty about a user's needs for assistance by considering multiple pieces of evidence, including information about a user's background and a user's activities that are autonomously sensed by me program, and, tiien, have offered to provide relevant assistance to a user based on tiiis reasoning. Nor have these systems considered monitoring user interaction with a software program so that, when a user does inquire about help directly with free-text queries, die system combines the analysis of the words in the free-text query with the ongoing analysis of user actions and program context. What is desirable is an intelligent user assistance facility that autonomously senses that the user may need assistance in using a particular feature or to accomplish a specific task, and tiiat offers to provide relevant assistance based upon considering multiple pieces of evidence, including information about a user's background and a user's activities. What is also desirable is an intelligent user assistance facility that combines the analysis of the words in die free-text query with the ongoing analysis of user actions and program context whenever a user asks directly for help with free-text queries. This invention solves the problem of autonomously sensing that a user may need assistance in using a particular feature or to accomplish a specific task, and offering to provide relevant assistance based upon considering multiple pieces of evidence, including information about a user's background and a user's activities. This invention also solves the problem of combining the analysis of the words in die free-text query with the ongoing analysis of user actions and program context whenever a user asks directly for help with free-text queries. In addition, the invention is able to monitor and perform inference about several classes of events, including the state of key data structures in a program, general sequences of user inputs with a mouse-controlled cursor in die normal course of interacting with a graphical user interface, words typed in free-text queries for assistance, visual information about users, such as gaze and gesture information, and speech information. Summary of Invention The present invention provides a method of building an intelligent user assistance facility for a software program to assist a user in operation of the software program. Functionality of the software program is identified for providing intelligent user assistance. A reasoning model is constructed for die identified program functionality for die task of providing intelligent user assistance. The reasoning model computes the probability of alternative user's intentions, goals, or informational needs through analysis of information about a user's actions, program state, and words. Modeled events for die identified program functionality are defined for use by die reasoning model to provide intelligent user assistance. Atomic user interface interactions are identified that signify the occurrence of modeled events. The present invention also includes a general event composing and monitoring system that allows high-level events to be created from combinations of low-level events. The event system, in combination with a reasoning system, is able to monitor and perform inference about several classes of events for a variety of purposes. The various classes of events include die state of key data structures in a program, general sequences of user inputs with a mouse-controlled cursor in the normal course of interacting witii a graphical user interface, words typed in free-text queries for assistance, visual information about users, such as gaze and gesture information, and speech information. The present invention additionally provides a system and method to monitor user interaction with a software program and to apply probabilistic reasoning to sense that the user may need assistance in using a particular feature or to accomplish a specific task. The system continues to examine a user's actions and, from this information, generates probabilities about user needs and goals. In an exemplary embodiment, die likelihoods tiiat various text-based help topics or demonstrations of various software tasks are relevant are computed and me assistance is made available to users. Probabilities are computed about relevant help topics as well as about the probability that a user would desire help. In tiiis embodiment, the invention computes the probabilities that a user needs alternate forms of help, and uses tiiis information to prioritize a list of help topics, when help is requested. When help has not been requested, the system uses its inference to determine when a user might desire assistance, and comes forward autonomously, depending on the computed importance of coming forward and die level at which a user sets a threshold. Whenever a user asks directly for help witii free-text queries, this embodiment combines the analysis of die words in e free-text query with the ongoing analysis of user actions and program context. The invention includes a rich, updatable user profiling system. In the help-topic embodiment, die inference system accesses the user profile system to continually check for competencies and changes assistance tiiat is given based on user competence. The present invention also includes a novel inference system with an annotated Bayesian network to include special temporal reasoning procedures. Temporal reasoning mechanisms are used to consider die changes in relevance of events with current needs and goals of users with time passing after an event has occurred. The inference engine includes a new specific approximation procedure which uses a single explicit Bayesian network knowledge base, but changes die likelihood information in the network based on die distance in die past that an observation was made. The system also allows users to control the tiiresholds that must be reached before users are offered assistance, allowing them to tailor the system's behavior to their own personal preference about being distracted with assistance. Finally, die methods have been integrated with multiple graphical user interfaces, including a social-user interface in the form of an animated character. Brief Description of the Drawings Figure 1 is a block diagram of a computer system. Figure 2 is a flowchart for building an intelligent user assistance facility for a software program. Figure 3 is a diagram illustrating a simple two variable Bayesian network. Figure 4 is a block diagram of an Intelligent User Assistance Facility. Figure 5 is a block diagram of an instrumented application program. Figure 6 is a block diagram of an instrumented spreadsheet application program for use with the Intelligent User Assistance Facility. Figure 7 is a block diagram of an Event Processor. Figure 8 is a block diagram of an Event System Specification Tool for creating a modeled event composer. Figure 9 is a block diagram of a User Profile System. Figure 10 is a flowchart of die Event Status Update Routine of die User Profile System of Figure 9. Figure 1 1 is a flowchart of the User Profile Access Routine of the User Profile System of Figure 9. Figure 12 is a flowchart of the Customized Tutorial Routine of the User Profile System of Figure 9. Figure 13 is a block diagram of the Inference System of the present invention. Figure 14 is a Bayesian network diagram illustrating die overall influence relationship for any software program using the IUAF of die present invention to provide user assistance. Figure 15 is a diagram illustrating a portion of a Bayesian network representing some probabilistic dependencies over time. Figure 16 is a flowchart of the value-of-information procedure according to die principles of the invention for acquiring user information. Figures 17 - 22 illustrate screen outputs of die IUAF made in accordance witii the principles of the present invention in an exemplary embodiment of a spreadsheet application. Figure 23 illustrates screen output of die IUAF according to the principles of die present invention in an exemplary embodiment of a spreadsheet application for displaying a summary of a custom-tailored tutorial. Figure 24 is a portion of a Bayesian network for IUAF made in accordance witii the principles of die present invention. Figure 25 is a portion of a Bayesian network for a spreadsheet application illustrating modeled and profiled events for charting data of a spreadsheet. Figure 26 is a Bayesian network annotated with temporal dynamics information made in accordance witii the principles of the present invention in an exemplary embodiment of a spreadsheet application. Figures 27 is a portion of a Bayesian network illustrating a model in accordance witii d e principles of the present invention for assisting with exiting in a multiple application setting. Figures 28 - 30 is a portion of a Bayesian network illustrating reasoning for assisting with exiting in a multiple application setting. Figure 31 is a diagram illustrating the control modes of d e IUAF Controller. Figure 32 is a method according to me present invention for combining inference analysis of user actions and program state with inference analysis of free-text query. Figure 33 is a flowchart of the autonomous assistance procedure of die present invention. Figure 34 is an illustration of a social interface providing intelligent user assistance for a spreadsheet program. Figure 35 is a block diagram of the IUAF with speech recognition system showing use of inference results to enhance speech recognition. Detailed Description of d e Invention The present invention provides a general event composing and monitoring system that allows high-level events to be created from combinations of low-level events. The event system, in combination witii a reasoning system, is able to monitor and perform inference about several classes of events for a variety of purposes. The various classes of events include die state of key data structures in a program, general sequences of user inputs with a mouse-controlled cursor in d e normal course of interacting witii a graphical user interface, words typed in free-text queries for assistance, visual information about users, such as gaze and gesture information, and speech information. The present invention also employs a novel event specification tool that allows fcr rapid development of a general event processor that creates high- level events from combinations of user actions. The present invention also includes a novel inference system with an annotated Bayesian network to include special temporal reasoning procedures. The inference engine includes a new specific approximation procedure which uses a single explicit Bayesian network knowledge base, but changes the likelihood information in the network based on the distance in the past mat an observation was made. The knowledge base includes special annotations with temporal dynamics information and die inference engine includes special procedures to handle changes in relevance witii the passing of time. The present invention also provides an intelligent user assistance facility and method for use of probabilistic and logical reasoning to make decisions about die best way to provide assistance to a computer software user. The present invention additionally provides a metiiod of building an intelligent user assistance facility by constructing a reasoning model to compute the probability of a user's intentions, goals, or informational needs d rough analysis of information about a user's actions, program state, and words. An exemplary embodiment of the present invention monitors user interaction with a software application and applies probabilistic reasoning to sense tiiat d e user may need assistance in using a particular feature or to accomplish a specific task. This embodiment of the present invention additionally accepts a free-text query from die user asking for help and combines the inference analysis of user actions and program state witii an inference analysis of the free-text query. This embodiment of the present invention also incorporates a novel user profile system that stores information about die competence of users that may be established initially by user input or dialogue with the user and tiiat is updated with die results of ongoing user activity. This persistent user profile provides user competency information during inference analysis and further enables customization of tutorial information for the user after an application session concludes. Furthermore, tiiis embodiment includes automated assistance reasoning to determine when a user might want help, and comes forward autonomously, depending on d e computed importance of coming forward and die level at which a user sets a threshold. When a user does inquire about help directly with free-text queries, die system also combines die analysis of d e words in d e free-text query with the ongoing analysis of user actions. Figure I is a block diagram of a computer system 10 mat is suitable for practicing an exemplary embodiment of the present invention. Those skilled in the art will appreciate that die computer of system 10 depicted in Figure 1 is intended to be merely illustrative and that die present invention may be practiced witii other computer system configurations, including distributed systems and multiprocessor systems, and handheld devices. The computer system 10 includes a processor 12 and an input/output system 14. The input devices may be. for example, a camera 15, a keyboard 16, a mouse 18, a microphone 20, a pointing device or other input device. The output devices may be, for example, a display screen 22, a printer 24, a speaker 26 or other output device. The computer system 10 may include a speech interface 27 tiiat interfaces a speech system with die microphone 20 and speaker 26. The computer system 10 may include a visual recognition and tracking interface 29 tiiat interfaces a visual recognition and tracking system with die camera 15 or otiier specialized head gear witii an infrared reflector or 3D ultrasound sensors. The computer system 10 may also include a network interface 28 that interfaces the computer with a network 30 that may be either a local area network or a wide area network such as die Internet. The computer system additionally includes a system memory 32 and persistent storage 34 tiiat contain application programs and die intelligent user assistance facility. The persistent storage may be a diskette, CDROM, hard-drive, or firmware. The computer system 10 includes an operating system 36 and several application programs such as a spreadsheet application program 38, a word processing application program 40, or otiier application program 42. A system bus 44 interconnects the processor 12 , system memory 32, persistent storage 34, and input/output system 14. Those skilled in die art will appreciate that the intelligent user assistance facility may be integrated directly into die application programs or may be a stand alone facility tiiat is part of a system library or operating system. Overview of the Intelligent User Assistance Facility (TUAF Although software usability studies can pinpoint user interface problems for accessing complex features and can simplify and make the user interface more intuitive for accessing die features, improvements to the user interface cannot hide die multitude of complex features or simplify d e functionality of a complex feature for me inexperienced user witiiout reducing me number of features exposed dirough the interface and/or exposing only simplified versions of the full feature. One by-product of software program usability studies can be die identification of user behavior when a user experiences difficulties in using basic functionality of a particular software program. This invention provides a process for making an intelligent user assistance facility for a particular software program by observing and understanding user behavior when a user experiences such difficulties or when a user might benefit by providing automated actions Figure 2 is a flowchart of d e method for making an intelligent user assistance facility for a software program. The first step 50 of the process is to identify die basic functionality of a particular software program in which users experience difficulties, or could benefit from automated assistance, and the user behavior exhibited by the user when the user is experiencing those difficulties or desire for assistance. One way of accomplishing this step is to observe and record user behavior when a user experiences difficulties during usability studies for tiiat particular software program. For example, during a usability study for a spreadsheet program, a user interacting with a spreadsheet may be asked to update a graphical chart (e.g., a bar chart) of data on a spreadsheet. The user may have no experience in changing or modifying bar charts once they have been created. The user subsequently exhibits the following behavior: First the user selects the bar chart by placing the mouse pointer on the chart and double clicking the mouse button. Then the user pauses to dwell on die chart for some period of time while introspecting or searching for me next step. Observation of this activity could serve as an indication that die user is experiencing difficulty in using the chart feature of the spreadsheet. Once the difficulties with using basic functionality are identified, die next step 52 is to build a model for the task of providing intelligent assistance for die basic functionality identified. One type of model is an network of interdependent variables such as a Bayesian network mat can represent probabilistic relationships between observable evidence, intermediate variables, and hypotiieses of interest. A Bayesian network is a directed acyclic graph in which the nodes represent random variables and arcs between nodes represent probabilistic dependencies among those variables. A Bayesian network represents a joint-probability distribution for a set of variables. Computational procedures, referred to as Bayesian inference algorithms have been developed to operate on Bayesian networks. These algorithms update die probability distributions over states of variables in a Bayesian network given changes tiiat are made in values of states. An example of state changes are new values assigned to states of variables representing observable states of die world, following the observation of these states in die world. A description of Bayesian networks can be found in "Probabilistic Reasoning In Intelligent Systems", by Judea Pearl, 1 Morgan auf ann Publishing Inc., San Mateo, 1988. Some of the nodes are variables that represent evidence tiiat may be observed. Other nodes represent unobservable or difficult to observe hypotheses of interest that may be used in automated decision making. A simple two-variable Bayesian network is displayed in Figure 3. The network represents the dependency between a user being in a state of needing assistance 68 and die user activity of multiple menu exploration 69 or "menu surfing" without making progress. Menu surfing can be sensed, but it cannot be easily observed whether a user needs assistance. In modeling user difficulties witii complex software features, evidence nodes may represent user behavior exhibited while performing actions toward certain goals or experiencing difficulty witii a software program feature, and hypotiiesis nodes may represent the goals of die user or die particular assistance needed by die user to complete a task using tiiat feature. For example, while creating a chart the user pauses after selecting the create chart command. An evidence node variable would represent d e fact mat die user paused after selecting a command. An hypotiiesis node variable may represent the probability of the hypothesis tiiat die user needs assistance in creating a chart given the fact that the user paused after selecting the create chart command. Using a Bayesian network is one way of building such a model of uncertain relationships between user actions and hypotheses. Those skilled in the art will recognize that other models can be used such as decision trees or rule-based reasoning. For any of these models, die next step 54 is to define evidence variables and corresponding modeled events that can discriminate among alternate difficulties and needs for assistance mat a person may have in using the basic functionality of the software program, and tiiat can be sensed during die user's interaction with software. A key task required in building die Bayesian network model for the intelligent assistance facility is defining die evidence variables that will be observed, and noting the probabilistic relationships of these variables to variables representing hypotheses of interest. These events are those that are useful in detecting and discriminating among alternate difficulties and needs a person may have in using complex software features in general and, in particular, specific complex software features of a software application. Classes of observation that are valuable for identifying when and what kind of assistance users need include evidence of search (e.g., exploration of multiple menus), of introspection, (e.g., sudden pause or slowing of command stream), of focus of attention (e.g., selecting and pausing on objects), of undesired effects of action (e.g., command/undo, dialogue opened and canceled widiout action), of inefficient command sequences, the structural and semantic content of file being worked on, and goal- specific sequences of actions. Also, program state and program context, user competencies, and die history of information reviewed by die user are useful. In developing die Bayesian network and specifying tiiese observable variables, it is important to consider die nature and definition of die intelligent user assistance facility which will be harnessed to detect user actions. Consideration must be given to die basic events tiiat can be made available from the software system or application. Modeled events detected as occurring by die system are designed to correspond with each observable variable. The modeled events must be defined in terms of die basic, or atomic events titat are generated by die software program. At run-time, the modeled events corresponding to die observable evidence variables tiiat are modeled in die Bayesian network are provided to die inference system which sets the evidence variables to specific values. The intelligent user assistance facility has die ability to consider die recent occurrence of multiple modeled events in parallel and to consider the time these events occurred, and to use tiiis monitored information to update die state of observed variables in die Bayesian network. The Bayesian network with its associated dynamically changing settings with regard to d e status and timing of observed variables is analyzed in die inference system which generates updated likelihoods on different hypotheses of interest. These probabilities are used in making decisions about action and display of information to users. Upon completing the task of defining evidence variables in a Bayesian network and tiieir associated modeled events, die next step 56 is to identify atomic events that indicate me occurrence of each modeled event. Modeled events can be defined by die occurrence of a single atomic event, associated with a user action or state of the program or may represent a sequence of one or more atomic events. For example, the two atomic events of (1) a user selecting a bar chart and tiien (2) pausing to dwell on die chart for more than 10 seconds can be composed into a single modeled event tiiat corresponds to an evidence variable in a Bayesian network. Botii of tiiese events may be combined to form a modeled event, Sel_Chart_Pause, that indicates an occurrence of a user having difficulty updating a chart with data on a spreadsheet. Variables in the Bayesian network may be binary and have just two states (e.g., absent and present), or may have multiple states. In cases where mere are multiple values, the variable is set to one of die states corresponding to die observation. Binary observational variables are described, but die techniques also apply to variables with greater numbers of values. When the modeled event is observed and is passed to the inference system, the evidence variable corresponding to this event is set to "present" at the time noted for when die event occurred. Whenever probabilistic inference is performed on die Bayesian network, die status of all variables that could be set by modeled events are considered. As a result of inference we may see changes in hypothesis variables of interest. For example, given the occurrence of Sel_Chart_Pause, and otiier observations that update die probability tiiat a user is having difficulty with chart-related tasks, the probability assigned to me hypothesis tiiat a user is having difficulty updating die chart with data on a spreadsheet may increase. Another example of a modeled event is the action of a user selecting the Undo command following any one of a set of chart-related commands. The occurrence of one of any atomic or modeled events in a set followed by an undo command would be composed as a Chart_Cmd_Undo modeled event. When tiiis modeled event sets d e corresponding evidence node in the Bayesian net, we might see an increase in die probability assigned to die hypotiiesis tiiat the user may be having difficulty updating chart with data on a spreadsheet. Continuing the example above, atomic events for the modeled event, Sel_Chart_Pause. are (1) a user selects a bar chart, followed by (2) some minimal prespecified period of time (e.g., 10 seconds) in which there is a dwell, indicated a cessation of user activity. Atomic events may serve directiy as modeled events. For example, DeI_Chart is an atomic event representing the deletion of a chart tiiat is also modeled event, corresponding to die observation variable in the Bayesian network. Modeled events also include contextual information about the state of data structures in an application. For example, Chart_View, means that a chart is present in the current display. This will increase the probability that charting assistance is relevant to the user. Words appearing in a free-text query are also atomic events. Higher- level, modeled events may be defined as die appearance of one of a predefined set of words in a user's query. If a user's query is, "How do I change die colors in tiiis chart?," the modeled event, that one of a set of words (e.g., in tiiis case, a set containing as elements the words "modify," "convert," and "update") has been noted in the query, is passed to die inference system. Other important words in die query, such as "color" and "chart", are also detected as modeled events when tiiey are noted to be in sets of previously modeled sets of similar words. These modeled events are analyzed in die same way as "convert." The class of modeled events tiiat are persistent across multiple uses of a software program are defined as profile information. These modeled events include events tiiat indicate user competency or lack of competency and are stored in die user profile database. Modeled events stored in the user profile provide additional information about die user, such as die user's previous experience with particular application features or accomplishment of specific tasks, or review of tutorial material in the past. These events may correspond to variables represented in die Bayesian network and used by die inference system to adjust die evaluation of the hypotheses. Other types of atomic events may include information about the presence or absence of user in front of die computer, as gleaned by proximity detectors, by visual features of the user, including information about the focus of the gaze of the user, expressions of the user, or gestures of the user, as identified by a video camera and vision recognition and tracking system, and speech utterances of a user as detected and processed by a speech understanding system. After atomic events and their appropriate combination are identified for each of die modeled events, the next step 58 is to construct an event monitor for the software program that will survey user interface actions to extract the atomic events for input to inference analysis. The event monitor constructed is integrated with the software application to instrument tiiat software application at step 60 in making an intelligent user assistance facility. Those skilled in die art will appreciate that the event monitor may be integrated within die application software, or may be a stand alone component at is part of a system library or operating system. To complete the intelligent user assistance facility, an event processor is to compose modeled events from atomic user-interface actions (step 62). Next, a knowledge base is constructed from the model (step 64). The last step 66 is to construct an inference engine from the model which uses die knowledge base to determine suggested user assistance for die occurrence of modeled events. A Bayesian network witii inference procedures serves botii as a knowledge base and inference engine. Figure 4 is a functional block diagram of the components of an embodiment of an Intelligent User Assistance Facility constructed by using die method described above. The Intelligent User Assistance Facility includes a software program 72 mat has been instrumented to monitor actions or events initiated by a user who is interacting witii the software program. Periodically, these actions or events are scrutinized by an event processor 74 to discover whetiier any of them, either individually or in combination, represent observable variables in the Bayesian network. Modeled events are analyzed by an inference system 76 to form and evaluate multiple hypotheses of what assistance the user may need. These events can lead to increases or decreases in die probability that a user is experiencing a problem in using a particular application feature or in accomplishing a specific task. The inference system 76 also accesses the user profile system 78 to check for competencies and changes assistance tiiat is given based on user competence. User's background, successful completion of key tasks indicative of competence in particular areas, and previous help reviewed by die user are some of the variables stored in die user profile system 78. The IUAF controller 79 initiates a cycle of inference analysis by the inference system 76 based upon d e setting of its control mode. An inference cycle may be initiated whenever a user asks for help, or whenever one or more of any number of special events have occurred, or may simply occur on a regular clocked cycle, or for any combination of these modes. When die control mode is set to trigger an inference cycle upon occurrence of a special event or die control mode is set to occur on a regular clocked cycle, the inference system 76 will autonomously offer help to the user whenever the computed importance of coming forward exceeds die autonomous assistance tiireshold set by die user. When the control mode is set to initiate an inference cycle whenever the user asks for help, the inference analysis of user actions and program context is combined witii an analysis of the words in a free-text query whenever die user submits a free-text query. Those skilled in d e art will appreciate that the functional blocks illustrated in die diagram may be implemented as separate components or several or all of the functional blocks may be implemented within a single component. For example, a separate library may be implemented tiiat contains the reasoning system functionality and die event processor functionality. In such an implementation, the reasoning system may query the instrumented program periodically for all of the atomic events since the last query or may simply ask for a specific number of the last occurring events, and tiien the reasoning system may access the modeled event database for tiiat particular software program to deterrnining whether any of the atomic events are modeled events for input to inference analysis. Those skilled in the art will also appreciate tiiat the inference analysis may be implemented to include only die ongoing analysis of user actions and program context except when a user asks directly for help witii a free-text query. In that case, the inference analysis may be implemented to include only die analysis of die words in the free-text query whenever a user asks directly for help witii a free-text query. Those skilled in die art will also appreciate tiiat a separate analyses could be undertaken for different classes of modeled events, such as for words in a query and for actions in the interface, and die results of these separate analyses could be combined with the ability to control die weight given to die results of die different analyses. Instrumented Program Any software program or library may be an instrumented program, including operating system programs and application programs. As an illustration of an instrumented program, an application program will be described. A typical software application contains a user interface and application procedures. As a user interacts with a software application using input devices such as depressing a key of me keyboard or clicking the button of a mouse, the operating system translates those user actions into events and sends diem to die application program. The user interface component of the application program processes those events and forwards diem to die appropriate application procedures for responding to tiiose events. The event monitor constructed for die Intelligent user assistance facility for a particular application may be integrated within the application software as illustrated by Figure 5. In tiiis configuration, die event monitor 84 watches for events passing from the user interface 82 component to application procedures 86 and forwards diem to the event processor through a call interface to the event processor. It also may be implemented as a stand alone component mat is part of a system or application library which makes periodic calls upon the application program to send it all events since the last period or it may simply request that the application program send only a specific number of the last occurring events. Alternatively, it may be incorporated as part of die operating system in which case the event monitor screens events passing from the operating system to the application program and forwards diem to die event processor. Figure 6 is a functional block diagram of an instrumented spreadsheet application program as in the help-topic embodiment. As a user interacts witii a spreadsheet application program using input devices, die operating system translates those user actions into events and sends them to the spreadsheet application program. For example, the user may place the pointer of the mouse on a menu item and may then click on the button of mouse. The operating system will translate that user action into an event that die user has clicked on an application menu item and send die event to die spreadsheet application. The user interface 92 component of the instrumented spreadsheet application program 90 receives that event and forwards it to the appropriate spreadsheet application procedures 96 for processing that event. The spreadsheet events monitor 94, watching for events passing from the user interface 92 component to application procedures 96, will see that event and forward a copy to the event processor. Event Processor The event processor is a general monitoring and event composing system that allows high-level events to be created from combinations of low-level events. The event processor does not need to include sophisticated reasoning capability. However, those skilled in the art will also appreciate that a variety of deterministic and probabilistic event preprocessing methods can be employed to work with arbitrary abstractions or clusters of events and to transform events into numeric information with a variety of mathematical functions, including tiiose that might be directly interpreted as likelihoods. Since the Event Processor produces a set of logical events, any reasoning engine, rule-based or probabilistic, can utilize its output. Figure 7 is a block diagram illustrating the components of the event processor. Atomic events or user input device interactions are sent by an events source 100 such as an instrumented program to the event processor. The instrumented program may use a call interface that specifies the event information to the event processor. Upon receiving these events, the event processor may time-stamp each event and store them in local storage 102, such as system memory, in one of several kinds of data structures for storing information, including a database of records or finite circular queue ordered by die time stamp, or first in, first out order. A modeled event composer 104 periodically surveys the atomic events in local storage 102 in search of one or more atomic events that may be composed into a modeled event. This typically would be initiated by die inference system 74 at the beginning of an inference cycle; however, die modeled event composer 104 could perform composition of events between inference cycles such as whenever a new atomic event is received, or when special trigger events are received. The modeled event composer 104 then forms modeled events from atomic events according to die event composition rules defined in die event specification. The modeled event composer 104 stores each modeled event tiiat the composer 104 generates from atomic events in the modeled event database 108. Those skilled in die art will recognize that there could be implemented a modeled event database for each individual program employing the intelligent user assistance facility. For example, mere could be a modeled database for each instrumented application program resident on a computer system. Those skilled in die art will also recognize tiiat tiiere may additionally be a separate general modeled database tiiat contains common system or application events such as activating a program or exiting a program. In such a case, the inference system may access both the general modeled event database and die active program's modeled event database during a cycle of inference. In one example of a modeled event database, tiiere is a single record for every modeled event for tiiat database. When a program with the intelligent user interface is activated, pre-existing persistent events stored in die user profile may be used to initialize the modeled event database. As modeled events are formed by die composer, the record for tiiat event is updated in the modeled event database. An example of a record format for modeled events in tiiis modeled event database is: Of die fields used to count die number of occurrences and die rate of tiieir occurrence, LastTime and Count are stored in die user profile database for all persistent modeled events. Upon initialization of the program, these fields get loaded from d e user profile database into tiieir corresponding modeled events in die modeled event database. Modeled events are only relevant for a comparatively short time. This period of time during which a modeled event is relevant may be referred to as its horizon. Different events may have different horizons, a sixty second horizon is a suitable length of time for the horizon of most events generated by user actions. The duration of the horizon determines the length of time that a modeled event is considered in die inference system 76. Each modeled event may be assigned a default system or application horizon or it may be assigned a specific horizon. Modeled events that have resided in die modeled event database 104 beyond tiieir horizon time are discarded whenever die modeled event database 104 is accessed or updated. However, before they are discarded from die modeled event database 104, persistent modeled events are recorded in die user profile. The inference engine 76 and user profiler, in general, act as event sinks and access die modeled event database 104 to extract modeled event records. However, tiiere is an exception. At program initialization time, pre-existing persistent events stored in die user profile may be used to initialize die modeled event database 104 and, as a consequence, modify the program's behavior. Event Svstem Specification Tool The event specification tool allows for rapid creation of die modeled event composer and modeled event database for specific application programs during creation of an intelligent user assistance facility for that software program. A language was developed for constructing modeled events (e.g., menu surfing) from atomic events made available by a program, for instance an application (e.g., multiple menus visited without action within 10 seconds, position of cursor on spreadsheet, etc.). The language allows atomic events to be used as modeled events directly, as well as for atomic events to be formed into higher-level modeled events. Also, modeled events can be further combined to create other modeled events. More specifically, the language allows for Boolean combinations of atomic events and for combining die Boolean events into modeled events with operators that capture notions of temporality. The event specification tool can be linked directly with a Bayesian network modeling tool so tiiat die modeled events and tiieir definitions can be generated while building and refining the Bayesian user model. Figure 7 is a block diagram of an event system specification tool 110 used for generating code for d e modeled event composer 104 and modeled event database definitions 1 18. Each modeled event definition 112 created during die step of defining modeled events is used to specify the events in the event language 114. The event specification 114 is then input to an event language translator 116 which translates the event language statements of the specification into high-level language code, such as C, to create die modeled event composer 104 component. The event language interpreter also creates the modeled event database definition. As part of tiiat process, the event language interpreter 116 may also create the modeled event database 106 directly from the modeled event database definitions 118 in systems employing a database structure to store information on the status of modeled events. The event language includes Boolean and set operators, witii the addition of temporal operations including dwell and sequence. Modeled events are defined in a separate text module written in the event specification language. However, they can also be constructed witii the use of special definition forms. The text definitions are created as named statement blocks for each modeled event. These definitions contain die labels of atomic events and indicate operations on one or more atomic events. The general form of a modeled event declaration in die event definition language is: declare ModeledEventName { Expression list> } An example of the modeled event declaration for the Dwell_on_Chart modeled event is: declare Dwell_on_Chart { (and (Select_Chart, Dwell(5,s)) } The interpreter translates the syntax statement of the event definition language to the modeled event name, Dwell_on_Chart and updates the modeled event database by adding a record witii that event name and initializes all record fields. A modeled event may be a complex synthesis of several other events, including otiier modeled events, or it may be simply a renaming of an atomic event. The , event syntiiesis language supports infix expressions which entail logical combinations of atomic events, modeled events, arithmetic, and logical operators. As each elementary operation is performed, the intermediate result is treated as an event and has similar properties. The event language has logical, set-theoretic operators, temporal, and aridimetic operators. Operators allow the defimtion of specific events as well as events defined as generalizations based on sets of events. For example, higher-level events can be built via abstraction or generalization with operators like Element: Element^x,,..^}): Any event drawn from the elements of the set of events {x,,...^ } occurs. Such sets can be defined as specific classes of events. Temporal operators allow us to define events in terms of sequences of events over time. Temporal intervals may be measured in terms of the number of user actions, die amount of time, or other measures of duration tiiat can be defined as functions of user actions and time. For example, it can be useful to define modeled events in terms of Scaled_seconds, a measure of duration where seconds are scaled by die rapidity at which a user is working, so as to adapt die temporal constants to users that work at faster or slower rates than an average user. When specifying temporal operators, we indicate die dimension of die measure of temporal interval by specifying the temporal dimension d witii a value (e.g., c for commands, s for seconds, and ss for scaled seconds). Some useful temporal operators are: Rate(x,t,d): At least x atomic events occur in duration t of dimension d. Ensemble_N({x,,...x 0 },t,d) At least N events from the set of events {x^.-.x,,} occurs witiiin interval t of dimension d. All({X|,...x n },t,d): All events in a specified set of events {xl,...xn} occur within duration t of dimension d. Sequence({x„...x n },t,d): All of the events specified in a set of events {xl,...xn} occur within duration t of dimension d. TightSeq({x„...x n },t): All of the events specified in a set of events {x,,...x„} occur witiiin occur within duration t of dimension d. Dwell(t,d): No user action for t seconds or scaled seconds of dimension d. In addition, parameters can be specified that define die persistence or dynamics of probabilistic relationships between modeled events and otiier variables in a Bayesian network with increasing amounts of time since the modeled event has occurred. In d e general case, we can provide any temporal function that describes how die probabilistic relationships of events to other variables in a Bayesian network change as the time following the occurrence of an event increases. More specifically, the language allows the specification of how p(E, ,t_ |H j , t p ), the probability of event E, occurring at time t 0 in die past conditioned on me trutii of hypotheses H ; at the present moment, t p changes with the increasing amount of time t_. = t since the event last occurred. Useful distinctions for representing the temporal dynamics include horizon and decay: Horizon: The interval of time beginning at the time t=t 0 that an event becomes true, that die probabilistic relationship persists as p(E, , t 0 | H r t 0 ) without change. The probability remains unchanged as long as difference between the present moment, t„, and die time, t 0 , the event was most recently seen is less than the horizon. Dynamic: The time-dependent functions tiiat describe p(Ej , t 0 1 H j , t p ) and p(E, , t 0 |not(H j ), t p ) after a horizon is reached. The dynamics can be summarized with a description of die change in die likelihood ratio defined by die ratio of tiiese probabilities. The functions indicate how die initial probabilities p(E t , t 0 | H j , t p ) and p(E, , t 0 |not(H j ), t p ) change as the time die event became true becomes increasingly distant from die present time, t p . It can be asserted tiiat these probabilities converge at some time to p(not(Ej)| H j , t p ) and p(not(E,)|not(H j ), t p ), and die initial likelihood ratio, when ^ = t 0 , converges to the ratio of these latter probabilities, and, therefore, functions can be assessed tiiat decay die probabilities or likelihood ratio from the initial likelihood ratio when t p = t 0 to the lU elihood ratio associated witii absence of the event. The probabilities can be computed as a function tiiat takes as arguments the initial probabilities (at t_0), me probabilities associated with die finding being absent, and die time of die present moment, t p , and ensures consistency among probabilities at any moment. That is, p(E, , t 0 1 H,, =f [p Ei , t 0 1 H,, t 0 ), p(nouΕ,)| H Jf t p ), t p ] and p(E„ t 0 1 not(H j ), =f [p^ , t 0 1 not(H j ), tj, p(not(E,)|(not(H j ), y, g Operators being used to define modeled events may affect the duration information of the resulting modeled event. Conjunction results in storing die latest occurrence time of any subordinate events. Disjunction results in storing die times associated with the first true subordinate event. The Value field of die generated intermediate result of the modeled event is set according to die result of the expression. The result of all arithmetic comparison operations is either one (Boolean TRUE) or zero (Boolean FALSE). If die argument of an arithmetic operation is an event, the argument is evaluated as one if the event has occurred and zero if d e event has not occurred. The time stamps associated witii simple numbers are set to die span of die current cycle; in otiier words, die start time is the time of the last cycle and die end time is the current time. Since d e syntax allows for recursion, care should be taken that infinite recursion not occur. These statements are entered into a text file known as die event specification module. The event specification module 114 is tiien processed by die event definition language translator 116. The event language translator converts the event specification language 114 into C++ code which may be compiled to machine language and linked directly to me event processor system library, IUAF library, operating system library, or other implementation library. The results of translating a high-level event specification is the modeled event composer 104 which creates modeled events. When die modeled event composer 104 is invoked during a cycle of inference, it builds die set of currently active modeled events and tiien returns to die caller. The inference code tiien performs appropriate actions indicated by the event set. User Profile Svstem The inference system 76 accesses the user profile system 78 to check for competencies and changes assistance that is given based on user competence. User's background, successful completion of key, tasks indicative of competence in particular areas, and previous help reviewed by die user are variables that can be stored in a persistent file and updated witii time. Such persistent information about user background, experience, and competence is referred to as "profile information." Figure 9 is a block diagram of die user profile system 78. The user profile system 78 includes a user profile database 120, a user profile access routine 122, an event status update routine 124, a background and competency dialog routine 126, and a customized tutorial routine 128. The user profile database 120 contains records identical in format to the records in die modeled event database 106 so tiiat there is a common format between the modeled event database records and d e user profile database records. This common format makes it more convenient both for updating the user profile database witii modeled events and for die inference engine to interpret these records when it access tiiese databases for inference analysis. The user profile database records are stored persistently so that they create an historical record of particular user's competency with specific software applications. This database is maintained on a by-user-by-application basis. An example of persistently stored modeled events tiiat are indicative of user competency are die completion or non-completion of certain tasks, successful or unsuccessful use of particular features, and assistance received or help information reviewed in the past. Figure 10 is a flowchart illustrating how the user profile database 120 is updated witii event status of a user interacting with a specific application program. The event status update routine 124 in step 130 retrieves die first modeled event record in d e modeled event database and checks in step 132 whether the record is marked as a persistent record. If it is marked as a persistent record, tiien the record is added to the user profile database in step 134. If it is not marked as a persistent record, tiien it is not added to the user profile database. Each subsequent record in the modeled event record database is retrieved in turn (steps 136 and 138), checked whedier the record is marked as a persistent record (step 132), and added to the user profile database if it is marked as a persistent record (step 134). The availability of a standard stored user profile containing information about "persistent events" could follow a user around over a local network or over die Internet, custom-tailoring the user's software wherever the user may be. While a software application is active, a new user may log on to the system and use the active software application. Figure 1 1 is a flowchart illustrating how a user profile is accessed whenever a new user signs on to die system or application. When a user logs on to die system or application (step 140), the user profile access routine 122 searches the local user profile database for that user's profile (step 141). If the profile is found, the path to that user profile is passed to die inference system 76 (step 142). If that user's profile is not found, because tiiat user may be using the application at a remote location, then the user profile access routine searches the available networks for any user profile databases tiiat contain the user profile (step 143). If the user's profile databases is not found or die user's profile is not found in any user profile databases accessed, tiien the user profile access routine asks the user for permission to enter a user competency dialog with the user (step 144) and creates a user profile for that user (step 145). The path for that user profile is passed to die inference system 76 (step 142). If the dialog is not completed, d e patii to default profile information is passed to die inference system 76 (step 146) and used. In addition to maintaining a persistent user profile for use during realtime inference, a continuing background analysis of repetitive patterns of a user's needs for assistance during one or more sessions that exceed a tiireshold, may be used to customize a tutorial of help information that may be offered to die user at die end of a user's session with the tiiat program. Figure 22 is a flowchart of the routine for generating a customized tutorial. During a user's session with a specific application program, a histogram of help topics exceeding a relevant probability tiireshold is recorded by die inference system 76 (step 150). When the user asks to quit the session with the application program, the user profile saves the histogram in the user's profile (step 152) and prepares a customized tutorial of help information related to d e help topics recorded in the histogram (step 154). The user profile system notifies the user upon exiting the application program that a customized tutorial was prepared for online review or for printing as a manual (step 156). Inference Svstem When a cycle of inference analysis is initiated, the inference system 76 accesses the modeled event database 106 to extract modeled event records for each of the modeled events that has occurred since die last cycle of inference. A functional block diagram of die inference system is displayed in Figure 13. The inference system 76 includes one or more knowledge bases 160 and an inference engine 165. Knowledge bases 160 include information relating variables that represent observable states of the world, such as user actions and words, to variables tiiat represent hypotheses of interest about a user's goals and needs for assistance that may not be observed directly or tiiat are costly to observe. For example, the goals of users can not necessarily be directly inspected, but a sequence of computer commands can be recorded. A user can be actively queried about goals, but this may be quite distracting to users. A deterministic knowledge base consisting of an interrelated set of logical rules may link observations to hidden hypotiieses. However, it is often more appropriate to process the uncertain relationships as probabilities between observations and die likelihood of hypotheses about a user's needs. For example, in attempting to understand and to predict the behavior of a complex system such as human physiology it is typically not possible to completely model with deterministic relationships all components of the system, and to tiien have access to a deterministic model for performing diagnosis or designing tiierapy based on a set of symptoms. For diagnosis and decision making about complex systems, we are often forced to reason under uncertainty, and to explicitly address die incompleteness in our understanding. Probability provides us with a means of diagnosis and forecasting about the behavior of complex systems given knowledge about a set of relationships among observational variables and hidden variables we may identify as being important. We can use probabilistic methods to represent and reason about weak and strong uncertain dependencies among observations, such as symptoms of a patient and variables such as diseases in a patient. A good example of complex system is a user attempting to perform a task while interacting with a computer software application or system. It is very difficult to build deteirrninistic models tiiat link a user's behavior to a user's goals and intentions. The best way to diagnosis a user's needs is to develop appropriate abstractions, based on our understanding of the relationships among various kinds of user's goals and actions, and to represent and reason about die relationships witii probability. Probabilistic methods allow us to build models at a level of abstraction that is appropriate in light of our incomplete understanding about users and their actions. A Bayesian network or a generalization of a Bayesian network, called an influence diagram, can be employed to represent the certain or uncertain relationships among user actions and such hidden, but important, states as user goals, user intentions, and user needs, given observable information such as one or more user actions. A Bayesian network is a directed acyclic graph where nodes are random variables and arcs represent probabilistic dependencies among tiiose variables. Variables in a Bayesian network are chance variables or deterministic variables. A Bayesian network represents a joint-probability distribution for die set of variables it represents. The probability distributions over die values of chance variables depend on die values of direct ancestors, or parent variables that are parents of nodes. The value of deterministic variables is a deterministic function of predecessors. Influence diagrams are a generalization of Bayesian networks which represent additional nodes that represent possible actions and die utility of outcomes. The inference engine 165 includes inference procedures 166 tiiat operate on the knowledge base 160. The knowledge base 160 includes a Bayesian network 162. Those skilled in the art will recognize that the knowledge base may be a deterministic knowledge base witii logical chaining procedures as die inference procedures of die inference engine. Or the knowledge base may be a Bayesian influence diagrams witii inference procedures for operating on Bayesian networks as the inference procedures of die inference engine. Temporal reasoning procedures 167 and value-of-information procedures 168 are also included as part of die inference engine 165. Other specialized procedures may be included. Bayesian inference procedures operate on Bayesian networks to compute a consistent posterior probability distribution over die values of variables in the network given the setting of states of observable, or evidence, variables to specific states based on the observations. Assume we are interested in die probability distribution over unobserved hypotiieses of interest, H„... H,,,, and have access to observations and profile information E„... E n . Bayesian network inference algorithms compute a probability distribution over H given the observations, written p(H| E„... E . For influence diagrams, decision-theoretic inference is performed to identify the expected utility of alternative actions. The best action is the one associated with die highest expected utility. In the most general sense, the task of designing inference for an intelligent user assistance facility is best undertaken from die perspective provided by decision tiieory, an extension of probability theory to reflect concerns of value under uncertainty. Influence diagrams allow us to express fundamental relationships about uncertainty, action, outcomes following action, and the value of those outcomes. This representation is useful in the design, understanding, and in many cases, die actual implementations of intelligent user assistance systems. However, it is often the case, that a simpler systems may be built without explicitly representing decisions, outcomes, and the utility of outcomes, and instead to use Bayesian networks to represent probabilistic relationships, and to use probabilistic inference in combination with procedural controls and tiiresholds as approximations of more complex influence diagram models. A general influence diagram for user modeling and action to assist users of software is portrayed in Figure 14 as an exemplary embodiment of a Bayesian influence diagram as a knowledge base. As portrayed in die figure, a user's background 170 influences with uncertainty, a user's overall goals 171 in using software, as well as die user's knowledge 172 in using software. User's knowledge 172 is also influenced by the previous help 173 that user may have seen. The user's background 170 and previous help 173 are variables that can be stored in a persistent file and updated witii time. Such persistent information about user background, experience, and competence is referred to as "profile information." As indicated in me influence diagram, die user's goals 171 and knowledge 172 in turn influence witii uncertainty, die informational needs 174 of die user. The goals 171 and needs 174 in turn influence the sensed activity 175 and the words tiiat might be used in a query 176 to die software, or software's help system. A utility function of the user 177 is represented as a diamond. The utility 177 is influenced directly by die informational needs 174 of die user, die cost of taking autonomous action 178 (e.g., distraction for die user's current focus of attention) and die action that is taken. Several classes of action may be available to the system, including the providing of advice or help 179, die execution of software actions of various kinds 180 and die acquisition of additional, previously unobserved information from the system, 181 or directly from die user. As indicated in the Figure 14 by the scale on the cost of assistance variable 178, we may wish to allow the user to directly change the cost of the assistance so as to control, in a fluid manner, the degree of autonomy given to d e system. The overall goal of the inference system is to identify actions that will optimize the user's expected utility given the user's needs and die cost of taking autonomous action. Given a set of evidence E about a user's background and actions, die probability distribution over hypotheses of interest about a user's needs, H, is computed. In the case of the Bayesian influence diagram in Figure 14, the probability distribution over a user's needs for assistance is computed. The expected value of actions in die set of all possible actions A must be considered. To do tiiis, consider the utilities over outcomes, represented as a utility model (diamond node). The utility model contains information about the value or utility of outcomes. Outcomes (A,H) are defined as doublets of actions A taken and d e state actual user's needs H. The utility model tells us the utility associated witii each outcome, u(A,H). The best action to take, A*, is the action that maximizes the expected utility under uncertainty, computed as follows: A* = arg max A Σ j u(A,,F ) p(H j [E) Although influence diagrams represent explicit models of action, Bayesian networks are often easier to build and can be used for decision making and action by employing thresholds or rules about probability over variables in the network to indicate when actions should be taken based on the degree of belief assigned to a variety of states including states tiiat describe preference about action. Influence diagrams such as die one portrayed in Figure 14 can be used to clarify approximations used in the Bayesian network. Temporal Reasoning; and Dynamics The inference system 76 also contains special temporal reasoning knowledge 164 in the knowledge base 160, and procedures 167 for performing inference about the changing relationships of observations to other variables in the model as the observations occur at progressively more distant times in the past. In the general case, applications of Bayesian procedures and knowledge bases to reasoning about patterns of observations seen over time requires the consideration of variables and tiieir interdependencies within a single time and at different times. Building and performing inference with Bayesian networks that include copies of variables and dependencies for different times slides can lead to difficult computational reasoning problems and unacceptable response times for a user interacting with a program. Thus, several approximations are of value. In one kind of approximation, only specific dependencies considered to be of die greatest importance are considered over time. A portion of a Bayesian network with sets of variables at different times and prototypical dependencies represented is displayed in Figure 15. Figure 15 displays a Bayesian network that explicitly represents random variables at different points in time, and probabilistic dependencies among variables at a single time and among variables at different times. The lack of dependencies among variables are assertions of assumptions of independence. The figure displays possible influences among the primary relevant assistance to provide a user at present moment with the most relevant assistance to provide users at earlier and later times. Also, the figure highlights potential dependeηcies among the status of observations (E, and E j ) in the present, with observations made in the past and future. The figure also indicates the relationship between the primary relevant assistance in the present and observations in the past. In the general case, such multiple-connected networks are difficult to solve and to assess during die construction of the models. We will now describe an approach to reasoning about relevant assistance over time that is more tractable to solve and to assess, dirough making additional assumptions of independence and representing the relationships among evidence seen at progressively more distant times in the past and hypotheses of interest with parameterized functions tiiat dictate die strength of the probabilistic relationship between those observations and current die goals or needs for assistance. The use of this approximation in an exemplary embodiment employs a single explicit Bayesian network, but allows die system to consider implicitly multiple Bayesian networks over time. This method takes advantage of direct assessment during modeling time of functions that adequately describe die dynamics of the probabilistic relationships between observed variables and otiier variables in a Bayesian network. At modeling time, a horizon and dynamics are assessed for each observational variable E„ and die variable is annotated with this information. At run-time, the inference engine 165 includes procedures 167 for using this information about horizon and dynamic. The horizon for an event captures die interval of time the probabilistic relationships witii hypothesis H j persists as p(E„ t 0 j H,, t 0 ) and p(E„ t 0 1 not(H j ), t 0 ) without change. The dynamics is e time-dependent change of the probabilities in the present moment as described earlier. Heuristics in defining a horizon for events include the use of a default horizon for all observational events considered by a system unless otherwise specified, and die use of an event queue of finite length k, where only the last k modeled events are considered in the analysis. This approach can be combined with dynamics as just described. Value of Information The inference engine 165 also includes expected value of information (EVI) procedures 168 to compute the expected value of acquiring information from a user. EVI procedures and information- theoretic approximations that can be employed in probabilistic models are well-known to people skilled in the art of decision theory. The EVI is a means for computing the expected value of acquiring information about variables tiiat have not yet been observed. Such information includes answers by users to questions posed by the computer system about their goals and needs. The Net Value of information (NEVT) is net value of gathering information, including die costs of gathering the information. The inference system 76 only asks a question, or gathers information autonomously, when the informational benefits of die information outweigh the costs. If E x refers to each previously unobserved variable tiiat can be queried, O k is a possible observational value of E,, and A is die value tiiat will be observed when die variable is evaluated, die NEVI of each variable is: NEV1(E J = ∑ k p(E x = O k |E) * [max A Σ, u(A i ,H) pCH E-E,- OJ] - max A Σ J u(A,,H J ) p(H J |E) - C(E x ) where C(E X ) is the cost of evaluating evidence E„. EVI can be applied directly to influence diagrams. Several well-known information-theoretic algorithms, including those based on computation of entropy, function to provide similar functionality for decisions about information gathering in probabilistic models such as Bayesian networks. These algorithms are typically more tractable than computing NEVI with influence diagrams. They do not explicitly manipulate utilities, but nevertheless can be employed in conjunction with heuristics that balance die cost of information with measures of informational value. Figure 16 is a flowchart of value-of-information procedures in the value of information component. The value of information component lists all of the previous unobserved information in order of die value of it as alternative information (step 190) and weighs die benefits of obtaining the information against the cost of distracting die user for each item of information (step 192). If the benefit is greater than the cost set by the user, the IUAF asks the user to supply the item of information that has the highest value (step 194). If the user responds, then die value of information component repeats the first two steps until either the cost of distraction is greater than the benefits of obtaining the information or the user does not respond (step 196). Scenarios Illustrating the Screen Outputs of the IUAF Figures 17 through 23 illustrate the screen outputs of die intelligent user assistance facility in an exemplary embodiment of a spreadsheet application. The system considers a user profile, user-specified threshold information, and combines words and user actions to provide intelligent assistance to die user. The system has the ability to respond to requests for assistance as well as to autonomously provide assistance. Figure 17 shows an assistance interface 200 mat is generated when die user explicitly has requested help. Guesses about useful assistance to provide the user are displayed in the list box 201 in the upper left-hand comer. The current system settings box 202 in the lower left-hand corner indicates die user is an expert user. This information was provided by the user profile system. The current system setting box 202 also indicates tiiat both user actions and free-text queries are used by the inference engine during a cycle of inference analysis. Given the profile information and die recent actions involving interaction with the layout of text, in combination with pauses, and with the user taking action to change the appearance of rows and columns shortly before help was actively requested, die system believes the user may best benefit by receiving assistance on working with fonts, advanced formatting instructions, and witii methods for changing the dimensions of the spreadsheet document. To the right of tiiis screen photo is displayed an inference graph 203 showing the probability distribution over a set of task areas tiiat was generated by d e Inference System 76. This display was built for engineering purposes but may be displayed to die user. The length of the bar graph next to each task area is the probability assigned to tiiat area. The two highest probability areas (those with the longest associated bar charts) are for the tasks of working with fonts and advanced formatting topics. In Figure 18, the profile information was changed to a profile for a novice user. The expertise level in the current systems setting box 202 indicates tiiat the user has a level of expertise of a novice. All other events handling remained unchanged. We have used a profile for a novice user. The profile information is used to modify die probabilistic relationships in the Bayesian network. The inference graph 203 displaying die probability distribution over relevant assistance shows the revised probability distribution with the profile information. As can be seen in the best guesses list box 201, the system now believes that the user may most benefit by assistance with basic working with rows and columns of the spreadsheet, changing alignment and basic formatting of charts. Figure 19 shows the analysis of the same set of user actions, but now, with consideration of the words in a user's query. The user has input to the system the natural-language query, "How do I make this look prettier?" in the query input box 204. The analysis of the words and die actions are combined to generate a new probability distribution, as indicated in d e inference display 203, and a new corresponding list of recommended topics in the best guesses list box 201. Now, the list is resorted and updated with autoformatting assistance being recommended as the most relevant assistance, but also still contains otiier formatting topics, including changing alignment, working with borders, and working witii fonts. Figure 20 shows the program at a later time when help is again requested after interaction with a chart in the document, coupled with pauses on chart commands. The probability distribution computed by me inference system 76 is displayed in die inference graph 203. Now, the recommended topics in the best guesses list box 201 focus on a variety of high-likelihood areas in the area of graphing information. Figure 21 shows the addition of information submitted in the form of a query in the query input box 204. The natural language query from the user is, "I need to access data from a different application". The words are now considered in conjunction witii the events. The inference system 76 provides a revised probability distribution in the inference graph 203 and a revised list of recommended topics in die best guesses list box 201, centering in retrieving data from a database and about changing the data displayed in a chart. Figure 22 illustrates die screen outputs of the inference system 76 offering autonomous help to a user. While the user has been interacting witii a spreadsheet program 205, an assistance monitoring agent computes the probability tiiat a user needs assistance and die inference system 76 also computes the likelmood of alternative kinds of help to give the user, should die user require assistance. The assistance monitoring agent displays die residt of inference on the probability that a user needs assistance in the assistance monitoring agent window 206. Like the inference graph 203 display described above, the assistance monitoring agent 206 was built for engineering purposes but may be displayed to die user. The user who has been interacting with a spreadsheet program 205, now selects the whole sheet and pauses. As d e assistance monitoring agent window 206 shows, die computed probability tiiat the user needs help moves from 26% to 89%, reaching a threshold, and a small timed window, die autonomous assistance window 207, autonomously comes forward displaying d e highest likelihood assistance areas that were computed. In this case, the highest likelihood topics include formatting cells, checking for spelling errors, and performing calculations, topics tiiat have implications for analysis or modification of the entire document. The autonomous assistance window 207 politely offers help. It also provides a chance for the user to reset a threshold that will increase or decrease die probability required on the likelihood die user needs help before displaying die window. The window 207 will time out and be removed with an apology for distracting die user if the user does not interact with the window 207. Figure 23 illustrates the display 208 of die topics tiiat have been determined to be of value to die user based on the recording and summarization of ongoing background inference about problems that user has been having during a session using a software program. Profile information about the user's background, competence, and about die assistance that the user has received or reviewed in the past are also included. These topics have been prepared for printing as a custom-tailored manual for later perusal. Bavesian Network Annotated witii Temporal Reasoning Figure 24 shows an example of a Bayesian network that computes the probabilities of alternative forms of assistance to provide a user as a function of profile information about the user, as well as recent actions taken by me user. To indicate that this structure may be repeated for many classes of observations and task-specific needs for assistance, variables x, y, z, and A have been used in several of die nodes. In this model, we represent profile variables that represent the status of user competency in two different areas of software functionality, x and y, with a set of variables labeled User Competence x 210 and User Competence y 211. The user competencies are each influenced by variables representing (1) specific observed activities by die user, (2) die history of help topics that have been reviewed by the user, and (3) the overall user background 212 that may be uncertain or set by a dialogue witii the user. As indicated in the Bayesian network, the user competencies directly influence the prior probability of different assistance being relevant to d e user, as represented by die states of d e Primary Assistance Needed variable 213. This variable is also influenced by a context variable 214, tiiat describes information about program state, such as the existence in die current version of an application of a particular data structure. In this model, die problem is formulated widi a single primary assistance variable, with states representing alternate forms of assistance. The model assumes that tiiere is only one state of primary assistance the user needs at any particular time. Multiple variables about assistance can also be represented to capture die notion tiiat several types of assistance may all be relevant at a single time. As depicted in the Bayesian network, the Primary Assistance Needed node 213 influences a set of observed modeled events, such as selecting a graphical object Z, then pausing for more than some predefined period of time (Sel Z Pause 215), or modifying an object and tiien performing an undo, (Z Cmd Undo 216). At run time, these modeled events are detected and passed to die Inference System 76 by the Event Processor 74. The corresponding observable variables to d e modeled events are update and Bayesian inference is performed to update die probabilities over all of die unobserved variables in the system, including die Primary Assistance Needed variable 213. The time of me event is noted and as the event flows progressively into the past, temporal reasoning procedures 167 are applied to update the probabilistic relationships in the network. Figure 25 shows an instantiation of the nodes witii variables x and z with distinctions with relevance to reasoning about the relationship of actions and profile information on charting or graphing information from a spreadsheet, such as the Microsoft Excel product. Variables that are persistent and stored in a profile are marked witii an adjacent P. Variables tiiat are observed as modeled observable events are marked witii M. One or more nodes may represent various classes of competency with charting. In tiiis case, a single variable, User Competence Charting 220, is displayed as the variable that contains information about the overall level of charting ability of the user. The probability distribution over the states of this variable are influenced by Hx Help Charting 221 and Hx Activity Charting 222, and User Background 212. Hx Help Charting 221 is set by observations that are stored in persistent profile about one or more charting activities the user has completed successfully and information about the help information on charting in an online manual that the user has reviewed. Competencies about charting and a variety of other areas of software functionality influence the Primary Assistance Needed variable 213. This variable in turn influences the probability of observing different behaviors by the user. For example, the state of a user needing assistance on a specific type of charting task, influences the probability of seeing the user select and pause for s seconds on a chart in the document (Sel Chart Pause 223). Appendix 1 contains a more complete Bayesian network in an exemplary embodiment of a spreadsheet application. Figure 26 represents an exemplary embodiment of temporal knowledge and inference. Each observable modeled event is annotated with information about the effects of time flow on the probabilistic relationships of the event with other variables in the Bayesian network. In this case, each node is annotated with temporal dynamics information about a horizon and decay, which may be implemented as a table of probabilities or other data structure. The dimensions of time for the temporal dynamics of each variable are indicated in seconds tiiat have occurred since the event became true. We now provide an example of a case based on components in the knowledge base displayed in Figure 26. Let us consider a case where we have die following profile information: User_Background 212: Consumer_Novice HX_Help_Charting 221 : No_Help_Reviewed Context: Normal View Objects :Sheet( 1 ),Chart(2) At time t=50 seconds, we have noted die following modeled events: Chart_Cmd_Undo 224: Absent Chart_Create_Pause 225: Absent Sel_Chart_Pause 223: Absent Move_Chart_Pause 226: Absent Chart_Dialog_UnSucc 227: Absent Menu_Surfing 228: Absent Click Unrelated 229: Absent Sel Chart Pause 223 p(E 1 ,t H ) ,t 0 ) = .15 p(not(E,)| H,, t 0 ) = .85 p(E„t o |not(H J ),t o ) = .005 p(not(E,), t 0 1 notfl-L . ), t 0 ) = .995 Horizon: 5 seconds Dynamics: p(E„ t 0 1 H j , t 0 ): linear convergence at 15 seconds p(E,, t 0 |not(H,), t 0 ): linear convergence at 15 seconds Chart_Dialog_Unsucc 227 p(E 2 ,t o |H J ,t o ) = .08 p(not(E 2 )|H ] ,t 0 ) = .92 p(E 2 ,t o |not(H J ),t o ) = .0005 p(not(E 2 ),t not(H J ),t 0 ) = .9995 Horizon 20 seconds Dynamics: 0 A cycle of analysis is initiated at t=50 seconds. The cycle includes die composition of modeled events from atomic events local storage 102, the transmitting of the events to the Inference System 76, and inference with the new observations. We will explore the current probability that die primary assistance needed by die user is help witii charting information, p(Charting_Assistance|E). The prior probability of the user needed help in this area conditioned on the user background, competence, and history of reviewing help is .001. The context information has increased this to a probability of .04. Probabilities are also assigned to otiier hypotiieses about the primary assistance as a function of all of the evidence seen so far (but tiiat is not explicit in this example). At t=52 seconds die user selects a chart. The atomic event of chart being selected is detected and is stored in the atomic event local storage 102. The user then pauses for 3 seconds without doing anytiiing. A dwell of 3 seconds is detected in die event local storage 102. A cycle of analysis is called at t=60 seconds. A modeled event Sel_Chart_Pause 223 is composed by die Event Processor 74, tagged as becoming true at t=55 seconds, and is sent to die Inference System 76. The Inference System accesses die Bayesian network that is annotated with temporal dynamics information. As indicated in the table of probabilities for Sel_Chart_Pause 230, there is a horizon of 5 seconds, and a linear convergence of probabilities to the probabilities of absent at 15 seconds. At t=63 seconds, die user selects a chart dialog and cancels the dialog witii out success at t=66 seconds. A cycle of analysis is called at 70 seconds, and d e modeled event Chart_Dialog_Unsucc 227 is composed and passed to the Inference System 76 with a time stamp of 66 seconds. As indicated in d e table of probabilities for Chart_Dialog_Unsucc 231, there is a horizon of 20 seconds, and no temporal dynamics. This user has set die threshold for being bothered with automated assistance at p=.12. Thus, the user is offered assistance on charting when the probability that this topic is relevant rises to p= .14. At t = 50 seconds p(Sel_Chart_Pause, t 0 | H, , t p ) = .15 p(Sel_Chart_Pause, t 0 |not(TL), g = .005 p(not(Sel_Chart_Pause)| H, , g = .85 p(not(Sel_Chart_Pause)jnot(H j ), g = .995 p(Chart_Dialog_Unsucc, t 0 1 H j , = .08 p(Chart_Dialog_Unsucc, t 0 |not(TL), g = .0005 p(not(Chart_Dialog_Unsucc)|not(H,), g = .9995 p(not(Chart_Dialog_Unsucc)| H j , g = .92 Inference result: p(Charting_Assistance|E, = .02 At t = 60 seconds p<Sel_Chart_Pause, t 0 1 H,, g = .15 p(Sel_Chart_Pause, t 0 |not(H j ), g = .005 p(not(Sel_Chart_Pause)| H,, g = .85 p(not(Sel_Chart_Pause)|not(H j ), g = .995 p(Chart_Dialog_Unsucc, t α | H j , g = .08 p(Chart_Dialog_Unsucc, t 0 |not(TL), g = .0005 p(not(Chart_Dialog_Unsucc)|not(H j ), g = .9995 p(not(Chart_Dialog_Unsucc)| H j, t p ) - .92 Inference result : p(Charting_Assistance|E, = .07 At t = 70 seconds p(Sel_Chart_Pause, t 0 1 H , g = .15 -> .46 p(Sel_Chart_Pause, t 0 |not(H i, g * = .005 -> .66 p(not(Sel_Chart_Pause)|not(TL), t p ) = .995 p(not(Sel_Chart_Pause)| H J5 g = .85 p(Chart_Dialog_Unsucc, t 0 1 H } , g = .08 p(Chart_Dialog_Unsucc, t 0 Inou LJ, g = .0005 p(not(Chart_Dialog_Unsucc)|not(H J ), g = .9995 p(not(Chart_Dialog_Unsucc)| H,, t p ) = .92 Inference result: p(Charting_AssistancejE, g= .04 At t = 80 seconds p(Sel_Chart_Pause, t 0 1 H,. g = .15 -> .46 -> .85 p(Sel_Chart_Pause, t 0 |not(H,), g = .005 --> .66 --> .995 p(not(Sel_Chart_Pause)|not(H ] ), g = .995 p(not(Sel_Chart_Pause)| H, , β .85 p(Chart_Dialog_Unsucc, t 0 1 H } , g = .08 p(Chart_Dialog_Unsucc, t 0 |not(H,), = .0005 p(not(Chart_Dialog_Uπsucc)|not(H J ), g = .9995 p(not(Chart_Dialog_Unsucc)| H, , g = .92 Inference result: p(Charting_Assistance|E, g= .13 At t = 90 seconds p(Sel_Chart_Pause, t 0 1 H,, g = .85 p(Sel_Chart_Pause, t 0 |not(H j ), t p ) = .995 p(not(Sel_Chart_Pause)|not(H,), t p ) = .995 p(not(Sel_Chart_Pause)| H,, = .85 p(Chart_Dialog_Unsucc, t 0 j H j , g = .08 p(Chart_Dialog_Unsucc, t 0 |not(H j ), g = .0005 p(not(Chart_Dialog_Unsucc)|not(H,), g = .9995 p(not(Chart_Dialog_Unsucc)| H,, = .92 Inference result: p(Charting_Assistance|E, = .04 Svstem Level IUAF for Multiple Applications The methods described can not only be applied to individual applications, tiiey can also be employed at the operating system level to reason about providing assistance in a system with multiple applications. In an exemplary embodiment to provide system assistance, a Bayesian network is used to assist a user witii exiting an application by guessing when the user has completed or will soon be completing a task. A Bayesian network knowledge base for assisting a user with this task is displayed in Figure 27. Profile information including wheti er or not die user has reviewed help in past (Reviewed_Heip_in_Past 240), has exited before (User_Exited_Before 241), and has demonstrated tiiat they can perform a double-click operation (Successful_Double_Click 242) are included. Modeled events represented as observations in the Bayesian network include dwell after activity (Dwell after Activity243), sequence of clicks on a sequence of unrelated graphical icons (Click on Seq of Unrelated 244), mouse meandering (Mouse Meandering 245), whether a document has been recently printed (Print Doc 246) or a message has been sent (Send Msg 247), and die duration of time an application has been up (Duration of Time with App 248). A variable represents a probability distribution over the most desired action, allowing us to use probabilistic inference to reason about the likelihood of alternative best actions. The sample scenario, demonstrates the results of the effect of monitored events on inference about the user. The sample case assumes the following profile: die user has not exited before on his/her own, the user has not demonstrated a successful double-click action, the user reviewed help about exiting applications but did not dwell on the information. The system now detects that die user has been in email for almost 10 minutes, and that die user has clicked on an unrelated sequence of graphical icons. Figure 28 displays die states of each random variable, and shows, by die length of bars next to the states, the probability over different states of each random variable. As demonstrated by the bar graph, the Inference System 76 has computed tiiat there is a high probability the user is ignorant about exiting (User Ignorant about Exit 249) and a low probability that the user has or will shortly complete a major task (Major Task Completed 250). In Figure 29, we see the results of inference after new modeled events are considered. In this case, die user has sent email (Send Msg 247) and has now dwelled for more than three scaled seconds after activity (Dwell after Activity 243). Providing a tip to the user is now identified as die most desired exit-related action (Most Desired Exit Action 251). Figure 30 shows the same scenario with one change: the user has received help or assistance witiiin the last two minutes (Recent rec Exit Help 252). Now the most likely desired action is to do notiiing, followed by asking the user if the system should exit the application for them (Most Desired Exit Action 251). IUAF Controller There is typically a need for the overall control of various components of the Intelligent User Assistance Facility. Controls are needed for making decisions about the policy for calling the Event Processor 74 and Inference System 76, and for deterr ining when assistance should be provided autonomously. Figure 31 is a diagram illustrating various overall coordinative control modes of die Intelligent User Interface controller tiiat may be used separately or togetiier in combination. The first coordinative control mode illustrated is the timer mode 260 in which a repeated system timer fires to notify the IUAF controller to begin another cycle of monitoring and inference analysis (step 261). The IUAF controller then invokes the inference system (step 262). Upon completion of the inference analysis, the controller waits until the timer fires again (step 263). The timer mode can be extended to consider otiier constraints before allowing a cycle to begin. For example, in cases where complex inference occurs during event monitoring and inference, the additional condition of assessing the availability of computational resources (e.g., identifying whetiier there is idle time) can be added. Thus, die cycle of event processing and inference will occur when a timer fires and when there is also a condition of computational resource availability. The second mode illustrated is die demand mode 265. This mode only performs inference analysis when the user asks for assistance. When an instrumented application receives a query for help information (step 266), the instrumented application sends notification to die IUAF controller (step 267). As a result of receiving the notification, the IUAF controller then invokes the inference system (step 268). Upon completion of the inference analysis, the controller waits until it receives the next notification (step 269). The third mode illustrated is d e special event trigger mode 270. In this mode, tiiere is a list of special events that trigger a cycle of inference analysis. Whenever the event processor detects an occurrence of one of the special events (step 271), the event processor sends notification to the IUAF controller (step 272). Again, the IUAF controller then invokes the inference system as a result of receiving the notification (step 273). Upon completion of the inference analysis, the controller waits until it receives the next notification (step 274). Any two or all three modes may be active at the same time. In the case when all three modes are active, if the user has not asked for assistance and has not initiated any user actions that translate into one of the special events during the period of die timer, then a cycle of inference analysis would occur when the period of the timer expired. Otherwise, the cycle of inference analysis would occur during d e period of die timer when the user asked for assistance or initiated a user action that translated into one of the special events. Integration of Analysis of Free-Text Ouerv with Events As mentioned earlier we can treat words in a user's free-text query for assistance as sources of modeled events. The Microsoft Answer Wizard integrated in all applications of the Microsoft Office '95 product line makes use of a probabilistic model relating words in free-text query to the probability of relevant help topics. This has been described in U.S. Patent Application No. 08400797 and is incorporated hereby by reference in its entirety. In one exemplary embodiment, words and actions can be handled togetiier in a uniform way as modeled events in a system that reasons about the probabilistic relevance of words and actions. In an alternate embodiment, there are separate subsystems for handling words and for handling actions. The analyses of these separate subsystems are combined after separate probabilistic analyses are completed. Figure 32 is a flowchart of the metiiod for combining separate probabilistic analyses. First a Bayesian analysis of the most relevant help topics is computed for d e given free-text query (step 280). This may be done following the methods described in U.S. Patent Application No. 08400797. The next step is to output a list of help topics in rank order by the highest probability of relevance (step 281). Then a second Bayesian analysis of die most relevant help topics is computed for d e given program state, user profile and sequence of user actions (step 282). The next step is to output a second list of help topics in rank order by the highest probabϋity of relevance (step 283). Then both of these lists of help topics are combined, after assigning a weight to the help topics on each list, by computing the probability that each help topic which is the same on both lists is relevant (step 284). The final step is to output the combined list of help topics in order of highest probability of relevance (step 285). In tiiis embodiment, the performance of die system can be tuned by weighting the results of one set of events more heavily than the other by changing the value of a real-numbered parameter that is used to multiply the likelihoods assigned to the probabilities of hypotheses of interest (e.g., relevance of help topics) provided by die word or action analyses. Building separate systems for analyzing the handling of words in a free- text query and user actions allows the two subsystems to be separately optimized based on specific properties of each class of events. The same can apply to otiier sets of actions, such as vision and speech events in systems with event monitoring that is extended witii these additional sensory modalities. Separate analyses also allow for d e ease of implementing specific policies on combining the results, separating them, or sequencing them. For example, an embodiment might display an initial guess of assistance based on inference based on monitored actions, but when words are added, rely solely on the analysis based on die words, given die performance of a word analysis systems versus an action system. An alternative approach is to have control rules about the combination versus separation of the inference in different subsystems based on a comparative analysis of the results of the words and actions analysis. Control of Communicating and Performing Assistance Beyond coordinative control functions, die IUAF controller also makes decisions about when to bother the user with autonomous assistance or with queries for information about the user's goals (based on value of information computations). In an exemplary embodiment, a special Bayesian network, or component of a network, resident in the Inference system 76 computes die overall probability tiiat a user would like assistance at the current time. The IUAF controller uses this changing probability to control when autonomous help is provided. The IUAF provides autonomous help whenever the computed probability that a user would like assistance at that time exceeds a tiireshold which may be changed by the user. A users changes the threshold for offering autonomous assistance using a threshold controller. The threshold controller, for example, may be in the form of a sliding threshold control can be displayed to users on an autonomous help window, allowing them to change the tiireshold depending on die value tiiey find in receiving help versus the distraction it causes. A screen shot of a dynamic assistance window witii a threshold slider is displayed in Figure 22. Figure 33 is a flowchart of the method of providing autonomous assistance in this embodiment. During a cycle of inference analysis, the inference system 76 outputs a list of relevant help topics in order of highest probability of relevance (step 290). This may be done as described previously in the discussion of the inference system. The next step is to determine whether the probability of the user needing help exceeds the threshold set by d e user for providing autonomous assistance (step 292). If the probabUity of the user needing help exceeds die tiireshold set by die user, tiien the inference system 76 provides a list of relevant help topics in the order of highest probability (step 294). The list may be truncated so as to only show the most likely or several most likely topics, but within a window tiiat allows the user to scroll through a longer list if desired. Next, the list of relevant topics are checked for redundant help topics tiiat have appeared in d e previous list witiiin a specified time period (step 296). If tiiere are no redundant help topics, the list is displayed to d e user (step 298). If die user responds to die autonomous offer of help, then steps 290 through 298 are repeated until the user fails to respond before expiration of the response timer. If the user fails to respond before the expiration of the response timer, then a message of apology is displayed on the title of the window (step 299) and die window is subsequently removed. Those skilled in die art will recognize that alternate embodiments may be used such as only offering autonomous assistance when directly requested by die user, e.g. by clicking on a graphical icon associated with the intelligent assistance facility. The system can also use computed measures of expected utility or its approximation for offering autonomous assistance. Furthermore, the system could only offer autonomous assistance when the sum of the individual probabilities of the relevance of each topic in the set of topics tiiat will be offered to provide assistance exceeds some constant value. In an exemplary embodiment, guesses on help topics are not presented when a user requests assistance, unless die probability computed for die top five topics togetiier do not sum to at least .40. In yet another alternate embodiment, autonomous assistance will not be offered unless die user is pausing, so as to not distract die user while the user is engaged in activity unless it is deemed important to assist the user with that activity while the activity is in progress. It can also be useful to provide social conventions and metaphors. For example, the results of inference can be used to control the behavioral gestures of a graphical social cartoon character. An example of this kind of interface is displayed in Figure 34. IUAF inference results about likely problems the user is having or potentially valuable assistance might be alternately be displayed in a "thought cloud" metaphor over a character's head. Free-text queries can be typed into a graphical text input box that appears to be a means for a character to see or listen to the query. Speech Recognition Enhancement via Integration with IUAF Components Those skilled in die art of speech recognition will appreciate the power that could be gained if die speech language models used to characterize phonemes by probability were dynamically influenced by information computed about die goals, intentions, or needs of computer users. As portrayed in the influence diagram in Figure 12, user background and goals influence d e actions seen in an interface, the words used in free text query, and the speech utterances generated by users in attempting to communicate with a software system or application. Understanding the likelihood of goals and intentions of users in making utterances can enhance our ability to perform automated speech recognition. Such systems will allow us to adjust d e probabilities over utterances, and tiius, the likelihood of words, and phonemes being uttered by users of computer software. Speech recognition involves processing the audio signal generated by an utterance into likely phonemes, and die processing of phonemes into likely words. Probabilistic systems for speech recognition may compute the likelihood of phonemes given d e audio signal and die likelihood of alternate words given the signal. The term speech is used to refer to the evidence provided by die steps of processing an utterance into audio signals or into phonemes. Bayesian speech understanding systems compute die probability of word or stream of word from an utterance as follows: p(words| speech) = p(words) * p(speech | words) p(speech) By computing me probability over a user's needs or goals given user actions as represented by modeled events (including those based on gaze), we can refine the accuracy of the probability of words given a user speech as follows: We can update die likelihood tiiat words or word strings will be used in die context of goals by representing the likelihood that words or word strings will be used in the context of specific goals, and update d e base probabilities tiiat words will be used, p( words), contained in a typical language model in real-time. That is, instead of using a static database of p( words), we instead update the probability of words as follows: p(words) = , p( words | user needsj * p(user needs,) This computation takes advantage of a knowledge base of context-specific language models tiiat contain information of the form p( words) = Σ, p(words | user needs,). At run-time, actions are analyzed by the Event Monitoring System and are passed to d e Inference System which provides dynamically die continually recomputed probability distribution over user needs, p(user needs | events) as described above. One exemplary application is the reasoning about help topics, and context specific language models contain information of the form p(words | relevant help topic). In a more general statement showing die modification of die above equation for speech recognition, we input dynamic events p(words I speech, events) = Σ, p(words I user needs,, events) * p(user needs, | events) J * p(speech | words) p(speech) This can be reduced to: p( words | speech, events) = p( words [ events) * p(speech | words) p(speech) Figure 23 displays die key components and flow of analysis employing key components of the intelligent user assistance facility to enhance speech recognition by dynamically changing the likelihoods over words, and thus, phonemes uttered. As displayed in the figure, user actions are tracked by an instrumented program 72, and atomic events are composed into modeled events by die Event Processor 74 and passed to the Inference System 76. The inference system computes a probability distribution of die needs of a user and the weighted list of needs are passed to a Dynamic Language Model Generator 300. The Dynamic Language Model Generator 300 has a mapping between alternative needs and die likelihood of utterances or words. This component may contain information from a Language Model Database 301 that contains language models containing probabilistic information of the form, p(words | user need), die probabilities of different words or word strings being uttered by a user given the user needs. These language models can be constructed dirough training with statistics from a large corpus of strings of words tiiat are recorded in different user-needs contexts. At run-time, the Inference System provides a probability distribution over user needs which is used to control the creation of an updated language model, based on weighting the language models from the different contexts. The updated language model 302 contains information of the form, p(words | events), created by weighting sets of words in terms of die likelihood of alternative needs based on die probabilistic inference results. Overall, taking advantage of context in listening can enhance the accuracy of speech recognition system 303 by lowering the probability of utterances that are unlikely and raising the probability of utterances that are more likely, per the user modeling. Beyond use with software in receiving assistance, the dynamic speech understanding has application in variety of speech understanding tasks. As one example, the methods have application in a variety of interfaces with command and control, referring to the manipulation of controls and functionality of software. If we model die goals of die user, we can generate grammars that are appropriately weighted to reflect die next steps of d e user, and mere are less prone to error. These methods can be used in conjunction with models tiiat generate the probability of the next software command given user goals. In this approach we focus on a particular user need, die desire for action. The user's desire for action may refer to the implementation of one or more software controls by speech, including die access of one or more help topics. We substitute p(desired action | events) for p(user needs | events) in the above equations, and employ language models tiiat contain information p( words I desired action), instead of p(words | user needs). Events considered in this model can include context which may include information about the window that is active and the text, buttons, and controls that are displayed to die user while the speech utterance is occurring. For example, dynamic language models for command and control have application in systems that explicitly generate and display probabilistic results as part of their functioning. Consider as an example, a probabilistic reasoning system that employs a Bayesian network or influence diagram for assisting a physician witii diagnosis from a set of symptoms. Bayesian reasoning systems in medicine may have sets of windows containing the results of diagnostic inference. A window may list diseases by computed likelihoods, anotiier may list the best next symptoms or tests to evaluate, based on value of information. By building or assessing a model of die probability of the user's actions given the context of displayed information, which may include functions of die computed probabilities and expected utilities assigned to displayed objects, we can compute and use a dynamically re-computed p( words events) in speech recognition. While die present invention has been illustrated with reference to exemplary embodiments, those skilled in the art will appreciate that various changes in form and detail may be made widiout departing from die intended scope of the present invention as defined in die appended claims. For example, the general event composition and inference system may also be used in an operating system to provide an intelligent user shell and, more generally, to optimize the functionality of any computer system or software. Because of the variations tiiat can be applied to die illustrated and described embodiments of the invention, the invention should be defined solely with reference to the appended claims.

Claims: Claims 1. A method of building an intelligent user interface facility for a software program to assist a user in operating the software program, comprising the steps of: identifying program functionality of the software program for providing intelligent user assistance, building a reasoning model for the task of providing d e intelligent user assistance for the identified program functionality of the software program, defining modeled events for the identified program functionality for use by the reasoning model to provide intelligent user assistance, and identifying for each modeled event one or more atomic user-interface actions that signify the occurrence of each modeled event. 2. The method of claim 1 further comprising the steps of: constructing an event monitor to capture the identified atomic user-interface actions, and integrating the event monitor with the software program to instrument that program for intelligent user assistance. 3. The method of claim 1 further comprising die step of: constructing an event processor to compose modeled events from atomic user- interface actions. 4. The method of claim 1 further comprising the step of: constructing a knowledge base from the model, and constructing an inference engine from the model which uses die knowledge base to determine suggested user assistance for the occurrence of modeled events. 5. The method of claim 4 wherein the determination of suggested user assistance is performed by a probability analysis inferring the most likely user assistance that is helpful given the occurrence of specific modeled events. 6. The metiiod of claim 5 wherein a Bayesian network is employed to perform the probability analysis. 7. The method of claim 5 wherein a Bayesian influence diagram is employed to perform the probability analysis. 8. The method of claim 1 wherein the modeled events include contextual information about die state of data structures in die program. 9. The metiiod of claim 1 wherein the modeled events include words in a free-text query seeking help information in using the program. 10. The method of claim 1 wherein the software program executes on a computer system with a speech recognition system and die modeled events include words identified by die speech recognition system. 11. The method of claim 1 wherein the software program executes on a computer system, that includes a display screen and a vision recognition system, and the modeled events include the focus, identified by die vision recognition system, of a user's gaze on the screen. 12. The method of claim 1 wherein the modeled events include menu commands of die program. 13. The method of claim 1 wherein the modeled events include a time period during which there is no user activity. 14. The method of claim 1 wherein the software program executes on a computer system with a display screen and die modeled events include text displayed on die screen followed by a period of dwelling and a subsequent scroll. 15. The metiiod of claim 14 wherein the text displayed on d e screen is help information and die modeled event is used for indicating a user's competency in using specific program functionality. 16. The method of claim 14 wherein the modeled event of the text displayed on die screen followed by a period of dwelling and a subsequent scrolls is used for tracking a user's indication of interest in the textual information. 17. The method of claim 16 wherein the text is stored in the modeled event database. 18. The metiiod of the claim 16 wherein the path of the text's location is stored in die modeled event database. 19. A computer readable medium having computer executable instructions for performing the steps of claim 1. 20. An intelligent user interface facility for a software program to assist a user in operating the software program, comprising: an event processor that obtains events from the software program, and an inference system tiiat determines suggested user assistance from die occurrence of die events. 21. The intelligent user interface facility of claim 20, wherein the software program is instrumented to monitor user interface actions and to extract user interface events. 22. The intelligent user interface facility of claim 20, wherein the software program is an application program. 23. The intelligent user interface facility of claim 20, wherein the software program is an operating system program. 24. A computer readable medium having computer executable components of claim 20. 25. The intelligent user interface facility of claim 20, wherein die event processor composes the events into modeled events. 26. The intelligent user interface facility of claim 20, further comprising: a user profile system that maintains an historical record of events for die user tiiat is used by die inference system in determining suggested user assistance from the occurrence of events. 27. The intelligent user interface facility of claim 26, wherein the modeled event database is initialized by persistent modeled events for the program which are stored in the user profile of the user of the program. 28. A computer readable medium having computer executable components of claim 26. 29. The intelligent user interface facility of claim 20, further comprising: a controller for initiating a cycle of inference analysis by the inference system. 30. The intelligent user interface facility of claim 29, wherein the controller initiates a cycle of inference analysis on a periodic cycle. 31. The intelligent user interface facility of claim 29, wherein d e controller initiates a cycle of inference analysis whenever one or more events has occurred. 32. The intelligent user interface facility of claim 29, wherein the controller initiates a cycle of inference analysis whenever the user activates the help facility of the program. 33. The intelligent user interface facility of claim 20, wherein the suggested user assistance is a list of help topics. 34. The intelligent user interface facility of claim 33, wherein the inference system uses probabilistic inference analysis to determine the list of help topics and die inference system lists only those help topics which have a likelihood of relevance given die occurrence of the events that exceed a confidence measure. 35. The intelligent user interface facility of claim 34, wherein the inference system lists those help topics, which have a likelihood of relevance that exceed die confidence measure, in a scrollable dialog box in order of highest probability value. 36. The intelligent user interface facility of claim 34, wherein the inference system offers assistance autonomously to the user whenever the likelihood tiiat a help topic is relevant given the occurrence of the events exceeds a tiireshold value. 37. The intelligent user interface facility of claim 36, wherein the threshold value is set by the user. 38. The intelligent user interface facility of claim 34, wherein the inference system combines the probabilistic inference analysis to determine the list of help topics given the occurrence of events with a probabilistic inference analysis to determine a list of help topics given a free-text query. 39. The intelligent user interface facility of claim 38, wherein the inference system lists only those help topics of die combined analysis which have a likelihood of relevance that exceed a confidence measure. 40. The intelligent user interface facility of claim 34, wherein the inference system only uses a probabilistic inference analysis of the words in die free-text query to determine a list of help topics whenever a user enters a free-text query. 41. The intelligent user interface facility of claim 20, wherein the inference system determines suggested user assistance using probability and offers assistance autonomously to the user whenever the inference system determines that the probability that the user needs assistance given die occurrence of die events exceeds a tiireshold value. 42. The intelligent user interface facility of claim 41 , wherein the tiireshold value is set by die user. 43. The intelligent user interface facility of claim 20, wherein the inference system requests information autonomously from the user whenever the inference system computes that the value of acquiring information from the user is greater than a threshold value. 44. The intelligent user interface facility of claim 43, wherein the threshold value is set by die user. 45. The intelligent user interface facility of claim 20 wherein the inference system determines suggested user assistance from both the occurrence of the events and a free-text query submitted by the user. 46. The intelligent user interface facility of claim 20 wherein the suggested user assistance is provided to the user through a social user interface in the form of an animated character. 47. The intelligent user interface facility of claim 20, wherein the event processor and die inference system are implemented as a single component chosen from the group consisting of a software program, a software library or an instantiated object. 48. The intelligent user interface facility of claim 20, wherein die event processor obtains only a specific number of the last occurring events during a cycle of inference analysis. 49. An event processor in a computing device having an event source comprising: a local store for temporarily storing die events; a composer for generating modeled events from one or more events; and a database for storing the modeled events generated. 50. The event processor of claim 49, wherein die events stored in tthe local store are assigned a horizon. 51. The event processor of claim 49, wherein the modeled events generated have an assigned horizon. 52. The event processor of claim 49, wherein the events are user-interface actions. 53. The event processor of claim 49, wherein die source of events is chosen from the group consisting of a software program, a software library or an instantiated object. 54. The event processor of claim 49, wherein the events are atomic events and die composer generates modeled events from one or more atomic events. 55. The event processor of claim 49 wherein the events are atomic events and die composer generates modeled events from one or more atomic events and from one or more modeled events. 56. The event process or claim 49 wherein the composer generates modeled events from one or more modeled events. 57. The event processor of claim 49 wherein the local store is a circular queue. 58. The event processor of claim 49 wherein the local store is a database. 59. The event processor of claim 49 wherein the database for storing the modeled events is in system cache. 60. The event processor of claim 49, wherein there is a single record for every modeled event for that database. 61. The event processor of claim 49 wherein me database contains records tiiat include a set of counters of the number of times a modeled event has occurred. 62. The event processor of claim 49 wherein a record of the database contains horizon and probability dynamics information. 63. The event processor of claim 49 wherein a record of die database is marked for persistent storage. 64. The event processor of claim 49, wherein the modeled events generated are logical events. 65. The event processor of claim 49, wherein there is a separate database for each source of events tiiat stores the modeled events generated. 66. The event processor of claim 49, wherein there is a separate database for each source of events that stores the modeled events generated and a general database tiiat stores common system or application events. 67. A computer readable medium having computer executable components of claim 49. 68. An event system specification tool for a computing device comprising: an event language for specifying modeled events; and an event language interpreter for translating statements of die event language into a target code language. 69. The event system specification tool of claim 68, wherein the event language interpreter is used for translating statements of the event language into modeled database definitions. 70. The event system specification tool of claim 68, wherein the event language includes temporal operators. 71. The event system specification tool of claim 68, wherein the event language includes Boolean operators. 72. The event system specification tool of claim 68, wherein the event language includes set-tiieoretic operators. 73. The event system specification tool of claim 68, wherein the modeled events are some of the variables of a reasoning model and die event language includes temporal functions that define die persistence of probabilistic relationships between one or more modeled events. 74. The event system specification tool of claim 68, wherein the modeled events are some of the variables of a reasoning model and die event language includes temporal functions that define the persistence of probabilistic relationships between one or more modeled events and one or more other variables in the reasoning model. 75. The event system specification tool of claim 74, wherein the reasoning model is a Bayesian network. 76. The event system specification tool of claim 74, wherein the reasoning model is rule-based. 77. A computer readable medium having computer executable components of claim 68. 78. The event system specification tool of claim 70, wherein a temporal operator is chosen from the group consisting of rate, sequence and dwell. 79. An inference system for an intelligent user interface comprising: a knowledge base tiiat includes temporal reasoning knowledge; and an inference engine that includes temporal reasoning component. 80. The inference system of claim 79 wherein the knowledge base is a Bayesian network. 81. The inference system of claim 79 wherein the knowledge base is a set of logical rules. 82. The inference system of claim 79 wherein the inference engine is a Bayesian network. 83. The inference system of claim 79 wherein the inference engine further includes a value-of-information component that computes the probability mat the value of acquiring information from the user is greater than a threshold value. 84. A computer readable medium having computer executable components of claim 79. 85. A Bayesian network comprising: nodes representing hypotheses, nodes representing observed evidence, and temporal reasoning approximation function associated with at least one of the observed evidence nodes to compute die probability of die relevance as it changes with die passage of time. 86. The Bayesian network of claim 85, wherein the observed evidence are modeled events of user actions. 87. A method for an inference system to autonomously acquiring unobserved information, given the occurrence of specific events, from a user to determine suggested user assistance, comprising computing the probability that the value of acquiring information from the user is greater than a threshold value. 88. A user profile system for providing intelligent user-interface assistance for a software program, comprising: a user profile database which persistently stores records of user's experience witii functionality of the software program, a user profile access component that access a user's records of experience with functionality of the software program , and an event status update component which updates die user's records of experience with functionality of the software program as the user interacts with the software program. 89. The user profile system of claim 88, further comprising: a user competency dialogue component which establishes user competency by obtaining information about a user's background with the functionality of the program. 90. The user profile system of claim 88, further comprising: a user competency dialogue component which establishes user competency by obtaining information about a user's goals with die functionality of the program. 91. The user profile system of claim 88, further comprising: a user competency dialogue component which establishes user competency by obtaining information about a user's experience with the functionality of the program. 92. The user profile system of claim 88, further comprising: a customize tutorial component which list in rank order die most useful information topics to train the user in the functionality of the software program. 93. The user profile system of claim 88, wherein the user profile database contains at least one record of a successful completion of a program command. 94. The user profile system of claim 88, wherein the user profile database contains at least one record of a unsuccessful completion of a program command. 95. A computer readable medium having the computer executable components of claim 88. 96. An intelligent user interface facility for a software program to assist a user in operating the software program mnning on a computing device witii a speech recognition system having a language model with probabilities associated with words of die language, comprising: an event processor that obtains events from the software program, an inference system tiiat deteπnines suggested user assistance from the occurrence of the events, a dynamic language model generator that uses the suggested user assistance determined by die inference system to modify probabilities of the words of die language recognized by die speech recognition system . 97. The intelligent user interface facility of claim 96, wherein the software program is instrumented to monitor user interface actions and to extract user interface events. 98. The intelligent user interface facility of claim 97, wherein die software program is an application program. 99. The intelligent user interface facility of claim 97, wherein the software program is an operating system program. 100. The intelligent user interface facility of claim 99, wherein the operating system uses the speech recognition system for command and control of die computing device. 101. A computer readable medium having the computer executable components of claim 96. 102. A method for modifying die probabilities of words in a language model database tiiat are recognized by a speech recognition system comprising the steps of: receiving user actions from an instrumented program, composing modeled events from the user actions, employing probabilistic inference to compute a probability distribution of die needs of a user from the modeled events, and modifying the probabilities of the words in the language model database tiiat are recognized by die speech recognition system using the probability distribution. 103. The metiiod of claim 102, wherein the instrumented program is used for directing software controls with speech. 104. The method of claim 102, wherein the instrumented program is used for receiving spoken help queries. 105. A computer readable medium having computer executable instructions for perforating the steps of claim 102.

Inventors: BREESE JOHN S, HECKERMAN DAVID E, HOBSON SAMUEL D, HORVITZ ERIC, HOVEL DAVID O, KLEIN ADRIAN C, ROMMELSE JACOBUS A, SHAW GREGORY L, BREESE, JOHN, S., HECKERMAN, DAVID, E., HOBSON, SAMUEL, D., HORVITZ, ERIC, HOVEL, DAVID, O., KLEIN, ADRIAN, C., ROMMELSE, JACOBUS, A., SHAW, GREGORY, L.
Applicants: MICROSOFT CORP, MICROSOFT CORPORATION
Application year: 1997
Main classification: G06F9
IPC codes: B82B1, G06F3, G06F9, G06N5