Conduct a statistically significant number of trials. With few trial, the highest ranked agents will be the ones with a high variance in possible score, rather than the agents with the highest average score.
Allow no libraries, except for a very small whitelist (e.g. random numbers).
No timing, no threads. They make analysis too hard. The payoff might have to be changed to make it never in your best interest to make your opponent diverge, e.g. (-1, −1).
The rule “This is about Prisoner’s dilemma, not the language you’re working in. If you violate the spirit of this rule, your agent will be disqualified.”
(Possible) Change language to a restricted dialect of Python. You can analyze your opponent bytecode, if you wish, or run your opponent as a black-box. Programs with side effects (such as writing to global variables) and programs that use Pythonic trickiness (such as inspecting the stack) are verboten.
Most of these suggestions are okay, but don’t move away from Lisp. A very restricted Scheme (e.g. one way to set variables, one looping construct (I really like foldl, as N shows), etc.) would be good; the lexical scoping and general immutability make it one of the best Lisps for our purposes.
+1 for restricted Scheme. I suggest restricted Python because it is more accessible and would allow more people to participate, but personally I like Scheme a bit more.
On the other hand, many many people were turned off by Scheme last time, and few of them will be reading this post. I’d like to give them a shot, if only to get a more diverse crowd.
On looping constructs: Would that buy us anything? What if people use recursion for looping? Should we restrict recursion?
Question for the audience: would there be a benefit to using a programming language that allows only primitive recursive functions?
I think a programming language that only allows primitive recursion is a bad idea. One common pattern (which I think we want to allow) was for bots to simulate their opponents, which entails the ability to simulate arbitrary valid code. This would not be possible in a language which restricts to primitive recursion.
I’ll list some suggestions.
Conduct a statistically significant number of trials. With few trial, the highest ranked agents will be the ones with a high variance in possible score, rather than the agents with the highest average score.
Allow no libraries, except for a very small whitelist (e.g. random numbers).
No timing, no threads. They make analysis too hard. The payoff might have to be changed to make it never in your best interest to make your opponent diverge, e.g. (-1, −1).
The rule “This is about Prisoner’s dilemma, not the language you’re working in. If you violate the spirit of this rule, your agent will be disqualified.”
(Possible) Change language to a restricted dialect of Python. You can analyze your opponent bytecode, if you wish, or run your opponent as a black-box. Programs with side effects (such as writing to global variables) and programs that use Pythonic trickiness (such as inspecting the stack) are verboten.
Most of these suggestions are okay, but don’t move away from Lisp. A very restricted Scheme (e.g. one way to set variables, one looping construct (I really like foldl, as N shows), etc.) would be good; the lexical scoping and general immutability make it one of the best Lisps for our purposes.
+1 for restricted Scheme. I suggest restricted Python because it is more accessible and would allow more people to participate, but personally I like Scheme a bit more.
On the other hand, many many people were turned off by Scheme last time, and few of them will be reading this post. I’d like to give them a shot, if only to get a more diverse crowd.
On looping constructs: Would that buy us anything? What if people use recursion for looping? Should we restrict recursion?
Question for the audience: would there be a benefit to using a programming language that allows only primitive recursive functions?
I think a programming language that only allows primitive recursion is a bad idea. One common pattern (which I think we want to allow) was for bots to simulate their opponents, which entails the ability to simulate arbitrary valid code. This would not be possible in a language which restricts to primitive recursion.