223 karma · joined December 9, 2009
kick if i%4 == 0
clap if i%8 == 4
hat if i%8 in [0,2,6,7]
bass always, according to some function of iThis kind of feedback extracts several more bits of information from the player than a single rating (making better use of them). However, it breaks the applicability of an evolutionary algorithm which treats both artifacts and fitness evaluation as black boxes. If you use a search algorithm that was aware of how the game was built from components, I'm guessing that component-level feedback (being both more objective and more specific) could provide more informative pressure to drive the algorithm than the standard interactive genetic algorithm setup gets.
Instead of proposing some metric for fun that is valid a-priori, we are going to look for the very grounded game-specific correlates of fun and optimize with respect to those. Satisfactorily capturing the entire fuzzy sense of human fun in a finite piece of code is silly, but cataloging the observed feedback for every popular combination of level elements (e.g. "goomba two blocks to the right of a coin block while the player has a fire flower") is both practical and useful for automating level design.
If you think of the error function as the combined output of a bunch of "obvious flaw" detectors instead of a "theory of fun", then speculative optimization where the initial conditions come from a human's design under consideration becomes a potentially interesting bit of design automation. Think of design rule checks in CAD with a bit of fuzziness and a default bias -- instead of saying just yes/no, it can say "X might be a better alternative according to the metrics you've enabled in the preference window, consider adopting some of its edits".
Also, the fact that I had a good experience playing an "academic" class character in Traveller during college was also an influence in deciding to go to grad school. I haven't seen this class in any other RPG.
The gist is that games are fragile with respect to mutations (motivating the need for a search paradigm not based on gradualism). This fragility may not exhibit itself as strongly for the parameter tweaking involved in the balancing problem, but balancing quickly shades into general game design when you start to consider non-trivial tweaks.
Also, a sudoku puzzle generator directly incorporating the unique solution constraint: http://asparagus.cs.uni-potsdam.de/encoding/show/id/12739
Here's a tutorial application of ASP to map generation: http://eis-blog.ucsc.edu/2011/10/map-generation-speedrun/
The original application I imagined would be very simple arrays to be used in kids' tile puzzles where you could have square-peg-in-square-hole style thinking but without hole geometry (choosing something more semantic instead). Puzzle tiles would only have strong attraction to their correct location and all other locations would be relatively neutral.
In the quasi-whimsical view of Anonymous as a legitimate internet-dwelling mentality, it's these definedly group actions act actually constitute the speech (a vector of communication) for that entity. Every textual or video message signed "Anonymous" is quickly interpreted as the speech of an individual or small group of collaborating authors, relatable on human terms. The attacks, despite their sit-in level overall effectiveness, are inherently aggregate, as opposed to that-13-year-old or that-15-year-old-and-his-botnet.
Sloppy programming can lead to lots of unnecessary backtracking, of course, but some of the main benefits of Prolog come in using it for problems where you would have otherwise written your own ad-hoc backtracking search process to find a solution. That is, good Prolog code only likely to be slow because of it's backtracking when an imperative solution would have been slower/buggier.
Runtime slowness because Prolog is a dynamically-typed language that also strongly encourages the development of meta-intepreters as a common tactic is a separate issue. Often times a slower run time is acceptable in exchange for a much faster development time with the use of custom metalanguages (DSLs).
Integrated search aside, another benefit of logic programming comes in declarative knowledge representation. In an expression optimizer I wrote, it was easy to concisely define several code substitution patterns as simple logical statements and then create the overall optimizer as an interpreter over those declared patterns.
For problems that don't really revolve around search or knowledge representation (i.e. most CRUD web stuff), Prolog doesn't provide practical benefits. Nonetheless, understanding the otherwise foreign concepts of the language can give you the seeds of new design patterns and idioms for your familiar languages.
Using your file I've been building up a solver for these questions in Prolog (using DCGs for parsing and simple predicates for the common sense facts and answer calculation). It's nowhere near "done", but it does get 45% of the questions now after only a few hours and 450 lines of code.
The trick to factoring someone else's generative space is to spot the symmetries and build your self a little domain-specific language for explaining those symmetries to your program.
Here's some snippets:
tomorrow(wednesday,thursday).
food(butter).
body_part(arm).
plenty(arm).
above_waist(arm).
ordinal(2) --> lit('2nd').
question( tomorrow -> Answer) -->
p(['Tomorrow is ',token(Tomorrow),'. If this is true, what is today?']),
{ tomorrow(Answer,Tomorrow) }.
question(count_2(P) -> Answer) -->
p(['The list ',token_list(L),' contains how many ',pred(P),'?']).
{include(P,L,Goods), length(Goods,Answer)}.
pred_name('something each person has more than one of',plenty).Here's a little oversimplification that I've found useful for understanding this stuff.
* Mercury is the Haskell of Prolog
* Curry is the Prolog of Haskell
It's interesting to see a lot of the ideas in Mercury addressed from the opposite direction Curry. See for yourself: http://www-ps.informatik.uni-kiel.de/currywiki/So, forward simulating (and embedding my sentiments as a measure of my ease of sleeping):
Case {they implement it any nobody learns of the exploit}: I'm remembered as the one who stood up to help reduce friction to new apps being listed. They keep me as a positive point of contact for future design changes. I feel good about baleeting bad software design. Reputation improves, presumably.
Case {I don't tell them about it, they implement it, and somebody turns the conceptual exploit into a real tool after deployment}: The company company loses, consumers win (yarr). The company (and every company they swap stories with) decides never to deal with me, if they decide to pin it on me as intentional. I feel good about baleeting bad software design as well as demonstrating the counterproductiveness of DRM (albeit in a contrived way). Reputation declines, conditionally.
Case {I do tell them, they continue anyway in the name of reduced friction}: They take a calculated risk and own the result. Yay for improved design, but hard to forward simulate any more. Reputation unchanged-ish, regardless of whether the concept is exploited or not.
Case {I do tell them, and they decide to quit the project and keep their old solution}: They feel less receptive to future requests in the name of reduced integration friction ("ya know, it might have a flaw!"). I don't list my apps with them, and I hope that others don't either. Reputation unchanged. The concept of third-party-android-marketplace's reputation (and indirectly Android's)? Decreased relative to potential.
By this, non-exhaustive, in-the-reply-box analysis. It sounds like I should tell them, but somehow do it in a way that doesn't talk them out of it. Best option so far, but somewhat hard to enact.
Btw, I'm not a professional software consultant.
The general idea is that it is a command line tool that reads a regex as input (along with a number of examples to generate). It parses the regex into an abstract syntax tree, then hands it over to an interpreter to "execute" the expression/program several times.
The 'simpleparse' python library does a nice job of easing the regex-to-tree mapping.