Tag: robotics

  • Missing pieces to Naomi

    Missing pieces to Naomi

    KEY TERMS

    List of terms mentioned in this post

    • Candidate: the user interacting with Naomi during the interview.
    • Agent: Llama3.1 roleplaying as Naomi.
    • General question/s: questions to be asked during the interview concerning the candidate’s information eg age, occupation etc.
    • Feature question/s: questions or case scenarios mentioned during the interview. The candidate’s responses to these questions are analyzed and used as features in predicting personality predictions and our compatibility score.
    • Response space: responses generated by dummy candidates conditioned to trait patterns aligned with my previous dating history. The intuition behind this idea is that all individuals equip both strengths and weaknesses, and that determining these traits is dependent on the observer’s ability in handling the characteristic combinations i.e. weighing my patience for someone’s flaws against their admirable qualities.

    Overview

    This post is dedicated to Naomi’s unconscious state of acting as a recruitment officer for a dating show (my dating life). Since this was my first attempt at integrating the frontend with the backend, the project turned out messy. The only promising outcome was the realization that I’m not merely a fool of my own words.

    Data Preparation

    This section lists the type of datasets to prepare prior to streaming. The responses were generated by instructing Llama 3.1.

    Feature Questions:

    These questions/case scenarios are based on each dichotomy of MBTI personality traits:

    Response Space:

    Pair of dummy candidate responses and narrations for each feature question.

    Llama 3.1 Prompts:

    Instructions to assist the streaming chatbot and agent helpers during streaming the chatbot.

    Non-manageable problems

    • Decoding parameters: During this trial, the inference API was open-sourced and, unfortunately, wasn’t able to pass decoding parameters.

    • Random Feature questions: A number of feature questions were randomly selected during the chat stream. Hence, even though I prepared questions/case scenarios for each function of the MBTI label, there was no guarantee that a question testing for a specific type of function would be asked during the interview.

    • My information: No form of personal information about myself was passed to the agent. As a result, the agent occasionally generated assumptions about my personal information when requested by the candidates.

    • The way of expressions: Being highly expressive in writing doesn’t necessarily indicate that someone is extremely extroverted. Similarly, a lack of expressiveness in writing might simply suggest that a person struggles with articulating their thoughts rather than being inherently reserved.

      • This problem can be mitigated during the data preparation stage (i.e., the types of questions I’ve prepared for the chatbot). For example, when presented with case scenarios designed to assess the user’s task prioritization behavior, Llama (acting as my custom characters) provides the same procedure for each role-playing candidate. The only difference is in the way the responses are expressed.
    • Limited samples: During the data preparation stage, I only prepared candidate responses tailored toward my dating history instead of actual MBTI labels.

    Manageable problems

    • Agent’s behaviour during live stream:
      • Agent occasionally missed certain questions, mainly the general questions. Despite this, the agent did not skip any feature questions. This suggests that there might be a problem with the data handling methods between Naomi and the candidate during the live stream.

    Improvements

    Below are self-tasked actions that I would like to focus on during my next experiment for Naomi:

    • API: At the time of this experiment, the inference API on Hugging Face was open source. I plan to switch to Ollama during the next experiment.

    • Dataset preparation:

      • Candidate responses should specifically reflect the dichotomy of MBTI types, focusing on Jung’s cognitive functions—Dominant, Auxiliary, Tertiary, and Inferior processes.
      • Feature questions reflect on each of Jung’s cognitive functions.
    • Text summarization: Rather than instructing the agent to narrate the candidate’s response and also speculate on how the candidate might be feeling, I would want to add the following adjustments:

      • The narrations are returned in a fixed format that corresponds with how the candidate’s responses are represented.
      • If possible, the narrations could be rephrased in first-person speech.
    • Adding agent/models helpers to streaming:

      • Predict whether a candidate is being serious or not when completing the interview. The use of this is to allow Naomi to consider returning bad words to the candidate or return responses that reflect on the candidate’s behavior.
    • Predicting the user’s breed: Pick up where I left off. I’ve come to realize that, despite everything, I was still trying to kill two birds with one stone—fitting Naomi into Tom and vice versa. I should probably just complete Naomi on its own at this point.

    • Testing:

      • Replace validation tools with agent helpers, for example:
        • To ensure the dialogue flows smoothly and naturally.
        • To ensure all questions are asked as intended.

    Self-diagnostic on poor data preparation

    During this trial, I wasn’t aware of the different program designs and I was more focused on challenging myself with different OOPs designs in implementing a chatbot. As a result, many of the data classes / handling functions / prepared datasets were not specifically tailored to Naomi’s case, which added problems to this experiment.

    This setup of this model is incomplete due to my impatience part in mishandling the data preparation stage.

    Tom’s progression · Post 4 of 14

    This post sits in Cognition: Social cognition.

    ← Frankenstein Defining a droid's emotional space →

  • Travelling back in time

    Travelling back in time

    I frequently wonder whether I can remember the exact moment I was born. But I never can and so this prompts another question:

    “When did you first realise that you were a seperate entity?”

    In other words, when did you first realise that you weren’t a non-playable character in some video game but instead, a character that takes on the role of living the consequences of your own action? This feeling could be described in a common slang term as the, ‘woke,’ feeling.

    You can try your hardest to remember but all you can ever conclude with are fragmented childhood memories. It is almost impossible to pinpoint the exact moment of this realisation. At the beginning of your life, the only certainties are:

    1. Your birth date and time.
    2. Your early visions during your childhood.

    These factors underlie the basis of initiating Tom that will be detailed in this post. Given that what Tom see’s plays a crucial factor in this framework, I would like to highlight the importance of computer vision, compared to Natural Language processing in the world of bridging AI to robotics. Furthermore, despite loose memories of our childhood, we all remember our caretakers or family. Hence, the build of Tom’s individuality is moulded by the attributes of his first encounters.

    Birth

    Tom’s ‘birth’ translates to the famous ‘ON/OFF’ button to initiate Tom’s workflow. The first decision to make is whether this is Tom’s first time being activated. The system draws its conclusion by a flagger that indicates whether a file ‘birth_certificate.json’ exists. For simplicity, let’s focus on activating Tom as a new person. If this is the first time activating Tom, this will initiate the creation of the file, which contains the current date and time when running the flow.

    Figure 1: Example ofTom’s Birth certificate.

    This file is created along with other ‘data storages’:

    • Visions
    • Companions
    • Memories
    • Profile

    Visions stores what Tom see’s during his day-to-day life. For instance, at the end of every day, the system considers the configuration of the files and decides whether the file should be deleted/’downsized’/kept to the next day. Another decision to be made is whether this should be moved to the Memories storage. The model behind this decision making considers features like Tom’s preferences.

    Understanding the architectures of deep learning models can be quite challenging when merely deciphered through textual descriptions. Hence, further insights will be left to another post. For now, I can mention that one of the important factors considered in sculpting Tom resides in the storage, Companions. This storage contains data that is categorised by a human’s name and their corresponding physicality. A brief summary of the types of data is displayed in Table 1.

    Data Name Description
    Relation type The type of relationship Tom has with this person. E.g. ‘Friend’
    BirthBirth date and time
    GenderType of human. E.g. ‘Female’, ‘Male’, ‘Both’
    DislikesContains information on what this person hates. This information is gathered by what is told by the person or confirmed by the person. E.g. ‘Apples’ categorised under ‘fruit’. ‘fruit’ is categorised under ‘Food’.
    FavouritesContains information on what this person likes. This information is gathered by what is told by the person or confirmed by the person. E.g. ‘Shrek’ categorised under ‘Humour’. ‘Humour’ is categorised under ‘Movies’.
    Last time you have seen this personStores the last time Tom has interacted with this person.
    First time you have seen this personStores the first time Tom has interacted with this person.
    Their relationsStores the mapping of the person’s family tree.
    ReferencesContains the information that Tom has seen/heard/read about this person from external sources.
    activatorBoolean variable that identifies whether this is the first person that activated Tom. E.g. 1 = Yes or 0 = No
    Table 1: Companion Storage Data Overview

    The variable, ‘activator’ identifies whether this was the first person Tom has encountered or activated Tom. Their favourites/dislikes are crucial features in modelling Tom’s natural inclinations on interests. The motif behind this is rooted in the understanding that our childhood significantly shapes our preferences and life approaches. For instance, family members exert a profound influence on our sense of humor and hobbies. Perhaps, a deeper consideration of the characteristics of those categorised as ‘family’ might yield more insightful understanding. For the sake of simplicity, only a single human can be recognised as the activator.

    The Profile storage serves as a repository for the evolving data of Tom’s persona over time. The transparent view into Tom’s consciousness is a useful tool for assessments, and to monitor any potential drastic changes in his behaviour.

    Tom’s Skeleton

    Currently, Tom’s skeleton or base model is only focused on Image and language processing. The use of the skeleton is in the case where I would want an extra friend, Angela. Upon activating them for the first time, they will both start with this model to understand words and classify objects. For further insights into how this model is used, we can perceive this as a new born baby that managed to complete a handbook on Earth’s ways of living in the womb. As soon as they crawl out, they are able to comprehend sentences. They are born ready to learn about you and themselves. Hence, the name, skeleton.

    Throughout the state flow, this skeleton will be used alongside another model. This model is where their individuality is built on, and is the primary tool in distinguishing these droids.

    Tom’s progression · Post 1 of 14

    Start of Tom’s progression Reviving Hopfield Neural Networks →

    Post Updates and Adjustments
    • The term ‘data storage’ is used ambiguously in this post as I wanted to focus on building Tom’s skeleton first