opencog-dev team mailing list archive
-
opencog-dev team
-
Mailing list archive
-
Message #00169
Scheduler
Hi all,
I was about to post a blueprint/'first implementation' with improvements
to opencog's scheduler when I saw the latest e-mails from Linas
regarding his threading problems (and simultaneously saw the code of his
"WordSendeProcessor" agent, which uses threads...). So I thought I'd
better get some input on what is the general consensus regarding
opencog's scheduler before I waste more time.
The following sections of the Novamente Developer's Guide explain in
details the original design:
https://extranet.vettalabs.com:8443/bin/view/Novamente/DevelopersGuide#Scheduling_agents_execution
https://extranet.vettalabs.com:8443/bin/view/Novamente/DevelopersGuide#Task_System
I've also glimpsed through
https://extranet.vettalabs.com:8443/bin/view/Opencog/ChapterSixScheduler
but the description and nomenclature seems to be closer to the original
Novamente design.
>From what I could grasp from the current opencog implementation, *many*
simplifications have been made, but a few premises still hold:
* except for the request processor, there are not supposed to be
any threads (and consequently no concurrency) accessing the
cogserver and/or atomspace
* one may "simulate" an agent's priority using the "frequency"
attribute
* agents are supposed to voluntarily release control to the
lobe/scheduler (i.e., there is no preemption)
* the 'run' method of an agent shouldn't take too long (so that
the other agents won't suffer from starvation). This means that
some agents may have to be coded in such a way that its work is
broken into multiple "fast and resume-able units"
So, basically what I'd like to know is: which of these premises are
supposed to be discarded and which are supposed to remain? What's the
policy regarding threads? What about additional features? Is there a
short/mid/long term plan?
--
Gustavo
Follow ups