Advertisement

Did anyone ever make any progress with Interactive Storytelling ?

Started by October 20, 2005 06:20 AM
122 comments, last by Nytehauq 18 years, 11 months ago
Gah - I promised myself I was going to respond to this after I made my quota today, but now that I finally did (8,600, yeah baby!) it's 5 in the morning and I'm too tired to write anything intelligent. >.<

Well, just so I can feel like I did something, I'll outline what I'm planning to post about next:

Choosing a theme, the range of theme, generating characters and obstacles to illustrate theme, how this is directed by understanding teleology, working forward from the initial incident (which is the opposite of working backward from the climax, the method a real human writer would use.)

There, that's good, that will make it easy for me to write about it quickly tomorrow (err, this afternoon/evening. Whatever, as long as it's after I get some sleep.)



Oh, and I forgot to comment on this statement by tj963 which bothered me a little before, "These states would contain properties like the ones sunandshadow mentions: emotions, inventory, etc. Which properties are included would depend on the particular game, story setting, and what kinds of choices you want to present."

I just wanted to make sure it was clear that the range of properties the engine knew about would be the same for every game/setting/theme, it would only be the choices the engine made among them when assigning them to specific characters and objects which would differ.

I want to help design a "sandpark" MMO. Optional interactive story with quests and deeply characterized NPCs, plus sandbox elements like player-craftable housing and lots of other crafting. If you are starting a design of this type, please PM me. I also love pet-breeding games.

I'll start by apologizing twice - once for never finding time to reply to this since september, and once for necroposting it now. But I got to thinking about plot today, and realized that I actually had more to say on the topic and this was the best place to say it.

