edit
IndependentProject.Context
Independent Project
.
Context
See Also: [[Independentproject.Intelligence]] [[[RepresentationOfHistory]]] #### What is the context? The context is a stack (or tree ?) of recent commands, data, etc that have been referenced. #### What is it good for? The context is necessary in order to understand commands that refer to previous commands. ex: * emails * from bob * no from nancy * no joel * or his friends * last week * 'del''del' (or some other way to get back to square one - list of all emails) #### How the context is indexed and used In the example above, at least 2 (let me know if there are more) different methods of referring to the context are used. One is the '[emails] from bob' sequence. In this case a query from the context is added to by adding another pattern or modifier. The query is getting more specific. This can be matched by allowing queries in the context to match one or more of the matchtypes in a rule. In this example, from bob would match '%emails% from %people%' by finding that the first type on the stack matches %emails%. Pros and Cons of this type of matching: Pros: * does not require more rules * seems to handle a lot of cases Cons: * might this be slow? * In what order is the search expanded? Look for all matches where only 1 item in the context is used then when 2, etc. Or start by allowing the use of the top, then the next two, etc. Should this decision change depending on how many variables there are in the rule to be matched against? Another example is the 'no from nancy, no joel' sequence. In this case a query from the context is being altered. Are there cases where this could be ambiguous as in: 'emails, joe's friends' actually in this case the from has never been used so that shouldn't be a problem. Still... it seems like this algorithm may cause some strange and unwanted behavior.