Download Artifical intelligence and more Study notes Artificial Intelligence in PDF only on Docsity!
Advanced Topics: Expert Systems
Representation – Expert System Shells – Knowledge Acquisition
(with Examples)
1. Expert System (Introduction)
An Expert System is an AI program that imitates the decision-making ability of a human expert in a specific domain by using knowledge and reasoning. Examples:
- Medical diagnosis systems
- Fault diagnosis systems
- Advisory systems
2. Knowledge Representation in Expert Systems
Knowledge representation defines how expert knowledge is stored in the system so that reasoning can be performed.
Common Knowledge Representation Techniques
1. Rule-Based Representation
- Knowledge stored as IF–THEN rules Example: IF patient has fever AND cough THEN disease = flu ✔ Easy to understand ❌ Large rule base becomes difficult to manage
2. Frame / Slot–Filler Representation
- Knowledge stored as frames with slots and fillers Example: Frame: Disease Slot: Name → Malaria Slot: Symptom → Fever ✔ Structured ❌ Limited reasoning
UNIT 5
18 January 2026 21:
❌ Limited reasoning
3. Logic-Based Representation
- Uses predicate logic
- Facts and rules represented formally ✔ Accurate reasoning ❌ Complex to implement 3. Expert System Shell
Definition
An Expert System Shell is a ready-made framework that contains all components of an expert system except the knowledge base. Developer only needs to add domain knowledge.
Components of an Expert System Shell
- Inference Engine
- User Interface
- Explanation Facility
- Knowledge Acquisition Tools Knowledge base is added separately.
Examples of Expert System Shells
• CLIPS
• JESS
• EMYCIN
Advantages of Expert System Shells
- Faster development
- No need to build system from scratch
- Easy maintenance 4. Knowledge Acquisition
Definition
Knowledge Acquisition is the process of collecting, organizing, and encoding expert knowledge into the expert system. It is known as the knowledge acquisition bottleneck.
Sources of Knowledge
- Human experts
- Books and manuals
- Databases
- Case studies
Methods of Knowledge Acquisition
1. Interviewing Experts
- Direct interaction with domain experts
2. Observation
3. Document Analysis
- Studying reports, manuals, records
4. Machine Learning
Minimax is a strategy where:
- One player ( MAX ) tries to maximize the score
- The opponent ( MIN ) tries to minimize the score Each player assumes the other plays optimally. 3. Assumptions of Minimax
- Two players (MAX and MIN)
- Players move alternately
- Zero-sum game (one wins, other loses)
- Fully observable environment
- Finite game tree 4. Minimax Search Procedure (Steps)
Step 1: Generate Game Tree
- Nodes represent game states
- Edges represent moves
Step 2: Assign Utility Values
Terminal states are assigned values ○ Win → + ○ Loss → − 1 ○ Draw → 0
Step 3: Backward Evaluation
- MIN nodes choose minimum value of children
- MAX nodes choose maximum value of children
Step 4: Choose Optimal Move
- MAX selects the move with the **highest minimax value
- Minimax Algorithm (Pseudo Explanation)**
- If node is terminal → return utility
- If node is MAX → return max value of children
- If node is MIN → return min value of children 6. Example of Minimax
Tic-Tac-Toe Example
- MAX wants to win
- MIN tries to block
- Minimax explores all possible moves
- Chooses move that guarantees best worst-case outcome Example values propagated from leaves to root. 7. Advantages of Minimax
- Guarantees optimal play
- Simple and systematic
- Works well for small games 8. Limitations of Minimax
- High time complexity
- Not practical for large games
- Requires full game tree
- Requires full game tree 9. Time and Space Complexity
- Time: O(bᵈ) Space: O(bd) (where b = branching factor, d = depth)
10. Minimax vs Alpha-Beta Pruning (Short Note) - Alpha-Beta pruning improves minimax - Eliminates unnecessary branches - Produces same result faster 11. Conclusion The Minimax Search Procedure is a fundamental algorithm in AI game playing. It ensures optimal decision-making by assuming rational opponents, but its efficiency can be improved using pruning techniques. **Alpha–Beta Pruning in Artificial Intelligence
- Introduction Alpha–Beta Pruning** is an optimization technique for the Minimax algorithm used in AI game playing. It reduces the number of nodes evaluated in the game tree without affecting the final decision. Result: Same optimal move as Minimax, but faster. 2. Need for Alpha–Beta Pruning
- Minimax examines all possible game states
- This is inefficient for large games (e.g., Chess)
- Alpha–Beta pruning cuts off branches that cannot influence the final decision 3. Key Terms
Alpha (α)
- Best (highest) value found so far for MAX
- Initially: −∞
Beta (β)
- Best (lowest) value found so far for MIN
1. Introduction (Definition) An Imperfect Information Game is a game in which all information about the game state is not fully visible to all players. In such games, players must make decisions without knowing some aspects of the current state, such as opponent’s cards or moves. These games involve uncertainty and hidden information. 2. Difference: Perfect vs Imperfect Information (Brief) Aspect Perfect Information Imperfect Information Visibility Full game state known Partial/hidden information Uncertainty No Yes Example Chess, Tic-Tac-Toe Poker, Card games 3. Characteristics of Imperfect Information Games - Incomplete knowledge of game state - Presence of uncertainty - Requires probabilistic reasoning - Players use beliefs/estimates - Opponent strategies are not fully known 4. Examples of Imperfect Information Games - Poker – players cannot see opponents’ cards - Bridge – hidden cards - Card games - **Real-world decision-making games
- Challenges in Imperfect Information Games**
- Minimax cannot be directly applied
- Game tree is not fully observable
- Requires reasoning under uncertainty
- Difficult to predict opponent moves 6. Techniques Used for Imperfect Information Games
1. Belief States
- Agent maintains a set of possible states
- Uses probability to estimate actual state
2. Expectiminimax Algorithm
- Extension of minimax
- Includes chance nodes
- Used when randomness is involved
3. Probabilistic Reasoning
- Uses probabilities to choose best action
- Expected utility is maximized
4. Learning-Based Approaches
- Reinforcement learning
- Opponent modeling 7. Imperfect Information vs Minimax (Key Point)
- Minimax assumes perfect information
- Imperfect games need **expectation and belief modeling
- Advantages**
- Models real-world situations better
- Handles uncertainty effectively 9. Limitations
- Computationally complex
- Requires probability estimation
- Hard to guarantee optimal decisions 10. Conclusion Imperfect Information Games represent realistic decision-making scenarios where players act under uncertainty. AI systems handle such games using belief states, probabilistic reasoning, and learning techniques , making them more applicable to real-world problems. 1. Introduction (Definition) Real-Time Decision Making in AI refers to the ability of an intelligent system to sense the environment, process information, and take actions within strict time limits. A decision is useful only if it is made before a deadline. Correct + late = wrong in real-time systems. 2. Why Real-Time Decisions are Needed
- Environments are dynamic and fast-changing
- Delays can cause failure or danger
- Systems must react immediately Examples: autonomous driving, robotics, medical monitoring. 3. Characteristics of Real-Time Decisions
- Time-bounded : decisions have deadlines
- Continuous perception : sensors provide constant input
- Interrupt-driven : events can occur anytime
- Approximate reasoning : best possible decision under time pressure
- Robustness : must handle uncertainty and noise 4. Types of Real-Time Systems
Accuracy High Good-enough Speed Less important Critical
11. Conclusion Real-time decision making is essential for AI systems operating in dynamic and safety-critical environments. Such systems prioritize speed and timely response over perfect accuracy, enabling intelligent behavior under strict time constraints. **Swarm Intelligent Systems – Ant Colony System (ACS)
- Introduction (Swarm Intelligence) Swarm Intelligence** is a branch of AI inspired by the collective behavior of social insects such as ants, bees, and birds. These systems show intelligent global behavior using simple local interactions without centralized control. Ant Colony System (ACS) is a swarm intelligence technique inspired by the food-finding behavior of ants. 2. What is Ant Colony System (ACS)? The Ant Colony System is an optimization algorithm where artificial ants cooperate to find optimal solutions by using pheromone trails and heuristic information. It is mainly used to solve combinatorial optimization problems. 3. Biological Inspiration
- Real ants deposit pheromones while moving
- Shorter paths accumulate more pheromone
- Other ants follow paths with higher pheromone concentration
- Eventually, the shortest path emerges ACS simulates this behavior artificially. 4. Components of Ant Colony System
1. Artificial Ants
- Agents that construct solutions step by step
- Agents that construct solutions step by step
2. Pheromone Trail (τ)
- Numerical value representing path desirability
3. Heuristic Information (η)
- Problem-specific knowledge (e.g., distance)
4. Probability Rule
- Determines next move of ant based on pheromone & heuristic 5. Working of Ant Colony System (Steps)
Step 1: Initialization
- Set initial pheromone values
- Place ants randomly
Step 2: Solution Construction
Each ant selects next node based on: ○ Pheromone intensity ○ Heuristic value
Step 3: Local Pheromone Update
- Pheromone is slightly reduced to encourage exploration
Step 4: Global Pheromone Update
- Best ant deposits more pheromone on optimal path
Step 5: Termination
- Process repeats until optimal solution is found or iterations end 6. Mathematical Idea (Simple) Probability of choosing path (i, j) depends on:
- Pheromone strength
- Heuristic value (e.g., inverse of distance) Higher pheromone + shorter distance → higher probability. 7. Applications of Ant Colony System
- Travelling Salesman Problem (TSP)
- Network routing
- Scheduling problems
- Vehicle routing
- Image processing
- Robotics path planning 8. Advantages of Ant Colony System
- Distributed and parallel
- Robust and flexible
- Finds near-optimal solutions
- Adapts to dynamic changes 9. Limitations of Ant Colony System
- Slow convergence
- Parameter tuning is difficult
- High computational cost for large problems
- Applied after each move
- Reduces pheromone slightly to encourage exploration
Step 4: Global Pheromone Update
- Best ant deposits pheromone on best path
- Reinforces optimal solutions
Step 5: Termination
Process repeats until: ○ Optimal solution found, or ○ Maximum iterations reached
4. Flow of Ant Colony System Initialization → Ant Movement → Local Update → Best Path Selection → Global Update → Repeat 5. Applications of Ant Colony System
1. Travelling Salesman Problem (TSP)
- Finding shortest route visiting all cities once
2. Network Routing
- Selecting optimal paths in communication networks
3. Scheduling Problems
- Job scheduling, task allocation
4. Robotics & Path Planning
- Obstacle-free shortest path selection
5. Image Processing & Data Mining
- Feature selection and clustering 6. Advantages of Ant Colony System
- Distributed and parallel
- Adaptive to dynamic changes
- Finds near-optimal solutions
- No centralized control 7. Limitations of Ant Colony System
- Computationally expensive
- Parameter tuning required
- Slower for very large problems 8. Conclusion The Ant Colony System is a powerful swarm intelligence technique developed from biological ant behavior. Its pheromone-based working mechanism makes it suitable for solving complex real- world optimization problems efficiently.