<?xml version='1.0'?>
<!DOCTYPE spec PUBLIC "-//W3C//DTD Specification V2.6//EN" "http://www.w3.org/2002/xmlspec/dtd/2.6/xmlspec.dtd"
[
  <!-- ================================================================ -->
  <!ENTITY draft.day "19">
  <!ENTITY draft.month "12">
  <!ENTITY draft.monthname "Dec.">
  <!ENTITY draft.year "2005">
  <!ENTITY iso6.doc.date "&draft.year;-&draft.month;-&draft.day;">
  <!ENTITY http-ident "http://www.w3.org/2001/tag/doc/leastPower">
]>

<spec w3c-doctype='wd' role='editors-copy'>
<header>
<title>The Principle of Least Power</title>
<w3c-designation>&http-ident;-&iso6.doc.date;</w3c-designation>
<w3c-doctype>Draft Tag Finding</w3c-doctype>
<pubdate><day>&draft.day;</day>
<month>&draft.monthname;</month>
<year>&draft.year;</year>
</pubdate>
<publoc>
<loc href='&http-ident;-&iso6.doc.date;.html'>&http-ident;-&iso6.doc.date;</loc>
</publoc>
<altlocs>
<loc href='&http-ident;-&iso6.doc.date;.xml'>XML</loc>
</altlocs>
<latestloc>
<loc href='&http-ident;.html'>&http-ident;</loc>
</latestloc>
<prevlocs>
</prevlocs>
<authlist>
<author><name>Tim Berners-Lee</name>
<affiliation>World Wide Web Consortium</affiliation>
<email href='mailto:timbl@w3.org'>timbl@w3.org</email></author>
</authlist>
<copyright>
<p>
<loc href='http://www.w3.org/Consortium/Legal/ipr-notice-20000612#Copyright'>Copyright</loc> &#xA9; 2005
<loc href='http://www.w3.org/'>W3C</loc><sup>&#xAE;</sup>
(<loc href='http://www.lcs.mit.edu/'>MIT</loc>,
<loc href='http://www.inria.fr/'>INRIA</loc>,
<loc href='http://www.keio.ac.jp/'>Keio</loc>),
All Rights Reserved. W3C
<loc href='http://www.w3.org/Consortium/Legal/ipr-notice-20000612#Legal_Disclaimer'>liability</loc>,
<loc href='http://www.w3.org/Consortium/Legal/ipr-notice-20000612#W3C_Trademarks'>trademark</loc>,
<loc href='http://www.w3.org/Consortium/Legal/copyright-documents-19990405'>document use</loc>, and
<loc href='http://www.w3.org/Consortium/Legal/copyright-software-19980720'>software licensing</loc>
rules apply.
</p></copyright>

<abstract>
<p>
When designing computer systems, one is often faced with a choice between using a more or less powerful language for publishing information, for expressing constraints, or for solving some problem.
This finding explains the Principle of Least Power, 
which suggests choosing the least powerful powerful 
language suitable for a given purpose.
</p>
</abstract>

<status>


<p>This document is a first draft of a proposed finding.
It has been produced by the <loc href='/2001/tag/'>W3C
Technical Architecture Group (TAG)</loc>.
The text of this finding was adapted from <loc href="http://www.w3.org/DesignIssues/Principles.html#PLP">Principle of Least Power</loc> in <bibref ref="Axioms"/>.
</p>


<p><loc href='/2001/tag/findings'>Additional TAG findings</loc>, both
accepted and in draft state, may also be available. The TAG may 
incorporate this and other findings into 
future versions of the  <bibref ref='AWWW'/>.
Please send comments on this finding to the publicly archived TAG
mailing list <loc href='mailto:www-tag@w3.org'>www-tag@w3.org</loc>
(<loc href='http://lists.w3.org/Archives/Public/www-tag/'>archive</loc>).
</p>

<p>The terms <rfc2119>MUST</rfc2119>, <rfc2119>SHOULD</rfc2119>, and
<rfc2119>SHOULD NOT</rfc2119> are used in this document
in accordance with <bibref ref='rfc2119'/>.</p>



</status>
<pubstmt>
<p>World-Wide Web Consortium,
Draft TAG Finding, 2005.</p>
</pubstmt>
<sourcedesc>
<p>Created in electronic form.</p>
</sourcedesc>
<langusage>
<language id='EN'>English</language>
</langusage>
<revisiondesc>
<slist>
<sitem>2002-04-30: Published draft</sitem>
</slist>
</revisiondesc>
</header>
<body>

<div1 id='discussion'>
<head>The Principle of Least Power</head>
<p>Computer languages range
from the plainly descriptive (such as Dublin Core metadata, or the content of
most databases, or HTML), 
through logical languages with limited propositional logic (such as
access control lists, or <em>conneg</em> content negotiation), 
through declarative languages that verge on the
Turing Complete (PDF), through those which are in fact Turing Complete though
one is led not to use them that way (XSLT, SQL),
through those that are functional and Turing complete (Haskell), 
to those which are
unashamedly procedural (Java, Javascript, C).</p>

