Currently programming is a process of figuring out how to give the computer exactly what it wants in order to perform a certain task.
I want to redefine programming as a process by which a computer helps a human clarify and communicate ideas.
That bears unpacking:
process
Programming is already far more than edit-compile-run, although most traditional languages tie you to at least 2 of those stages. But when I think of "programming", I think of far more than just coding to the whole end-to-end process (if it does end) from an ordinary person having an idea to it being expressed clearly enough that a computer or other person can act on it. More comments on the other person aspect later [FIXME], but it bears saying now that I'd like a computer to be able to help us clarify what we mean when talking with each other.
The central focus is not the code developed, but rather the interaction between programmer and computer. Hence my tagline: "Programming Is Interaction".
Most human-computer interaction (HCI) research focuses on interaction with pre-built applications, such as OS shells, office applications, and websites. Some precious few have applied HCI concepts to programming, with some amazing results. I've written a whole report on it, which I'll post up here sometime [FIXME]. Summary: MIT Media Lab and CMU Natural Programming are the big ones I've seen. [Please let me know if you see any other big work in the field in academia.]
I'll unpack process a lot more over subsequent entries.
help
Humans aren't born knowing how to program. That is, we don't instinctively know (1) how to think logically and communicate ideas clearly, nor (2) how to express these ideas in a computer system. The computer should do all it possibly can to help. Automatic code completion (and in some cases, generation) is just the begininng; how about helping us with the basic reasoning behind it too?
clarify
Generally we don't start out with a perfect idea of anything. What is a "paragraph", or an "audio track"? I can try to give a definition, but surely in the course of developing the word processor or sound editor I will refine this definition quite a bit. My definition will probably not look much like "a paragraph is a _____." anymore either; it will mostly talk about how a paragraph relates to other concepts, like words and pages. ("Concepts and Relationships" will cover this issue in depth. [FIXME])
My initial definition is practically worthless for laying down application code, since refinements in my thoughts will almost certainly change the structure of the implementation. (Ideally my thoughts have the same structure as the implementation. [FIXME]) Yet errors in my initial characterization of the problem can go unsolved for the entire lifetime of the system I develop.
So the programming environment should help me clarify what I mean by a "paragraph", helping me keep my concept consistent (though forgiving me for being temporarily inconsistent -- see "Rigidity, Corner Cases, and Syntax" [FIXME]) while I refine the structure of my thoughts.
It should ask questions like, "What should happen if the area of the paragraph extends outside the page margin?" -- because I gave it the concept of paragraph area and page margin and it determined that the two could be in conflict. Or "what should happen if the first line indent is negative?".
communicate
Everything makes nearly perfect sense, as long as it stays within the confines of my mind. As soon as it tries to leave, it crashes into reality and comes out a mess. In the process of clarification, my goal is to communicate thoughts clearly. Communicating with a computer is far more demanding than another human, because it probably doesn't share my instinctive understanding of the way the world works. But if I've accurately explained my world to the computer, making my concept understandable to it also makes it more understandable to fellow humans. The number of courses we must take in writing shows how little we start off understanding about clear communication. So there's a lot that the computer can do to help. [FIXME: this section is weak and not clearly differentiated from "clarify". Perhaps they are really the same thing.]
ideas
Not algorithms, structures, or processes. I mostly covered this in "(Big-Picture)".
Next: Concepts and Relationships
~Ken
Tuesday, December 5, 2006
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment