G-邏輯智能體-人工智能(AI)32_第1頁(yè)
G-邏輯智能體-人工智能(AI)32_第2頁(yè)
G-邏輯智能體-人工智能(AI)32_第3頁(yè)
G-邏輯智能體-人工智能(AI)32_第4頁(yè)
G-邏輯智能體-人工智能(AI)32_第5頁(yè)
已閱讀5頁(yè),還剩28頁(yè)未讀, 繼續(xù)免費(fèi)閱讀

下載本文檔

版權(quán)說明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請(qǐng)進(jìn)行舉報(bào)或認(rèn)領(lǐng)

文檔簡(jiǎn)介

1、邏輯智能體 Logical Agents (知識(shí),推理)Chapter 71“Thinking Rationally”Computational models of human “thought” processesComputational models of human behaviorComputational systems that “think” rationallyComputational systems that behave rationally2邏輯智能體邏輯(基于知識(shí))智能體 Logic (Knowledge-Based) agents通用知識(shí) 當(dāng)前的感知 在決定動(dòng)作前

2、推理(infer)出當(dāng)前狀態(tài)的隱含狀況這在部分可觀察環(huán)境中至關(guān)重要3要點(diǎn)基于知識(shí)的智能體 Knowledge-based agents怪獸世界 Wumpus world邏輯 Logic in general命題邏輯與一階邏輯 Propositional and first-order logic推理,合法,等價(jià),可滿足模式推理 Reasoning patterns 歸結(jié) Resolution前向/后向鏈 Forward/backward chaining4知識(shí)和推理 Knowledge & Reasoning知識(shí)庫(kù) knowledge base (KB): 智能體所知道的一系列知識(shí)根據(jù)推理的規(guī)

3、則( rules of inference )由舊的事實(shí)推出新事實(shí)邏輯 Logic 表示知識(shí),并進(jìn)行推理5知識(shí)庫(kù) Knowledge Base知識(shí)庫(kù) : 一系列 語(yǔ)句 以一種 知識(shí)表示語(yǔ)言 的格式來 表示(有關(guān)世界的)斷言基于知識(shí)的智能體:Tell it what it needs to know.Ask it what to do 應(yīng)遵循推理的規(guī)則由知識(shí)庫(kù)得到答案tellask6通用的基于知識(shí)智能體 Generic KB-Based Agent7基于知識(shí)智能體的特性能夠:表示狀態(tài)和動(dòng)作綜合新的感知更新關(guān)于世界的內(nèi)部認(rèn)識(shí)推導(dǎo)出世界的隱含性質(zhì)推導(dǎo)出適合的動(dòng)作8Mine SweeperDesign

4、 a logical agent to play minesweeper9PEAS Analysis Mine SweeperPerformance measure+1 for each mine correctly identified, -1 for incorrectly identifying a mine, -1000 for selecting a location containing a mine, +1000 for identifying all mines.Environment9 x 9 board, each square has a mine with probab

5、ility 0.1ActuatorsAgent can mark a location as containing a mine, can mark a location as unknown, or select a location for viewingSensorsAgent can sense the number of mines surrounding adjacent locationsAgent knows number of mines remaining10怪獸問題 Wumpus World怪獸Wumpus11怪獸問題的 PEAS 描述Performance measur

6、e 性能度量gold: +1000, death: -1000-1 per step, -10 for using the arrowEnvironment 環(huán)境Squares adjacent to wumpus are smellySquares adjacent to pit are breezyGlitter iff gold is in the same squareShooting kills wumpus if you are facing it. It screamsShooting uses up the only arrowGrabbing picks up gold if

7、 in same squareReleasing drops the gold in same squareYou bump if you walk into a wallSensors 傳感: Stench, Breeze, Glitter, Bump, ScreamActuators 執(zhí)行: Left turn, Right turn, Forward, Grab, Release,Shoot12Wumpus world 的特征Fully ObservableNo only local perceptionDeterministic Yes outcomes exactly specifi

8、edEpisodic No things we do have an impact.Static Yes Wumpus and Pits do not moveDiscrete YesSingle-agent Yes Wumpus is essentially a natural feature13Exploring the Wumpus WorldThe KB initially contains the rules of the environment.1,1 The first percept is none, none,none,none,none, Move to safe cell

9、 e.g. 2,12,1 Breeze indicates that there is a pit in 2,2 or 3,1Return to 1,1 to try next safe cell14Exploring the Wumpus World1,2 Stench in cell: wumpus is in 1,3 or 2,2YET not in 1,1Thus not in 2,2 or stench would have been detected in 2,1Thus wumpus is in 1,3Thus 2,2 is safe because of lack of bre

10、eze in 1,2Thus pit in 3,1Move to next safe cell 2,215Exploring the Wumpus World2,2 Detect nothing Move to unvisited safe cell e.g. 2,32,3 Detect glitter , smell, breezeThus pick up goldThus pit in 3,3 or 2,416What is a logic?一種格式化的語(yǔ)言語(yǔ)法 Syntax 怎樣的表達(dá)是合法的語(yǔ)義 Semantics 一個(gè)合法的表達(dá)式表示什么樣的意義邏輯中每一條語(yǔ)句的真值都對(duì)應(yīng)著世界里的

