From: AAAI Technical Report WS-97-09. Compilation copyright © 1997, AAAI (www.aaai.org). All rights reserved.
The Use of Plans in Knowledge ManagementTasks
Louise Pryor
HarlequinLtd
TechnologyTransfer Centre,
King’sBuildings,
Edinburgh EH93JL, UK.
louisep@h
arlequin.co.uk
Abstract
This paper discusses howa plan executionsystemcould be
used to assist in a knowledgemanagement
task, such as
searching a set of databases for a relevant document.
PARETO
iS a plan executionsystembasedon the as-needed
expansionof a hierarchy of sketchy plans. It has been
adaptedfor use in several different domains.Thereare several problemsthat wouldarise in adaptingPARETO
to assist
in a knowledgemanagement
task such as searching for a
relevant document
in a proprietaryintranet. However,
there
are also advantagesthat wouldbe providedby the use of
sucha system.
Introduction
There are manytasks that involve the skilled analysis of
large amounts of information. Examples include a manager analysing sales figures; an actuary setting the loss
reserves for a casualty insurance company; an environmental scientist analysing data from satellites; an analyst
preparing standard data files from miscellaneous inputs;
and anybodysearching for information on the interact or
an intranet. These tasks are all performed in a similar
manner. Usually, there is a (possibly very abstract)
frameworkaround which they are structured: the details
are filled in as the task progresses, based on information
that is learned during the task execution. Sometimes,the
whole course of the task changes from that originally anticipated, again, based on circumstances encountered
along the way.
This short paper describes howthese tasks can be seen
as plan execution tasks; it discusses howan opportunistic
plan execution systemcould be used to assist in their performance. The problem of finding information stored in
Lotus Notes® is used as a running example, and is described in the remainder of this section. The following
sections briefly discuss howAI planning techniques are
applicable to this and other knowledgemanagementtasks,
with particular reference to PARETO,
a plan execution system; and discuss the advantages and disadvantages of using such a system.
Finding information in Lotus Notes
Lotus Notes organises documentsin databases. In order to
find a particular documentyou first have to find the relevant database and open it. You cannot tell what documents are in a database without opening it; and in order to
open it you have to add it to your personal workspaceif it
is not there already. 1 Somedatabases mayrequire a password. The commandsthat are needed in order to open a
particular database thus depend on both the database and
the state of the user’s workspace.
Once a database has been opened there are manydifferent ways in which it can be viewed. The possible views
vary between databases, but typically include such options as by author, by category, by topic, or by
time created.Some databaseshave much more specialised views. Complexviews are often arranged hierarchically: a database with information about the people in
a company, for example, may have views such as
Employee/by
first name, Employee/by
last
name, Employee/by
group, Employee/by
email,
Telephone
numbers/by
person
and Telephone
numbers/by
room. In such a database the information
about each employee would be represented as a separate
document.
It is common
practice to have a database available that
lists all the databases on a particular network. Again, this
database catalogue can be viewed in several different
ways:by server, by path, or by title, for example.Finding a documentwhose name and location are not
knownoften involves viewing the database catalogue in
various ways in order to find a likely looking database,
opening it, and looking through its various views for potentially useful documents. The specific commandsused
will vary according to the databases that are looked at and
the subject matter that is being sought.
Supposethat you are just starting a project involving
knowledge management, and want to find out what techniques have been used in other projects in the company.
Your overall approach is likely to consist of finding a
1RegularLotus Notes users will recognize that this description is somewhat
simplified.
32
likely database, looking at its contents througha number
of different views, and then browsingsomeof the documentsin the database (if any of themlook likely). You
mayalso follow some cross reference links to other
documents
(possibly in other databases), before trying the
first step, of finding a likely database, again. Theexact
details of your search cannot be predicted in advance,
althoughthis overall outline is very stable across episodes. Moreover,there are a numberof subtasks that are
often performed: adding a database to your workspace,
opening a database, choosinga way in whichto view a
database, performingfull text search on a document,and
so on. In fact, there are very fewsubtasksthat are unique
to a particular set of circumstances,althoughthe exact
keystrokes usedto performthemwill indeedbe unique.
Planning
A goodworkingdefinition of planning is that it is the
constructionof a set of actionsthat, if executed,will lead
to the achievementof a goal. Traditionally, planningin
AI has been based on three major assumptionsabout the
world:
Simple:the world is simple enoughthat the planner can
havecompleteknowledge
of every thing in it;
Static: nothing changesin the world except through the
planner’sownactions;
Certain: all actions haveentirely predictable, deterministic outcomes.
Underthese assumptions,it is possible to performclassical planning:construct a sequenceof actions that is guaranteed to achieve the goal, given the initial conditions.
Executinga plan constructedin this wayis a very simple
matter:, everythinghas beenfully predicted, so there is
nothing to do but execute the actions, whichare guaranteed to succeed.
There are very few domainsin whichthese assumptions
hold true: mostly, the world is complex,dynamic,and uncertain. It is impossibleto have completeknowledgeof
the world, there are other agents and exogenousevents
changingit, and actions mayhaveuncertain results. This
meansthat in most domainsthe classical planning paradigmis not applicableas it stands. It is simplyimpossible
to construct a plan that is guaranteedto succeedandthat
specifies the completedetails of everyaction that mustbe
performed.
The Lotus Notes domainis one in whichthe classical
planning assumptionsdo not hold. The principal wayin
whichthey fail is that the domainis complex;perfect
knowledgeof the domain would meanhaving complete
information about all databases and all documentsin
them. In addition, there is somedynamism,
as other users
modify,add or delete databasesand documents.In theory,
the domain
is certain, in that actions are deterministic,but
in practice the complexityand dynamism
lead to a perceptionof uncertainty.
There have been a numberof approaches to the prob-
33
(define-rap
(index (open-database
?database))
(succeed (open ?database))
(method
(context (in-workspace
?database))
(task-net
(tl (really-open
?database))))
(method
(context (and (not (in-workspace
?database))
(know-location
?database)))
(task-net
?database)
(tl (add-to-workspace
(in-workspace
?database) for t2)
?database))))
(t2 (really-open
(method
(context (not (know-location
?database)))
(task-net
(tl (find-location
?database)
(know-location
?database) for t2)
(t2 (add-to-workspace
?database)
(in-workspace
?database)
for t3)
(t3 (really-open ?database))))
Figure 1: Part of a RAPto open a database
lem of constructing plans in real worlddomains,including contingencyplanning(see, for example,[1,2,3]) and
decision theoretic planning (see, for example,[4,5]).
Other workhas addressed the problemof howto execute
plans in these domains.Theissues that arise during plan
executioninclude: specifyingdetails of actions basedon
the exact circumstancesencountered,choosingalternative
courses of action, handling unexpectedplan failure, and
recognisingandtaking advantageof opportunities[ 6,7,8].
Plan execution
Anapproachto plan executionthat has provedproductive
is one that uses a hierarchyof sketchyplans, expandedon
an as-neededbasis. Asketchy plan is one that that provides an outline of the actions to be performed,without
specifying all the details. Systemsbased on this notion
2 [7], both of
include the RAPSsystem [6] and PARETO
whichuse RAPS
(Reactive Action Packages)to represent
plans. A RAPconsists of a numberof steps, each of which
expandsinto either another RAPor a primitive action.
Executionconsists of expandingsteps; the exact formthe
expansiontakes dependson the circumstancesat the time
of expansion.If a step expandsinto a primitive action,
that action is performed. This execution modelallows
details to remainunspecifieduntil they are required in
order to decideexactly whatto do. Theinstantiations of
the sketchy plans dependon the situations actually encounteredduring plan execution, thus reducing the need
for unreliablepredictions.
Figure 1 showsa simple RAPthat mightbe used in our
2 Planning and Acting in Realistic
Environments by Thinking about Op-
portunities.
The economist, sociologist
and philosopher Vilfredo Pareto
(1848-1923) is best knownfor the notion of Pareto optimality and for the
Pareto distribution, neither of which is used in thel’ARETOsystem.
exampledomain. Each PaP has an index, whichis used
to retrieve its definition fromthe PaPlibrary. Anindex
mayinclude variables, denotedby a beginning question
mark. The succeed clause specifies the conditions under
whichthe PaPmaybe considered to have succeeded.This
is necessarybecausesimplyperforminga sequenceof actions does not guarantee success in a dynamicenvironment. The RAPshownin Figure 1 has three methodS,or
different ways in whichthe task can be performed. The
context clause of each methodspecifies the circumstances in which it is appropriate. The context is
checked against PA_P~TO’S
current world knowledge,
whichhas been gained through observation and feedback
from actions that have been performed. Each method
contains a ta~k-net, whichspecifies the actions to be
performedand the dependenciesbetweenthem. The full
syntax of gAPsand the details of the executionalgorithm
are givenin [9].
Opportunities
Animportant aspect of plan execution in complexdomainsis the handlingof opportunities.If it is impossible
to foresee everythingthat mighthappen,whichit is, you
haveto be able to handlethe unexpected.Unforeseencircumstancesmighthave no effect on your goals, but they
mightaffect themeither favourably,in whichcase there is
an opportunity, or adversely, in whichcase there is a
threat.
Opportunityrecognition is complexin two ways. First,
there is an enormousnumberof elementsin every situation that no agent can possibly predict. Noneof these
elementscan be ruled out a priori as neverbeing relevant
to anygoal. Suppose,for example,that youhavea goal to
open a can of paint. Theobjects in your garage include
your car, the shelves on the wall, engineoil, etc. Fewof
these are relevant to your current goal, but they maybe
relevant to other goals at other times. Second,there are
manysubgoalsinvolvedin achievinga goal. For instance,
to pry the lid off the paint can you must find something
that is the right size andshapeto act as a lever, a strong
rigid surface on whichyou can rest the can at a convenient height, andso on.
Theanalysis of each situation elementof a complexenvironmentin the light of each of the agent’s manygoals
would involve huge numbersof subgoals and situation
elementsand wouldpreclude a timely response to unforeseen situations. Moreover,such an analysis wouldrequire
the determinationof each goal’s subgoals, thus demanding
the existence of a plan to achievethat goal. However,
the
recognition of an opportunity maytrigger a radical
changeof plan or the constructionof a plan for a hitherto
unplanned-for goal. PARETO
Canrecognise and take advantageof opportunitiesin these circumstances.It uses a
filtering mechanism
that indicates those situations in
whichthere are likely to be opportunities and that will
thereforerepayfurther analysis. For a detailed description
of this mechanism,
see [ 10,7].
PARETO’Sopportunity recognition mechanism
relies on
34
referencefeatures for its effectiveness.Reference
features
represent the functional tendencies of elements in
PARETO’S
world:for example,an object with the reference
feature sharp tends to cut soft objects, scratch harder
ones, burst membranes
and sever taut strings. The term
sharp labels a collection of related effects. Knowledge
about causal effects is thus representedin PARETO
by attaching reference features to objects in the worldand to
its goals. PARETO
uses this knowledge
in its heuristic filters, without ever havingto reason explicitly about the
associatedcausal effects.
The concept sharp is useful just because manycommonlyarising humangoals involvestructural integrity. If,
however,welived in a worldin whichstructural integrity
was unimportant, we might well not even have such a
concept,let alone find it useful. Thereference features
that an agent finds useful dependon the tasks that it habitually performs. Agentsperformingdifferent tasks in
the sameworldmayattach completelydifferent reference
features to objects in their environments.
Properties that
are significant to one agent maybe completelymeaningless to another.
Plan execution
in knowledge management
PARETO
was originally developedin a simulated domain:
it manageda robot delivery truck in a world developed
using the TRUCKWORLD
simulator [9,11,12]. Firby has
used a later version of the RAPSsystem from which
PARETO
was developed to managea mobile robot [13].
PARETO
itself has been applied to two software domains:
environmental
planning[14] and UNIX
[15]. It is not especially difficult to write gaps for newdomains;in fact,
they have provided a surprisingly natural framework
within whichto analysetasks. It is likely that the RAPS
frameworkwould be equally suitable for a knowledge
managementdomain.
Advantagesof a tool based on plan execution
Theobviousquestionto ask at this stage of the discussion
is whatthe point of applyinga plan executionsystemto a
knowledge managementtask would be. Howwould the
user gain? Whybother? There are several waysin whicha
tool based on plan execution could makeknowledgemanagementtasks easier to perform. Beforediscussing these
advantages,however,wemustconsider the formthat such
a tool wouldtake. For reasons discussedin the following
section, ir is likely that it would not autonomously
perform knowledgemanagement
tasks but would instead
be a mixed-initiativetool: onethat interacts with the user
as they jointly worktowardsthe user’s goals. Ideally, the
level of autonomy
in the tool wouldbe adjustable to suit
the user’s wishes.
Thetool wouldprovide a structure within whichto perform the task. Dependingon the task in question, this
structure mightprovide an elementof quality control in
the task; ensuringthat certain necessarystages are passed
through,for example,or that itemson a check-list are all
covered. Like manyknowledge-basedsystems, the tool
wouldhelp novice users by supporting themas they performthe task. It couldoffer explanationsof the decisions
taken in termsof the RAP-based
task analysis. Byadapting
itself to the user’s preferencesand level of expertise, it
could gradually reduce the level of support offered as a
novice user becamemorecompetent.
In addition, the use of a tool basedon a systemsuch as
PARETO
would enable the user to perform the task at a
moreabstract level; the tool wouldessentially form an
interface betweenthe user and the other systems being
used, such as LotusNotes, allowingthe user to ignore the
nitty gritty details of exactly howthe LotusNotesenvironment worksor the precise commands
neededin order
to opena givendatabase. It could in fact providea transparent interface to several different proprietary systems,
thus reducing or even eliminating the user’s learning
curve. It woulddo this by providingthe user with executable commands
at a muchhigher level than "add this
icon to my workspace". Commands
such as "open this
database"wouldbe treated by the tool as goals to be accomplishedthroughthe use of sketchy plans. Thesketchy
plans wouldthen be expandedinto the required low-level
commands.
Overall, the tool’s maincontribution wouldbe to reducethe effort required on the part of the user in performingthe routine parts of the task at hand, allowing
themto concentrateon the moreinteresting parts. In particular, as will be discussedin the next section, it would
allow the user to concentrateon the portions of the task
that require judgementanddomainexpertise.
Problems with plan execution systems
The previous section described someof the advantages
that wouldaccrue through the use of a tool based on a
plan executionsystem.However,in order to capitalise on
these advantagesthe systemmustactually be built. There
are two maintasks in building a knowledge-based
system;
choosingthe architecture andrepresenting the knowledge.
Wehaveseen howan architecture basedon the hierarchical expansion of sketchy plans could be used; we must
nowconsiderthe knowledge
representation issues.
There are two types of knowledgethat wouldhave to
be represented: knowledgeabout the knowledgemanagementtask, which I shall term task knowledge, and
knowledgeabout the domainin whichthat task is being
performed,whichI shall term domainknowledge.
Taskknowledge
is representedin the systemin the raps
that are used to specify howtasks are to be performed.
This knowledgedoes not dependon the domainin which
the task is being performed;the methodsused to find a
documentin Lotus Notes, for example,do not dependon
the subject matter of the document.Rather, they depend
on the wayin whichLotus Notes works.
Representing domainknowledge,on the other hand,
presents muchmore of a problem. The successful per-
35
formanceof a knowledgemanagement
task such as using
LotusNotes relies heavily on a great deal of information
about the contents of the documents,possible synonyms,
relationships betweenconcepts, the fact that document
titles maybe meaningful,etc. In order to build a system
that can assist in this task, weneedto be able to represent
at least someof this knowledge.Of course, in attempting
to build a systemto assist in the task rather than one to
perform the task autonomouslywe are not cutting ourselves off from the enormousamountof knowledgethat
the user can bring to bear on the problem;but in order for
the systemto be of any use it mustperformat least some
of the taskitself.
There are two principal problemsposed by the representation of domainknowledge.First, whatdomainor domainsare wetalking about? Auseful tool shouldbe able
to operate in manydifferent knowledgedomains. For
example, a tool that can help track downdocumentsin
LotusNotes wouldnot be muchuse if it could only track
downdocuments
on a single topic, or evenif there werea
set of predefinedtopics. Thetype of tool under consideration wouldbe useful precisely becauseit wouldobviate the needfor the comprehensive
indexing of documents
in advance.Userswouldnot be limited to queriesthat had
been anticipated by the authors of documents;the system
wouldhelp find documentsin response to queries about
topics that maynot even have existed whenthe documentswerecreated. Thedifficulty here, then, is the scope
of the domainknowledgethat wouldbe required.
The second problem with domainknowledgeconcerns
howit shouldbe represented.Asusual, the criteria usedto
judge the representation methodshould take account of
both howthe knowledgeis used by the systemand howit
is acquiredwhenthe systemis built. Ideally, the representation should facilitate the efficient operation of the
system and should be easy for the knowledgeengineers
building the systemto use. In PARETO,
the domainknowledge is used by the system to guide task execution by
choosing whichsketchy plans to expandand howto expand them.
Figure2 showspart of a RAP(the control informationis
omitted)to find a document
that is relevant to sometopic
specified by the user. The domainknowledgeis represented by such predicates as relevant-category
and
relevant-name. Predicates such as these, used in RAP
definitions in such places as the success and context
clauses (and elsewhere), are used to guide task execution
according to PARETO’S
beliefs about the world. To use
them, PARETO
mustbe able to judge whetherthey apply in
the situation in whichit finds itself. In other words,it
must be able to comparethe actual state of the world,
whichit discovers throughinteracting with it throughinformation-gatheringand other actions, with functional
requirements imposedby the goals it is pursuing. The
problemarises because of the necessity of translating
betweenthe two very different natural characterisations
that arise.
(define-rap
(index (find-relevant-document
(succeed
(and
(method
(context
of them), and it maybe possible to use themmoregenerally than in the recognitionof opportunities. Anotherapproach might be to use some form of reinforcement
learning to allow the systemto learn to associate functional characteristics with perceptualfeatures throughuser
feedback.
Althoughknowledgerepresentation issues are the most
importantproblemsthat arise in the use of plan execution
systems for knowledgemanagementtasks, they are not
the only ones. For instance, a potential advantageof the
use of such tools wouldbe transparency: the user could
remainignorantof the details of the particular proprietary
systembeing used to store the knowledgebeing managed.
However,this mightbe difficult to achieve in practice
becauseof the fairly high level constraints placedon task
performanceby the architecture of the underlyingsystem.
For example,LotusNoteshas a very different information
structure to the world wideweb; although both have hyperlinks, embeddedgraphics and so on, Lotus Notes imposes a muchmorerigid framework.
?topic
=> ?document))
(open ?database)
(contains ?database ?document)
(relevant ?topic ?document)))
(and
(open ?database)
(contains ?database ?document)
(relevant-name
?topic ?document)))
(task-net
(tl (check-contents
?topic ?document))))
(method
(context
(and (open ?database)
(relevant-category
?topic ?category
?database)
(contains ?database ?document)
(category ?category ?document)))
(task-net
(tl (check-contents
?topic ?document))))
)
Figure 2: Part of a document-findin~AP
Conclusion
Thefirst characterisationarises fromthe requirementto
guide task executionthroughconsiderationof the state of
the environment.PARETO
must characterise the world in
termsof its perceptualfeatures -- the features that it can
observedirectly) For example,it mightobservethe presence or absenceof particular wordsor phrases in a document,or of particular viewsin a database.
Thesecondcharacterisation arises throughthe requirementto guide task executionin order to achieve certain
goals, suchas the discoveryof a document
that is relevant
to a particular topic. To meetthis requirement,PAP,ETO
mustcharacterise the worldin terms of its functional features -- features that affect goal achievement.
Thetrouble is that these two characterisations are not
usually the same. Translating betweenthe two is a nontrivial task that mayrequire an arbitrary amountof reasoning using an arbitrary amountof domainknowledge.If
a tool basedon a systemsuch as pareto is to be effective,
it must run efficiently, whichmeansthat the reasoning
must be limited. Obviously, as machinesget faster the
absolute level of reasoningthat is possible without adversely affecting performanceincreases, but the problem
remains. Moreover,it is exacerbated by the problemof
domain scope referred to above and the problem of
knowledge
engineering.Is it possible to decidein advance
what knowledgeshould be represented in order to judge
relevanceto arbitrary future queries?
Anarea of future workthat maypoint towardsa solution to this problemis the continuedinvestigation of the
reference features that are used in PARETO’S
opportunity
recognition mechanism.Reference features are intended
to provide a bridge betweenperceptual and functional
representations(see [9,16] for a discussionof this aspect
3 Obviously the term "perceptual"
is used somewhat loosely here.
36
In this paper I havearguedthat it will proveproductive
to think of some aspects of knowledgemanagementin
terms of plan execution. Moreover,the hierarchical expansionof sketchy plans, as used in the RAPssystemand
its offshoot PARETO,
provides a natural frameworkin
whichto represent knowledgemanagement
tasks.
Thebig challenge is the representation of the world
knowledge.The challenge can be partially overcomeby
abandoningthe idea of an autonomoussystem in favour
of a mixed-initiativesystem,i.e., one that worksinteractively with the user to accomplishits tasks. However,in
order for sucha systemto be useful it mustnot leave everythingup to the user;, in particular, it mustitself have
someworld knowledgethat allows it to judge potential
relevance.
References
1 Peot, MarkA and Smith, DavidE. 1992. Conditional
NonlinearPlanning.In Proceedingsof the First International Conferenceon Artificial Intelligence Planning Systems, 189-197.CollegePark, Maryland.
2 Goldman,Robert P and Boddy,MarkS. 1994. Conditional Linear Planning. In Proceedingsof the Second
International Conferenceon Artificial Intelligence
PlanningSystems, 80-85. Chicago,IL.
3 Pryor, Louiseand Collins, Gregg. 1996. Planningfor
contingencies: A decision-basedapproach.Journal of
Artificial Intelligence Research4:287-339.
4 Haddawy, Peter and Suwandi, Meliani. 1994.
Decision-theoretic refinementplanning using inheritance abstraction. In Proceedingsof the SecondInternational Conferenceon Artificial PlanningSystems,
266--271.Chicago,IL.
5
6
7
8
9
10
11
12
13
14
15
16
Kushmerick, Nicholas, Hanks, Steve and Weld,
Daniel. 1995. An Algorithm for Probabilistic Planning. Artificial Intelligence 76:239-286.
Firby, R James. 1989. Adaptive execution in complex
dynamic worlds. Technical Report YALEU/CSD/RR
672, Department of ComputerScience, Yale.
Pryor, Louise. 1996. Opportunity recognition in complex environments. In Proceedings of the Fourteenth
National Conference on Artificial Intelligence, 11471152. Portland, OR.
Firby, R. James. 1996. Modularity Issues in Reactive
Planning. In Proceedings of the Third International
Conference on Artificial
Intelligence
Planning
Systems, 78-85. Edinburgh.
Pryor, Louise. 1994. Opportunities andPlanning in an
Unpredictable World. Technical Report 53, Institute
for the Learning Sciences, Northwestern University.
Pryor, Louise and Collins, Gregg. 1994. A unifying
frameworkfor planning and execution. In Proceedings
of the Second International Conference on Artificial
Intelligence Planning Systems, 329-334. Chicago, IL.
Firby, R James and Hanks, Steve. 1987. The simulator
manual. Technical Report YALEU/CSD/RR
563, Department of ComputerScience, Yale University.
Hanks, Steve, Pollack, Martha E and Cohen, Paul R.
1993. Benchmarks, testbeds, controlled experimentation, and the designof agent architectures. AI Magazine 14(4)" 17-42.
Firby, R James. 1994. Task networks for controlling
continuous processes. In Proceedings of the Second
International Conference on Artificial Intelligence
Planning Systems, 49-54. Chicago, IL.
Cheng, Boon Fooi. 1995. Plan Execution in an Environmental Domain.MScthesis, Department of Artificial Intelligence, University of Edinburgh.
Green, Shaw. 1996. Planning Actions in DynamicEnvironments: A UNIXAssistant. MScthesis, Department
of Artificial Intelligence, University of Edinburgh.
Pryor, Louise. 1994. Perceptual and functional representations: Bridging the gap. In Notes of the AISB
Workshop on Computational Models of Cognition and
Cognitive Functions, Leeds, AISB.
37