Welcome to the Hublab project repository! This innovative project is centered around integrating Pepper, a friendly humanoid robot, into the HUB-lab environment to serve as an interactive assistant for visitors. The HUB-lab, located within the HU library, is a dynamic space that offers access to cutting-edge technologies such as Virtual Reality, Robotics, Gamification, and Artificial Intelligence.
Human-Robot Interaction: We aim to explore and improve how visitors interact with technology, specifically through their engagement with Pepper. This component focuses on assessing participants' attitudes towards technology and refining Pepper's conversational abilities. By incorporating gestures and movements, we strive to make interactions not only more engaging but also more informative. Technical Development: For those with a technical inclination, this aspect of the project involves enhancing Pepper's ability to understand and respond to visitor inquiries. We're exploring the integration of advanced AI solutions, including ChatGPT, to enable Pepper to provide accurate and helpful information about the lab's resources and how to utilize various technologies. This will be particularly beneficial in workshop settings, where Pepper can assist participants more effectively. Project Goals:
The code interfaces OpenAI GPT-3 with the Aldebaran Pepper and Nao robots, allowing open verbal conversation with these robots on a wide range of subjects.
ToDO
PepperGPT depends on the NaoQi software to interface with the Pepper and Nao robots, and the OpenAI API to interface with GPT-3. Please refer to the detailed setup instructions below for your preferred operating system.
NaoQi is old and runs on Python 2.7 while OpenAI requires Python 3. We therefore need both Python versions installed. Here's a step by step guide for setup on Windows 11.
C:\Python27
to the environment PATH.python
refers to Python2.7 and python3
refers to your Python 3.x distribution.ollama pull phi3:mini
ollama run phi3:mini
Now we need a few of dependencies:
python -m pip install -r .\requirements.py2.txt
python3 -m pip install -r .\requirements.py3.txt
We will use VS Code to run things, you may also use another environment if you prefer.
Now we need the Python NaoQi API for communicating with the Pepper robot.
Finally, we are ready to check out the repository.
python init.py
to set up a default environment. Have your OpenAI account key available so that this can be stored with your configuration. NaoQi is old and runs on Python 2.7 while OpenAI requires Python 3.
python2
refers to Python2.7 and python3
refers to your Python 3.x distribution. If any of them are missing, please install through your preferred package manager. Now we need a few of dependencies:
python2 -m pip install -r .\requirements.py2.txt
python3 -m pip install -r .\requirements.py3.txt
We are now ready to check out the repository:
python init.py
to set up a default environment. Have your OpenAI account key available so that this can be stored with your configuration. We will use VS Code to run things, you may also use another environment if you prefer.
Now we need the Python NaoQi API for communicating with the Pepper robot.
python2
and make sure you can import naoqi
. OSX may throw a lot of warnings the first time NaoQi is imported. Google for the exact way to approve these. I haven't been able to make Choreographe to run on recent versions of OSX, but it's not needed for running this app.
Make sure you've gone through all steps in the Setup guide above before you start.
Note that the Speech recognition module uses a NaoQi (Autonomous Life Proxy) to switch focus to nao_focus. You may not have this script on your own robot and the the code will throw an exception as a result. This call is made solely to prevent the default dialogue system of the robot to interfere with PepperChat. You may safely comment this away or upload your own preferred focus script to the robot, e.g. using Choreograph.
python3 startDialogueServer.py --server
. If everything goes well, the server should respond with _Starting OpenAI chat server... or Starting Tinyllama server... besed on your server prefrence within the parameter
Type an input message to test your chatbot...python module_speechrecognition.py --pip pepper.local
(where pepper.local refers to your robot's ip ).python module_dialogue.py --pip pepper.local --server the model that you want
(where pepper.local refers to your robot's ip ). This script will ask for a participant id and then connect to the OpenAI chatbot server we started earlier. If everything goes well it will continue and register another NaoQi module that runs the dialogue. Pepper should now be ready to chat!This project is released under the MIT license. Please refer to LICENSE.md for license details.
Parts of the source code have specific license formulations. Please see the file headers for details.