My PhotoBruno Brás Silva

09, April 1986

info@brunosilva.net

Sintra Lisbon Portugal

Getting started with Windows Live Agents

Posted on 4:17pm 7/05/2008 by Bruno Silva in Programming, Software, Web, Windows Live

Windows Live Agents

Recently I’ve been exploring the Windows Live Agents SDK. This framework allows you to develop interactive Windows Live Messenger bots. You may already talked to a messenger bot like encarta@conversagent.com which allows you to search information from Encarta Encyclopedia or if you are Portuguese maybe you use info@destakes.com which gives you news about topics you choose, using data from several news websites.

To start developing your Agent/Bot/Buddy you must have Visual Studio 2005/2008 installed as well as .NET Framework 3.0. More details about requirements can be found in the Installation Requirements web page.

After fulfilling the requirements you can download the Windows Live Agents SDK and install it.

Now you are able to start developing your first agent! Open Visual Studio and open the “New Project” window. There will be a new project template under the “BuddyScript” project type. After choosing the “Windows Live Agent” project template, and typing your project name, you will be prompted for some project settings. You can choose several languages for your Agent and define if it will be able to do some default chatting with users. The only problem I found is that a project created this way is way too complex for a beginner, and if (like me) your target language is not supported or if you want your agent being able just to respond to specific messages, it is pretty difficult to use this template.

After hours trying to find out that was really relevant, I’ve created a Simple Project Template from which I removed a lot of files and settings from the original project. It has only some usage examples in Main.ddl (main BuddyScript file). This project is testable out of the box :)

The examples I left on the file are pretty simple. They cover how to set an expected input and how the bot is supposed to react. It also uses a package that makes available information about the current user, like his user name. I left some comments in the code. There are a lot of possibilities that can be explored. Something I tried already and that I will share in future posts is the usage of data sources like XML, Databases, RSS, etc. If you are curious about BuddyScript capabilities take a look at the BuddyScript Language Reference.

In order to test your agents you must have a license key, which is easy to obtain from within Visual Studio. Check out How to: Install the License Key.

You can test your agents directly in Visual Studio (Menu View > Other Windows > Conversation Window) with the interface showed bellow.

Windows Live Agents - Testing

More information about this kind of testing can be found on the How to: Launch the Agent in the Windows Live Agents IDE article.

Another way of testing your Agent which is much more fun, since you can ask your friends to test it too, is deploying your Agent on the Windows Live Messenger network.

Windows Live Agents - Deploying

Read How to: Launch the Agent in IM Environment to learn how achieve it.

More detailed information can be found in the Windows Live Agents SDK documentation at MSDN.

Next time I will talk about using data sources, background procedure (code that runs detached from user conversations), notifications (scheduling messages) and how to create pro-active agents that starts conversations instead of responding to user requests.

3 Responses to “Getting started with Windows Live Agents”

  1. Thanks! Isto pode dar jeito para um interface de domótica para perguntar à minha casa que temperatura está, como estão os sensores de movimento, etc. :)

  2. Tiveste problemas com a License Key??

    Eu faço o pedido e corre tudo bem, simplesmente na Management Console diz que a License Key é desconhecida.

    :D:D

  3. Já descobri…

    Os senhores da m$FT “esqueceram-se” de dizer que para quem tem o Windows XP, precisas de instalar o Windows 2003 Admin Pack, para a licença ser instalada com sucesso.

    Fica a dica.

Leave a Reply

XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

© Bruno Silva | Powered by Wordpress