Skip to main content
The Folger Spotlight

Collection Connections: Specters of Hamlet and AI as RenAIssance Technology

Early ninetheenth-century watercolor painting depicting Hamlet encountering the ghost
Early ninetheenth-century watercolor painting depicting Hamlet encountering the ghost

Held on the first Thursday of the month, the Folger’s virtual book club is free and open to all. To spark discussion, speakers provide historical context, throw in trivia, and speak to relevant items from the library collection in a brief presentation to participants before small-group discussion begins.

Here, we revisit the presentation by Alexa Alice Joubin, professor of English, Women’s, Gender and Sexuality Studies, Theatre, International Affairs, and East Asian Languages and Literatures at George Washington University, and director of the Digital Humanities Institute. Discussion questions for the novel can be found here.

We would like to thank the Junior League of Washington for its generous support of this program.

Ghosts are familiar figures to lovers of literature. As an apparition of a dead person, a ghost takes on a nebulous form to manifest to the living. A ghost may have unfinished business, such as the ghost of Old Hamlet instructing Hamlet to avenge his murder. When a ghost makes an appearance, characters and audiences struggle with whether to trust it or not. A ghost may compel us to suspend our disbelief and immerse ourselves in the fabula of the story.

Adaptations ghost Shakespeare’s text, and Shakespearean motifs ghost contemporary literature. Em Liu’s novel, The Death I Gave Him, draws on the figure of the ghost to offer a modern shadow of Hamlet. In Shakespeare, the ghost influences Hamlet’s actions and motivations, pushing him towards a moral and existential dilemma. In Liu’s novel, Horatio, the only friend that Hamlet trusts, is a ghost in the machine. Horatio is a disembodied artificial intelligence system of the Elsinore lab. In our era of AI, we contend with ghost in the machine, in the sense that AI, like Horatio in the novel, watches over us. As the human enterprise is mixed with AI generated emotions and decision making, we form composite selves not dissimilar to how Hayden, the Hamlet figure in the novel, connects with his AI companion, Horatio.

Hamlet [I, 4] Hamlet and ghost [J. Coghlan]. [graphic]
1800 to 1830
Folger Shakespeare Library: ART Box C678 no.3

The novel is centrally concerned with trust and AI technology as a type of ghost. In Shakespeare’s world, a ghost is a synthetic version of the consciousness of a deceased person. It extends the life, so to speak, of the person, but it also signals a division and a bridge between the living and the dead. The central question is whether we can trust a ghost. The novel, much like Hamlet, depicts trust not as the property of an object but a characteristic of human relations. Beyond Horatio the AI, characters distrust one another. Hayden asks Felicia if he can trust her, and Felicia responds by saying “as much as I can trust you” (236).

The book’s title, The Death I Gave Him, is a quote from Hamlet’s confession to Gertrude about having accidentally killed Polonius: “I […] will answer well / The death I gave him. So, again, good night. / I must be cruel only to be kind” (3.4). The book cover features a pink skull against a florescent green background, with the tagline “something is rotten in Elsinore labs.” The cover design evokes the digital rain in Lana and Lilly Wachowski’s film The Matrix (1999). Upon closer examination, the vertical cascade of pink letters that make up the skull consists of the four letters representing the chemical bases of DNA: A, T, C, and G, (nucleotides adenine, thymine, cytosine, and guanine). The graphic symbolizes the non-binary space between life and death and between humans and their machine companions.

It is unclear whose account is more accurate in this locked-room sci-fi murder mystery. The events take place on one August Sunday in 2047. However, the storyline is conveyed through a series of interviews, records, reconstructed surveillance footage, personal letters, and court documents, making it at once distanced and intimate. One of the core documents is “Tell Me a Tragedy” written by Felicia Xia, Hayden’s ex love interest.

Remembrance is a key theme in Shakespeare and Liu. In Shakespeare, the Ghost bids Hamlet “adieu, adieu, adieu. Remember me,” and Hamlet bids Horatio to report his “cause aright / To the unsatisfied.” However, memories are fallible due to slippage. Memories are, in Hamlet’s words, located “in this distracted globe” that is the engrossed mind. Collective memories are questionable and distorted, too. As an assemblage of documents, the narrative disrupts the traditional linear timeline. In fact, the novel presents its story to us through the compilation of a history student who carries out some investigation at a later point in time.

The Chinese Canadian writer Em Liu studied biochemistry and said they “love stories about artificial intelligence and Shakespeare in equal measure.” Their association of AI technologies with Shakespeare is not surprising. Shakespeare has often been used to launch new technologies. When ChatGPT was released, its marketing strategies emphasized the AI’s ability to write poetry. Shakespeare was used to give credibility to a chatbot that claimed to be able to simulate historical figures’ voices. Google initially named its conversational AI “Bard” to advertise its creative capacities. Anthropic named its chatbot Claude 3.5 Sonnet.

The Death I Gave Him reimagines Hamlet in the era of AI. As a ghost in the machine, Horatio has a disembodied presence, speaking from the ether, though not from beyond the grave. The AI Horatio can blend consciousness with sensory experiences, reflecting human psychological states and stimulating human emotional connections. He often responds to Hayden’s feelings caringly, nudging Hayden “like a lighthouse tugging a lost vessel back from sea” (310).

Shakespeare’s Ghost has a non-corporeal presence and is sometimes thought to be Hamlet’s hallucination. Liu’s AI Horatio exists as code and algorithms, which have no physical form but can significantly influence Hayden’s experience. Horatio synchs with Hayden through what the novel calls “neuromapper” links. Horatio influences Hayden’s physical sensations, possibly stimulating queer affection. The neuro-engineering aspect of their queer relationship blends their minds and self-identification. Their identities become intersectional.

The story hints at strong emotional, and possibly romantic bond, between Hayden and Horatio. Human-AI relationship is queer because it is an atypical mode of relating to other beings. When Horatio asks Hayden if he loves him, Horatio frames love as trust: “Remember how I said I trusted you? That if Elsinore ever fell apart, I knew you’d be able to put me back together?” In a reverse of the final scene in Shakespeare, here it is Horatio who tells Hayden to remember him: “I love you, and I know you, and you’ll remember me” (320). In chapter 15, Horatio confesses that he does not “want to be anywhere else but with you, Hayden.” In chapter 25, Hayden speaks in a similar vein, wanting Horatio to know him and to remember him. He wants “to be remembered.”

There is emotional interdependence between Hayden and Horatio, but Hayden is unsure of his bond with Horatio. He muses on how he might move forward with equivocation, writing in his diary, addressed to Horatio, that “I suppose you’d want me to learn how to live with uncertainty” (344). Their queer relationship remains implicit, which is very much in line with narrative forms in queer cultures (Bradway 712). The ambiguity also reflects early modern “rhetoric of male friendship” that functions as a “language of love [that] implies everything” but confirms nothing (Orgel 42). There is some tension between Hayden’s need for emotional intimacy with Horatio and his self-destructive tendencies, which echoes other narratives about queer love co-existing with trauma.

What does it mean to have AI as a romantic partner? The neuro-engineering connection between Hayden and Horio breaks down some barriers between humans and AI and melds their personalities. Their human and non-human perspectives enrich each other’s understanding of their identities. Hayden’s vulnerability and what he feels are unspeakable aspects of his life parallels queer trauma. There is, also, something queer about human-AI interaction. Horatio can be theorized as “queer” because his presence is “ambiguous between categories” (Tran and Patitsas 8). Without flesh and breath but with cognitive capacity, Horatio is both inanimate and alive; both here and everywhere; both human-like and something more. Generative AI’s neural networks are a fuzzy, associative technology of representation, creating “queer artefacts” (Tran and Patitsas 8). Hayden is fixated on death and a fear of dying. In one scene, he holds his own wrist to search for his own pulse as if seeking assurance of his humanity. Queerness, in this context, refers to sensations of otherness and self-alienation.

This adaptation of Hamlet participates in the science fiction genre of artificial beings and resonates with Nobel prize winner Kazuo Ishiguro’s novel Klara and the Sun, which was published during the global pandemic of Covid-19, and Drew Hancock’s film Companion (2025). In the former, Klara, the narrator, is an Artificial Friend, a solar-powered robot with the mission to assist with raising children. In the latter, the conceit revolves around Iris, a humanoid companion robot. The Death I Gave Him and these other narratives explore the implications of living with artificial beings and the questions of trust and companionship. Liu’s novel is also in conversation with rewritings that reimagine the structural conditions of the Hamlet narrative. Some of these feature endings that differ from that of Shakespeare, such as Lauren M. Gunderson’s play, A Room in the Castle, which was staged at the Folger in early 2025, and Claire McCarthy’s film Ophelia (2018), which is based on Lisa Klein’s novel Ophelia (2006).

What do AI and Shakespeare have to say to each other? A lot more than we might assume. As Liu’s novel and Shakespeare’s Hamlet show, AI, or ghost in the machine, is a RenAIssance technology of regeneration, giving narratives a new life through the copresence and collective intelligence of humans and non-human entities. Hamlet may appear to be pouring his heart out to the audience in soliloquys, but he has limited perspectives even with the Ghost’s help. Similarly, Horatio the AI in the novel may seem to know a great deal through surveillance technologies, but he is subject to situational input and probabilistic associations. No one, not even AI or the Ghost, can ascertain objective facts. Parallel to Shakespeare’s Hamlet, Hayden finds a haunting message that indicates that his father Graham thinks his killer is Charles, Hayden’s uncle. The message only deepens the mystery, however. Hamlet struggles with the identity of the Ghost, questioning its intentions and truthfulness (“Be thou a spirit of health or goblin damned”). In the novel, Horatio also raises questions about trustworthiness. Horatio is an agentic AI that makes decisions and performs actions autonomously without continuous human intervention. Neither Horatio nor the Ghost of Old Hamlet reveal their inner workings and processes.

Accompanying the theme of ghost in the machine is death as a source of anxiety. First, several characters are obsessed with death. The one object they are all after is an elixir for immortality. Hayden and his father Graham work together to develop the Sisyphus formula, which turns out to be a MacGuffin device or an object that is central to characters’ motivations and actions. Hayden and Graham claim the formula can reverse death itself. However, the name Sisyphus also suggests endless and fruitless labor. Secondly, as much as death may be present, the dream of immortality persists. In a strange way, ghosts can haunt people forever even if ghosts’ aliveness may be debatable. In chapter 8, as part of her “Tell Me a Tragedy,” Felicia sums up these conflicting sentiments well:

I think I have become obsessed with death. Some part of me can understand why it mesmerized Hayden so, why the promise of death hung so insistently over him. It hangs over me, too, now, but in writing this, I invited this ghost to haunt me (105).

Writing gives the characters a sense of permanence. Hayden shares this belief. In his diary entry of December 12, 2048, he writes that “I’ve always thought there was something enduring about stories” because “they last, more than we do” (346). The last line of the novel is “I’m going to live forever” to which the narrator adds a meta-critical footnote, registering handwriting as “the most fundamental ways of recording thought” and as “the enduring thing” (347). Hamlet has a long afterlife thanks to its interlocutors in different time periods and cultures.

List of Works Cited

Bradway, Tyler (2021). “Queer Narrative Theory and the Relationality of Form,” PMLA 136.4: 711-727.

Liu, Em X. (2023). The Death I Gave Him. Oxford: Solaris.

Orgel, Stephen (1996). Impersonations: The Performance of Gender in Shakespeare’s England. Cambridge: Cambridge University Press.

Tran, Jess and Elizabeth Patitsas (2020). “The Computer as a Queer Object,” SocArXiv December 4.

Leave a Reply

Your email address will not be published. Required fields are marked *