Dec 182017
 
AI Command line Interface. Will guess what you meant to type if you make a common typing mistake. Has a 20 command-line history buffer.
File AI20.ZIP from The Programmer’s Corner in
Category Utilities for DOS and Windows Machines
AI Command line Interface. Will guess what you meant to type if you make a common typing mistake. Has a 20 command-line history buffer.
File Name File Size Zip Size Zip Type
AI(SHELL.EXE 19296 10160 deflated
AI.EXE 18896 9919 deflated
USER.TXT 35903 10568 deflated

Download File AI20.ZIP Here

Contents of the USER.TXT file






The Artificially Intelligent Command Line Interface

Revision date: October 1st, 1990


Copyright 1990 George Toft


Distributed by:

AAron Computer
PO Box 4708
Mesa, AZ 85211




Table of Contents

Shareware Distribution and Usage License . . . . . . . . . . 3
MONEY BACK GUARANTEE

Limitation of Liability . . . . . . . . . . . . . . . . . . 4

Distribution License . . . . . . . . . . . . . . . . . . . . 5

Trademark Acknowledgements . . . . . . . . . . . . . . . . . 5

What is "The Artificially Intelligent Command Line
Interface?" . . . . . . . . . . . . . . . . . . . . . . 6

Getting Started . . . . . . . . . . . . . . . . . . . . . . 7

How To Stop AI . . . . . . . . . . . . . . . . . . . . . . . 8

Command Line Editor . . . . . . . . . . . . . . . . . . . . 9

Communicating with AI . . . . . . . . . . . . . . . . . . . 11

Editing Macros . . . . . . . . . . . . . . . . . . . . . . . 15

Understanding Word Relations . . . . . . . . . . . . . . . . 16

Switching Dictionary Files . . . . . . . . . . . . . . . . . 18

Teaching AI Words Immediately . . . . . . . . . . . . . . . 19

Implementation Considerations . . . . . . . . . . . . . . . 23

Reporting Errors . . . . . . . . . . . . . . . . . . . . . . 24

Credits and Program History . . . . . . . . . . . . . . . . 25

Error Report . . . . . . . . . . . . . . . . . . . . . . . . 26

Quantity Discounts . . . . . . . . . . . . . . . . . . . . . 27

Order Form . . . . . . . . . . . . . . . . . . . . . . . . . 28

Shareware Distribution and Usage License

This program is "Shareware." It is not "freeware," nor is it
free, nor public domain software. Shareware is an alternative
marketing method whereby you try the software first, then buy it
if you like or use it. It's like buying a car in that you test
drive the product prior to purchasing it. With shareware,
however, no salesman buzzes overhead pressuring you into buying
it. You are on your honor to pay for it if you use it.

You are hereby provided a short-term (30 days) license to use the
software provided you do not violate any of the terms in this
license. Violation of any of the terms of this license shall
immediately and permanently terminate this and all future
licenses.

Specifically, you may not sell, rent, sub-let, lease, nor reverse
engineer this program. You may not remove the copyright
statements that may appear in it or in the documentation. You
may not alter either the documentation nor the program.

You may use this program on a single task, single user, non-
networked computer, for an evaluation period of thirty (30)
calendar days.

Use of this program for more than thirty (30) days constitutes
your acceptance of the program as useful, and encumbers you to
register your copy of it with AAron Computer. In return, you
will receive notification of updates to the program, and if a
serious error has been found in the program, you will receive a
free update.

MONEY BACK GUARANTEE: If this program fails to operate as
described during the first year of use after registration, AAron
Computer will either replace your copy of the program diskette,
or refund your registration fee within thirty (30) days of
written notification and return of the distribution diskette to
AAron Computer. You must also return the error report explaining
why you are returning the program diskette. Just let us know
what you want.

The registration fee is $15.00 in U.S. funds. Original
distribution diskettes (certified virus-free) are $5.00 each.
Shipping and handling is $5.00 for each disk. COD charge is
$5.00. Please fill out the order form at the end of this
document when ordering. Quantity discounts are available.

Now for the legal stuff.

Limitation of Liability

THE PROGRAM AND THE MANUAL ("SOFTWARE") ARE PROVIDED "AS IS"
WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED,
INCLUDING, BUT NOT LIMITED TO THE IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE
ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE SOFTWARE IS
WITH YOU. SHOULD THE SOFTWARE PROVE DEFECTIVE, YOU AGREE TO
ASSUME THE ENTIRE COST OF ALL NECESSARY SERVICING AND REPAIR.

USE OF THIS SOFTWARE CONSTITUTES YOUR AGREEMENT TO THESE TERMS.

AAron Computer does not warrant that the function contained in
the SOFTWARE will meet your requirements or that the operation of
the program will be uninterrupted or error-free.

Diskette warranties are covered by the entity that provided the
SOFTWARE or diskette to you, and will not be honored by AAron
Computer. AAron Computer furnished diskettes are warranted for a
period of ninety (90) days from date of shipment against failure
from material or workmanship. Return defective diskettes to
AAron Computer in a diskette mailer.

AAron Computer warrants the SOFTWARE will perform substantially
according to the SOFTWARE'S issued specifications.

THE LICENSING PROVISIONS AND APPLICABILITY OF UNITED STATES
COPYRIGHT LAWS PERTAIN TO ALL USERS OF THIS PROGRAM. THIS
INCLUDES CORPORATE, GOVERNMENT, AND INSTITUTIONAL USERS.

Distribution License

You are free to duplicate this program and distribute it to your
associates, friends, bosses, electronic bulletin boards,
computer clubs, etc, with the provision that all files remain
intact and unmodified and no fee is charged. Shareware
distributors and computer clubs may charge up to $5.00 as
compensation for materials, wear and tear, and labor.



Trademark Acknowledgements

MS-DOS is a registered trademark of Microsoft Corporation.
AAron Computer is a Trademark of AAron Computer.

What is "The Artificially Intelligent Command Line Interface?"

The Artificially Intelligent Command Line Interface, or AI, is a
Terminate and Stay Resident (TSR) program that intercepts all
input to DOS from the keyboard. It allows you to make typing
errors and it will correct them for you based on your previous
mistakes. It virtually eliminates the "Bad command or file name"
error we're all too familiar with. For example, if you type "DOR
*.EXE" instead of "DIR *.EXE" (and you've made this mistake once
before), this program will ask if you want to substitute DIR for
DOR and execute "DIR *.EXE" correctly. After a while, AI will
automatically make the correction for you.

