Category:Enguage: Difference between revisions

No edit summary
Line 26:
These three examples of running the interpreter are: -t, the full unit test suite; -T the unit test for a given concept; and, the interactive shell.
==Algorithm==
All Enguage does is to swap the user's '''utterance''', ''"hello"'', with one of the interpretation's '''replies''', ''"hello to you too". It does this directly, see Hello World, or by issuing (thinking?) further utterances and using the replied answer and the status of that thought: 'if so, ...' being operated if the outcome is positive, and 'if not, ...' if it negative. This supplies the idea of conditional processing and recalling (recursion) is used to create loops, see the FizzBuzz example. Thus, interaction with Enguage is always given as a Turing complete discourse: utterance to reply.
It does this either directly, ''On "hello", reply "hello to you too".'', or by issuing (thinking?) further utterances and maintaining, and using, a replied answer and the status, or felicitous outcome, of that thought.
 
Each utterance has one or more interpretations <ref name="disamb">[http://dx.doi.org/10.1007/978-3-319-42102-5_16 A Pragmatic Approach to Disambiguation, ICISO, 2016]</ref>, which is the equivalent of a function in a traditional programming language.
As well as the 'reply "..."' imperative, Enguage also has several other such 'hooks' to allow other operations available to the software to be called, such as perform "..." to access the Java classes, and run "..." to run an external command. That Enguage passes off processing to traditional software is regarded as little different to machine code operating an ALU to provide arithmetic operations. The Turing complete qualities (lists of instructions, which can form loops, and which can be conditionally operated) are available to the implemented language.
Each function can be specified in a '''.txt''' file, or can be created by utterance, e.g. "''to the phrase hello reply hello to you too.''"
A group of utterances, a '''repertoire''', equivalent to an API in traditional languages supports an idea, or concept.
For example, a simple repertoire might be: ''i need a coffee'', ''i do not need a coffee'', ''do i need a coffee'' and ''what do i need''.
 
The Turing complete quality of a function is that it is represented as a list of instructions.
These instructions can form loops, and can be conditionally operated, and are implemented by the implemented language, not in source code (i.e. within the interpreter).
The felicitous nature of a thought can be used by prefixing a subsequent thought with 'if so, ...' if the outcome is positive, and 'if not, ...' if it negative. This supplies the idea of conditional processing and recalling (recursion) is used to create loops, see the FizzBuzz example.
Thus, interaction with Enguage is always given as a Turing complete discourse: utterance to reply.
 
===Hooks===
As well as the 'reply "..."' imperative, Enguage also has several other such 'hooks' to allow other operations available to the software to be called, such as perform "..." to access the Java classes, and run "..." to run an external command. That Enguage passes off processing to traditional software is regarded as little different to machine code operating an ALU to provide arithmetic operations. The Turing complete qualities (lists of instructions, which can form loops, and which can be conditionally operated) are available to the implemented language.
 
==References==
{{reflist}}
49

edits