Not sure exactly where I left off (I'll re-read this thread, but I want to post this first, before I forget what I wanted to say.) Hopefully I mentioned Cynthia Joyce Clay's book _Vector Theory and the Plot Structures of Literature and Drama_. Her major point in this book is that theme is expressed through the conflict between characters, which is representable as vector physics. She also says that a story starts out with lots of little vectors, and the rising action sees these absorb each other until at the climax only two big vectors are left, and they crash into each other leaving only one, so there is no conflict left and the story is over.

I'd like to elaborate on this idea and connect it to some of my other ideas. I don't know whether it was in this thread or elsewhere, but I defined the most basic plot as "Someone wants something BUT there is some obstacle in the way, so the someone chooses some method by which to struggle against this obstacle." That's pretty general, but recently I figured out how to make it more specific. The someone (perhaps this is obvious) is the protagonist of the story. A protagonist by definition is a character who is driven by a motivation to try to accomplish a goal. An antagonist (a very common but not universally necessary ingredient in a story) is also a character who is driven by a motivation to accomplish a goal, and this goal is one in opposition to the protagonist's. The protagonist and antagonist thus represent opposing thematic vectors.) Every goal that every character can have in a story is to affect the alliance/ownership state of an object (where the object could possibly be another character.

What do I mean by the alliance/ownership state of an object? Well, here are a bunch of examples: The protagonist wants to acquire the treasure. The antagonist wants to own the protagonist. The protagonist wants to stop being enemies (the negative version of being allied) with the antagonist, either by removing the antagonist's ownership of threatening weapons or by removing the antagonist's existence as an enemy by killing him. The protagonist and antagonist struggle over the ownership of a powerful foozle, or the rulership (ownership) of the kingdom, or the love of (alliance with) the princess.

So, the essential quality of every character and other object in our game is its relationships of ownership/alliance with any of the other objects in the game. And the plot of our game's story is the pattern of change in these relationships of ownership/alliance. A pattern of plot is like a sentence structure with different grammatical slots where you plug in nouns and verbs and things. Thus we can generate the characters and objects with which to initially populate the level of our game by analyzing our plot pattern to find out what slots we need to fill, and analyzing the theme we desire to convey to find out what details each object filling each slot should have.

So the next question becomes, when generating a story how do we know what plot pattern we want to convey and what sort of object slots it requires? How do we know what theme we want to convey and what sor of details would accomplish this?

I want to help design a "sandpark" MMO. Optional interactive story with quests and deeply characterized NPCs, plus sandbox elements like player-craftable housing and lots of other crafting. If you are starting a design of this type, please PM me. I also love pet-breeding games.

Advertisement
Plot Patterns

As I mentioned in the last post, the plot of a story is like the grammar of a sentence. Noam Chomsky discovered that it is possible to generate all possible sentence structures, and even all human languages, with a set of fairly simple equations. The set of equations is called transformational generative grammar. I believe that the plots of stories could also be generated with this type of grammar.

To do so, one would just have to follow the path Chomsky followed: start with a basic definition of a sentence(plot). Collect a large sample of naturally occurring spoken or written sentences(stories). Remove all the ones that don't obey the basic definition, or are 'ill-formed'. Analyse the rest to see what elements they are made out of, and form a definition for each element. Go through your examples and label these elements in all of them. Now record the pattern in which these elements occur in each example. Compare these patterns and look for meta-patterns. Encode the meta-patterns as equations and use them to generate new patterns. Test these to see if they still obey the basic definition.


Themes and Details

There is probably a finite number of themes. Themes are memes - clusters of concepts linked together by some organizing principle, generally an abstract concept like 'justice' or 'integrity'. Themes even tend to clump together into complexes of related themes just like memes clump into memeplexes. The set of concepts which are associated with each other to make up a theme is called a schema. If the plot of a story is like the grammar of a sentence, the list of all possible themes would be like the index of a thesaurus, while the schemas would be like the various entries in the thesaurus. IMHO the best way of storing a database of all themes and schemas would be a database created with a language like SOAR, which is designed to model the human thought process (the same human thought process which organizes ideas into memes, and the limitations of which are the reason why there is a finite number of themes - because the whole of recorded human culture is like a single human language, and we've only evolved a relatively small dictionary of abstract concepts, and the index of our thesaurus can only be made out of words from this dictionary).


Picking a plot and theme to generate a story about

Only certain themes and certain plots work together, so you have to pick one first and make sure the other is compatible, you can't pick both randomly. I would personally recommend asking the player what their preferences are, because most people have strong preferences about what types of plot and what themes they do and don't like. Then a random choice could be made among the plot types, a compatible theme could be chosen, and off our story generation engine goes! [smile] I suggest making the choice among the plot types because there will probably be fewer plot types than themes, and also because people expect the same themes to pop up again in a series of tv episodes or novels, but people don't like going through the same plot type twice in a row, so if we are randomly choosing the plot type we can add a rule not to pick the same type we used in the previous segment of the game.

[Edited by - sunandshadow on March 6, 2006 12:32:48 AM]

I want to help design a "sandpark" MMO. Optional interactive story with quests and deeply characterized NPCs, plus sandbox elements like player-craftable housing and lots of other crafting. If you are starting a design of this type, please PM me. I also love pet-breeding games.

It's been a while since I've read through this whole thread, and I don't really have the time right now to skim through it all again, so I apologise if I've written this before.

The Chomsky grammar approach that sunandshadow has described is probably my favoured approach to this problem. If the elements of a plot can be described in terms of symbol manipulation (and I believe they can, at least for a significant subset of stories) then theoretically it should be possible for a computer to construct a decent plotline.

The big problem is that you need to break down a plot into a full set of symbolic building blocks and figure out the set of grammar rules to stack the blocks together. This is challenging if you want your computer system to generate new novel plotlines. If the ruleset is too restrictive, the system will only generate slight variations of hard-coded plots. If the ruleset is too loose, the system will generate nonsense.

Nevertheless, I believe that this is probably the most sensible approach to generating stories, mainly because I believe that, like language, stories do have an inherent rule structure that can be modelled. I think that probably the easiest approach to start with is to pick a single theme or contrasting themes (for example, exploring loyalty and betrayal) and attempting to model that.

I've been thinking about this topic for awhile, and I brainstormed a general concept for a world that involves procedurally generated plot:

*Somewhat offtopic theory now ensues*

Supposing you've got a large scale persistent world:
Essentially, you have a "world" which is a composite of the physical terrain and model of the world (in this example the physical world is static) and the interactive objects, players, and characters that compose the game. It functions (in theory) like a sort of cellular automaton - each entity in the world has certain actions it can take, certain states in can be in (certain actions can be performed on it), and certain needs for survival. You first define some general properties for your various characters, e.g. the character "Mayor of Angbad" requires that his city be safe. "Safe" in this case is defined as the citizens getting what they need to survive. A neighboring group of orcs is hungry, and moves to attack a shipment of resources to find something to eat. This shipment is sent from somewhere else, but where is irrelevant at this moment. The orc characters satisfy their need for food attack a carravan. The citizens of the town no longer get what they need. The king, therefore, has a need to fullfil (in this situation, the townspeople are not elligible for plot advancing action - the king handles everything). Should you bug the king, he will inform you of the series of events that took place (capped within certain limitations of awareness - how this would be accomplished is even more off topic than this description already is, so I won't go into it here) and request that you remedy them in some way.

Of course, this is all rather tangential, but it's the general idea that counts. If you want an interactive story, you need an interactive world.

*End theory*

Now, as for the actual mapping of somewhat generic events to plot and story, that can get a bit complicated. It's essentially building a program for computer-human communication. Your program needs to learn to speak english. I find the best way to accomplish this feat is to have very robust characters. Forget what we think we know about what a "character" is - not just a model and a set of animations. You map and define the emotions, feelings, and actions of characters as well as their interactions with each other. Story is an account of a series of events as well as the feelings/thoughts/emotions to go with them (I'm sure we can learn alot from Will Wright's Spore on the issue of generating characters). If you model a sohpisticated enough AI, translating its "memory" and "feelings" into purpose oriented plot becomes much easier.

Generating a plot then becomes generating the events and actions that the characters take. Instead of you writing about a series of hypothetical and fictional events based on your perspective of the world to a certain purpose(or whatever reference you use) - the computer follows the same steps based on what "world" it has to work with.

I wish I had some links to give on AI topics and storyline generation, but I don't have anything other than poorly transcribed ramblings at the moment :(

EDIT: Now, how this pertains to language synthesis and most of the topics now discussed in this thread...

I read through some of the links in this thread http://www.gamedev.net/community/forums/topic.asp?topic_id=332564, and I found this one http://www.gamedev.net/community/forums/topic.asp?topic_id=18126 (sunandshadow's theory of plot based game design) rather interesting. There seems to be alot of theory about language synthesis, but I think it needs something else to mesh with it - artificial intelligence theory. Modeling story between complex characters is a complicated task (yay for redundancy) - and it seems to me that taking abstracted meaning and putting it to language is an easier task than coming up with that meaning first. Does anyone have any links about artificial intelligence to throw around? Actually...psychology would probably be better - AI topics tend to discuss the methodology of technology too much and stray away from the concept of synthetic intelligence. In any case, I haven't yet read through all of this thread, so bear with the offtopicness, but I'm thinking that having a computer parse a series of "events" into a narrative is going to require more than just figuring out how to have the computer write stories...how do you generate stories for it to write about? It seems to me that starting from examples of other stories and extracted plot concepts is backwards. In my mind, the narrative starts as an account of events with emphasis. Telling a story is recounting events. If I was developing a game with a computer generated storyline, I'd start off with a procedurally developed world that grows and changes according to logical and believable bounds (Kudos again to Will Wright and Spore for the brilliant implementation) even if it contains alien concepts. The narrative would then be the account of the events that occured, and the storyline would be the composite of the reactions of the individual characters in the world to each other.

Of course, no procedure is perfect, so you'd have to make sure that your world doesn't take itself down the path of armaggedon (as you don't want the world to blow itself up in the player's face) - and this is where I see plot analysis coming in. You define a huge and broad system for interaction and you program in themes and cutoffs - when the situation starts to resemble a dramatic situation (which will happen in the natural scheme of things) - the further plot advances will be influenced by predetermined themes, a la "Georges Polti’s 1868 postulation of the Thirty-Six Dramatic Situations" (Excuse the cut and paste from your post, sunandshadow ;)), for example.

So, all that has to be done is generating an extensive procedural approximation of every aspect of reality that is encountered in a narrative, and then a system to translate a series of events that occur and are logged by this procedural approximation into a raw, verbal account of the events. Then, you convert this into "interesting" plot - filtering out the unnecesary and adding stylistic touch.

Easy as pie.../sarcasm

In any case, I figure that a distilled version of the themes and writing style of an individual or group can be used as the base for the verbal parsing section - it's essentially figuring out how to store a representation of an individual's writing habits and stylistic devices, and then taking a raw series of events, reproduce a narrative based on how the templated writer would work given the same input.

This really starts to delve into some heavy stuff...

1) Get a series of events
2) Teach the computer how to simulate someone else writing about them