<p>When publishing information or programs on the Web, 
the choice of language is important.  The low power end of
the scale is typically simpler to design, implement and use, but the high
power end of the scale has all the attraction of being an open-ended hook
into which anything can be placed: a door to uses bounded only by the
imagination of the programmer.
Computer Science in the 1960s through 1980s spent a lot of effort making
languages which were as powerful as possible. Nowadays we have to appreciate
the reasons for picking not the most powerful solution but the least
powerful.  The reason for this is that the less powerful the language, the
more you can do with the data stored in that language. If you write it in a
simple declarative from, anyone can write a program to analyze it in many
ways. 
</p>
<p>The World Wide Web is unique in its ability to promote information reuse on a global scale.
Information published on the Web can be flexibly combined with other information, read by a broad range of software tools, and browsed by human users of the Web.
For such reuse to succeed, the broadest possible range of tools must be capable of understanding the data on the Web, and the relationships among that data.
By expressing constraints, relationships and processing instructions in less powerful languages, one increases
the flexibility with which information can be reused.
</p>
<p><a name="plp" id="plp"></a><em>Good Practice:</em> Use the least powerful language suitable for expressing information, constraints or programs on the World Wide Web.</p>
</div1>
<div1 id="exampleWebTechs">
<head>Web Technologies and the Principle of Least Power</head>
<p>HTML is designed not to be a full programming
language so that many different things can be done with an HTML document: 
software can present the document in various styles, 
extract tables of contents, index it, and so on.</p>
<p>
The Semantic Web is an attempt, largely, to map large quantities of
existing data onto a common language so that the data can be analyzed in ways
never dreamed of by its creators. 
If, for example, a web page with weather
data has RDF describing that data, a user can retrieve it as a table, perhaps
average it, plot it, deduce things from it in combination with other
information.  
At the other end of the scale is the weather information
portrayed by an ingeniously written Java applet. 
While the applet  might provide a very cool user
interface, the program cannot be analyzed at all. 
A search engine finding the page
will have no idea of what the weather data is or what it is about. 
Thus, the only way
to find out what a Java applet means is to set it running in front of a
person.</p>

<p>Thus, HTML and the Semantic Web are examples of technologies designed with 
"least power" in mind.  
Web resources that use HTML and the Semantic Web are more
likely to be reused in flexible ways than those expressed in more
powerful languages.
</p>
</div1>

<div1 id='ToDo'>
<head>To Do Before Publishing Finding</head>
<p>The following should be considered before we publish.</p>
<ulist>
<item><p>Is it a principle?  Roy suggests "no".  Should the GPN stay?  Is the title OK?</p></item>
<item><p>Tim BL to review.</p></item>
<item><p>Added reference to functional languages and Haskell OK?</p></item>
<item><p>New 3rd paragraph on "reuse on the Web" OK?</p></item>
<item><p>Existence and wording of GPN OK?</p></item>
<item><p>Separation of and minor rewording of section 2 OK? (Tim had everything in one section.)</p></item>
<item><p>Decide editor list.</p></item>
<item><p>Use RFC2119 uppercase terms?  If not, remove from intro and bibref. I'm leaning against [NRM]</p></item>
<item><p>Tim's original claims the Java applet "can't be analysed at all".  I've kept that for now, but it seems a bit strong.  [NRM]</p></item>
<item><p>Editorial: "the attraction of being an open-ended hook
into which anything can be placed" Mixed metaphor?  Can you place something into a hook?</p></item>

</ulist>
</div1>





<div1 id='references'>
<head>References</head>

<blist>

<bibl id='AWWW' href='http://www.w3.org/TR/webarch/'>I.Jacobs, 
N. Walsh, <titleref>Architecture of the World Wide Web</titleref>.
W3C. December, 2004.
</bibl>

<bibl id='Axioms' href='http://www.w3.org/DesignIssues/Principles.html'>T. Berners-Lee, <titleref>Axioms of Web Architecture</titleref>. 1998.
</bibl>

<bibl id='rfc2119' href='http://www.ietf.org/rfc/rfc2119.txt' key='RFC 2119'>S.
Bradner. <titleref>Key words for use in RFCs to Indicate Requirement Levels</titleref>.
IETF. March, 1997.</bibl>

</blist>

</div1>
</body>

 <back>
    <div1>
      <head>Change log</head>
      <slist>
         <sitem>19-Dec-2005 [NRM]: initial version</sitem>
      </slist>
      <slist>
         <sitem>19-Dec-2005 [NRM]: corrected a few typos, set right date in this change log.</sitem>
      </slist>
    </div1>
 </back>

</spec>
