[RavenclawDev 232] Re: accessing history of concepts from ravenclaw

Antoine Raux antoine at cs.cmu.edu
Wed Mar 21 21:36:22 EDT 2007


Hi Svetlana,

Sorry for not being responsive these days...

The answer to your question is that Reset is *supposed* to clear the 
values of all the concepts under this particular agent, including their 
history.
What you need in your case (apparently) is Reopen() (or the macro 
REOPEN). Reopen resets the completion state of the agent/subagents and 
pushes the concept values into their history, thus clearing the current 
value but not the history. This corresponds more to cases like yours 
where you want to allow the user to restart a given (sub)dialogue but 
not lose the concept values. Reset is more to completely restart from 
scratch (part of) a dialogue.

Hope this helps...

antoine

Svetlana Stenchikova wrote:

> Indeed, this change has affected the application. ravenclaw now
> (sometimes) gets in an infinite loop where the agents seem to be
> placed and executed (without any effect on the appication). I haven't
> been able to figure out what exactly causes it, but when clear()  in
> CDialogAgent::Reset() is called it works fine (but I  can not get
> history)
>
> I also tried to replace the call to clear() by ClearCurrentValue()
> but the history still does not get preserved.
>
> Please suggest if it is possible somehow to maintain the history.
>
> Has anyone ever used this functionality? If you think that this has
> not been tested and is not supposed to work, please tell me and I will
> stop asking this question.
>
> thank you
>
> Svetlana
>
> On 3/20/07, Svetlana Stenchikova <svetastenchikova at gmail.com> wrote:
>
>> Dear ravenclaw developers,
>>
>> could someone please help me to figure out how to use the past concepts.
>>
>> I am trying to get a value for the history (C("the_event")[-1]), but
>> it is empty.
>>
>> It looks like RESET_AGENT command also clears the concepts. My system
>> runs in a lookp (like the roomline) and RESET_AGENT is called at the
>> end of the loop.
>>
>> Is this an intended functionality to erase all past values?
>> This means that in the next iteration of the dialog (my system is
>> iterative) you can not get to the past values)
>>
>> If I comment out in CDialogAgent::Reset():
>>         /*for(unsigned int i = 0; i < Concepts.size(); i++)
>>                 Concepts[i]->Clear();*/
>>
>> this fixes my problem, but I am not sure if it will introduce other 
>> problems.
>> Please advise on the best solution,
>>
>> thank you
>> Svetlana
>>
>> On 2/6/07, Svetlana Stenchikova <svetastenchikova at gmail.com> wrote:
>> > Hi, I have a question about accessing history of a concept.
>> >
>> > Is this the right syntax to copy an old concept into a temporary 
>> value of
>> > the same type:
>> > EXECUTE(C("LOCAL_the_old_event") = C("the_event")[-1])
>> >
>> > It appears to be empty after this command, although "the_event" has 
>> had a
>> > value before.
>> >
>> > Could you please suggest what may be a problem? Do I have to do 
>> anything
>> > explicitly to keep the history of concepts?
>> >
>> > thanks
>> > Svetlana
>> >
>> >
>>
>



More information about the Ravenclaw-developers mailing list