Sunday, June 25, 2006

Queryable data store

It seems like my shout out for a sweeter handling of runtime queries against data store was on the agenda of the Microsofties Linq development team.

My proposed solution, however, has the extra feature of exposing the datamodel outside of its context, in order to be used for some type helping, for instance. That point is critical for me, as this is the only way to leverage all the work done inside of your software outside of your business scope. In a network economy, this is a crucial point for customers, as a software always need to fit in an ecosystem somehow, and that ecosystem plumbing is where a lot of cost and issue is.


If we go back to Linq, the added value this time is clearly the IQueryable interface.
Wanting to use Linq in a project, I ended up filling the dots exactly on the same place, around this notion of "data repository" with accept queries and translate them. This functionnality is now a standard feature of Linq, with the 2 main additions :


You can generate expression tree (aka build abstract representation of query from unstructured text)

    ParameterExpression p = Expression.Parameter(typeof(Customer), "c");

    LambdaExpression predicate = QueryExpression.Lambda("c.City = 'London'", p);

And turn those trees into actual function :
      Func<Customer,bool> d = predicate.Compile();


Now  you have a whole continuum for your Linq queries, ranging from static to dynamic, and you can handle back some control to your user.
Unfortunately, their only entry point is a ..... untyped string, which is precisely what Linq stands out against.


May be one day Microsoft will realize they need to do for end-user what they ambition with Linq for programmers, that is bring back some strong typing wherever we can, and they'll might end up with my solution and my genius will finally be recognized.

Tuesday, June 06, 2006

Building bridges : follow up

With the help of the illustration of my readers flow, I stressed out in my last post the pure randomness, or close to, some of my readership, who is most welcome nonetheless. If you bear with me, as a continuation this preceding post, I will try to show hows web 2.0 means empowering a very hot subject, mostly underground after long years in the desert of conceptual useless-land, the semantic web, whose european conference is to be held next week in Montenegro. (Now look at the picture and tell me you are not interested by semantic web..) I was previously stressing out the importance of building vocabularies statistically, and to show this I would like to raise the question of why do we know stuff.
  • Well we either identify some relevant concepts, and by intuition formulate an hypothesis on their relationship. then if true, we attached our name to the relationship and become famous, if not rich.
ex : F = m a (Sir Newton)
  • Now you can also, if you have lots of data dealing with those notions of mass and forces, even though their essence is unknow to you, find the same law statistically.
ex : That hammer falling on my foot hurts. Let's try from higher
In matter of human knowledge, a broader subject than 3 variables, now one is going to take on the tasks of describing all the notions in the world. you might consider having experts doing there own domains, but you might need too many people to then connect those domains. So the only viable option is to rely on heavily distributed method. If you add the other constraint that the content producer dont have to maintain themselves the map of the notions, as they dont necesseraly have the time or interest to do so, you have little space but for statistics to rely on... or at least it should provide a great help. This subject of semantic extraction is one of the workshop of european conference, and it summarizes may be better the point (and challenges..)
Mastering the Gap: From Information Extraction to Semantic Representation
Automating the process of semantic annotation of content objects is a crucial step for bootstrapping the Semantic Web. This process requires a complex flow of activities which combines competences from different areas. The Workshop will focus precisely on the interface between the information extracted from content objects (e.g., using methods from NLP, image processing, text mining, etc.) and the semantic layer in which this information is explicitly represented in the form of ontologies and their instances. The workshop will provide an opportunity for: discussing adequate methods, processes (pipelines) and representation formats for the annotation process; reaching a shared understanding with respect to the terminology in the area; discussing the lessons learned from projects in the area, and putting together a list of the most critical issues to be tackled by the research community to make further progress in the area.
The global goal of this semantic effort is certainly not to discourage my beloved reader to come from the finest and highly spirited sites in a random manner. Randomness is something you can always have, and it is very essential to provide you with radical new knowledge. Look just how many people know of the semantic web, and now you might be more of those cutting edge people. The goal of the semantic web is to pursue that discovery of theme on the ground of items which are relevant to certain subjects. A very simple illustration. I discovered yesterday that one notion, called categories, was helping a lot in various, very different subjects I am interested in, like algebra, quantum physics, and computer langage theory. How is it that, being interested in those subjects, I had never heard of categories? Well it might be that for any of those individual domain, they might be a bit too abstract, so it goes under the radar for many people. But when you consider the 3 domain, you are much better off learning categories first and saving lots of time later. Have I had access to a semantic map of those domain, I would have noticed this strange object belonging to all of them, and get informed on it. That's what the semantic web is for, and not for discouraging dear readers to come from other quality blogs ;)

