Wednesday, April 23, 2008

Who rules - Man or Machine?

I've been following Gilad Bracha's blog on programming language design. The concepts Gilad touches on are profound and his blog is a real interesting read, I recommend it.

Some of Gilads most recent posts have left me pondering whether he is focusing on the right things? Gilad calls himself a Computational Theologist. This is an interesting title since theology has to do with beliefs and belief systems. From Gilads posts on Monkey Patching and Cutting out Static, I get the feeling that Gilad believes that the machine should 'help' the programmer to do the right thing. What beliefs that underpins such an assertion? Perhaps such a believe stems from an acceptance that most programmers are poor to mediocre and need all the help they can get? Maybe this believe stems from an idea that a computer program is more a piece of mathematical logic then a piece of creative art?

I am assigning a lot of beliefs here to Gilad, which are probably things he doesn't believe. The point remains though, at a fundamental level we have the choice of either believing in people or believing in machines. Andrew has a post on Smalltalk where he refers to the original Smalltalk Byte article. The Smalltalk researchers had a human powered approach to 'computer research'. Reading their paper it is clear that they believe in people and our inherent creative abilities. To them the machine is merely a tool. Man, the creative artist exploits tools and mediums to express himself. A computer is merely one such tool with a unique set of characteristics. The purpose of a programming language is to allow Man to exploit the Computer.

It was interesting to hear John McCarthy say a similar thing. For example he rubbishes the commonly held belief that "goto" is evil and should be banned. As an artist I'm not sure how I feel about people banning things and limiting my expression. Imagine a word processor that didn't allow you to use certain words like "fuck" or "piss"? There is a strong argument that such words aren't the most effective form of communication , but can we say they should be banned in all instances?

There is an interesting point of debate here, and I have no firm conclusions, other than to say that people have far more potential then machines. At best machines can help people to explore their full potential and extend their influence and reach. But a machine has no consciousness, no intelligence, no imagination. A machine has no spirit.

As humans we have two parts to our brain. A logical side, and an emotive artistic side. I believe that both sides are involved in everything we do, including programming, and we need to appeal to both. This means that the most correct and safe programming language may not necessarily be the most useful.

I love reggae music. I grew up on it: Bob Marley, Dennis Brown, Gregory Isaac, the reggae greats of the 1970's. In recent times Reggae as become more commercial with modern"artists" placing less emphasis on spirituality. I find this change rather regrettable, because without spirit the music becomes just noise.


Yardena said...

Hi Paul,

It's hard to play good music with lousy tools. Computer scientists have not excelled in building a set of really good tools that help people achieve their potential as software engineers. I think this is what Gilad is trying to do (solely my interpretation of course). When I am looking where computer science is today, it's years of research spent on type systems or languages like Ada, that sacrifice programmers' lives in favor of someone's idea of "scientific correctness". But I think it does not apply to Gilad's work - for example, maybe this is why Newspeak is a dynamically typed language. So don't throw the baby with the bath water - programming language should help you to do the right thing, just like a good violin, or photo-camera, or any tool really. It should solve the problems which the programmer should not bother oneself with, no matter how skillful that programmer is. I think it's a noble goal, and I don't find it elitist at all.


Paul said...

Hi Yardena,

It should solve the problems which the programmer should not bother oneself with, no matter how skillful that programmer is. I think it's a noble goal, and I don't find it elitist at all.

I think you're right. Perhaps I'm just being paranoid. It would be nice to hear Gilads take.

I guess what triggered me off was the idea that "monkey patching" was intrinsically bad, and not something with pros and cons to be managed by people. Also the same can be said for static. Static is one form of coupling (a particularly nasty form I should add), but again it may make sense is some instances.

I like Gilads work, and like you say he is trying to improve the tools. Improving the tools and empowering the people are not orthogonal.

Thanks for the reminder.


Andrew said...

Paul, I confess that I am not as well versed in languages as Gilad, however, I think this can be viewed from both perspectives.

While I agree that a language, and in general the computer/tools should help you to do the right thing, but its not always quite so straightforward. It seems that the patching issue he talks about is one of those cases where there is no simple perfect answer.

In these cases, to me, I don't see why we shouldn't employ a human-driven approach such as establishing a simple, well considered protocol when the system fails to support us in a simple, comprehensible way.

To me the emphasis is on doing to right thing to make our system as humanly understandable and easy to work with as possible. This goal can be attained by system and human approaches equally.

Paul said...

Hi Andrew,

To be fair to Gilad his posts are pretty balanced. I still think that at a fundamental level you need to decide what is most important the man or the machine.

Matz with Ruby is very pragmatic. What he does is try stuff out and see what works well and what is useful. As a consequence Ruby has several idioms borrowed from other languages but they still work well together. Once you understand the Ruby way, programming in Ruby is a joy.

This process of trial and error is the same as the process adopted by the Smalltalk team. In contrast the Boo language is very clever and address a number of problems in computer science:

I haven't used Boo in anger so I can't really say, but my first impressions where Wow this looks really neat. Then I started to worry that perhaps Boo was trying to be too clever, covering too many bases and it was too scientific.

I guess it comes down to good taste and I wouldn't accuse Gilad of not having good taste :)

It was interesting to blog about how our basic beliefs may influence what we see as good taste. If I get a chance I'll ask Gilad to respond. I'm sure we'll learn something.

Yardena said...

First, a link to recent recording of Gilad's presentation of Newspeak popped up on LtU - you may find it helpful.

I agree that our beliefs and philosophy influence what we do and how, but I think we should focus less on the personality and more on the outcome of one's work.

Rather than looking at it as Man against the Machine, I see this as a challenge of building a bridge between the two, giving both sides respect and attention. I agree with Andrew - if the machine can't solve the problem it should delegate to the person, but do it simply and clearly. In a more philosophical sense, I think because computer science is so young, we have not figured out properly how to transition from "science" to "engineering" yet. To do this we need tools that are controllable and safe alongside creating good programming curricula to train "the pilots".

P.S. I firmly support Gilad's objection to static, based on a decade of experience with large Java projects. I hope to one day use a language that provides a better solution.

Paul said...

Hi Yardena,

You've convinced me. I'll take a look the the NewsSpeak video when I get a chance.

Thanks for your input and the link.