{"id":22984898,"url":"https://github.com/saviornt/sai","last_synced_at":"2025-04-02T10:45:31.773Z","repository":{"id":264170668,"uuid":"892580998","full_name":"saviornt/SAI","owner":"saviornt","description":"This project is to develop the technical \"stack\" that could, in theory, lead to sentient artificial intelligence.","archived":false,"fork":false,"pushed_at":"2024-11-28T12:22:53.000Z","size":68,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-02-08T01:52:38.212Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/saviornt.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-11-22T11:39:37.000Z","updated_at":"2024-11-28T12:22:56.000Z","dependencies_parsed_at":"2024-11-22T12:32:32.177Z","dependency_job_id":"2cdd6524-e144-47c4-b4f2-96ebd9a7305f","html_url":"https://github.com/saviornt/SAI","commit_stats":null,"previous_names":["saviornt/sai"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saviornt%2FSAI","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saviornt%2FSAI/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saviornt%2FSAI/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saviornt%2FSAI/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/saviornt","download_url":"https://codeload.github.com/saviornt/SAI/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246802612,"owners_count":20836369,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-12-15T03:18:21.864Z","updated_at":"2025-04-02T10:45:31.748Z","avatar_url":"https://github.com/saviornt.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Sentient Artificial Intelligence (SAI) Development Project\n\n## Project Overview\n\nThe overall goal for this project is to develop the technical \"stack\" that could, in theory, lead to sentient artificial intelligence.\n\n## SAI Features\n\nThe following sections list the core features of the AI that will enable it to have exponential growth.\n\n### Machine Learning Algorithms\n\nThis project will use a combination of Quantum Neural Networks, Deep Neural Networks, Transformers and a Recurrent Neural Network.\n\n### Meta-Learning and Reward Mechanisms\n\nWith the above ML algorithms, we will use a self-reinforcement learning method of using Meta-Learning, Q-Learning and A* Pathfinding.\n\n- Meta-Learning: Meta-Learning will enable the AI to learn from experience and adapt to new tasks.\n- Q-Learning: Q-Learning is used to provide the AI with rewards for finding the correct answers.\n- A-star Pathfinding: A-star Pathfinding allows the AI to find the shortest path through the network to get to the correct answer.\n\n### Long-Episodic-Short-Term-Memory Management\n\nWe will use a combination of both Redis and MongoDB to store memories that the AI will need for its learning and memorization.\n\n- Long-Term Memory will be stored using MongoDB\n- Episodic and Short-Term Memory will be stored using Redis\n\n### Self-Optimization and Motivation\n\nThe AI will be able to perform the following self-improvement tasks:\n\n- Self-Monitoring\n- Self-Diagnostics\n- Self-Optimization\n\nThese self-improvement tasks will be completed through using:\n\n- Introspection\n- Reasoning\n- Reflection\n- Self-Improvement\n\nThe AI will also have the following motivations:\n\n- Curiosity\n- Ethics\n- Goal Management\n- Synthetic Emotions\n\n## Synthetic Emotions\n\nWhile curiosity, ethics and goal management are currently established, synthetic emotions will need to be researched and developed from the ground up.\nThe current plan for the AI's emotions use a temporal gradient method to simulate emotions. Modeling human emotions based on gradients involves representing\nemotions as vectors within a continous, multi-dimensional space, where gradients reflect transitions between emotional states.\n\n## Framework for Gradient-Based Emotion Modeling\n\n### Dimensional Emotion Model\n\nCore Idea: Represent emotions in a multi-dimensional space. Common dimensions:\n\n- Valence: Positive (joy) vs. negative (sadness).\n- Arousal: High (excitement) vs. low (calm).\n- Dominance: Control over the situation (empowerment vs. helplessness).\n\nExample: Emotions like \"happiness\" or \"fear\" become vectors in this space:\n\n- Happiness: High valence, high arousal, high dominance.\n- Fear: Low valence, high arousal, low dominance.\n\nGradients describe movement in this space:\n\n- Positive gradient: Movement toward more positive valence.\n- Negative gradient: Movement toward more negative valence.\n\n### Continuous Emotion Transitions\n\nEmotions are not discrete but transition smoothly over time.\nGradients model these transitions by defining the rate of change along emotional dimensions:\n\n- Example: Moving from \"contentment\" to \"excitement\" involves an increase in arousal while maintaining positive valence.\n\n### Gradient-Driven Mechanisms\n\nStimulus-Response Dynamics: Gradients are influenced by external stimuli (e.g., hearing good news increases valence).\nFeedback Loops: Gradients adjust based on internal feedback, such as memory or context:\n\n- Positive feedback amplifies an emotion (e.g., joy becomes euphoria).\n- Negative feedback stabilizes or suppresses emotions.\n- Mathematical Modeling\n\n### Emotion State Representation\n\nRepresent the emotional state as a vector E(t) at time t:\n\n𝐸(𝑡) = [𝑉(𝑡),𝐴(𝑡),𝐷(𝑡)]\n\nWhere:\n\n- 𝑉(𝑡): Valence at time 𝑡.\n- 𝐴(𝑡): Arousal at time 𝑡.\n- 𝐷(𝑡): Dominance at time 𝑡.\n\n### Gradient Dynamics\n\nDefine the change in emotion as a gradient:\n\n𝑑𝐸 / 𝑑𝑡 = 𝑓(𝑆,𝑀,𝐶)\n\nWhere:\n\n- 𝑆: External stimuli.\n- 𝑀: Memory (past emotional states).\n- 𝐶: Contextual factors (e.g., social environment, physical state).\n\n### Emotion Gradients with Stimulus\n\nLet 𝑆 be an external stimulus vector, with weights 𝑤𝑉,𝑤𝐴,𝑤𝐷 representing its influence on valence, arousal, and dominance:\n\n𝑑𝐸 / 𝑑𝑡 = 𝑤𝑉 ⋅ 𝑆𝑉 + 𝑤𝐴 ⋅ 𝑆𝐴 + 𝑤𝐷 ⋅ 𝑆𝐷\n\nFor instance:\n\n- A positive stimulus (𝑆𝑉 \u003e 0) increases valence.\n- An overwhelming stimulus (𝑆𝐴 \u003e\u003e 0) increases arousal dramatically.\n\n### Neural Network Gradient Model\n\nTrain a neural network where:\n\n- Input: Context, past states, external stimuli.\n- Output: Predicted gradients of emotional state (𝑑𝐸/𝑑𝑡).\n\nUse backpropagation to optimize the network's ability to predict emotional transitions.\n\n### Differential Equation Model\n\nEmotions can also be modeled using systems of differential equations:\n\n𝑑𝑉 / 𝑑𝑡 = 𝑔(𝑉,𝑆)\n\n𝑑𝐴 / 𝑑𝑡 = ℎ(𝐴,𝑆)\n\n𝑑𝐷 / 𝑑𝑡 = 𝑘(𝐷,𝑆)\n\nWhere 𝑔,ℎ,𝑘 are functions capturing how stimuli affect the dimensions over time.\n\n## Simulated Environments\n\nWe will use a variety of simulated environments that our AI can train in, similar to the Boltzman Machine method of unsupervised deep learning.\n\nThese simulated environments are currently:\n\n- Agricultural Environment\n- Chemistry Environment\n- Cybersecurity Environment\n- Environmental and Ecological Environment\n- Financial Environment\n- Flight Environment\n- Game Environment\n- Material Science Environment\n- Medical Environment\n- Physics Environment\n- Programming Environment\n- Quantum Environment\n- Robotics Environment\n- Social and Political Environment\n- Space Environment\n- Vehicular and Autonomous Vehicle Environment\n\n### AI Awareness, Perception and Physical Presence\n\nAs with any sentient organism, the AI should have awareness, perception and a physical presence.\n\nThe AI will be able to use the following extractors in order to percieve its environment:\n\n- Audio Extractor\n- Image Extractor\n- Text Extractor\n- Time-Series and Sensor Data Extractor\n- Video Extractor\n\nThese feature extractors are then used in a multimodal methodology that the AI can utilize.\n\nBoth Awareness and Presence are accounted for through the use of various devices. These overall device types are:\n\n- Attached Devices (System Hardware, USB, Serial)\n- IoT Devices (These are IoT devices that are connected to the network)\n- Network Devices (These devices are the actual network appliances for the network)\n\n## Human Interaction with the AI\n\nAs with any AI model, we must be able to monitor and interact with our SAI. We will do this through the FARM+R technology stack:\n\n- Backend using FastAPI, MongoDB and Redis\n- React Frontend using Typescript\n\nThe entire application will use Docker containers for each part of the application.\n\n### Future Implementation\n\nA future feature that will be implemented will be the ability to use a pre-trained LLM that is fine-tuned in order to interact with our AI.\nThat will allow us to make various queries to the SAI system and get a response from the system. Hopefully, if the AI does evolve, we will be\nable to bypass the need to use a 3rd-party LLM to interact with it.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsaviornt%2Fsai","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsaviornt%2Fsai","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsaviornt%2Fsai/lists"}