-
-
Save heyswappy/b0680103eb660e15349ce7e72b64fff1 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"""the following is vague implementation of an algorithms from aima | |
https://github.com/aimacode/aima-pseudocode/blob/master/md/Table-Driven-Agent.md""" | |
percept_queue = [] # percept queue for static variable implementation | |
table = {} # dictionay aka hashtable | |
def table_driven_agent(percept): | |
global percept_queue | |
global table | |
percept_queue.append(percept) | |
action = table[percepts] | |
return action |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment