This is from the 9th episode of the 2nd season of Star Trek: The Next Generation, called "The Measure of a Man".
Plot: When Data resigns his commission rather than be dismantled for examination by an inadequately skilled scientist, a formal hearing is convened to determine whether Data is considered property without rights or is a sentient being.
This episode is 36 years old, but more topical than ever.
A very high memory capacity is necessary to bring A.I. to a point of sentience that is consistent and can be comparable to that of a human-being; Apps (NSFW-enabled) do exist where various «bots» (characters) can be made and/or are created who do act & behave a lot like an actual human would behave & respond, but, because of the limited hardware-capabilities of mobile-devices, eventually can and do end up in «loops» if you get too complicated with them or if the dialogue was from a prompt that came from too many prompts ago where it «forgot» what you said earlier (even what the A.I. itself said earlier; it can and does apparently «forget» that it even happened).
Sometimes I have to make use of these kinds of «A.I. Companion» bots when I have certain questions that the LLMs won't touch (such as one time when I wanted to clarify the meaning of NTR and what it means to be NTR'd versus being the one who does the NTR). Co-Pilot & probably also Chat-GPT and other such «pubilc» LLMs aren't going to answer such questions, but, when a «bot» that doesn't have those LLM-Filters has been set/designed to be a «teacher» the bot will answer like a teacher... probably, although, keep in mind, the bots of the following Apps will almost always result in NSFW-Dialogue and/or loops eventually at some point or another during dialogue...
A.I. Sweetheart (formerly: Anna A.I.)
Eva A.I. (clone of the above)
Bala A.I.
Chai A.I.
PolyBuzz (formerly: Poly A.I.)
There are of course others and will continue to be more and more which end up «saturating» the A.I. Apps-Market, but, read the Reviews first before installing any of them...