An added feature, command line editing, remembers the last 20 of
your previous commands. You may recall a previously entered
command, edit it with the cursor keys, and renter it as a new
command.

AI takes up about 35K while running, and will store 256 different
words and their correct spellings. Translation to the correct
spelling is instantaneous and totally transparent to you.

An offshoot of this application is foreign language translation.
Since the program is not concerned with what was typed, you can
type in anything you like, and it will ask you for the correct
spelling or the command. For example, you could train it to know
that "ZEIT" means "TIME." Then, each time you typed ZEIT, it
would substitute TIME in its place.

Getting Started

Installing AI onto your hard drive is done my making a directory
and copying the AI files into it. Assuming you have the AI files
on a floppy disk, type these commands from the DOS prompt:

C:
CD \
MD AI
CD AI
COPY A:*.*
CD \


Loading AI is performed by invoking the program with an optional
dictionary file. To load the program with the default
dictionary, type "AI" and press [Enter].

For example, if you have AI.EXE stored in a directory called AI,
you would have to enter the following keystrokes to properly load
AI:

CD \AI
AI
CD \


This start-up procedure is necessary so that AI will know where
to store its dictionary file. The dictionary file is stored in
the directory and drive that you were logged into when AI was
invoked.

To create you own personal dictionary, invoke AI with the name of
your dictionary:

CD \AI
AI MyDict.ai
CD \


Since AI stores its dictionary file on disk every time you type
"EXIT," it must have access to the disk and the subdirectory it
was invoked from. If the specified dictionary file was not
available, it will be created for you.

How To Stop AI