I apologize if it sounds overly dry, cold, and technical - I tend to express things in that way, even if they appear more natural and lively to me. And if it's vague, it's because I'm simultaneously deadpan and impressionistic...

[Edited by - Nytehauq on March 9, 2006 7:45:39 PM]
::FDL::The world will never be the same
Quote:
Original post by Nytehauq
Generating a plot then becomes generating the events and actions that the characters take. Instead of you writing about a series of hypothetical and fictional events based on your perspective of the world to a certain purpose(or whatever reference you use) - the computer follows the same steps based on what "world" it has to work with.


Except, stories have meaning _because_ of the perspective from which they are seen. Stories are inherently subjective. This is an argument I've had before - just modeling a world, even if you could do it with Matrix-like perfection, would not create a story, a dramatically satisfying player experience. It is essential to have a story in mind and then create a world specifically to tell that story. Because the meaning of the story is encoded in the way the world changes over time, so you can't let that change happen automatically, you need to control it so it happens in whatever way necessary to make the story's point.

Quote:
I'm thinking that having a computer parse a series of "events" into a narrative is going to require more than just figuring out how to have the computer write stories...how do you generate stories for it to write about? It seems to me that starting from examples of other stories and extracted plot concepts is backwards. In my mind, the narrative starts as an account of events with emphasis. Telling a story is recounting events.


