I'm not a native schemer, but it looks like you can check fuel by calling run with a large number and seeing it if fails to return... eg (eq (run 9999 (return C) (return C)) 'exhausted) [note that this can cost fuel, and so should be done at the end of an agent to decide if returning the "real" value is a good idea]
giving us the naieve DefectorBot of (if (eq (run 9999 (return C) (return C)) 'exhausted) C D)
[Edit: and for detecting run-function-swap-out:
(if (neq (run 10000000 (return C) (return C) 'exhausted) C ;; someone is simulating us
(if (eq (run 9999 (return C) (return C)) 'exhausted) C ;; someone is simulating us more cleverly
D)) ]
[Edit 2: Is there a better way to paste code on LW?]
Re: not showing source: Okay, but I do think it would be awesome if we get bots that only cooperate with bots who would cooperate with (return C)
Re: message passing: Check out http://en.wikipedia.org/wiki/Message_passing for what I meant?
Subscribe to RSS Feed
= f037147d6e6c911a85753b9abdedda8d)
Awesome! The only suggestion I have is to pass in a putative history and/or tournament parameters to an agent in the evaluation function so the agent can do simple things like implement tit-for-tat on the history, or do complicated things like probing the late-game behavior of other agents early in the game. (E.G. "If you think this is the last round, what do you do?")
Thanks! Yes, I figure one-shot and iterated PDs might both hold interest, and the one-shot came first since it's simpler. That's a neat idea about probing ahead.
I'll return to the code in a few days.