• Sonuç bulunamadı

Commonsense aspects of buying and selling

N/A
N/A
Protected

Academic year: 2021

Share "Commonsense aspects of buying and selling"

Copied!
26
0
0

Yükleniyor.... (view fulltext now)

Tam metin

(1)

C OMMONSENSE ASPEC TS OF BUYING

AND SELLING

VAR OL AKMAN

Department of Computer Engineering and Information

Science, Bilkent University, Bilkent, Ankara, Turkey

MUR AT ER SAN

Department of Computer Science, Brown University,

Providence, Rhode Island, USA

W e de scribe an e xpe rime ntal approach toward im ple m enting a comm on-se non-se ``microthe ory’ ’ for buying and on-se lling. O ur prototype syste m characte r-ize s how inte llige nt agents hold ite ms and mone y, how the y buy and se ll ite ms, and the way mone y and ite ms are transfe rre d. The ontology of the

.

syste m include s mone y cash, che ck, cre dit card , age nts pe ople ,

organiza-. .

tions , item s m ovable , re al estate , se rvice , barte r, and the notions of transfe r, loan, buying by installm ents, profit, and loss.

Som e ye ars since , Made moiselle Z e lie, a singe r of the The atre

Â

 Ã

Lyrique at Paris, m ade a profe ssional tour round the world, and gave a conce rt in the Society Islands. In e xchange for an air from Norma and a few othe r songs, she was to re ce ive a third part of the

.

W e thank David Dave nport Bilkent Unive rsity for his pe rce ptive re marks on a pre vious version of the manuscri pt. Akman’ s re se arch is supporte d in part by a grant from the NA TO Science for Stability Program me III. Sun W orkstation is a re giste re d trade

-.

m ark of Sun Microsyste ms, Inc. KE E Knowle dge Engine ering Environme nt is a trade -m ark of Inte lliCorp, Inc.

Addre ss corre sponde nce to V arol Akman, De partme nt of Com pute r Engine ering and Informatio n Science , Bilkent Unive rsity, Bilkent, Ankara 06533, Turke y. E-mail: akman@ bilke nt.e du.tr.

Cybernetics and Systems: An International Journal, 27:327] 352, 1996 CopyrightQ1996 Taylor & Francis

(2)

receipts. W he n counted, her share was found to consist of thre e pigs, twe nty-thre e turkeys, forty-four chicke ns, five thousand cocoa-nuts, be side s conside rable quantitie s of bananas, lem ons and orange s. A t the Halle in Paris, as the prima donna remarks in he r lively le tte r, printed by M. W olowski, this am ount of live stock and vegetables might have brought four thousand francs, which would have be e n good remune ration for five songs. In the Society Islands, howeve r, pie ce s of money we re ve ry scarce ; and as Madem oiselle could not consume any conside rable portion of the receipts he rse lf, it be cam e ne ce ssary in the me antime to fe ed the pigs and poultry with the fruit.

W he reas in modern civilize d socie ty inconvenience s of the above sort

.

1

Je vons, 1973, p. 25 are not really felt, the conve ntional wisdoms of buying and se lling re main to be fully articulated. H aving intuitively pe rceived the function of money, we still ne ed to orde r our perce ptions pre cise ly into a logical frame work. It should be rem arked that Schank’s

.

conce ptual de pendency theory Schank & Abe lson, 1977 and late r work

.

of his Schank, 1980 concern repre senting and drawing infere nce s about the transfer of abstract relationships such as possession, owne r-ship, and control

}

relationships of obvious concern to buying and se lling. O the r re lated works in this regard include application systems

w

.

such as ATRANS Lytine n, 1986 , which processe s money transfe r

.

me ssages, and O pE d Alvarado, 1990, 1992 , which unde rstands argu-me nts in editorial texts conce rning trade re lationships, e conomic pro-tectionism, and so on. In the are as of financial e xpe rt system s and

.

e xpe rt systems in busine ss Barrett & B ee re , 1988 , the re are similar

.

applications e.g., Lassez e t al., 1987 , which nee d detaile d repre senta-tions of com monse nse knowledge of buying and se lling.

Despite all these groundbreaking, original studie s, we are not aware of studie s of eliciting the commonse nse knowle dge ne cessary to solve

1

A colle ague re marke d that the proble m of Made moise lle Z e lie is not unlike theÂ

.

proble m of having an inte rnal curre ncy only trade d with a country and an e xte rnal .

curre ncy trade d against othe r curre ncies . He the n adde d that this is the case in China and would be a good exam ple .

(3)

.

the simple daily problem s of e conomic transactions such as buying and se lling. It is true that a good place to look for information about the

.

kind of knowle dge involve d in simple micro e conom ics is an

introduc-.

tory textbook on the subje ct e .g., Froye n & Gree r, 1989 . Superficially, such texts appear to summ arize the kinds of knowle dge require d to a sufficie nt degree , and it may be thought that formalizing that knowle dge would be rathe r easy. A close examination, howe ve r, re ve als that this is but an illusion. In all beginning e conomics books the re is an implicit assumption on the authors’ part that the re ade r has an existing com-monsense frame work. This ``pre-e conomics’’ knowle dge forms the back-ground with which the ne wly described pie ce s of knowle dge can be

w

understood. Similar rem arks have be e n m ade in the conte xt of a pione ering study by de Klee r on naive physical re asoning de Klee r,

.

x 1975 .

W e hope to contribute to such a study he re and prese nt a common-se ncommon-se microthe ory2 for buying and selling and its impleme ntation. The comm onse nse knowle dge of eve nts involve d in this activity is form al-ized. O ur the ory de scribes how inte llige nt age nts hold ite ms and money. W he n an age nt de cide s to buy or se ll an ite m, the theory ge ne rate s the re sulting e vents, such as the transfe r of an ite m from a se ller to a buye r and the corresponding transfer of money from a buyer to a selle r. The system has some portion of the naive knowle dge that an age nt living in a W e ste rn country in the 1990s should have in orde r to understand the issue s involve d in a buying and se lling proce ss. The ontology

incorpo-.

.

rate s mone y cash, check, credit card , agents pe ople or organizations ,

.

ite ms m ovable , re al estate, se rvice , shops, barter, and the notions of transfer, loan, buying by installme nts, profit, and loss.

It should be noted, howe ve r, that we have not built an e xpert system that is making de cisions and assisting humans in business prob-lems, like those use d in credit evaluation, investme nt planning, or risk

