Sam Eldin’s Switch-Case Algorithm
Introduction:
Algorithms:
Algorithms are procedures, often described in mathematical language or pseudocode, to be applied to a dataset to achieve a certain function or purpose.
Decision Tree:
According to Google search:
A decision tree is a tree-like model that acts as a decision support tool, visually displaying decisions and their potential outcomes, consequences, and costs. From there, the "branches" can easily be evaluated and compared in order to select the best courses of action.
Decision tree analysis involves visually outlining the potential outcomes, costs, and consequences of a complex decision. These trees are particularly helpful for analyzing quantitative data and making a decision based on numbers.
:
Decision trees in machine learning provide an effective decision-making method because they lay out the problem and all the possible outcomes. It enables developers to analyze the possible consequences of a decision, and as an algorithm accesses more data, it can predict outcomes for future data.
Pros and Cons of Decision Tree:
We need to present both the Pros and Cons of Decision Tree based.
The Decision Tree Method comes with certain advantages disadvantages:
Pros:
Easy to use, Easy to understand, clear and efficient, can handle multiple outputs, analysis, advanced data analysis.
It reduces data cleaning, minimal data preparation, provides uniform, simple structure, parsing and branching.
Cons - Issues:
Stability, handling imbalanced data, tree traversing, depth limitation, early stopping, looping, reliability, cross-validation, biases, limitations, complexity and performance - benefits. Image #2 is showing Uneven Tree Structure - only two branching (Left or Right branching).
Our Switch-Case Algorithm Alternative:
Switch-Case Programming Structure:
A programming switch statement is a control flow structure that allows the execution one of many code blocks based on the value of an expression. It is often used in place of if-else ladder when there are multiple conditional codes. The basic syntax of a switch-case structure in Java is as follows:
switch(expression) {
case x: // code block
break;
case y: // code block
break;
default:
// code block
}
Image #3 presents a comparison between If-Else and Switch-Case, where the Switch-Case statement is more direction execution (more of Goto statement) with several options based on the value of the switch-case expression. As for the Decision Tree is very much an If-Else statement with only two branching (Left or Right branching).
Our Switch-Case Algorithm Structure (not a Tree):
What are we trying to sell or provide?
The Decision Tree had been used for long time and we believe we have a better solution which address the AI demands and cost reduction.
The questions are:
1. What is our Switch-Case Algorithm?
2. What is our Switch-Case Algorithm Structure?
3. What are the levels of processing and processing power?
4. Comparison between Decision Tree and our Switch-Case Algorithm Structure.
5. What are the wishful goals of Switch-Case Algorithm Structure?
What is our Switch-Case Algorithm?
Our Switch-Case Algorithm:
Our Switch-Case Algorithm is: an intelligent expandable, reusable, iterate-able replacement of the Decision Tree algorithms, AI model and AI agents.
What are the processes-steps of our Switch-Case Algorithm?
The details needed for any algorithm to be built and executed for all cases including integration can be overwhelming and the amounts of details based on the business type and the target output would vary considerably.
The following is the 2,000 Foot-View of Our Switch-Case Algorithm Processes needed:
1. Using and expanding the programming Switch Statement control flow
2. Added MISC and EXCEPTION cases to the Switch Case default
3. Provide more decision making and processes-points
4. Looping Options in the Switch-Case Control flow
5. Decision-making can be programmed, controlled and loop back for reuse
6. See the integration processes in Integrating Our Switch-Case Algorithm with other Algorithms section
7. Handling Big Data, ML matrices, AI options and AI control flow
Image #4 presents our Switch-Case Algorithm Structure using switch statement programming language control flow. The algorithm uses the default case, 7 other cases plus MISC and EXCEPTION cases (a total of 10 cases) to provide decision control options. Each of these decision control options or cases can be nested to create another-addition 10 more decision control options. The algorithm has the ability of looping back from the beginning and that would also expand the options for iterating decisions and reusing the existing options (services).
Image #4 presents the use of Decision-Maker control to direct the flow of executions of service or make nested or new decisions.
Image #4 has three levels of nesting. The first level (Level #0) has 10 (what we recommend) decision points, the second nested level (Level #1) can have up to 100 decision points and the third nested level (Level #2) can have up to 1,000. The total of 1,110 decision-points. Looping back from the beginning or from a level higher would make the total of our algorithm decision-points in the tens of thousands.
Comparison between Decision Tree and Our Switch-Case:
Image #5 presents the comparison between Decision Tree and our Switch-Case. It is obvious that our Switch-Cass structure can handle more decision-point at every level as the execution is parsed from top-to-bottom. Our Switch-Case literally accommodates more decision-points as the executing code transverses downward.
Implementation:
See our Switch-Case AI Model-Agent (Our AI Virtual Receptionist Systems):
Our Switch AI Model-Agent 2,000 Foot View Tiered Structure:
A 2,000 Foot-View Tiered Structure is a common business phrase that refers to a high-level, strategic perspective, allowing for a broader understanding of a situation or problem, rather than getting bogged down in the details.
Image #6 presents a rough picture of Our Switch-Case AI Model-Agent 2.000 Foot View Tiered Structure Diagram. Our AI Model is composed of the following tiers:
1. Big Data Tier
2. Machine Learning Analysis Tier
3. Data Matrices Pool Tier
4. Added Intelligence Engines Tier
5. Management and Tracking Tier
6. Updates Tier
7. User Interface Tier
Implantation of Switch-Case Algorithm:
See our Switch-Case Algorithm Page:
Pharmacy and Insurance Companies Use Cases and The Needed Processes:
We are presenting more of simplified use case of an incoming call to a pharmacy or an insurance company. The income call would have to pass through the company phone caller ID and security check.
Caller ID:
Caller ID is a phone feature that displays the name and/or phone number of an incoming call. It is available on mobile phones, landlines, and VoIP.
The Call:
The caller can be one of the following:
1. Current customer or client personal phone - mobile
2. A person who is calling on the behave of a current customer or a client
3. New customer-client
4. A con artist or scammer - Fraud
5. Unknown number
6. Known-Telemarketing
7. Individuals with disabilities
8. Misc
Image #7 presents the 2,000 Foot-View Steps for Our Switch-Case Algorithm for General and Integration Processes. It shows our ML Analysis Engines Tier would be preparing all needed security, decision-making and the needed data for processing the caller. Our Switch-case Handler Engine Container would be performing by using our Switch-Case Algorithm. Our system would also update the system’s data.
Security Check Process:
Our ML would receive the call ID request for more information and how to handle the call.
Our ML would do its analysis processes and return a number of data matrices for ML Call Handler Engine to handle the call.
Prepare Decision-Maker to Expression Calculation Value:
Decision-Maker-Method (...)
Our ML Call Handler Engine:
The ML Call Handler Engine will execute its code and call the Decision-maker to run and return Expression integer for our Switch-Case Algorithm Handler to run its course.
Possible Cases of Expression Integer:
1. Company System in out of service “system is down” out of service handler
2. Caller with disabilities - Special handler
3. Unknown Customer-Client
4. Fraud Handler
5. MISC
6. EXCEPTION
7. Default
Rationale Behind Choosing the Algorithm:
Looking at our presentation, we are trying to answer and address improvement to Decision Tree algorithm and other algorithms such as ID3 (Iterative Dichotomiser 3). New algorithms are central for improving both AI models and agents. New algorithms would empower them to learn, adapt, and perform more effectively.
The following are features for our Switch-Case Algorithm:
1. Clarity - Easy steps to follow
2. Small number of processes
3. Logical Sequence
4. Easy to envision
5. Correctness
6. Improve efficiency
7. Can handle a wide range of inputs and scenarios
8. Scalable
9. Provides more options
10. Handles default, exceptions and miscellanies
11. Replace and Answer Decision Tree limitations
12. ML can use it to perform most of the data analysis
The readers or our audience can check this document to see for themselves how Our Switch-Case Algorithm addressed the following:
• Big Data
• ML
• Other Algorithms
• Tools
• Desired outcomes
• Efficiency
• Accuracy