Learn something new every day
More Info... by email
When people speak about natural language in computing, they are referring to a programming language that contains constructs and syntax that mirrors normal human speech. The primary purpose of any natural language is to permit a programmer to use linguistic rules and terms with which he or she is already familiar to communicate actionable instructions to a computer. Due to the requirement for end-user explicitness and leveraging an already known and spoken language, natural languages such as Programming in Logic (Prolog) or Lisp tend to be more intrinsically complex than other programming languages, depending on the higher-order or symbolic abstractions of what the computer can understand and act upon. In other words, the easier it is for the end-user to create a computer program without having to know a structured procedural language, or any language other than the one he or she already speaks, the more complex the natural language program engine must be to support the freedom of expression.
Natural languages contain parsers and databases. The databases determine what action the computer must perform based on the instruction, and the parser determines in which order the syntax must be executed. For example, if the user types, "Add two and two," the parser must make a distinction between noun and verb, understand what the verb's action should accomplish, search the database for an appropriate response, and then produce an output that satisfies the instruction. If the user types, "Add two to two," the parser must be able to understand that "and" and "to" indicate that the same action should occur and then produce the same result.
Proponents of natural language programming argue that because natural languages tend to be non-procedural in nature, novice programmers can produce meaningful programs and achieve significant results in shorter time frames than they do when required to create procedural algorithms that lead to the same results. With natural language programming, students learn to express a logical notation of facts. Prolog programs consist of a database, the relationships between database items, and all the boundary conditions that determine which answers are acceptable ones.
Noam Chomsky's research and publications regarding linguistic theory and usage include diagrammatical explorations of the syntax structure of a language. The Prolog and Lisp parsers behave in much the same way, logically sorting the instruction into its components and assessing the action to take as a result of the parsing. Most natural languages are written for English input and output, although many efforts are underway to support localization for other languages.
One of our editors will review your suggestion and make changes if warranted. Note that depending on the number of suggestions we receive, this can take anywhere from a few hours to a few days. Thank you for helping to improve wiseGEEK!