2

The term m icroth eory is borrowe d from Cyc, whe re it is use d to re fe r to a spe cial .

class of conte xts Lenat & Guha, 1989 . Diffe re nt microthe orie s m ake diffe re nt assump-.

tions and diffe re nt sim plifications about the world. Conte xts provide a me chanism for re cording and re asoning with the se assum ptions. For any give n topic, such as buying and se lling, the re m ay be diffe re nt m icrothe orie s of that topic, at varying leve ls of de tail and gene rality.

(4)

.

assessme nt Barre tt & Be e re, 1988 . These are the tasks of an ``e xpe rt’’ on a spe cific topic. W e are trying to formalize basic com monse nse issues that e ve ry ``ordinary’’ individual is involve d in and has intuitions about.

.

In the first ve rsion of this pape r E rsan et al., 1993 , there we re se veral simplifying assumptions. E vents involving tim e such as inflation and inte rest we re not cove red. In the current formalization, the y are introduced but still are not comple te ly cove red. Previously, it was assumed that the buying and se lling proce ss is pe rforme d only using

.

mone y. The e xchange of ite ms without using money i.e., barter was not taken into consideration. Now, the the ory comple te ly covers barter. It is possible to ge ne rate the eve nts that take place in a barte ring situation. Ne w notions are also introduced into the system; for example, it handle s the borrowing of mone y and can compute the profit and loss of the se lle rs. Given an inflation rate , the system is able to de duce the numbe r and amount of installme nts, if the buying is being realized in install-me nts. Also, the se lle r’s willingne ss to se ll ite ms is take n into conside ra-tion. It is take n for grante d that e very agent accepts cash and check and that e very shop acce pts e very kind of credit card. Diffe rent currency units can be use d in buying and se lling.

The e sse ntial motivation for this work come s form the Cyc proje ct

.

Le nat & Guha, 1989 . W e have e spe cially be e n influe nce d by

Cyc-re-.

lated work by Pratt and Pratt 1991 on naive the ories of mone y. The se are microthe ories that describe the ways in which age nts store and transfer mone y. A particular microtheory focuses on the docume nts that are use d to transfer mone y, the accounts that can store mone y, the spe cial case of cash, and various m one y transfer actions. Howe ver, the theory does not cove r situations in which money is use d, such as buying an item. In that sense , our theory cove rs all these aspects and seve ral othe rs. W e we re mainly influe nced by the idea of formalizing common-se ncommon-se notions and the way it is done in Cyc. Pratt and Pratt’s ove rvie w is

.

rathe r parenthetic after all it is only five pages long , and as we have no

.

acce ss to the more recent but classifie d Cyc docum ents, we cannot hope to e valuate the curre nt abilitie s of Cyc vis-a-vis our naive e co-

Á

nomics. Howe ver, we can probably hope that our prese nt system doe s

.

incorporate many of the capabilities cite d in Pratt and Pratt 1991 . W e must e mphasize that our aim was not to build a comme rcial product but to te st the feasibility of such a task. O ther factors that he lped formulate our frame work include Hayes’ pione ering m

(5)

ethod-.

ological studies of naive physics Haye s, 1979, 1985 and the gene ral

3

.

advice of McCarthy re garding basic re se arch in AI McCarthy, 1990 . The imple me ntation of the the ory has be en performed on a Sun

.

workstation using KE E Knowle dge E ngine e ring E nvironme nt KE E ,

.

1993 . Howe ve r, we do not want the m ain value of this paper to be see n as an application of KE E software in modeling the be havior of individu-als in an e conom ic system that allows for many choice variables and many e xoge nous influe nces. Although pote ntially this sort of modeling could be useful in a num ber of real-world applications e .g., modeling of

.

financial markets, valuation of inve stme nt asse ts , the main goal of our re search is to unde rstand the com monse nse expectations about buying and se lling. As a re sult, seve ral sim plifying assumptions have be en made in the the ory, too many, as a matte r of fact, to le ave a potential re ade r with an uncomfortable fee ling about gaps and brittlene ss. U nfortu-nate ly, this se em s to be a major proble m with rese arch in commonsense re asoning in ge neral. True, some

}

if not a majority

}

of the system rule s to be prese nte d in the se que l will see m ad hoc. The re is some difficulty in imagining the system scaling up. At this stage, we cannot re ally comfort the reade r with such proble ms in m ind.4 Le t us simply re iterate that we belie ve that what we are doing he re is expe rim ental computer scie nce, with no pre te nsions to be use d as the basis of a practical re asoning system or a natural language system.

BUYING AND SELLING

Money in Buying and Selling

Mone y is a ke y instrume nt in buying and se lling. Age nts can hold mone y in diffe rent form s. They can have cash, and today this is still the

3 .

w x

McCarthy state s that 1990, p. 188 `` w e ne e d good proble m domains} the AI analog of what Drosoph ila did for ge ne tics.’’ W e be lie ve that buying and se lling is a good proble m domain in this re gard. First, it is full of fundam ental que stions} som e of which we hope to tackle in the pre se nt pape r} and ope n proble m s and long-te rm re se arch issue s. Se cond, this is a domain in which to m ake e xpe rim ents that are re ally informative.

w x w x

To quote McCarthy again 15, p. 188 , `` a t pre se nt the failure s are m ore im portant than .

1990, p. 188 , the succe sse s, be cause the y ofte n te ll us that the inte lle ctual m echanisms we im agine d would inte lligently solve ce rtain proble ms are inade quate .’ ’

4

w x Maybe it m ay he lp to note that a re ce nt Cyc ne wsle tter state s that `` t he entire

w x

te chnical approach . . . upon which a proje ct such as Cyc is base d is innovative and risky.

w x

