Dec 17 2010

Artifical Intelligence – “understanding”?

First I have to apologize to all religious people whom I might offend with my next lines - yet I assume they would not be reading this article anyway. Anyhow, I respect their faith and form of life nonetheless.

What is understanding?

Many brilliant minds have taken up the challenge to define “understanding” with not much success, so I won’t attempt do so myself. However, using some common sense I will build a theory about why AI is such a hard nut to crack and how understanding plays such an important role in modeling its complexity.

The AI research community has always been quite diverse in defining what actually is the holy grail of Artificial Intelligence. Some people think that we are completely or almost entirely on a wrong track with our current approach to AI. Some others – not neccesserily AI researchers but philosophers, actually oppose the idea and insist that AI is actually wasted time and it is impossible to produce. I tend to agree more or less with the second lot but in a little bit different way… Continue reading

Related reading:

ArtificialArtificial Intelligence for Games
Creating robust artificial intelligence is one of the greatest challenges for game developers, yet the commercial success of a game is often dependent upon the quality of the AI. This book focuses on the problem of improving the quality of…
ArtificialArtificial Intelligence: International Version: A Modern Approach
For one or two-semester, undergraduate or graduate-level courses in Artificial Intelligence. The long-anticipated revision of this best-selling text offers the most comprehensive, up-to-date introduction to the theory and practice of artificial intelligence. View chapters 3 and 4 from the…

Dec 16 2010

The importance of modeling

Why is it important?

Modeling is building, creating a representation of something – an object, a process or maybe a series of events. More often than not its main purpose is to create an opportunity to closely observe and examine the subject, to help the observer to a better understanding.

The sole purpose of software development is to solve problems. Even video games can be reduced to problems and their solutions that together ultimately led to the end product that so many of us enjoy. The first step towards successfully solving a problem is to study and thoroughly understand them.

How does this help us?

In IT we use UML (Unified Modeling Language) to help us with this task. There are various diagrams that can be made using UML. One of the simplest ones are called use case diagrams. As the name suggests, these charts are used to map out how the user should interact with the solution. Amongst the most common objects there are, of course, users (actors), systems, packages, etc. These objects can be assigned IDs and connected to one another, similarily to the better known everyday flow charts. Probably the most significant difference is that in case of use case models objects are really in depth objects containing details, requirements, sub-diagrams, etc. Continue reading

Related reading:

Dec 11 2010

Google Analytics Pain…

Let us admit that Google Analytics (GA) is brilliant and not to mention free before I go into the details of the problems that one have to face by implementing it.

First of all GA is JavaScript based.

I know this does not sound like a problem at first but let us not get too ahead of ourselves and think about it a for bit…
We all know at least two things about JavaScript and that it works on the client computer and that it is susceptible to errors in the code. What does this mean?

Since scripts run on the client computer, the users decides whether they want to allow or deny them in their browser. In fact, user statistics show that 5-10% of all users turn off scripting in their browsers. Although this number has been improving over the last few years I still think ignoring 5-10% of one’s customer base would be a mistake. – I can actually hear some people saying that “…this should not matter, because 90-95% is still a representative number and it should give you a very good idea about what your users are doing blah blah blah” and they might be right. However in my opinion that 5-10% represents a specific segment of your users – probably the more tech conscious ones who perhaps should be targeted in a different way precisely for that reason.

This is stretching out into the realms of marketing so let’s move on…

The second thing I mentioned is the bigger issue, I think. If you dare to do a little experiment and go for some free surfing on the web you will quickly realize what I am talking about. Most of you must have seen that annoying little exclamation mark in a bright yellow triangle at the bottom left corner of your browser windows. It is likely that some of you haven’t even noticed this while you were digging around the web, simply because all seemed to be fine… However, as always, not all is what it seems!

Let’s say someone who is new to the web world… a jockey for instance who decided to get off the saddle and do something more static, like stooping at the front of a computer screen and try to decipher HTML and JavaScript. Since our guy is a jock and not stupid, he probably spent a reasonable amount on a good domain name and even paid a bundle of cash to a semi-professional to build a half decent web site and implement Google Analytics.

So, now that the good deed is done our theoretical retired sportsman is free to start experimenting with the mighty code. – Well, this is also where the problems start. It takes only a typo to brake a js file then GA stops working right there and then.

I know that my example is a little extreme but in the real world when some company hires some developer whose job is to implement and maintain GA could face serious issues due to the same reasons. If our guy is not lucky he could end up having to work with a website that is using a mixture of coding languages and awkward methods spreading over a number of servers likely with no documentation what so ever. Just to make it worse the board could be full of people with project management, marketing etc. background whom actually have no clue about what has been happening with their web site for the past 5 years or so…

Hmmm…In this unfortunate situation our newbie employee will have to be really careful. The site could easily have hundreds, maybe thousands of pages and GA should be implemented on all of them. Not to worry, our lad is smart so he wraps the Google code into a library and run a global search to implement it on the pages. Within a few days the nice charts starting to appear as the marketeers log into their accounts and they are all happy campers. Job well done!

However, it is not the end of the story. In a few months time someone changes something in some js file and suddenly figures start dropping… The next day the marketing crew is banging on the table demanding an answer, and by one look at the Director’s sweaty forehead our chap feels urged to find one. – Where shall he start?

Well, there are quite a few different ways to find the problem but none of them is simple. Hence my reluctance to accept JavaScript as the best analytics method. Back in the oldies, we had tracking pixels and they worked just fine. Why Google got rid of it? – I don’t know.

In summary, my suggestion to anyone who is about to implement GA is that they should make a bulletproof plan for the implementation and try to explain to its future users what they should expect. In the plan, carefully consider the IT infrastructure and map out rewrites and redirects before jumping into the deep water. It is generally true that good planning saves you time and money…in this case it also does save you lots and lots of headache.

Related reading:

Nov 23 2010

Correct file permissions for your web site

There is a lot of confusion between rookie web developers about file permissions…

Here is a short list about file permissions in general and some reasons why they are supposed to be set this way.

Your website will have a directory on the server where all your files will reside in. It is usually called public_html in case of a Linux based host. Permissions for this directory is normally set to 711.

There are a few folders that might have been created for you within the home directory, such as the cgi-bin which could be hosting all SSI (CGI,PERL) scripts. Like for all directories the permission is recommended to be set to 755. Files within however should be set to 700. This stands for all PERL and CGI scripts as well.

The notorious trouble makers, the htaccess files should be set to 644like all other html, shtml, etc files of your web site.

Most web masters do not recommend the use of htaccess files and on some servers they are not even enabled. However, if you are using them and have acces to them, it is good practice to prevent others from viewing them by placing the following code into your main htaccess file.

<Files .htaccess>
order allow,deny
deny from all
</Files>
Related reading:

Nov 10 2010

You think you are good?

You think you are good? – Do some CodeKata by Dave Thomas

Related reading:

© George Berdal 2006-2010 All Rights Reserved


Valid HTML 4.01 Transitional