Sunday, June 04, 2006

Web 2.0 : Building bridges

So having proved in my previous post, once and for all, that the web 2.0 concept is manyfold, I can only go on and add one aspect on what the web 2.0 is, also. Many of my readers right now, may be you, are coming from my girlfirend's blog. Her readers are coming from this best of breed blog called inparisnow which has recently been referenced in a wall street journal article. How deceptive is it for a reader of charming (or not) stories about paris to come here and see stuff about "continuations" and "first order logic".... Even to wall street journal readers, whose interests can be close to what my job is, since I happen to work in finance, the journey must be pretty deceiving. Well this recognized fact is precisely what I think is the target for web 2.0 Tagging, social networking, sites mashups, all this is about building semantic groups which relates a specific audience to a specific content. The added twist to this bridge construction is the distributed nature of the semantic group. What look to one reader as "computer theory" will be seen as a "typing system" by another, depending their prevalent knowledge : the thought vocabulary is different between users, and naturally creates groups of users. Within a group sharing a common vocabulary, opinions might diverge on the relative importance of theories, but if you accept the fact that the intragroup variations are smaller than the intergroup variations, then to solve the problem of bringing information is more complex than just a democratic vote, and the solution is not a straight forward one. Having just a popularity system looks like voting for what the result of 2+2 is wont help much.. So after the current ways like tagging, voting, are taken to their technical limits, my bet is that the next challenge will be on how to easily build those 'vocabularies' in a distributed way, through complex statistics tools or method which will be rethought to integrate very easily. Which eventually will bring me to develop the "emergence" section sometime soon :)

Saturday, June 03, 2006

Closure and asynchronous functions

Closures are, in a programming langage, the ability to access at runtime in a local function the objects available at runtime at the point of definition of that local function. For instance void somefunction () { string variable1 = "Hello"; myButton.Click += delegate { myButton.Text = variable1;} } will be legal, even though the button will be clicked way after somefunction() has exited, where the variable variable1 is normally out of scope. This are very handy when dealing with asynchronous programming. Asynchronous programming involves breaking down a single function into a call to a service, and a treatment of the response to that service. Closures enable you to access to a single set of variables, just like in a single function, across all the pieces from the original function. void synchronousfunction() { myquerybutton.status = disabled; results = makebigQuery(); window.display(variable); myquerybutton.status = enabled; } void asynchronousfunction() { myquerybutton.status = disabled; query.oncomplete += new function(results) { window.display(results); myquerybutton.status = enabled; } query.launchquery(); } The code looks very much alike, thanks to the closure. These kind of closure can be found in csharp, javascript 1.5 and many functional programming langages. Now if someone knows an easy way to synchronize my job schedule with my personal one, I'd be glad :)

Web as a media

It would be easy to assume web is known territory nowadays, but this assumption is far from true. There are many tools to master before efficiently contribute to it and some others to has a good perception of its reality. To see how those tools can effectively change the perception one can have, this picture is a screen capture of my desktop. Now those windows have no information by themselves, indeed they are inormation about the web. They represent the web as a media. To the left is a window from www.swarmthe.com which shows the traffic between different sites. located bottom right is a firefox add in which displays comments made in the blogosphere about that web page. On the right is a view of Google analytics which helps to understand better what the audience of a website is. Then the last window where I am editing this post. Strange views of the good old web indeed ... !! ------------------------------------------------------ On peut croire le web territoire connu. Que nenni. Il y a pas mal d'outils a maitriser avant de pouvoir efficacement contribuer et encore d'autres outils pour bien percevoir le web. Ces outils changent effectivement la perception que l'on peut avoir de ce medium. Pour vous en convaincre, voici une petite capture d'ecran de mon bureau. Toute ces fenetres ne sont que differentes vues du web en tant que media. A gauche une fenetre de www.swarmthe.com qui montre le trafic entre differents sites. En bas a droite de cette fenetre se trouvent les commentaires que differents bloggers ont pu faire sur leurs blogs a propos de ce site. A droite une vue de Google Analytics qui permet de comprendre quelle est l'audience d'un site. Enfin, la derniere fenetre ou je tape ce billet. De biens droles de vues du web et pourtant c'est bien lui !!

powered by performancing firefox