If you are looking to implement some kind of communications like this you
should check out MumblePlugin that I wrote. That should give you a pretty
good idea about the C++ linking to your libs, building a plugin to
implement the things you need and how to expose and interact it to/with
Tundra javascript engines to expose the features to the application layer.

Best regards,
Jonne Nauha
Adminotech developer


On Wed, Mar 28, 2012 at 9:52 PM, Toni Alatalo <t...@playsign.net> wrote:

> On Wed, 2012-03-28 at 10:13 -0700, Carlos wrote:
> > Hi Toni, thanks for your answers and your good humor ;-)
> > I like to know about how we can integrate scripting languages for
> > conversational agents like AIML or MPML3D. Has Tundra just implemented
> > a config and protocol similar to OpenSim or SL?
>
> Yes one of the Javascript example / reference apps is chat. That's what
> I called 'in-world chat'.
>
> AIML seems to have implementations in e.g. C++, Python, Java etc. Of
> these you can use C++ or Python directly in Tundra, so could write some
> kind of a NLPPlugin or AIMLPlugin.
>
> There's two options:
>
> a) Tundra plugin which uses the e.g. AIML lib of your choice, listens to
> events from the Javascript-written Tundra/reX simple Chat Application
>
> b) a relay of the Tundra chat to e.g. XMPP, and then making a simple
> XMPP bot which uses the lib. Connect those to the same server, or even
> just use IM (the XMPP bridge (client) in Tundra can just send the
> messages to e.g. your / the bots Google talk account or whatever).
>
> This code basically has what both of those options need:
>
> https://github.com/realXtend/naali/blob/tundra/bin/pymodules/irc/serverrelay.py
>
> That is: a) connecting to the Chat App qt signals in Python, and
> listening to & receiving messages, which you could respond to here if
> using the NLP lib directly, but in the case of this example it b) relays
> them to an IRC channel (i've used it to monitor servers and to be able
> to chat to inworld folks from irc) .. so if you'd go the XMPP route,
> would just forward there similarily. I've been now devving stuff with
> XMPP and also py written XMPP bots (to simulate kind of WebNaali clients
> actually, for movement sync stress tests :) -- jabberbot
> (pythonjabberbot in google code) makes it quite nice and easy, uses the
> xmpppy library.
>
> Here is was mostly assuming you want bots to the scene that participate
> in the in-world chat. SL also has group chat. I would use something
> existing for that with Tundra, probably XMPP. We already had a module
> using that in the Naali 0.x versions, worked with google talk and
> facebook chat and such. It is also possible to do groups etc. with the
> own Tundra chat app, but the characteristics of SL group chat is that
> it's not connected to the sims / regions. Just like a IM thing for
> friends and groups.
>
> ~Toni
>
> > More thanks
> > Carlos M. Lorenzo
> >
> > On 28 mar, 11:14, Toni Alatalo <t...@playsign.net> wrote:
> > > On Mar 28, 2012, at 3:14 AM, Jonne Nauha wrote:
> > >
> > > > You are really have to be a bit more specific if you want detailed
> answers. "How do I make X" (or include it in Tundra)
> > >
> > > Yes, it all depends on the details.
> > >
> > > What do you want to do with it, and how? For what data, with what
> perhaps existing software? Some natural lang lib that you already use? Or
> suggestions of natural language processing tools?
> > >
> > > If you want to e.g. have some system listen to the in-world chat, you
> can just integrate with that somehow. It is written in Javascript with the
> Tundra API (the chat messages are sent with entity-actions).
> > >
> > > Or if you for example have some existing service for the NLP which
> uses XMPP transport, you can connect Tundra to that.
> > >
> > > > In Tundra you make "bigger" features and functionality as C++
> plugins/modules. For example if you use other C++ libraries to
> > >
> > > Or in Javascript or Python -- as for example the avatar and chat
> functionalities are in JS. And system things like IRC relay and and the
> Blender integration in Python .
> > >
> > > Relaying chat messages to some service does not need C++, but if you
> plan to use some existing C/C++ nature language processing lib, then it can
> be nice to integrate it as a native Tundra plugin (which Jonne basically
> described).
> > >
> > > > Jonne Nauha
> > >
> > > ~Toni
> > >
> > >
> > >
> > >
> > >
> > >
> > >
> > > > On Tue, Mar 27, 2012 at 9:06 PM, Carlos <carlos...@gmail.com> wrote:
> > > > Please, any idea about how can I include a conversation agent with
> natural languages capabilities in a Tundra scene?
> > > > Thanks in advance
> > > > Carlos M Lorenzo
> > >
> > > > El 27 de marzo de 2012 17:49, <realxtend@googlegroups.com> escribió:
> > > >   Today's Topic Summary
> > > > Group:http://groups.google.com/group/realxtend/topics
> > >
> > > > Script for a character in Tundra [2 Updates]
> > > > Tundra Script [7 Updates]
> > > >  Script for a character in Tundra
> > > > Vaibhav Vaidya <vaibhav.vaidy...@gmail.com> Mar 27 05:50PM +0530
> > >
> > > > Hii all,
> > >
> > > > I am new to Tundra. I have created a scene. I want to attach a
> script to a
> > > > character. I tried hard to write a simple script which moves the
> character
> > > > to-and-fro when the client logs in, but got stuck.
> > > > Can anybody suggest a sample script for above mentioned purpose??
> > > > The entity name is UrbanFemale and it has only one animation "Walk",
> > > > animation controller name is UrbanFemaleAnimation.
> > >
> > > > ~Vaibhav
> > >
> > > > "Ali Kämäräinen" <stinkfi...@gmail.com> Mar 27 04:30PM +0300
> > >
> > > > Hi,
> > >
> > > > Could you try to stick in one thread, instead of creating multiple
> threads
> > > > for the same issue?
> > >
> > > > Grey skies,
> > > > Ali Kämäräinen
> > >
> > > >  Tundra Script
> > > > Vaibhav Vaidya <vaibhav.vaidy...@gmail.com> Mar 27 03:17PM +0530
> > >
> > > > Hii all,
> > >
> > > > var entityNameToFind = "UrbanFemale.";
> > >
> > > > function ShowAnimation()
> > > > {
> > > > var objectToAnimate = scene.GetEntityByName(entityNameToFind);
> > > > console.LogInfo("Hey great, I found " + entityNameToFind +" Starting
> > > > animation");
> > > > var availableAnims =
> > > > objectToAnimate.animationcontroller.GetAvailableAnimations();
> > > > console.LogInfo(availableAnims);
> > > > }
> > > > else
> > > > {
> > > > console.LogWarning("Entity " + entityNameToFind + " was not found or
> > > > animation controller component is not there! Trying again in 1
> second.");
> > > > frame.DelayedExecute(1.0).Triggered.connect(StartAnimation);
> > > > }
> > > > }
> > >
> > > > // Only run on client. One time animation enabling.
> > > > if (!server.IsRunning() && !framework.IsHeadless())
> > > > {
> > > > StartAnimation();
> > > > }
> > >
> > > > Vaibhav Vaidya <vaibhav.vaidy...@gmail.com> Mar 27 03:29PM +0530
> > >
> > > > Hii all,
> > >
> > > > I have written the following script. I checked "Run on load" to
> true. When
> > > > I launch the client see the message:
> > > > Hey great, I found UrbanFemale. but do not see the available
> animation.
> > >
> > > > But when i go to view -> scene -> UrbanFemale. ->
> AnimationController ->
> > > > functions -> GetAvailableAnimations()
> > > > It shows me the animation "Walk".
> > >
> > > > var entityNameToFind = "UrbanFemale.";
> > >
> > > > function ShowAnimation()
> > > > {
> > > > var objectToAnimate = scene.GetEntityByName(entityNameToFind);
> > >
> > > > console.LogInfo("Hey great, I found " + entityNameToFind );
> > >
> > > > var availableAnims =
> > > > objectToAnimate.animationcontroller.GetAvailableAnimations();
> > > > console.LogInfo(availableAnims);
> > > > }
> > >
> > > > if (!server.IsRunning() && !framework.IsHeadless())
> > > > {
> > > > StartAnimation();
> > > > }
> > >
> > > > Also, when i run the script view -> scene -> UrbanFemale. -> Script
> -> Run()
> > > > This runs the script and shows the message:
> > >
> > > > Hey great, I found UrbanFemale.
> > > > Walk
> > >
> > > > Am I missing anything??
> > >
> > > > ~Vaibhav
> > >
> > > > Vaibhav Vaidya <vaibhav.vaidy...@gmail.com> Mar 27 03:30PM +0530
> > >
> > > > Please ignore the previous part..
> > >
> > > > On Tue, Mar 27, 2012 at 3:29 PM, Vaibhav Vaidya
> > >
> > > > "Ali Kämäräinen" <stinkfi...@gmail.com> Mar 27 02:32PM +0300
> > >
> > > > GetAvailableAnimations() returns a list so you need to print each
> element:
> > >
> > > > var availableAnims =
> > > > objectToAnimate.animationcontroller.GetAvailableAnimations();
> > > > for(var i = 0; i < availableAnims.length; ++i)
> > > > console:LogInfo(availableAnims [i]);
> > >
> > > > Grey skies,
> > > > Ali Kämäräinen
> > >
> > > > Vaibhav Vaidya <vaibhav.vaidy...@gmail.com> Mar 27 05:11PM +0530
> > >
> > > > @Ali :
> > >
> > > > I tried this also but I see the same results.
> > >
> > > > "Ali Kämäräinen" <stinkfi...@gmail.com> Mar 27 04:28PM +0300
> > >
> > > > I see that your script is calling StartAnimation(). However, I see
> no such
> > > > function in the text you pasted, but only ShowAnimation(). Are you
> calling
> > > > non-exising function by accident?
> > >
> > > > Jonne Nauha <jo...@adminotech.com> Mar 27 04:29PM +0300
> > >
> > > > The reason why you get a empty list with "Run On Load" is probably
> because
> > > > the skeleton asset has not been inspected yet for the animation
> names. Also
> > > > i think you cannot start them if that is the case. This is why later
> when y
> > > > ou run the script it responds with the proper anim names.
> > >
> > > > Seems that there is no proper way to ask
> ent.animationctonroller.IsReady()
> > > > or IsDetected() etc. So you can just assume to try again in 1 second
> if the
> > > > animation name list is empty like so:
> > >
> > > > if (availableAnims.length <= 0)
> > > > frame.DelayedExecute(1.0).... etc....
> > >
> > > > Best regards,
> > > > Jonne Nauha
> > > > Adminotech developer
> > >
> > > > On Tue, Mar 27, 2012 at 2:41 PM, Vaibhav Vaidya
> > >
> > > > You received this message because you are subscribed to the Google
> Group realxtend.
> > > > You can post via email.
> > > > To unsubscribe from this group, send an empty message.
> > > > For more options, visit this group.
> > >
> > > > --
> > > >http://groups.google.com/group/realxtend
> > > >http://www.realxtend.org
> > >
> > > > --
> > > >http://groups.google.com/group/realxtend
> > > >http://www.realxtend.org
> > >
> > > > --
> > > >http://groups.google.com/group/realxtend
> > > >http://www.realxtend.org
> >
>
>
> --
> http://groups.google.com/group/realxtend
> http://www.realxtend.org
>

-- 
http://groups.google.com/group/realxtend
http://www.realxtend.org

Reply via email to