[ Log In ]
General Tools
Core Principles

Ideal Automate


An Abstract Algorithm that can be used to Solve Any Problem

Here is an abstract algorithm that can be used to solve any problem:

1. A Problem arises when there is a "gap" between the Actual and the Ideal.
2. The first step to solving the problem is to compare the Actual to the Ideal and find the Differences.
3. Once the Differences have been identified, we need to translate those differences into Actions that we know how to perform.
4. Once the Differences have been translated into Actions, we perform those actions on the Actual in order to transform it into the Ideal.

When we learn how to automate the above algorithm, we can go on "autopilot" and let the computer solve any problem that arises. Until that time, we can automate manual repetitive tasks one at time, but we should only automate those tasks where the cost savings for automating them is greater than the cost of doing them manually.

Open Source C# Development Platform for Automating Computer Tasks

Ideal Automate is an open source development platform that allows C# developers to automate any repetitive task and to share what they have automated with other developers.

Ideal Automate allows one to automate almost any task. It does this by making it possible for you to write scripts that can find images on the screen. By finding an image on the screen, you are able to locate where you want to read or write something, regardless of which application the image resides within. The fact that you can read and write to virtually any location makes it possible to create a degree of artificial intelligence where the script is able to perform real-time, problem-solving activities. For example, the script can read a piece of information, interpret what it has read, and then make decisions in real time about what to do based on that interpretation.

Ideal Automate is based on the reuse of scripts that others have built. The ideal is that one person solves a problem and many can benefit from that solution when it published.

Three Components of IdealAutomate

Ideal Automate consists of three basic components:

1. IdealAutomate - This is a simple WPF C# application that allows you to easily execute the DOS command to start any application with the content you specify. This allows you to create a central repository of all the C# applications that you have created to automate various repetitive tasks. The WPF Application provides the central repository with a menu that allows you to assign hotkeys to the applications so that you can cause them to execute just by pressing a combination of keys. Here is a screenshot of the IdealAutomate component:

2. IdealAutomateCore - This is a class library that contains most of the methods that are commonly used to automate any task on the computer. For example, there are methods that allow you to easily do the following things:

A. Find an image on the screen and click on it
B. Display a window that will allow users to provide input using most of the standard controls (textbox, dropdownlist, etc.)
C. Automatically type text on the screen at any location
D. Get and Put information into the clipboard
E. Run another application as a process thread. The thread can run asynchronously (the parent application does not wait for completion of the child application) or synchronously (where the parent application does wait for the child).

3. ActionScripts - Each application that you write that uses the IdealAutomateCore class library is referred to as an "automation script," or "script" for short. A script is created by using Visual Studio to create a new C# WPF application that is based on the IdealAutomateCore project template. This template makes sure that your project includes a reference to the IdealAutomateCore Class Library, which contains all of the functions that you will need to automate any task. Scripts do not involve learning a special scripting language. This allows you to leverage your existing C# knowledge.

General Workflow

Here is the general workflow process for solving problems with IdealAutomate. Whenever we solve a problem, we start out by comparing the Actual to an Ideal. The "actual" is what the computer is currently doing and the "ideal" is what we want the computer to do. In order to transform the actual into the ideal, we need to find the differences between the actual and the ideal and translate those differences into actions that we can perform on the "actual" to make it become the "ideal." I use two types of libraries to help me in this process of transforming the actual into the ideal.

Knowledge Base Library

The first type of library is my "knowledgebase." I use Abstract Spoon's open source ToDoList as my knowledgebase, but you can use any type of knowledgebase that you want. The knowledgebase is just a dictionary that defines "unknown things" in terms of "known things." In order for a knowledgebase to work, we must start out with some basic things that we "innately know" and build up from those basic building blocks. The types of things that we innately know include such things as being able to read and write information and recognize shapes and patterns on the computer screen and so on. These basic building blocks are meaningful to us because we know what they represent or what they can be used to accomplish. When we define other things in terms of these basic building blocks, we are transforming what was previously meaningless to us into what is meaningful. It is in this way that we expand our world of meaning. We can only solve problems when we are dealing with things that are meaningful to us. When we can not translate something complex into something more simple that we already understand what it means, we are blocked in our problem solving process. This is why a knowledgebase is one of the important libraries that we need in the problem solving process. The knowledgebase contains a repository of everything we understand and of everything that is meaningful to us. Once we translate the differences that exist between the actual and the ideal into items that are contained in our knowledgebase, we can begin the process of solving the problem. Once the differences between the actual and the ideal are meaningful to us, we have the tools at our disposal to start figuring out the steps that we need to take to remove the differences one step at a time. If we know all of the simple components that go into making up one of the differences between the actual and the ideal, we can work from the level of those simple components that we understand to remove that larger difference that we did not at first appear to understand. For example, suppose that when we compare the actual to the ideal, we find that we need to add a textbox to the actual in order to transform it into the ideal. If we did not know all of the details about what makes a textbox different from a label, we would not be able to identify whether a textbox or label was what was causing the actual to be different from the ideal. Similarly, if we did not know all the detail steps involved in adding a textbox to a web page, we would be at a loss. However, if the knowledgebase provides us with all of that information, we can proceed to identify the difference between the actual and the ideal as being a textbox and then we can take each of the steps cataloged in the knowledgebase in order to change the actual into the ideal.

The knowledgebase that I build with Abstract Spoon's software is not something rigid and formal. It is basically a set of notes that I take everytime I learn something new. I do not formally tie everything back to the ultimate basic building blocks of things that I innately know. I just try to keep my knowledgebase simple and structure it the best I can as I proceed.

ActionScript Library

The knowledgebase just provides me with the information that I need in order to accomplish the task manually. However, if I notice that I am performing the same task over and over again, I may want to automate that process. When I want to automate an item in my knowledgebase, I set a flag on that item to remind me that I would like to automate this someday. This is where the second type of library that is involved in the problem-solving process comes into play. This second type of library is called the action script library. The action script library consists of the three components described above as the three components of IdealAutomate.

Let us look at the example of adding a textbox to a webpage. In this example, we can write a C# application that has a reference to the IdealAutomateCore library that can perform all of the steps needed in order to add any textbox to any webpage. The application will take some initial parameters from the user that specify some of the specifics regarding the textbox and the webpage, and then it will perform all the required steps without requiring our intervention of decision-making skills. Everytime we have to make a decision manually, it takes energy and time on our part, but when we automate that, the energy and time are no longer required from us.