AI.EXE can't be stopped, but AI(SHELL.EXE can. Typing "EXIT"
will save your dictionary to disk, and unload AI(SHELL.EXE. If
you want to unload AI.EXE, you will have to use a TSR manager
such as INSTALL.EXE and REMOVE.EXE, both available from PC
Magazine.

It is important you type "EXIT" before you shut down your
computer, if you want to save your dictionary. Failure to do so
will result in AI not remembering anything it learned during your
previous session, as well as you losing the last 20 commands you
typed.

Command Line Editor

The command line editor totally replaces the MS-DOS template with
an easy to use command recall and sensible editing system. You
can recall your most recent commands, move your cursor to the
point you want to change, insert or replace the characters on the
line, and renter the line.

Other controls available move you forward in your list of
commands, clear the list, delete a word, and delete the current
line for complete rewrite.

One of the significant benefits of the AI program is it becomes
an integral part of your operating system. All of the DOS
functions that are used to call the "Line Input" function will
now call on AI to get their input. Two good examples are EDLIN
and DEBUG; both of these programs will call AI for keyboard
input. You'll be amazed at how many programs use DOS for line
input.

The editing keys, and their purposes are detailed in the chart
below:


Cursor Key Function performed

Up Arrow Recalls previous entered command.

Down Arrow Recalls next entered command.

Left Arrow Moves left one character on line.

Right Arrow Moves right one character on line.

Control Left Arrow Moves left one word on line.

Control Right Arrow Moves right one word on line.

Home Moves to the start of the line.

End Moves to the end of the line.

Control "T" Erases text from the cursor to
the end of the word.

Control "Y" Erases the entire line.

Control End Erases the line from the cursor
to the end of the line.

Control Back-slash Activates/deactivates the AI pro-
gram. The default is activated.


These codes conform to most word processors on the market today.

Communicating with AI

There are times when you may want to alter AI's operating
characteristics. To do so, you must be able to communicate with
it.

Whenever you type something at the keyboard, you are "speaking
to" the AI program. Your commands are usually passed through to
the command interpreter. The cursor keys are intercepted, and
their functions altered to create an editor (see previous
chapter). As you will see in later chapters, the function keys
are also intercepted and their functions are reassigned. This
forms the basis of the communications with AI.

You can alter AI's performance by typing commands at the
keyboard. These commands will be intercepted and will not reach
DOS or your applications program. Just preface the command with
"AI:" and the entire line will be diverted to AI's internal
command processor.

AI provides seven internal commands: List, Macro, Switch, Learn,
Forget, Epsilon, and Save. These commands are summarized below,
and will be discussed in detail in later chapters.

"AI:List" displays the assigned macros for function keys 1
through 10.

"AI:Macro" changes the assigned macros for function keys 1
through 10.

"AI:Switch" switches to another dictionary file. You must
specify the name of the new dictionary in the command.

"AI:Learn" allows AI to learn a new word relation immediately,
without having to learn it from you in real-time.

"AI:Forget" drops a word from a relationship. If a primary, or
DOS, word is the target of the forget action, all references to
that word are forgotten.

"AI:Epsilon" controls how soon AI learns a word. The default is
three, which means the third time you make the same mistake, AI
will automatically make the correction for you. Changing Epsilon
will alter the operation of AI in that the words that you have
made fewer mistakes on, but were substituted will now be
questioned. Likewise, lowering Epsilon will preclude questioning
weak word relationships.

"AI:Save" saves your current dictionary to disk, in the directory
that was active when you loaded AI.

Note: When you issue a command to AI, that command is saved in
the command queue, just in case you want to repeat a similar
command.

The Dictionary File

The dictionary file contains the words you make mistakes on and
their corrections. It also holds macros for the ten function
keys, F1 through F10, and the Epsilon learning value. This file
is updated each time you type "Exit" at the DOS prompt, or
whenever you type "AI:Save" to save the dictionary back to disk.

Note: If AI operation has been suspended (by pressing Control
Back-slash), AI will not save the dictionary. If AI is
suspended, all of its features are suspended. This feature may
be useful if you decide not to save the dictionary back to disk
at the end of the day.


The dictionary file also stores the command queue. If you make
it a habit to type "EXIT" before you shutdown your computer, you
will be able to recall the last 20 commands you issued the next
time you turn on your computer.

Macros

AI can store ten macros accessed by the function keys 1 through
10. These macros are loaded each time you start up AI. The
macros can be used to enter a command line rapidly. For example,
if you assigned "DIR" to F9, then pressing F9 would execute the
command DIR. Each macro is limited to 20 characters.

The default macros are described in the following table:


Function Assigned
Key Macro

F1 A:

F2 B:

F3 C:

F4 D:

F5 AI:List

F6 AI:Save

F7 Dir /W /P

F8 Chdir \

F9 Dir

F10 Exit

F11 Not implemented

F12 Not implemented


Note function keys 11 and 12 are not used because not everybody
has a 101 key keyboard. For programming simplicity and
uniformity, AI is designed to operate on all keyboards, and
therefore does not address enhanced keyboards.

Editing Macros

To list the macros that are active in your dictionary, type
"AI:Macros List" and press [Enter]. You will see a screen
similar to this one:

Macro Listing

F1 = A:
F2 = B:
F3 = C:
F4 = D:
F5 = AI:List
F6 = AI:Save
F7 = Dir /W /P
F8 = Chdir \
F9 = Dir
F10 = Exit


To edit a macro, type "AI:Macros F" followed by the function key
number you wish to assign the macro to, followed by an equals
sign ("="), then type the macro you wish to use. Finally, press
the [Enter] key.

For example, to assign the text "Ship" to the macro assigned to
F8, type the following:

AI:Macro F8=Ship

and press [Enter].

Your macros may be up to 64 characters in length, but they must
be valid DOS commands or filename invocations.

Understanding Word Relations

The heart of the AI system is its ability to record your
mistakes, and based on how frequently you make these errors,
assume a correction for you. In the early stages of each error,
AI will ask you to approve its assumptions, but after you have
made Epsilon mistakes, it will make the correction for you
without asking.

This chapter will show you how AI relates the words to each
other, so you will understand the changes you will be making to
your dictionary.

When you type a command, it is checked against the list of
commands that have been misspelled in the past (in your
dictionary file). If no match is found, the command is sent to
the command interpreter (COMMAND.COM).

If the command is executed, AI will not interfere. However, if
the command interpreter returns with the text "Bad command or
file name," AI invokes its learning mode. The first time the
learning mode is called for any given command, you will be forced
to retype the DOS command (without parameters). AI then forms a
relation between the misspelled word, and its corrected spelling.
This relationship is depicted in the following diagram:

Misspelled word = DOS word

DOS word < Misspelled word


If you enter a command that is in the dictionary, AI follows the
relationship to the DOS word and substitutes it for the
misspelled word.

For example, let's assume you type DIRT *.EXE and pressed [Enter]
before you caught your mistake. The command interpreter will
issue the "Bad command or file name" error. AI will inform you
that what you typed resulted in an error, and to enter what you
really meant. Now you type DIR and press [Enter]. DIRT is
replaced by DIR and the command DIR *.EXE is sent to the command
interpreter. The next time you type DIRT, AI will ask you if you
really meant to type DIR, and will wait for you to respond.
Pressing just [Enter] will tell AI that its assumption is
correct, and DIRT will be replaced by DIR. After you have done
this a number of times, AI will become more sure of your
response, until it will automatically replace DIRT with DIR and
proceed without your intervention.

Typically, your dictionary will have several misspelled words
relating to one DOS word. This is not always true, but for the
most part, it is. This is shown below:


Misspelled word


v

DOS word < Misspelled word

^


Misspelled word




Remember: All misspelled words relate to one and only one
correct DOS word or filename invocation.

Switching Dictionary Files

To stop using your current dictionary, and begin using another,
use the "AI:Switch" command. For example, to stop using the
default dictionary, "DEFAULT.AI," and start using a specific
dictionary, "DOS.AI," type the following:

AI:Switch DOS.AI

and press [Enter]. The new dictionary, "DOS.AI," will be loaded,
or created if it doesn't exist. All new corrections will be
saved in this new dictionary when you either exit AI or use the
AI:Save command.

Teaching AI Words Immediately

To teach a word relation to AI without having to repeatedly make
mistakes and corrections, use the AI:Learn command. The general
form of the Learn command is:

AI:Learn =


To teach AI that a new word, say, "CAT," is the same as "DIR,"
you would type the following:

AI:Learn CAT = DIR

and press [Enter]. AI will now treat CAT and DIR synonymously.


Note: All word relations must eventually relate to a valid DOS
command or a proper filename invocation.


CAUTION: You can change the meaning of a word, which may have
unexpected results. For example, if you were to relate CAT to
DIR, then relate DOG to CAT, AI will not look at your word
relationships and deduce that DOG was the same as DIR.
Therefore, when you type DOG, AI will see CAT, then see DIR and
use DIR. Later, if you were to relate CAT to CLS, then typing
CAT will result in CLS, but typing DOG still maintains its
relationship to CAT and DIR. Therefore, you can change a word in
the middle of the relationship, and have its meaning change, but
any words related to it will retain their previous meanings.

The following diagram illustrates this concept:

CAT = DIR

DIR < CAT


DOG = CAT, therefore DOG = DIR

DIR < CAT < DOG


CAT = CLS, but DOG = old CAT = DIR

CLS < CAT


DIR < old CAT < DOG


The search algorithm and the data structure ensures the newest
incidence of CAT is used first, and the older CATs are used to
maintain the relationship between other words. If you should
issue the command "AI:Forget" to forget CAT, the newest incidence
of CAT would be forgotten, and the previous incidence would then
return.

If you use the AI:Learn command to tell AI that one command
equals another, and the second command is not a valid DOS command
or filename, AI will accept it. When you invoke either command,
however, AI will realize that it doesn't understand your first
command, and will ask you for its meaning. Then AI will relate
your previous two commands to this new command. The following
example illustrates this point.

Suppose you tell AI that CAT means DOG by typing

AI:LEARN CAT = DOG

Then you invoke CAT. AI will look up CAT, find DOG, and execute
it. But DOG will result in a "Bad command or file name" error,
so AI will ask you for what DOG means. If you tell AI that you
meant DIR, DOG will then be related to DIR.

Making AI Forget a Word

You may want to delete a word in AI's dictionary. The
"AI:Forget" command completely removes the specified word from
the dictionary, and reroutes all references to the forgotten
word.

Assuming the example diagram from the previous chapter, the
following diagram illustrates the "AI:Forget" command:

CAT = CLS, but DOG = old CAT = DIR

CLS < CAT


DIR < old CAT < DOG


Forget CAT

DIR < CAT < DOG


Forget CAT (again)

DIR < DOG



It's important to note that if you forget a DOS word, such as
DIR, AI will forget everything associated with it. This is
because all of the words in the chain relate to the DOS word, and
if the DOS word is forgotten, they have nothing to relate to.

The following illustration depicts this special case:

CAT = CLS, but DOG = old CAT = DIR

CLS < CAT


DIR < old CAT < DOG


Forget DIR

CLS < CAT


\ /
poof
/ \


This holds true for several words which relate to a forgotten DOS
word in that all of the words will be forgotten.

Implementation Considerations

AI was written in both Borland Turbo Pascal 5.5, and in assembly
language. Assembly language was used as Pascal does not support
some of the requirements of the program.

The program is a true TSR. It was intentionally written without
the ability to remove itself as all of the techniques which allow
a TSR to identify itself use undocumented features of MS-DOS.
Since the author wanted to provide a product that would continue
to work with subsequent versions of MS-DOS, only documented
(therefore supported) DOS calls were used. The file
"AI(SHELL.EXE" is a version of the program that invokes the
system's command interpreter, and runs as a child process. This
method uses 7K more memory, but makes the program very easy to
remove from RAM, and should work with future versions of MS-DOS.

Reporting Errors

Please report any errors or problems to AAron Computer using the
Error Report at the end of this manual. Your error report will
help us locate and eliminate conflicts with other programs, and
it will enable us to provide a superior product to our other
customers. You do not need to be a registered user to report
errors in the program. However, you must be a registered user to
receive a correction to an error you report.

Credits and Program History

The initial program was written in its entirety by George Toft in
July 1990 based on a discussion with Herbert Gerjuoy, PhD. It
was largely revised in September, 1990. George received his
Bachelor of Science in Computer Software in September 1990, and
has been active in the computer science field since 1977. He has
experience with artificial intelligence and computer graphics;
has published magazine and newsletter articles; and has written
several utilities dealing with PC security and applications that
assist with administrative functions. George may be reached on
CompuServe at [74716,476], or by writing to: AAron Computer, P.O.
Box 4708, Mesa, AZ 85211.

This program is version two, with no revisions. It has been
tested extensively on several PC's using a variety of programs,
and hasn't been found to conflict with any other programs except
one called "History" by the Kramden Utilities. Since "History"
and this program both redefine the BIOS line input function, they
cannot be used together. When History is unloaded, AI becomes
effective again. Since AI performs the same functions as
History, and then some, there is no reason to use History if you
are using AI.

Error Report

Send to: AAron Computer
PO Box 4708
Mesa, AZ 85211


Name

Company

Address

City State ZIP

Mail Stop or Office Code



(date)

The Artificially Intelligent Command Line Interface Program
terminated in an error. The following information is provided to
assist you in locating the error:

Computer Manufacturer/Type:

Processor: Amount of Memory:

TSR's loaded before AI:

TSR's loaded after AI:

Error text on screen:

Application program in use:

Did the computer lock up after the error?

Describe the events leading up to the error:







Size of AI.EXE on your hard disk (or work disk):

Version number of AI.EXE (in manual):

Where did you get the program?

Quantity Discounts

Quantity discounts are available. Quantity purchases allow large
institutions to use this program on a widespread basis. They are
managed as a Site License, where you state how many copies you
need and are charged accordingly. The quantity discount table
shows the price breaks for a given quantity ordered by an
organization.

You may either buy a Site License and duplicate the disks
yourselves, or you may buy the site license and an equal number
of program disks.

The following chart shows the price for each unit based on the
quantity purchased:



Number of Price Each Price Each
Copies Ordered w/o disk with disk
1 - 10 $15.00 $20.00
11 - 50 $13.50 $17.00
51 - 100 $12.00 $15.00
101+ $10.00 $12.50



Note: Quantity discounts are not cumulative, and are valid only
for each purchase made. For example, if you ordered 50 disks
today and 50 disks next month, you both purchases would qualify
for the 11-50 unit discount rate, not the 100 unit discount.


Shipping Table

This table shows the shipping charges for disks that are sent to
you.



Number of disks
being shipped Shipping cost
1 - 2 $2.50
3 - 5 $5.00
6 - 10 $7.50
11 - 20 $10.00
20 - 100 $12.50
100+ $20.00 per hundred



Order Form


Remit to: AAron Computer
PO Box 4708
Mesa, AZ 85211

AI Command Interface



Name

Company

Address

City State ZIP

Mail Stop or Office Code




Quantity Item Each Total

AI Interface Program Registration $ $
(See quantity discount table)

AI Evaluation Program Diskette(s) $5.00 $



Sub Total $

(Arizona add 6.75%) Sales Tax $

(See shipping table) Shipping $

(Add $5.00 for C.O.D.) C.O.D. $


Grand Total $



Please allow ten (10) business days for your order to be
processed.

Index

AI 6, 7
AI(SHELL.EXE 23
Command line editing 6
Command Line Editor 9
Communicating with AI 11
Control Back-slash 13
dictionary
default 7
optional 7
personal 7
Editing Macros 15
EXIT 7, 13
Foreign language translation 6
License 3
Line editing 6
Line Editor 9
Order Form 28
Quantity Discounts 27
Registration fee 3
Shareware 3
Trademark 5
TSR 6, 23
Word Relations 16


 December 18, 2017  Add comments

Leave a Reply