Fortunate ly, ove r the past eight years the proje ct has progre sse d to the point whe re the `risk’ is now sm all.’ ’

(6)

most common way. The y can have bank accounts and cre dit cards. The re are seve ral other ways. Howe ver, the se thre e are the most comm on one s and our the ory cove rs only these . The thing all the ite ms use d as mone y have in common is their acce ptance in a particular

.

historical context in re turn for othe r goods and services with the understanding that othe rs would likewise acce pt the m.

Cash can be used physically. In orde r to use the mone y in a bank account, che cks are used. Agents can use as much money as they have in the ir bank accounts. In the case of cre dit cards, agents have a card and a re late d account with a lim it. They can spe nd an amount of money not e xcee ding this lim it. W hen they spe nd som e mone y using a credit card, they owe that mone y to the account and should pay it back later. E ach agent in our system has an amount of money that he can spe nd in a buying and se lling proce ss. This amount is the sum of an age nt’ s whole money, e ither in cash, bank account, or cre dit. The value

.

of an age nt’s be longings car, house , etc. and the am ount of the agent’s spe ndable mone y total another amount calle d the assets of an agent. This information about an agent should be known by the system, be cause an age nt who wants to buy some thing must have enough money to do so. If the item that the age nt wants to buy is real estate, the spe ndable money might not be enough to buy it. B ut the agent might have other re al e state and can sell the latter and use this money to buy the former.

Items in Buying and Selling

In eve ry buying and se lling proce ss an item is involve d. In our the ory, e verything that can be bought and sold is conside red as an ite m. Actually, the re are thre e diffe rent kinds5 of ite ms: movable, real e state , and se rvice . O ur theory tre ats ge tting a se rvice such as a haircut or dry

.

cleaning as a buying and se lling proce ss; that is, an age nt simply buys a se rvice from anothe r age nt who sells this service. Ite ms are also classi-fie d as durables and nondurable s, transfe rable and nontransferable goods. Those that are durable have an e xpecte d lifetime and an age

5

This se e ms quite arbitrary, and the re must be m ore and diffe re nt kinds of items. For exam ple , bonds and stock change owne rship, but the ir posse ssion doe s not esse ntially change be cause the y are still he ld centrally in a bank. In our pre liminary the ory we did not tre at this issue in de tail be cause of the numbe r of technicalitie s involve d.

(7)

using which we can calculate their de preciation. W ith the latter classifi-cation, it is se en that a se rvice can be thought of as a nondurable an d nontransfe rable good.

E ach ite m in the system has an owne r. This owne r can be a shopke epe r or an ordinary pe rson. Both of the m can se ll the ite ms that they own. The re are different kinds of shops. Agents have some com-monsense knowledge about where the ordinary ite ms of daily life are

6

.

sold. For e xample , bread and ne wspape rs are sold at the corne r store. The values of the se ite ms are also within the commonsense knowle dge of age nts. If an agent has e nough money and knows whe re to buy the ite m, he can buy it.

The owne rship of item s depe nds on the kind of item s. If an item is movable , the owne r holds the ite m physically. If an ite m is real e state , there are docume nts about the item and the pe rson who holds the se docume nts owns the ite m. If the item is a se rvice , a process receiving

.

se rvice is involve d and no one can hold this ite m physically.

The ore tically, there se em s no re ason why ``shares’ ’ of goods could not be e asily incorporate d in our framework. Although our system curre ntly does not support this, a reasonable approach would be to

.

de fine y x, n as 1 unit of a good that is itse lf an n th share in x, a share d good.

Transfers in Buying and Selling

O ne of the esse ntial aspe cts of our theory of buying and se lling is the ide a of a transfe r. The the ory considers buying and se lling as a money transfer and a corre sponding item transfe r, whe re the former stands for paying the value of the item and the latte r stands for changing the owne rship of the ite m.

For all these transfe rs to occur, som e pre conditions re garding the buyer and se lle r should hold. The buye r m ust have e nough money and know where the ite m is sold, and the se lle r should be willing to se ll that

6

The re is a proble m he re that doe s not go away whe n the individuals know the location of all the store s but not the price s at each store . Normally, individuals have to face a trade -off be twe e n acce pting the price of a particular se lle r or incurring furthe r se arch costs in the hope of finding a lowe r price or a be tte r brand, or a close substitute ,

.

e tc. else whe re . U nfortunate ly, se arching is known to be a costly activity in ge ne ral. W e admit that it would make our syste m m uch more inte re sting, but we did not addre ss the ide a that agents are engage d in a se arching activity.

(8)

ite m. In our the ory we assume that all shopke epers are willing to se ll the ite ms in the ir shops. In fact, shops e xist to sell ite ms. O n the othe r hand, an ordinary se lle r who is not a shopke epe r should agree to se ll the ite m be fore the money and item transfe rs take place.

As the system define s money in thre e diffe re nt types cash, che ck,

.

and cre dit card , the transfe r of m one y is also categorize d into thre e differe nt classes. Cash transfe r is the most common one . O ne assump-tion of the system is that m one y transfe rs of le ss than some some fixe d

.

amount are made in cash. No one with a right mind would use che ck or credit cards to buy newspape rs or bre ad. W he n cash is use d in buying and se lling, the amount of m one y that an agent owns directly incre ase s

.

or decre ase s according to this role selle r or buye r .

To use a che ck or a credit card, an agent should have a bank or, say, a V isa account. If an age nt buys an item by writing a check, the balance of his bank account would de crease by the amount transfe rre d. O n the othe r hand, if a credit card is used, the n the am ount that the age nt owes to the V isa account incre ases. The refore, the se accounts may have ne gative balance s. It should be ke pt in mind that an agent who buys an ite m from anothe r agent who is not a shopke epe r cannot use his credit card but pays e ither in cash or by check. It is not usually possible to buy a house or your ne ighbor’s car using your credit card.

E ach m one y transfe r has an amount and change s the amount of the spe ndable m one y of the age nts. So buying an ite m de crease s the amount of spendable m one y of the buye r by the amount transfe rred. Anothe r im portant fact is that a money transfe r doe s not always occur with a corre sponding item transfer. In some cases an additional money transfer occurs whe n the se ller give s change back to the buyer. The amount of the extra mone y transfe r can be calculate d by subtracting the value of the ite m from the amount of the money transfe r. This ``payback mone y transfer’ ’ occurs only whe n cash is use d in the mone y transfe r. The theory allows the money transfers to be in any curre ncy unit; so an age nt who gives Dutch guilders can be paid back in U.S. dollars if he wants.

The main ide a be hind an ite m transfe r is the change of the owne rship of an ite m. He re, we should reme mbe r that se rvice s are also conside red to be item s and are handled in a spe cial way. Afte r an ite m transfer occurs, the new owne r of the ite m is the buye r, unless the ite m is a se rvice. The way an item is transferre d de pends on the type of ite m.

.

(9)

``giving’’ the item to the buye r. If the ite m is a service, the n the se ller

.

gives service to the buye r by cutting the buyer’ s hair, for example . The transfer of real estate, on the othe r hand, is conside red as a transfe r of a docume nt of owne rship or authorization and affe cts the ne t asse ts of age nts. If an age nt buys re al e state, this results in an incre ase in the assets of the agent, and the se ller’ s amount of assets de creases by the amount of that re al e state.

.

Schank and Abe lson 1977 introduced and inve stigate d a universal knowle dge repre sentation system in which the y introduce d the te rm

atran s, which stands for the transfer of an abstract re lationship such as

possession, ownership, or control. It is note d that Schank and Abelson’ s

.

gene ral aim was also to m ode l comm on se nse 1977, p. 4 :

O ur focus will be upon the world of psychological and physical e ve nts occupying the m ental life of ordinary individuals. O ur knowl-e dgknowl-e systknowl-ems will knowl-e mbody what has bknowl-e knowl-en callknowl-e d `naivknowl-e psychology’ w. . .x

}