11、一種可能例如算數(shù)語(yǔ)言X+2 = y is a sentence, x2+y is not a sentenceX+2 = y is true in a world where x=7 and y =1X+2 = y is false in a world where x=0 and y =617蘊(yùn)涵Entailment蘊(yùn)涵 Entailment 意味著一個(gè)東西跟隨另外一個(gè)東西:KB 知識(shí)庫(kù) KB 蘊(yùn)涵語(yǔ)句 當(dāng)且僅當(dāng) KB 為真的所有情況里也為真例如 一條語(yǔ)句的知識(shí)庫(kù)KB “the Giants won and the Reds won” 蘊(yùn)涵 “The Giants won”.又如, x+y

12、= 4 蘊(yùn)涵 4 = x+y蘊(yùn)涵其實(shí)就是語(yǔ)句之間基于語(yǔ)義的一種關(guān)系18模型 models邏輯學(xué)家的就是以模型的方式來進(jìn)行思維的如果在m中為真,則m是語(yǔ)句的一個(gè)模型M() 表示語(yǔ)句的所有模型的集合則 KB iff M(KB) M()例如 KB = Giants won and Reds won = Giants won19怪獸問題里的蘊(yùn)涵Entailment in the wumpus world為說明方便,對(duì)Wumpus world進(jìn)行簡(jiǎn)化,只考慮有關(guān)陷阱的模型下圖為探測(cè)到方格1,1什么都沒有,然后向右到方格2,1,感知到2,1有微風(fēng)之后的情形 20Wumpus models IAll pos

13、sible models (exactly 8) in this reduced Wumpus world.PitBreeze21Wumpus models IIKB = 怪獸世界的規(guī)則由感知得到的觀察22Wumpus models III1 = “1,2 is safe”, KB 1, 通過模型檢驗(yàn)(model checking)得證23Wumpus models IV2 = 2,2 is safe, KB 224推理過程Inference ProceduresKB i 即 語(yǔ)句通過過程i從KB導(dǎo)出可靠 Soundness: 只要 KB i , 就有KB 為真 ,則稱i 是可靠的(推理不會(huì)出

14、錯(cuò),但不一定能夠?qū)С鏊械恼_結(jié)論)完備 Completeness: 只要KB , 就有KB i 為真 ,則稱i 是完備的(所有的正確結(jié)論都會(huì)被導(dǎo)出,但是可能會(huì)導(dǎo)出一些多余的錯(cuò)誤結(jié)論)25語(yǔ)義透視圖當(dāng)知識(shí)庫(kù)KB為真時(shí),由一個(gè)可靠的推理過程導(dǎo)出的語(yǔ)句也一定是為真的26命題邏輯: 語(yǔ)法命題邏輯是最簡(jiǎn)單的邏輯命題符號(hào) P1, P2 等,表示語(yǔ)句If S is a sentence, S is a sentence (negation)If S1 and S2 are sentences, S1 S2 is a sentence (conjunction)If S1 and S2 are senten

15、ces, S1 S2 is a sentence (disjunction)If S1 and S2 are sentences, S1 S2 is a sentence (implication)If S1 and S2 are sentences, S1 S2 is a sentence (biconditional)27命題邏輯: 語(yǔ)義Each model/world specifies true or false for each proposition symbolE.g. P1,2 P2,2 P3,1 falsetruefalseWith these symbols, 8 poss

16、ible models, can be enumerated automatically.Rules for evaluating truth with respect to a model m:Sis true iff S is false S1 S2 is true iff S1 is true and S2 is trueS1 S2 is true iff S1is true or S2 is trueS1 S2 is true iffS1 is false orS2 is true i.e., is false iffS1 is true andS2 is falseS1 S2is t

17、rue iffS1S2 is true andS2S1 is trueP1,2 (P2,2 P3,1) = true (true false) = true true = true命題邏輯不要求S1和S2之間存在任何相關(guān)性或因果關(guān)系;如果S1為真,則我主張S2為真,否則我不做任何聲明28Truth tables for connectives29Wumpus world sentencesLet Pi,j be true if there is a pit in i, j.Let Bi,j be true if there is a breeze in i, j.start: P1,1 B1,1 B2,1Pits cause breezes i

溫馨提示

  • 1. 本站所有資源如無(wú)特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請(qǐng)下載最新的WinRAR軟件解壓。
  • 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請(qǐng)聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
  • 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁(yè)內(nèi)容里面會(huì)有圖紙預(yù)覽,若沒有圖紙預(yù)覽就沒有圖紙。
  • 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
  • 5. 人人文庫(kù)網(wǎng)僅提供信息存儲(chǔ)空間,僅對(duì)用戶上傳內(nèi)容的表現(xiàn)方式做保護(hù)處理,對(duì)用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對(duì)任何下載內(nèi)容負(fù)責(zé)。
  • 6. 下載文件中如有侵權(quán)或不適當(dāng)內(nèi)容,請(qǐng)與我們聯(lián)系,我們立即糾正。
  • 7. 本站不保證下載資源的準(zhǔn)確性、安全性和完整性, 同時(shí)也不承擔(dān)用戶因使用這些下載資源對(duì)自己和他人造成任何形式的傷害或損失。

最新文檔

評(píng)論

0/150

提交評(píng)論