HOME

TheInfoList



OR:

DWIM (do what I mean) computer systems attempt to anticipate what users intend to do, correcting trivial errors automatically rather than blindly executing users' explicit but potentially incorrect input.


Software

The term was coined by
Warren Teitelman Warren Teitelman (1941 – August 12, 2013) was an American computer scientist known for his work on programming environments and the invention and first implementation of concepts including Undo, Undo / Redo, spelling correction, advising, online ...
in his DWIM package for BBN Lisp, part of his PILOT system, sometime before 1966.Warren Teitelman, "PILOT: A Step towards Man-Computer Symbiosis",
M.I.T. The Massachusetts Institute of Technology (MIT) is a private land-grant research university in Cambridge, Massachusetts. Established in 1861, MIT has played a key role in the development of modern technology and science, and is one of the m ...
Ph.D. Dissertation,
Project MAC Computer Science and Artificial Intelligence Laboratory (CSAIL) is a research institute at the Massachusetts Institute of Technology (MIT) formed by the 2003 merger of the Laboratory for Computer Science (LCS) and the Artificial Intelligence Lab ...
MAC-TR-32, September 1966
DTIC AD0638446PDF
p. 51
Warren Teitelman, "Toward a programming laboratory", in J. N. Buxton and
Brian Randell Brian Randell (born 1936) is a British computer scientist, and Emeritus Professor at the School of Computing, Newcastle University, United Kingdom. He specialises in research into software fault tolerance and dependability, and is a noted auth ...
, ''Software Engineering Techniques'', April 1970, a report on a conference sponsored by the NATO Science Committee, Rome, Italy, 27–31 October 1969, p. 108''ff''.


InterLisp

Teitelman's DWIM package "correct derrors automatically or with minor user intervention", similarly to
autocorrection Autocorrection, also known as text replacement, replace-as-you-type or simply autocorrect, is an automatic data validation function commonly found in word processors and text editing interfaces for smartphones and tablet computers. Its principal ...
for natural language. Teitelman and his
Xerox PARC PARC (Palo Alto Research Center; formerly Xerox PARC) is a research and development company in Palo Alto, California. Founded in 1969 by Jacob E. "Jack" Goldman, chief scientist of Xerox Corporation, the company was originally a division of Xero ...
colleague
Larry Masinter Larry Melvin Masinter is an early internet pioneer and ACM Fellow. After attending Stanford University, he became a Principal Scientist of Xerox Artificial Intelligence Systems and author or coauthor of 26 of the Internet Engineering Task Force's ...
later described the philosophy of DWIM in the
Interlisp Interlisp (also seen with a variety of capitalizations) is a programming environment built around a version of the programming language Lisp. Interlisp development began in 1966 at Bolt, Beranek and Newman (renamed BBN Technologies) in Cambridge, ...
programming environment An integrated development environment (IDE) is a software application that provides comprehensive facilities to computer programmers for software development. An IDE normally consists of at least a source code editor, build automation tools a ...
(the successor of BBN Lisp):
Although most users think of DWIM as a single identifiable package, it embodies a pervasive philosophy of user interface design: at the user interface level, system facilities should make reasonable interpretations when given unrecognized input. ...the style of interface used throughout Interlisp allows the user to omit various parameters and have these default to reasonable values...
DWIM is an embodiment of the idea that the user is interacting with an agent who attempts to interpret the user's request from contextual information. Since we want the user to feel that he is conversing with the system, he should not be stopped and forced to correct himself or give additional information in situations where the correction or information is obvious.
Critics of DWIM claimed that it was "tuned to the particular typing mistakes to which Teitelman was prone, and no others" and called it "Do What Teitelman Means" or "Do What Interlisp Means", or even claimed DWIM stood for "Damn Warren's Infernal Machine."


Emacs

The concept of DWIM has been adopted in augmented form within the context of the
GNU Emacs GNU Emacs is a free software text editor. It was created by GNU Project founder Richard Stallman, based on the Emacs editor developed for Unix operating systems. GNU Emacs has been a central component of the GNU project and a flagship project of ...
text editor A text editor is a type of computer program that edits plain text. Such programs are sometimes known as "notepad" software (e.g. Windows Notepad). Text editors are provided with operating systems and software development packages, and can be us ...
to describe the design philosophy of
Emacs Lisp Emacs Lisp is a dialect of the Lisp programming language used as a scripting language by Emacs (a text editor family most commonly associated with GNU Emacs and XEmacs). It is used for implementing most of the editing functionality built into Ema ...
functions or commands that attempt to intelligently "
do the right thing ''Do the Right Thing'' is a 1989 American comedy-drama film produced, written, and directed by Spike Lee. It stars Lee, Danny Aiello, Ossie Davis, Ruby Dee, Richard Edson, Giancarlo Esposito, Bill Nunn, John Turturro, and Samuel L. Jackson, a ...
" depending on context. The Emacs
wiki A wiki ( ) is an online hypertext publication collaboratively edited and managed by its own audience, using a web browser. A typical wiki contains multiple pages for the subjects or scope of the project, and could be either open to the pu ...
gives the example of a file copy command that is able to deduce the destination path from a split window configuration that contains two
dired Dired (for Directory Editor) is a computer program for editing file system directories. It typically runs inside the Emacs text editor as a specialized mode, though standalone versions have been written. Dired was the file manager, or visual edi ...
buffers, one of which displays the source path; this behaviour also generalises to many applicable dired actions that take two directory paths for arguments. DWIM behaviour, when available, is often mentioned in a command's name; e.g. GNU Emacs has a comment-dwim function that comments out a selected region if uncommented, or uncomments it when already commented out, while using comment characters and indentation appropriate for the programming language environment and current context. This kind of DWIM is often not directly concerned with correcting user error but rather guessing user intent from available context. For example, the Emacs
Magit Magit is an interface to the Git version control system (a Git Client), implemented as a GNU Emacs package written in Elisp. It is made available through the MELPA package repository, on which it is the most-downloaded non-library package, with a ...
package evinces this design philosophy pervasively. Among its numerous
diff In computing, the utility diff is a data comparison tool that computes and displays the differences between the contents of files. Unlike edit distance notions used for other purposes, diff is line-oriented rather than character-oriented, but it ...
commands, there is a magit-diff-dwim command, which requires no further input from the user but simply guesses what the user wants to analyse based on the location of the
cursor Cursor may refer to: * Cursor (user interface), an indicator used to show the current position for user interaction on a computer monitor or other display device * Cursor (databases), a control structure that enables traversal over the records in ...
. The Magit User Manual describes the behaviour of magit-diff-dwim simply: "''Show changes for the thing at point''".


See also

*
Principle of least astonishment The principle of least astonishment (POLA), aka principle of least surprise (alternatively a law or rule), applies to user interface and software design. It proposes that a component of a system should behave in a way that most users will expect it ...
*
Affordance Affordance is what the environment offers the individual. American psychologist James J. Gibson coined the term in his 1966 book, ''The Senses Considered as Perceptual Systems'', and it occurs in many of his earlier essays. However, his best-know ...


References


Further reading

* Warren Teitelman, "Automated programmering '' ic': the programmer's assistant", in ''Proceedings of the FJCC'', 1972 {{doi, 10.1145/1480083.1480119 Usability Spell checkers Text editor features ru:Графический интерфейс пользователя#DWIM