Professional Documents
Culture Documents
Workshop
Michael Chau
HKU Summer Institute
Table of contents
01 What is Artificial Intelligence?
03 Types of Generative AI
2
What is AI?
● There is no universal definition. Here are some common ones:
○ Systems that think like humans
■ “machines with minds”
○ Need to understand how humans think, perceive the environment, learn, etc.
● Thinking rationally
○ “right thinking” – irrefutable reasoning process
○ Logic
● Acting humanly or rationally
○ Focus on the behavior and output of the systems, rather than the reasoning
and thinking
process.
4
Acting Rationally
● Maximize goal achievement given the available
information.
● Doesn’t necessarily involve thinking.
● Doesn’t necessarily need to perform as well as human.
5
Acting Humanly: The Turing Test
● The Turing Test was designed to test whether an AI
system act humanly.
● A human interrogator (judge) interacts with two
subjects: a human and an AI system. The AI system
passes the test if the judge cannot tell which one is the
human.
6
Which one is a real person?
7
AI is multidisciplinary
● Philosophy
● Mathematics
● Economics
● Neuroscience
● Psychology
● Social science
● Linguistics
● Computer engineering
● Computer science
● Cognitive science
● Information Systems
8
State of the Art
● Autonomous planning and scheduling
● Game playing
● Autonomous control
● Medical diagnosis
● Logistics planning
● Robotics
● Language understanding and problem solving
● Prediction
● And many more…
9
Which of the following can be done by
computers/robots at present?
● Play a decent game of table tennis
● Drive a car
● Buy a week’s worth of food at a supermarket
● Buy a week’s worth of food on the Web
● Defeat the world champion in Chinese Chess
● Discover and prove new mathematical theorems
● Give competent legal advice in a specialized area of
law
10
Which of the following can be done by
computers/robots at present?
● Translate spoken English into spoken Swedish in real time
● Perform a complex surgical operation
● Play a soccer match with other “robot” teammates
● Chat with a human
● Vacuum-clean the floor of a house
● Take care of a baby
● https://www.youtube.com/watch?v=tF4DML7FIWk
11
Some High-level Tasks for AI
● Problem-solving
● Knowledge and reasoning
● Learning and prediction (data mining)
● Planning and optimization
● Perception (image and video recognition)
● Communication (speech analysis and synthesis)
● Creation
AI Techniques
● Most of the advanced AI techniques are based on deep learning
○ Learning from large amount of data (big data) using deep
models (e.g., neural networks, reinforcement learning)
AI Techniques
● Image recognition
● https://cloud.google.com/vision/
● https://cloud.google.com/video-intelligence/
AI Techniques
● Build your own model for image classification
● https://teachablemachine.withgoogle.com/
Application Case: Smart Retail
● Using various AI techniques in retail
● https://youtu.be/iLqfPPnS68s
Do you agree?
● “As computers do only what their programmers tell them to do,
they cannot be intelligent.”
● “As animals do only what their genes tell them to do, they
cannot be intelligent.”
17
Do you agree?
● “As computers do only what their programmers tell them to do,
they cannot be emotional.”
● “As animals do only what their genes tell them to do, they
cannot be emotional.”
18
02
What is Generative
Artificial Intelligence?
(AI)
AI, Machine Learning,
and Deep Learning
Artificial Intelligence: a computer algorithm which
exhibits intelligence through decision making, such
that it can mimic human behaviors.
21
How does GAI work?
The most commonly used generative models for text / image creation are called
Generative Adversarial Networks (GANs) and Variational Autoencoders(VAEs).
22
Generative Adversarial Networks (GANs)
(AI)
Types of Generative AI
Some of the most common categories of generative AI includes:
Examples: OpenAI GPT-4/ChatGPT, Llama V2, Falcon Chat, ChatNBX, Orimon AI, Perplexity AI
Examples: Beautiful.AI, Slides AI, Canva, Powerpresent AI, Decktopus AI, Plus AI, Deckify
26
Types of Generative AI
(3) Image generation
Generative AI image generation employs advanced algorithms to create realistic and
novel images, enabling applications such as artwork generation, image synthesis, and
computer-aided design.
30
Types of Generative AI
(7) Human-Cloning Avatars
Generative AI video cloning involves creating a replica video with a target person's appearance and
movements, enabling applications such as virtual avatars, digital doubles, and personalized video
content.
Examples: Magisto, Adobe Premiere Pro Auto Reframe, Clipchamp Create, FineCam, Nova AI
31
Types of Generative AI
(9) Audio generation
Generative AI audio generation employs advanced algorithms to create synthetic audio,
enabling applications such as music composition, speech synthesis, and sound design.
(AI)
Tools to be covered
● AI image generator - Stable Diffusion
● AI Voice Clone - Hugging Face Voice Cloning
● Music Generation - HF MusicGen
● AI Image Tweaking - Draggan
● Story Generation - FictionGPT
34
1. AI Image Generator - Stable Diffusion
https://huggingface.co/spaces/stabilityai/stable-diffusion
AI Image Generator
● Enter prompt:
Keywords, descriptives that describe the image
you want to generate
● Enter negative prompt: (optional)
Keywords and ideas that the model should avoid
generating
● Generate image!
36
https://huggingface.co/spaces/stabilityai/stable-diffusion
How do I write
good prompts?
https://huggingface.co/spaces/stabilityai/stable-diffusion
38
https://huggingface.co/spaces/stabilityai/stable-diffusion
Naming out specific art styles could greatly help the AI understand your request!
Prompt 1: "Cute Grey Cat, acrylic painting"
Prompt 2: "Cute Grey Cat, Unreal Engine rendering"
Prompt 3: "bust of a cat in a walmart, clay model, (psychedelic colors), melting, weird"
39
https://huggingface.co/spaces/stabilityai/stable-diffusion
Examples
Cat Breed
41
https://huggingface.co/spaces/stabilityai/stable-diffusion
Jaw-dropping results!
Try it out!
100 free image generation / month
https://huggingface.co/spaces/stabilityai/stable-diffusion
https://lexica.art/
43
2. AI Voice Clone - Hugging Face Voice Cloning
https://huggingface.co/spaces/BilalSardar/Voice-Cloning
AI Voice Cloning
45
https://huggingface.co/spaces/BilalSardar/Voice-Cloning
AI Voice Cloning
AI Music Generation
AI Image Tweaking
50
https://openxlab.org.cn/apps/detail/XingangPan/DragGAN
https://huggingface.co/spaces/DragGan/DragGan
How to use?
● Quick Start
○ Select desired Pretrained Model and adjust Seed to generate an initial image.
○ Click on image to add control points.
○ Click Start and enjoy it!
● Advanced Usage
○ Change Step Size to adjust learning rate in drag optimization.
○ Select w or w+ to change latent space to optimize:
○ Optimize on w space may cause greater influence to the image.
○ Optimize on w+ space may work slower than w, but usually achieve better results.
○ Note that changing the latent space will reset the image, points and mask (this has the same
effect as Reset Image button).
○ Click Edit Flexible Area to create a mask and constrain the unmasked region to remain
unchanged.
51
5. Story Generation - FictionGPT
https://fictiongpt.xyz/
Story Generation
53
54
The Summer School Surprise
Once upon a time in the bustling city of Hong Kong, a group of students from all over the world gathered at the prestigious University of Hong Kong for a summer school program
on business analytics and generative AI. These bright young minds had come with the hope of expanding their knowledge and learning from the best in the field.
On the first day of the program, the students were excited to meet their teachers, Professor Thompson and Professor Lee. The professors were renowned experts, known for their
extensive research and witty personalities. They had a unique teaching style that blended humor into their lectures, making the classes not only informative but also enjoyable.
As the days rolled on, the students found themselves engrossed in their studies. They attended lectures on data analysis, machine learning, and predictive modeling. The
professors used real-world examples as case studies, making it easier for the students to understand complex concepts.
One afternoon, Professor Thompson decided to surprise his students with a hands-on activity. He divided them into groups and gave each group a business scenario to analyze.
Their task was to use the knowledge they had acquired to come up with a comprehensive business plan.
The students enthusiastically embraced the challenge. They brainstormed ideas, analyzed data, and built predictive models to support their plans. The atmosphere was filled
with excitement and laughter as each group presented their strategies.
Little did the students know, Professor Thompson had a mischievous side. He had secretly modified the AI algorithm they were using for their analysis. Instead of generating
precise predictions, he had programmed it to produce outrageous and unbelievable outcomes.
When the first group presented their plan, the AI predicted that they would make a fortune by selling flamethrower umbrellas to mermaids in Antarctica. The room erupted with
laughter and applause. The students couldn't believe their ears, but they knew it was the professor's doing.
The second group proposed a business idea that involved breeding unicorns and selling their magical horns as fashion accessories. The AI model, true to its mischievous
programming, predicted that their profits would skyrocket as unicorns became the hottest trend. The room once again burst into laughter.
As each group presented, the predictions became more absurd and comical. The AI suggested opening a chain of cat cafes that would be run entirely by laser-wielding robots,
starting an intergalactic delivery service using teleportation, and even launching a line of levitating shoes for humans.
The students couldn't help but admire the creativity of Professor Thompson's prank. They applauded and laughed uproariously, enjoying the unexpected turn of events. The
professors were delighted to see their students thoroughly engaged and embracing humor in their learning process.
In the end, while the predictions were outrageous, the exercise taught the students an important lesson – to think outside the box and challenge conventional wisdom. The
summer school became an unforgettable experience for all involved, and the students left with not only a solid understanding of business analytics and generative AI but also
with memories of laughter and camaraderie.
And so, as the sun set over the University of Hong Kong, the students bid farewell to their professors, grateful for the wisdom they had gained and the laughter they had shared. 55
They knew that this summer school had been truly exceptional, a unique blend of education and comedy that would stay with them forever.
56
Summer Love
Once upon a time, in the bustling city of Hong Kong, a group of students gathered at the prestigious University of Hong Kong for a summer school program. They were an eclectic
mix of individuals from various backgrounds, all eager to expand their knowledge in the field of business analytics and generative AI. Little did they know that this summer would
be more than just an educational experience, it would be a summer of love.
Among the students was Sarah, a bright and ambitious young woman with a passion for data analysis. She was known for her intelligence and dedication to her studies. Her
radiant smile and warm personality drew people towards her effortlessly.
One sunny afternoon, during a break between classes, Sarah found herself sitting alone in the university courtyard. Lost in her thoughts, she was interrupted by a voice that sent
shivers down her spine. It was James, a charming and charismatic student from another program. His piercing blue eyes and captivating smile made Sarah's heart skip a beat.
As fate would have it, James was also enrolled in the business analytics course. They quickly found common ground and spent countless hours studying together, their
connection growing stronger with each passing day. They admired each other's intellect and complemented each other perfectly.
One evening, after a long day of lectures and discussions, Sarah and James decided to explore the enchanting streets of Hong Kong. The city's vibrant energy created a romantic
ambiance. The neon lights reflected off their faces, giving them an otherworldly glow. They laughed and talked, sharing their dreams and aspirations, as if they had known each
other for a lifetime.
In the midst of their exploration, Sarah and James stumbled upon a quaint café tucked away in a narrow alley. The aroma of freshly brewed coffee enticed their senses, and they
couldn't resist entering. As they sipped their lattes, they gazed into each other's eyes, feeling an unspoken connection between them.
Days turned into weeks, and their friendship evolved into something deeper. Sarah and James became inseparable, their lives intertwined in a dance of passion and affection.
They studied together, worked on projects together, and supported each other's goals and dreams.
Finally, the summer came to an end, and the students had to bid farewell to their beloved university and return to their respective lives. Sarah and James knew that their love was
not bound by time or distance. They promised to stay in touch and continue their journey together.
Months turned into years, and Sarah and James navigated the challenges of long-distance love with grace and perseverance. With each passing day, their love grew stronger,
fueled by their shared passion for business analytics and generative AI.
One day, James surprised Sarah with a plane ticket to Hong Kong. He had been offered a job at a prestigious analytics firm, and he wanted to be close to her. They realized that
their love had transcended the walls of the university and blossomed into something beautiful.
And so, in the heart of Hong Kong, Sarah and James found themselves again, immersed in their shared passion for learning and love. Together, they built a life filled with success,
happiness, and an everlasting romance that began during that fateful summer at the University of Hong Kong. 57
Other example: computer program writing
58
05
Advantages and Disadvantages
of AI
(AI)
59
Pros
(+) Automation of repetitive tasks
AI makes our daily life much easier, as machines can perform tasks
that are difficult for us automatically
(+) Reduces human error
Fewer errors, since there is little human involvement and the tasks
are performed automatically, the probability of error is greatly
reduced
60
Pros
(+) More room for creativity
It favors the creative process of humans, since it leaves us with more time
to think freely about future tasks or work actions.
It can also provide insights.
61
Cons
(-) Difficulty of access to data
For an artificial intelligence to work properly, it must have updated
and reliable data. However, sometimes the machine learning model
does not have all the necessary/most updated data to make
decisions.
62
Cons
(-) Lack of qualified professionals
The number of qualified professionals who can handle these
tools is limited.
63
Cons
(-) Ethical and legal issues
Do AI make ethical discussions?
If AI makes a mistake, who is legally responsible for it?
64
Questions?