KnEd provides several methods for adding, removing, and changing values in the knowledge base. These methods are only available in the text panes.
The user can add values to a slot of a frame using the menu choices under the "Value Addition" label on the frame, slot, value, or annotation menus. The following are the characteristics of these menus:
frame menu - the user specifies the slot and the value to add.
slot menu - the user can add a value directly to the slot or can annotate the slot.
value menu - the user can add a semantic annotation or a value annotation.
annotation menu - the user can add other annotations.
Problem: When adding values, the user sometimes wants to add a value to a nested annotation that doesn't yet exist in the knowledge base. For example, the user might want to assert that "The leaves of plants are green":
Plant
parts: Leaves
LEAVES
color: Green
If the knowledge base includes the (Plant parts Leaves) assertion, then the user can simply annotate the value Leaves with the <color, Green> attribute. However, the knowledge base might not yet include this assertion.
Solution: The user enters an address instead of a single slot when adding values. In this case, the user would choose the "Add Value to Address" option on the frame menu and enter:
Address: (parts Leaf color) Value: Green
This causes the automatic creation of the (Plant parts Leaf) assertion, to which Leaf is annotated with the <color, Green> attribute. Without this feature, the user would have to create nested annotations one level at a time.
The user can remove values using the menu choices under the "Value Removal" label on the frame, slot, value, or annotation menus. The following are the characteristics of these menus:
frame menu - the user can delete the entire frame.
slot menu - the user can either delete the values of the slot or delete the slot values and all annotations connected to the slot.
value menu - the user can delete either the value or the value and all of its annotations.
annotation menu - the user can delete the annotation and any annotations nested within the annotation.
Problem: When removing a value from a slot, it's usually the case that the annotation should also be removed.
Solution: Since it's impossible for KnEd to determine when the annotation should be deleted, a menu appears asking the user to confirm whether the annotation should be deleted.
Values can only be changed using the value menu. The user selects "Change Value" from the value menu and enters what the new value should be. The value and all of its annotations are changed to use the new value.
Problem: When performing add, remove, and change operations, the user wanted to be sure the operations worked.
Solution: As operations are being performed, KM makes a list of frames that have been modified. KnEd then matches this list against the frames it has in its text panes. If it finds any matches, it updates the text panes so the user can see if the modifications worked.
Problem: Sometimes, the user only wants one text updated (updating can be time consuming when many panes are updated at the same time).
Solution: The user has the option of updating either all text panes, only the text pane an operation is being performed in, or no text panes at all. In the case of the latter option, the user can use a menu choice to force a text pane to update itself by choosing the "Redraw" option on the text pane menu.
Figure 25: An example of the copy frame window. The information that's highlighted will be copied to the Tulip frame.
Another feature desired by the user is the capability to copy existing information from one frame to another. This is supported by two different methods. The first method lets the user copy an entire frame. The user chooses "Copy Frame" from the frame menu and enters the name of the frame to copy to. A menu appears with the name of the new frame and the contents of the original frame. Via mouse clicks, the user selects the information to be copied. Figure 25 is an example of this copy frame window when copying the Rose-Plant frame to the Tulip frame.
Also, the user desired to copy only a subset of a frame. This resulted in a two step process. Via menu operations, the user first selects the segment of information they want to copy. The user can either select a slot and its annotations using the slot menu, or an annotation and its subannotations. The user then does an add operation, but instead of entering a value, he/she enters :a. This then brings up the copied information in a menu similar to the copy frame menu, from which the user selects the information they want added.
Problem: The user sometimes wanted to use the copy frame menu as a template, such that the values being copied could be changed.
Solution: By a mouse click, the user can choose values in the copy frame menu that they want changed. The copy frame menu is updated to reflect the new value.
Figure 26: An example of the inverse menu for the (Rose-Plant parts Leaf) assertion. By selecting the circle, the inverse (Leaf part-of Rose-Plant) is also installed.
When adding assertions to the knowledge base, it's possible that they will have inverses. For example, if (Rose-Plant parts Leaf) is asserted, then (Leaf part-of Rose-Plant) should also be asserted. Since it's not always clear when an inverse should be created, the user is given a menu that lets them choose whether he/she wants to add the inverse or not. Figure 26 is an example of the inverse menu for the (Rose-Plant parts Leaf) assertion.
It's possible that an assertion that's being added is incorrect. As assertions are added, KM performs many checks to make sure that the assertion is valid. If the assertion fails to meet any of KM's constraints, then the user is notified by a textual messages. There is currently no graphic interface to help the user view these messages.
Whenever the user performs an operation, there's always a chance that he/she made a mistake. So, KM was modified to keep track of changes made to the knowledge base. KnEd collects this information for each operation that is performed and gives the user the option of undoing the last operation by choosing "Undo" on the edit menu. The user can review all of the modifications made to the knowledge base during the last operation by choosing "History of Last Action" on the edit menu.
When entering information in the menus, it often became tedious for the user to type in the names of very long frames. So, a name completion mechanism was implemented. By typing a partial name followed by <tab>, the name is extended as far as uniquely possible. If there are no unique extensions of the name, then a menu appears listing all of the possible completions. If no extensions are possible, then the user hears a beep.
The user also wanted to copy information from the screen and insert it into the input menus. This resulted in a two step process. The user first copies the desired information into a buffer via <shift>-Left and <shift>-Middle commands (see Table 2). Then, when adding values, the user types @ to yank the information into the current input field.
Figure 27: Creating the Habitat slot using the slot creation menu
One repetitive operation performed by the user is the creation of slots. Since the user typically adds the same relations when creating a slot, a menu was created just for slot creation. Figure 27 is an example of this menu. One feature of the menu is that the domain and range only have to be entered once. If an inverse is given, then the domain is added to the inverse's range, and the range is added to the inverse's domain.