Students are familiar with Binary Search Tree Insertion and Traversals.
Practice Binary Search Tree (BST) traversals, explore how prompt wording affects LLM output, and understand why clear alt-text matters for accessibility.
In this activity, you will:
- Build a Binary Search Tree
- Use an LLM to generate a traversal-based description (alt text) of your tree
- Exchange descriptions with a partner
- Attempt to reconstruct each other’s trees from text alone
Alt text (alternative text) is a short textual description of an image that conveys the meaning and purpose of the image.
Alt text is used by:
- Screen readers for users who are vision impairments
- Browsers when images fail to load
- Search engines to understand images
Good alt text balances:
- Completeness - all relevant structural information
- Conciseness - no unnecessary detail
Guiding question:
“If someone cannot see this image, what do they need to know?”
- Choose 7 distinct integers.
- On paper, insert them into an empty Binary Search Tree in the order you choose.
- Write down or sketch the final tree structure.
Pair up with your neighbour, and each partner must distinctly choose one of the following traversals:
- Preorder
- Inorder
- Postorder
- Level-order
- Go to the NavigatorAI Chatbot or a LLM chatbot e.g. ChatGPT, Claude, Gemini, etc.:
https://it.ufl.edu/ai/navigator-chat/ - Select any model.
- Use a prompt similar to:
I have a Binary Search Tree built from these values inserted in the following order:
[list your numbers in insertion order].
Generate alt-text that describes the tree using [chosen traversal].Refine your prompt if the output is unclear or ambiguous.
- Do not show your tree.
- Read your alt text aloud to your partner.
- Your partner reconstructs the tree from the description.
- Compare results and discuss accuracy.
- Switch roles.
Discuss:
- Was the description easy to follow?
- What information was missing or ambiguous?
- How did traversal choice affect clarity?
- How does this relate to web accessibility?
Write a program that automatically generates alt text for a Binary Search Tree using a specified traversal.
- Who was your partner?
- Which model did you select on Navigator? If you used an external tool - e.g., ChatGPT, Gemini - state the tool and why did you chose it over Navigator?
- State the prompt that you used when interacting with your chatbot to construct alt-text descriptions.
- I found this activity engaging.
- Strongly agree
- Agree
- Neutral
- Disagree
- Strongly disagree
- After this activity, how would you describe your understanding of digital accessibility (e.g., alt text and why it matters)?
- I had little or no understanding of alt-text before and still feel unsure,
- I had little or no understanding of alt-text before and now have a basic understanding
- I had some understanding of alt-text before and now I understand it even better
- I already knew how alt-text work before this activity and did not gain anything new
- Reflect on your interaction with the chatbot and what you learned about accessibility.