A story consists of events, but they way events are chosen, the relatedness that makes them a story rather than random chatter, is theme. The reason I think it's essential to study other stories and extract plot concepts is that I don't yet know the rules for generating events from a chosen of theme.

Or to put it in your terms, you have to know what the writer wants to say before you can figure out what events are best to say it with.


In other news I'm getting some new books on plot from the Carnegie Mellon library on Saturday, so maybe they'll give me some new insights. [smile]

I want to help design a "sandpark" MMO. Optional interactive story with quests and deeply characterized NPCs, plus sandbox elements like player-craftable housing and lots of other crafting. If you are starting a design of this type, please PM me. I also love pet-breeding games.

Advertisement
Oop...AP above is me...stupid school computers.
::FDL::The world will never be the same
In my personal opinion, if it's not representative of artistic work it's not worth doing.

The overall goal of what? This thread? Generating stories? Trying to generate the best stories possible? Making games which include a story generation engine? A game or game story generated with the proposed engine? I'd be happy to answer, except I'm not sure what you're asking.

I want to help design a "sandpark" MMO. Optional interactive story with quests and deeply characterized NPCs, plus sandbox elements like player-craftable housing and lots of other crafting. If you are starting a design of this type, please PM me. I also love pet-breeding games.

So you don't think modelling a completely dynamic world where all choices are made by the player could result in evolving story-lines that would have dramatic satisfaction?

I guess I can understand that, and it would be difficult, but I think it can be done. My design for a multiplayer persistant and dynamic world really make me think that it is possible.

I think the key would be to provide enough goals for the players (and design in such a way that many, if not MOST of the goals would be (A) more likely to suceed with help/interaction from others, and (B) VERY likely to conflict with the goals of other players.

The problem then becomes the fact that not everyone can suceed in their goals at the same time. However, since this is a persistant scenario, any set-backs/failures along the way are just seen as continuation of the plot conflict, but the game MUST be designed so as to present it in this way. When, finally, a goal is realized, then that serves as the closure for that particular plot-line. However, the object of the goal can still be threatened at a future time, and perhaps lost (which could serve as a conclusion for someone else) but because there is no end to the story things go on. For this to work however, the player must still feel like the story is going somewhere, that is, the plotlines should still be as captivating as any story that intends to end. If this is the case, they should react to the story in much the same way as any other.

In such a game, the player has to put forth some effort to succeed in any goal, and they may aim for a goal that is so lofty that if/when they finally do acheive it, they can effectively call it the end of the story and either quit or start over doing something completly diferent. I think that the interactive nature of games works with this idea of setting a goal and taking steps to acheive it, which is a mechanic that is absent from literary entertainment where the player reads to find out what they KNOW has already been determined as the outcome, rather than a plot/goal they have to work at.

This type of story-telling reminds me of how, as a children, we would take a certain scenario of play from one session to the next, always adding more to the story and furturing the adventures. Those stories never came to an end besides the fact that we grew up and stopped playing them, but while we were IN those stories and participating in the events, they were as real a story as any.
Quote:
Original post by sunandshadow
In my personal opinion, if it's not representative of artistic work it's not worth doing.

The overall goal of what? This thread? Generating stories? Trying to generate the best stories possible? Making games which include a story generation engine? A game or game story generated with the proposed engine? I'd be happy to answer, except I'm not sure what you're asking.


No, just the goal of this thread, or whatever it's become. Are you trying to create an actual program to generate stories?
::FDL::The world will never be the same

This topic is closed to new replies.

Advertisement