the common sense though pe rhaps wrong

.

assumptions which pe ople make about the motives and be havior of the mse lve s and others

}

and also a kind of `naive physics’, or primitive

intu-.

ition, as is capture d in Conceptual Depe nde ncy CD the ory. In our the ory both the transfe r of m one y and that of item s can be conside red as atrans. Howe ver, we belie ve that a commonsense mi-crotheory should be more fine -grained than this approach. For e xample, in Schank and Abelson’ s pragmatic approach the transfe r of the owne r-ship of mone y must sim ply be considere d as an atrans of money. Ye t, in our system we further cate gorize this transfer of m one y into thre e differe nt classe s because the re are diffe rent rule s dealing with differe nt classes. The same argum ent holds for the transfe r of ite ms.

The following sce nario is given to e lucidate how the system pe r-forms a buying and selling proce ss. E ach KE E figure represe nts a unit. E ach unit has a num ber of slots, and each slot has a ce rtain value of a certain value class. The values of a unit may be inhe rite d from anothe r

.

unit indicate d as From Unit in the figures according to the inhe ritance

.

type indicated as Inhe ritance in the figure s . John is an agent in the

.

.

system Figure 1a . H e wants to buy a newspape r Figure 1b . His goal is given to the system using the structure in Figure 1c. Give n only this information, the system trie s to pe rform the buying and selling proce ss. First, the system checks whe the r John has enough money to buy a

(10)

( )

Figu re 1 a . The unit re pre se nting John, an age nt. It ke eps the amounts of John’ s asse ts,

loans, and spe ndable mone y. All of the se slots are of inte ge r type . The y all have ce rtain value s none of which is inhe rite d.

( )

Figu re 1 b . The unit re pre se nting the ne wspape r.

( )

(11)

( )

Figu re 1 d . The unit re pre se nting Bill, anothe r age nt.

ne wspaper. Although the price and the seller of the newspape r are not given explicitly, the system has the comm onse nse knowle dge of what the price of a newspape r is and where it is sold. In the system, Bill is the proprietor of the corne r store whe re the newspapers are sold Figure

.

.

1d . Finding out that John has e nough money and the current owne r of the ne wspape r is B ill, the system gene rates an item transfe r Figure

.

.

1e from Bill to John and a m one y transfe r Figure 1f from John to B ill. It de duces the commonsense knowledge that when a ne wspaper is sold the owne rship changes by giving the item physically. Sim ilarly, it de duces that the payment is made in cash and no payback will occur be cause it is not state d that John has paid an e xce ss amount of money to B ill. Afte r the buying and selling process is over, Bill’ s spe ndable

.

.

mone y has incre ase d Figure 1g and John’s has de cre ase d Figure 1h .

.

The new owne r of the item is John Figure 1i .

( )

(12)

( )

Figu re 1 f . The transfe r of m one y from John to Bill.

Profit and Loss in Buying and Selling

In ge neral, se lling processe s are profit oriented. A seller’ s, e spe cially a shopke epe r’s, main aim is to make profit. Nobody wants to sell an ite m to lose money. But there are some exce ptions. The selle r may ne ed

( )

(13)

( )

Figur e 1 h . The unit re pre se nting John after the proce ss is ove r.

some amount of m one y urge ntly. In this case, he sells an item without conside ring profit. In anothe r case , the se lle r knows or strongly guesse s that if he doe s not sell a particular kind of item with a little loss, he will not be able to se ll it in the future at all. The refore, he can accept to lose some money. Also, in som e case s, se lle rs sell an ite m with loss de libe r-ate ly because the y expect othe r kinds of profit from this selling process. The profit may be in cash or in some othe r form e .g., to make some

.

othe r se ller lose mone y or e ven to make som eone go bankrupt . Ite ms have two types of price : purchase price and sale price . In a buying and se lling process, if the sale price of the item involved is greate r than the purchase price of the ite m, the seller make s a profit. The am ount of profit is the differe nce of two prices of the ite m. If the sale price is less than the purchase price , this indicate s a loss for the se lle r. Afte r the buying and selling proce ss is performed, the purchase price of the ite m is changed to the sale price . If the new owner of the ite m wants to do so, he can dete rmine the ne w sale price of the ite m.

( )

(14)

W hile de te rmining the ne w sale price, the owne r of the ite m knows that,

.

in ge neral, the sale price of the ite m should not be much more or le ss than the marke t price of that ite m.

The system also takes into account the de preciation of the goods

.

e spe cially for se cond-hand goods and the inflation rate whe n calculat-ing the profit and loss. De pre ciation is the loss in value due to physical

.

de te rioration we ar and te ar as we ll as the obsole sce nce of a durable good. It is also considere d as the cost of owning an asse t for, say, a year. Among a varie ty of depre ciation me thods based on the price of the durable good, the most comm on one is straight-line de preciation. Ac-cording to this method, the same fraction of the original price is charge d to curre nt costs e ach ye ar of the expe cted use ful life of the durable good. So if one buys a use d car for $600 and expe cts to use it for 6 ye ars, then at the end of e ach ye ar he should de duct $100 dollars from the price. As a re sult, if he se lls his car for $450 at the e nd of the se cond year, it should not be conside red as a loss, but a profit of $50.7 The theory doe s not cove r the notion of profit and loss of the buye r,

.

which might occur whe n an age nt buys an ite m for a highe r or lowe r price than the market price. Howe ve r, if an agent has alternatives, he pre fe rs to buy an ite m from the se ller who sells the same ite m for a lowe r price. Sim ilarly, a selle r pre fers to se ll his ite ms to the age nt who makes the be st offe r.

Buying in Installments

In a buying and se lling proce ss, if the se ller and buyer agree , the buye r does not have to pay the whole price of the item imme diate ly. The se ller and the buye r can agree on a payme nt plan according to which the buyer pays the price of the item in portions at predefine d date s. This is known as buying in in stallm en ts. This kind of buying can occur when the price of the ite m involved is more than a certain amount. This amount change s according to the time and place, but it is com mon knowle dge that nobody buys bre ad in installme nts. O nly if the price of the ite m is

7

Similarly, assume that a shopke e pe r buys a came ra for $100, ke e ps it in stock for a ye ar, and the n se lls it for $105. The shopke epe r would not have made any profit, if the inflation rate turns out to be highe r than 5% .

(15)

high enough to buy it in installments m ight buye rs prefe r this kind of buying.

He re, agre em ent of the se lle r and the buye r is the most important point. The amount of the installme nts and the date s whe n the y will be honore d are decided. These are usually different for differe nt se llers and buye rs at differe nt tim es. A se ller m ay want some kind of assurance from a buye r that the buye r is able to pay that amount of m one y. For e xample , if the buye r has som e docume nts indicating that he has a re gular salary, then the se ller might be convince d. In gene ral, the agre eme nt is not ve rbal; some docum ents are prepared and signe d by both the buye r and the se lle r. There fore , the buyer has to pay all the installme nts in time . If he does not, the se ller has the right to sue the

.

buyer or to repossess the sold ite m . Similar conside rations apply to the se lle r; spe cifically, he has to give the item to the buye r in tim e. Usually the buyer pays a ce rtain amount of the ite m’s price in advance and the

.

re st of the m one y is divide d into e qual payme nts. W he n the buyer is willing to pay m ore in advance, the portions be come sm aller in amount or in number.8

Depe nding on the agree me nt reached be twe en the buye r and se ller, the buye r rece ive s the ite m e ither afte r the agre em ent is made or after all of the installm ents are paid. O ther conditions be ing e qual, buye rs would usually prefer the forme r option.

Loan

An important proce ss in economic life is the borrowing of m one y and ite ms. It can be define d as taking or re ce iving som ething for a ce rtain time , inte nding to return it. If an age nt borrows an item, he can use it for a time pe riod. The important point is that only the user of the ite m change s, the owner of the ite m does not. Some time s, pe ople borrow ite ms from the ir frie nds and do not pay anything in return exce pt,

.

probably, a word of thanks . If an agent borrows an item from a shop

8

While de ciding the amount of installme nts, the rate of inflation should be take n into conside ration. The total amount of mone y that the se lle r will ge t should be high e nough to com pe nsate for the loss arising from inflation. Thus, the price of the ite m is augm ente d by an am ount accordin g to the curre nt annual inflation rate and the n divide d into portions. If the inflation rate is I, price of the ite m is P, am ount paid in advance is A, and num be r of installm ents is M, the n the amount of installme nts should be at least

. . .

(16)

.

i.e,. re nting , he should pay for it. The se conce pts are not covere d in this theory. W e will mainly de al with le nding and borrowing money. So we can conside r a loan as a way agents incre ase their spe ndable money for a certain time pe riod.

W hen an age nt wants to borrow m one y he should first find a lender. The re are gene rally three type s of le nders:

An agent who is a re lative or a friend.

An agent whose profession is le gally to le nd mone y, such as a bank. An agent who illegally lends mone y, such as a usure r.

The borrower should re turn the mone y in a ce rtain am ount of tim e e ither by paying the whole amount or by paying by installme nts. This usually depe nds on who the le nder is.

If the le nde r is a friend, the amount to be borrowe d cannot be m ore than a ce rtain am ount, which is gene rally proportional to the we alth of the lende r. De pending on the amount borrowe d and the pay date , e ither no or low intere st will be paid.

If the le nde r is an age nt whose reason for e xistence is le nding mone y, such as a bank, the borrowe r m ust have some assurance to offe r the bank. The amount of m one y the bank will lend is proportional to this assurance. In addition to the assurance, the borrower should not have any se rious debts to othe r agents in orde r to borrow m one y from a bank. The re is always some intere st involve d, and the pay dates are strict. If the loan is not paid back on time , the age nt m ay be charged some m ore m one y or the bank may seize the ite ms that we re offere d as an assurance .

If the age nt borrows mone y from an usure r, the inte rest rate is gene rally highe r than that of the bank. Some usure rs do not ne ed an assurance , but if the mone y is not returned on tim e the borrowe r might be in trouble in countle ss ways.

Barter

.

In our pre liminary study of the ontology E rsan e t al., 1993 , we de alt only with buying and selling pe rforme d using m one y. This should not be conside red the only way to obtain an item , as the illustration preceding this pape r shows. Barte r is an alternative for the same proce ss. It is de fined as the dire ct e xchange of ite ms of e qual value without the use

(17)

of curre ncy. In fact, in time s whe n m one y did not exist barter was the only way to obtain items. The barte ring proce ss starts whe n an agent wants a specific ite m and has some othe r ite ms to offe r for this ite m. Anothe r agent who owns the spe cific ite m and is willing to e xchange it with the offe red ite ms should also e xist. The proce ss e nds with the e xchange of ite ms and can be considere d as consisting of two ite m transfers.

The important aspe ct of barte r is a de sire to e xchange. How do age nts decide that two ite ms may be e xchange d? O ne answe r would be that this de pends on the value s of ite ms, but the te rm value is also intricate. V alue is the ratio in which the unit of me asure of one thing e xchange s for a m ultiple, or fraction, of the unit of me asure of any othe r dete rminate thing. For instance, we may say that the value of a certain kind of whe at, at a given time and place, is 30 shillings, if a quarter of such wheat is actually exchanged, at that tim e and place , for 30 shillings. V alue , in othe r words, is a mathe matical proportion be -twe en two quantities of we alth exchange d against one another in a given marke t. Agents assign values to items according to differe nt crite ria. O ne is the price of the ite m; another is the ``craving’’ of the age nt for that item . Some item s, although che ap in price, may have

.

great private value e.g., a broken watch inhe rite d from a grandfathe r . O ne othe r crite rion that de cide s the value is the time and place in which the barte r takes place. If an ite m is not produce d or e asily found in a country, its value is greate r than the same kind of ite m’s value whe re it is produce d. As a re sult, value is affe cted by many factors such as e conom ical, psychological, and historical factors.

The main proble m with barter, and the reason it is rarely practiced, is that the age nts must have a double coincide nce of wants Froyen &

.

9

Gre er, 1989 . Such match-ups scarce ly e xist in the re al world.

IMPLEMENTATION

Knowledge Engineering Environment

In the imple me ntation of the the ory, KE E is use d as a software

.

de ve lopme nt tool KE E , 1993 . This is a knowle dge system de velopme nt product that provide s software de velope rs with a se t of programming

9

For e xample , to work as a McDonald ’s counte r atte ndant, one would have to be willing to exchange 6 hour of daily labor se rvice s for some thing like six Big Macs and two Coke s pe r day eve ry day!

(18)

tools and techniques for building applications to repre sent and analyze knowle dge.

KE E has a frame system . The basis of this system is a unit. Units are similar to frame s. The y re prese nt the objects in the the ory. Units contain a numbe r of slots. Slots are use d to describe the attribute s of obje cts and can hold num erical data, text, table s, graphics, pointe rs to othe r units, and proce dure s written in Lisp. Units can be organize d into hie rarchie s, enabling the knowle dge base to be constructed in a m ore

.

logical manne r Figure 2 . Coupled with KE E ’ s inhe ritance me chanism, this allows e fficie nt storage and re asoning.

In our system commonsense knowle dge is deduce d using a numbe r w x

of rule s. The se rule s are impleme nte d in the Rule system sic of KE E . Rule s, like any othe r data structure in KE E , are in the form of units and can be organize d into classes. W hat the Rule system doe s is to prove the conclusions of a rule using the pre mise s of the rule . W hen the pre mise s of a rule can be shown to hold by the information in the knowle dge base, the conclusions are deduce d to be true . The Rule sys-tem supports both forward and backward chaining.

(19)

As for the rule s them se lve s, they m ay se em to be token rules that re prese nt num erous similar rule s that would be ne e de d. Since we do not have thousands of such rule s, we should indicate this, and provide a fee ling for the ir cove rage. The proble m is that som e rule s are re al de faults; as we treat the individual instantiations of eve ry re al-world

.

situation, the re will be a ne ed for de fault re asoning Ginsbe rg, 1987 . The re are assorted proposals in the AI literature to perform the latter and there fore we do not, in this paper, de lve into the spe cifics of de fault rule s.

Implementation D etails

Units.

The re are e ight main units: agent, ite m, money, shop, transfe r,

want.buy, want.borrow, and want.barter.

Agent

re prese nts the agents involved in the buying and selling proce ss. Age nts can be people or organizations. Buye rs and se lle rs are introduced to the system as m embers of this unit. It has three slots: assets, loan, and spendable .money.

Item

re prese nts the item involved in the buying and selling process. The re is no limit on the num ber and kind of items that can exist in the system. The re are five slots of this unit: ite m.kind bre ad, apple , car,

.

.

house , e tc. , ite m .type m ovable , se rvice , re al e state , own e r,

.

purchase .price, sale .price , durability durable , non.durable , life .time , and age .

Money

holds the common attribute s of money in differe nt forms that an agent can have. It has two slots, holder and balance , and two subclasse s, cash and account. Cash re prese nts the money that an agent has in cash.

Account

re prese nts the accounts of an age nt, with an additional slot account.administrator. Bank.Account and Cre dit.Account are two subclasses of account.

Bank.Account

describes the bank ac-count of an agent. Credit.Acac-count describe s the cre dit card acac-count of an agent. It has one additional slot, lim it, that indicates how much cre dit an age nt has.

Shop

re pre sents the shops in which the buying and selling takes place . The kinds and the numbe r of shops in the system are not limite d. This unit has two slots: kee pe r and shop.type pharm acy, re al e state

.

age ncy, etc. .

Transfer

re pre se nts the transfe rs pe rforme d in buying and selling. It has two subclasses, ite m.transfe r and mone y.transfer, and two slots that de scribe the common attribute s of the transfe rs: from.location

(20)

and to.location.

Item.Transfer

repre sents the transfer of ite ms in buy-ing and sellbuy-ing. It has two additional slots: item.transfe rred and ite m.transfe r.mode.

Money.Transfer

repre se nts the mone y transfe r from buyer to se ller in a buying and se lling proce ss. This unit is also use d whe n the buyer should receive change from the se ller. Its main slots are am ount.transferre d, money.transfe r.mode cash, check, credit

.

card , and curre ncy.

Want.Buy

repre sents a dem and for buying an ite m. W he n an agent wants to buy an item, this unit is use d to hold the information of the buying and se lling process. It has five slots: what.item, which.age nt,

.

price, se ller, and profit.loss of the seller .

Want.Borrow

re prese nts a dem and for borrowing money. This is the unit used to hold the information of the borrowing proce ss and has se ven slots: borrowe r, amount.borrowe d, lender, category frie nd, bank,

.

usurer , pay.date, intere st, and assurance .

Want.Barter

is the unit which holds the necessary information about a barte ring proce ss. It is use d whe n an agent wants to e xchange one of his ite ms with anothe r agent’s ite m. The slots of this unit are first.age nt, wante d.ite m, offere d.ite m, and second.age nt.

Rules.

The infere nce mechanism of the system is provided by a numbe r

of rule classes built into the Rulesystem. To make the re asoning m ore e fficie nt, the rules are groupe d into classes. Depe nding on the type of knowle dge e nte re d, a certain rule class is trigge red and ne w facts are adde d to the knowle dge base. Among these rule s, some can be re garde d as de faults, that is, rule s for default reasoning. Using the se rule s, it is possible to de rive conclusions despite the absence of total information. Currently, the system contains four rule classes: item .rule s, m one y.rules, want.buy.rule s, and transfer.rule s.

Item.Rules

is triggered whe neve r a ne w ite m is created. It contains rule s that de duce the sale price and type of each ite m, that is, whe the r it is re al e state, service, or movable . These rules are defaults and are activated if the user does not provide total information. W hen an ite m is cre ate d, its owner and kind should be spe cifie d. Some of the rules

.

translate d to E nglish are as follows:

If the sale price of bread is not specifie d, the n it is a couple of dollars. If the sale price of a car is not spe cified, then ask the use r.

If the ite m is a newspape r, the n it is a movable item . If the ite m is a haircut, the n it is a service.

(21)

The re is one more rule stating that when a real estate is create d, the net worth of the owne r of this item is incre mented by the value of that item .

Money.Rules

is triggere d e ach time a money unit is create d; this can be eithe r cash, bank.account or cre dit.account. It updates the amount of the spe ndable m one y of the age nt who owns this money. Some rules:

If an agent is given cash, the n his spe ndable mone y increases by the am ount of the cash.

If an agent is given a bank account, the n his spe ndable money incre ase s by the amount of the account balance .

If an age nt is given a V isa account, then his spendable money incre ase s by the amount of the lim it of that account.

Want.Buy.Rules

can be considere d to be the he art of the system be cause when a buying and se lling process occurs, this rule class is triggere d. The agent and the ite m he wants to buy should be specified. The se ller and the amount of money offe re d are optional. If the se are not spe cifie d by the user, the se ller is de duce d using transfer.rules and the money given is assume d to be equal to the price of the item . Using the purchase and sale price of the item, the profit or loss of the se lle r is calculate d. If the conditions for a buying and se lling e vent are satisfie d, the system create s a corre sponding m one y transfe r and an ite m transfe r automatically. Som e e xample rules are :

If an agent wants to buy an ite m from a seller and has e nough money, the n a money transfer from the agent to the se lle r and an ite m

.

transfe r from the seller to the agent occur Figure 3 .

If the mone y that the agent gives is not specifie d, then assume that the agent give s the e xact price of the ite m, not m ore .

If the sale price of the ite m is greate r than its purchase price, the n the profit of the se ller is the differe nce be twe e n the sale and purchase price s.

If the sale price of the item is less than its purchase price, the n the loss of the se lle r is the diffe rence betwe e n the sale and purchase prices.

Want.Borrow.Rules

is triggered each time an age nt wants to borrow an amount of money from anothe r age nt, which can be e ithe r a frie nd, a bank, or a usure r. The borrowe r and the amount of be

(22)

Figu re 3. An e xample of how rule s are im ple me nte d in KE E. He re , Lisp comm ands and

the rule structure of KE E are com bine d. This rule is activate d whe n an age nt wants to buy an item . It is che cke d whe the r the age nt has enough m one y and the se lle r is known by the syste m. If the pre mise s are satisfie d, the syste m ge ne rate s an ite m transfe r and a corre sponding mone y transfe r, filling the slots of the se units with the ne ce ssary inform a-tion.

borrowe d must be specifie d. If the inform ation about the other slots is not given, it is determ ined by de fault rules such as the following one s. If all the conditions are satisfied, a mone y transfe r is create d from the lender to the borrower. Some of the rule s are :

If an agent wants to borrow som e m one y from anothe r age nt who is willing to lend it, a money transfe r from the le nde r to the borrowe r occurs.

A bank is willing to le nd money only if the borrowe r has some assurance and little or no debt to the othe r age nts.

The amount of money a bank will le nd is proportional to the borrowe r’s assurance.

If an agent borrows from a frie nd less than a couple of hundre d dollars for a couple of months, no intere st will be charged.

(23)

If the lender is not specifie d and the amount of m one y to be borrowe d is more than a couple of hundre d dollars, the n the le nder is a bank.

Want.Barter.Rules

is triggered whe ne ver there is a de mand for barte ring. The agent who wants to barte r should spe cify the item he wants, know the owne r of that ite m, and offe r one of his items in e xchange . If the other age nt acce pts this offe r, the barter takes place. Some of the rules in this class are :

If an age nt wants to barter an item from another agent offering an ite m, see if the agent is willing to e xchange his item with the offere d one. If both agents agree on the barter, two ite m transfers occur.

Transfer.Rules

is triggere d whe n a mone y or ite m transfe r is cre ate d by the want.buy.rules and fills the re quired slots of the se transfers. If the se ller of an ite m transfe r has not bee n specifie d during a buying and selling process, a group in this class of rule s de duces the comm onse nse knowledge of who the selle r is. Anothe r function of the se rule s is the balancing of money, bank, and, say, V isa accounts. So e ach time a mone y transfer occurs, the balance of the se ller is incre ase d while that of the buye r is de cre ase d. This rule class also de te rmine s whe the r the seller will re turn change to the buye r. In this case a new mone y transfe r occurs from the se lle r to the buyer.

The money transfer mode of the proce ss is de te rmine d. If the mone y transfer mode has not bee n specifie d and the am ount that is to be transferre d is less than some fixed am ount, the n it is assume d to be a cash transfer. O therwise, the user is asked to enter the transfe r mode . The ite m transfer mode is de te rmine d according to the type of the ite m. The re are rule s that determ ine the ne w owne r of an item after an ite m transfer and how the asse ts of an agent change whe n the item trans-ferre d is re al e state. Some of the rule s in this class are:

If not spe cified, then the selle r of apples is the gre engroce r. If not spe cified, then the selle r of a house is a re al estate agency. If a mone y transfe r is made in cash, then both the am ount of cash that

the seller owns and the amount of his spendable money incre ase . If a mone y transfe r is made by a che ck, then both the balance of the

buyer’s bank account and the amount of his spe ndable money decrease.

(24)

After an ite m transfe r, the ne w owne r of the ite m is the age nt who bought it.

C ONC LUD ING R EMAR KS

This paper sum marize d the impleme ntation of a preliminary mode l for comm onse nse buying and se lling, following in the tradition of Cyc. W e have built a pre liminary microtheory for buying and selling. In this comm onse nse theory, the basic objects and e vents of buying and selling are form alize d. W e have covere d a part of the intuitive knowle dge that an age nt should have in orde r to understand the eve nts involve d in a buying and se lling proce ss. W e have imple me nte d a system that use s this theory to re pre se nt the ste ps of buying and selling, the re sulting situations, and the commonsense knowle dge involve d in these situa-tions.

It is useful to exte nd the the ory to cover more difficult notions like stealing, spe nding patterns, liquidity pre fere nce, price fixing, tax, black market, and search for the adequate price . Se em ingly innocent ques-tions such as ``Is the re a limit to se rvice availability e .g., an out-of-print

.

book ? ’’ or ``Can an age nt re fuse to pay for a faulty ite m e .g., a

.

tasteless soup ? ’’ should also be addresse d. Cle arly, the answe r to both

.

questions should be in the affirmative.

It is also possible to se e a narrowe r scope for the program e xplained in this paper, that is, to show how it can help us unde rstand how an

.

e conom ic system made up of many agents making many intelligent de cisions. This would probably take us to more involved issues, but it is worth serious conside ration. For example , a colle ague has aske d whe the r our program can show what happens when money is introduce d into a barte r e conom y.10

W e agree that these are all inte resting

}

and e qually troublesome

}

questions and, at this stage , can only add that the y are be ing actively

10

Unfortuna te ly, this is a difficult que stion that has more to do with simulation and game the ory than knowle dge re pre se ntation pe r se . More spe cifically, what happe ns to the aggre gate we alth of the individuals? W hat happe ns to the volum e of trade ? If productio n de cisions are inte grate d into the program, do individuals be come more spe cialize d afte r m one y is introduce d?

(25)

w x

re searched by us and, we hope , by others. Afte r all, `` d oing this job is

.

ne ce ssary, im portant, difficult, and fun’ ’ Haye s, 1985, p. 35 .

R EFER ENC ES

Alvarado, S. J. 1990. Understanding Editorial Text: A Com puter Model of

Argu-m ent CoArgu-m prehension. Boston: Kluwer Acade Argu-mic Publishe rs.

Alvarado, S. J. 1992. Argument compre hension. In Encyclopedia of Artificial

Intelligence, ed. S. C. Shapiro, 2nd e d., 30] 52. New York: Wiley.

Barre tt, M. L., and A. C. Be erel. 1988. Expert System s in Bu sin ess: A Practical

Approach. New York: Halste d.

de Kle er, J. 1975. Q ualitative and Q uantitative Knowle dge in Classical Mechan-ics. Te chnical Re port AI-TR-352, AI Laboratory, Massachuse tts Institute of Technology, Cambridge .

Ersan, M., E. Ersan, and V . Akman. 1993. O ntology for buying and se lling: A preliminary study. Proceedings of the Seco nd Turkish Sym posium on AI an d

Artificial Neu ral Networks, eds. S. Kuru e t al., Bosphorus Unive rsity,

Istan-bul, Turke y, pp. 1] 7.

Froye n, R. T. and D. F. Gre er. 1989. Prin ciples of Microecon om ics. Ne w York: Macm illan.

Ginsberg, M. L., e d. 1987. Readings in Non om on oton ic Reasoning. Los Altos, CA: Morgan Kaufmann.

Haye s, P. J. 1979. The naive physics manifesto. In Expert System s in th e

Micro-Electronic Age, ed. D. Michie , 242] 270. Edinburgh, UK: Edinburgh

University Pre ss.

Haye s, P. J. 1985. The second naive physics manife sto. In Form al Theories of th e

Com m onsense World, e ds. J. Hobbs and R. Moore , 1] 36. Norwood, NJ:

Ablex.

Jevons, W. S. 1973. Barter. In Monetary Theory: Selected Readings, e d. R. W. Clowe r, 25] 29. Harmondsworth, Middlesex, UK: Penguin.

.

KEE Knowledge Engineering En¨ironm ent . 1993. Software De ve lopme nt

Sys-te m, V ersion 4.1, InSys-te lliCorp Inc., Mountain V iew, CA.

Lasse z, C., K. McAloon, and R. Yap. 1987. Constraint logic programming and .

option trading. IEEE Expert 2 3 :42] 50.

Le nat, D. B., and R. V . Guha. 1989. Building Large Knowledge-Based System s

(Representation and Inference in the Cyc Project . Re ading, MA: Addison-)

Wesley.

Lytine n, S. 1986. ATRANS: Automatic proce ssing of mone y transfer me ssage s.

( Proceedings of th e Fifth National Conference on Artificial Intelligence

AAAI-)

(26)

McCarthy, J. 1990. AI ne eds more emphasis on basic re se arch. In Form alizing

Com m on Sen se: Papers by John McCarth y, e d. V . Lifschitz, 187] 188.

Nor-wood, NJ: Ablex.

Pratt, D., and W. Pratt. 1991. A naive theory of mone y. In The World According .

to Cyc, Part 4, D. B. Lenat et al. contributors . Technical Re port

ACT-CYC-022-91, Microe le ctronics and Computer Technology Corporation, Austin, TX, pp. 19] 24.

Schank, R. C. 1980. Language and me mory. Cogn. Sci. 4:243] 284.

Schank, R.C., and R. P. Abelson. 1977. Scripts, Plans, G oals, an d Un derstan din g. Hillsdale, NJ: Lawrence E rlbaum.

Şekil

Figure 1 c . The unit re pre se nting John’ s goal of buying a ne wspape r. ( )
Figu re 1 e . The transfe r of the ne wspape r from Bill to John. ( )
Figu re 1 f . The transfe r of m one y from John to Bill. ( )
Figur e 1 h . The unit re pre se nting John after the proce ss is ove r. ( )
+3

Referanslar

Benzer Belgeler

47 Figure 22: Impulse Response Function of Real Stock Returns to Negative and Positive Oil Price Shocks in Canada, France Germany and Italy .... 51 Figure 23: Impulse Response

Taking advantage of the weakness of the Sultanate of Delhi after Taimur's invasion in 1398, Zafar Khan a s s u m e d independence and founded his own Sultanate of Gujarat,

6) Liquids may evaporate in open containers. The particles with large kinetic energies can escape to the gas phase by defeating these intermolecular

Merdinin vnldeleri ve Mardin ve Harı Adil Arda ve Necati Yalını ailelerinin

Üniversiteyi yeni bitirmiştim; meslek yaşamıma adımımı attığım sırada, kısa süre içinde yaşadığım olaylardan sonra, kendimi Haluk Alatan hocanın yönettiği

Therefore, some PWR nuclear fuel assemblies such as Westinghouse PWR contain integral fuel burnable absorber (IFBA) rods, which load with uranium dioxide (UO2)

There has been a lot of research on the relationship between religiosity, religious affiliation and some aspects of consumer behavior hypothesized in this study:

When you look at then sector growing rate of both residental building and building construction sector over the current price it is obviously seen that there