ICS 3202 - Artificial Intelligence - December 2022

Download as pdf or txt
Download as pdf or txt
You are on page 1of 5

SCHOOL OF COMPUTING AND ENGENEERING SCIENCES

BACHELOR OF INFORMATICS AND COMPUTER SCIENCE


ICS 3202: ARTIFICIAL INTELLIGENCE
END OF SEMESTER EXAMINATION

DATE: 6th December 2022 Time: 2 Hours


INSTRUCTIONS
1. Answer Question 1 (Compulsory) and any other Two Questions.
2. In the calculations, show your workings for full marks.

QUESTION One: - COMPULSORY 30 Marks

a. An ICS student is in the process of developing a machine learning solution for a Classification
task. As such they need to prepare their data and then use it for training alongside a relevant
algorithm.
i. During data preparation they have to handle missing values. Discuss any two ways for
handling missing values. (2 Marks)
ii. Assuming they opt to use kNN algorithm, what are some of the metrics to adhere to
when picking the value of k? (2 Marks)
iii. Apart from kNN, what other four classical algorithms would be applicable is the task
described above? (2 Marks)
b. Using a relevant diagram, describe a perceptron. (3 Marks)
c. List any four-activation functions that can be used in an artificial neural network e.g. the one
from question “d” above (2 Marks)
d. Suppose you are training a neural network model and notice it is overfitting on the training
data, what three ways can be used to reduce chances of overfitting. (3 Marks)

1
e. By providing relevant supporting examples, discuss each of the following three terms and
demonstrate how they differ from each other. (6 Marks)
i. Supervised Learning
ii. Reinforcement Learning
iii. Unsupervised Learning

f. Draw a truth table for the following propositional formula (4 Marks)


~𝑝 𝑜𝑟 ~𝑞 ~𝑞 ^ ~𝑟

g. Translate the sentences below into first order predicate logic. (6 Marks)
i. All students are smart.
ii. There exists a student.
iii. There exists a smart student.
iv. Every student likes some student.
v. Every student likes some other student.
vi. There is a student who is liked by every other student.

2
QUESTION TWO 15 Marks
a. What are the building blocks of Artificial Intelligence (2 Marks)
b. Using a relevant diagram, describe they key components of an AI agent. (4 Marks)
c. You’ve been appointed to assist in developing an AI used by a self-sailing public boat
sponsored by R4M Auto Inc. Given that a Task environment can be described using four main
areas, use relevant examples to describe the four areas for this task environment (4 Marks)
d. Two students working on an IS Project plan to create AI agents with a goal of predicting share
prices; these agents will later be set free in the same environment. Describe the two ways in
which these agents can be deployed/set up (2 Marks)
e. You are provided with the following confusion matrix for a Binary Classification task.

Positive Negative
Positive 130 17
Negative 10 125

Using the values in the confusion matrix, calculate the following performance metrics. Show
your working / formulas for each. (3 Marks)
i. Accuracy:
ii. Precision:
iii. Recall:

QUESTION THREE 15 Marks


a. NLP applications range from sentiment classification, Machine Translation and Social Media
Monitoring. However, the same is not 100% true when dealing with Low resource Languages
such as Swahili, Zulu, Kinyarwanda etc. What are some of the emerging techniques being used
to resolve challenges for low resource NLP applications? (3 Marks)
b. Suppose you are doing a multiclass classification task where the raw input is a single string
containing the text of the entire document. Using a diagram describe the pipeline to go from
the raw input to a predicted class with possibility of improving the model in future. (6 Marks)
c. In an NLP pipeline, Bag of Words (BoW) can be used for feature extraction. Given the
following corpus of tweets by customers, generate a vocabulary and the corresponding vectors
when using BoW. Do not perform any stop word removal on the given corpus. (4 Marks)
Review 1: This movie is very scary and long

3
Review 2: This movie is not scary and is slow
Review 3: This movie is spooky and good

d. Referring to the examples in question ‘c’ above, what are the drawbacks of using a Bag-of-
Words (BoW) Model. (2 Marks)

QUESTION FOUR 15 Marks


a. Describe the three steps followed by Problem Solving Agents when attempting to reach a Goal
State? (3 Marks).
b. Company XYZ deploys sales-agents across Kenya every 2 to 3 months. To ensure efficient
deployment and travel of sales-agents from Nairobi to other destinations, the company plans
to develop some sort of intelligent agent that can return efficient pathways that sales-agents
can use while traveling.
i. During development, the company discovers lots of loops returned by initial prototypes of
the intelligent agent. Advice on ways of how this huddle in development can be overcome.
(2 Marks)
ii. Describe the Goal state and the Initial State for the problem above. (2 Mark)
c. The graph below presents one Starting Point ‘S’ and 2 Possible Destination points G1, G2. Use
the provided Heuristics (Indicated within the node e.g for node S the value is 5, and for Z the
value is 7).

4
i. By showing your expansion approaches from the source ‘S’ to the other nodes, write in
the final A-star scores for all nodes. (5 Marks)
Node Score
S
X
Z
U
V
W
Q
G1
G2
S

ii. State the pathways to the specified goals when using the following algorithms (3 Marks).
i. Greedy Search (To G2)
ii. A-Star Search (To G1)
iii. Iterative Deepening Depth First Search (Consider shortest path to any goal with
a Limit of 3)

QUESTION FIVE 15 Marks

a. There are many ways of defining what we might look for in a fair artificial intelligence system.
Describe any two criteria which can be used to describe fairness in AI models. (1 Mark)
b. In their research paper titled A Framework for Understanding Sources of Harm throughout the
Machine Learning Life Cycle, HARINI SURESH and JOHN GUTTAG discussed various
types of bias that may arise during development and deployment of AI systems. By
using/providing relevant examples, discuss any 5 types of bias in AI systems. (10 Marks).
c. What are some of the ethical concerns with the recent adoption of AI in business sectors such
as prediction of cryptocurrency prices (4 Marks)

You might also like