Welcome to DOFBOT-Ultra repository
2. AI Encyclopedia-Arithmetic Master
AI Encyclopedia-Arithmetic Master
Please ensure that the web control program backend process is not running in the background. To close it, refer to the [Get Started Quickly - 2. Access the Terminal] section in [Disable the Auto-Start Web Control Backend Process]. After closing, please restart DofbotUltra!!!
Before running this function, you need to close the web control program backend process. For the closing method, refer to the [4. Preparation] section [1. Manage Web control services].
1. Function Description
After the program starts, give the large model an arithmetic problem. After thinking, the large model will reply with the correct answer, find the correct answer on the desktop, and control the robotic arm to point to it. If the correct answer is not on the desktop, the robotic arm will shake its head.
2. Startup
Taking the text version as an example, Raspberry Pi (DofbotUltra) users can directly open a terminal and enter the following command:
ros2 launch largemodel largemodel_control.launch.py text_chat_mode:=TrueThen open a second terminal and enter the following command:
xxxxxxxxxxros2 run text_chat text_chat
Then input arithmetic content in the text_chat terminal, for example, let the large model calculate what 6 multiplied by 11 equals, you can input like this: "Let's do an arithmetic problem, tell me what is the result of eleven multiplied by six", and press Enter; if it's the voice version, wake up the voice module and directly say to the voice module "Let's do an arithmetic problem, tell me what is the result of eleven multiplied by six", then wait for the large model to think and reply, as shown in the figure below:

The robotic arm will point to 66 on the desktop, as shown below:

There's an important point to note: when asking, we need to start with Let's do an arithmetic problem so that the large model will plan the correct steps. Otherwise, the large model will directly reply with the result without pointing to the arithmetic result.
3. Task Planning
Reply with the arithmetic result.
Call the
seewhat()function to observe the desktop.If the arithmetic result number exists on the desktop, call
point_to(x1, y1, x2, y2)to control the robotic arm to point to this number.If the arithmetic result number does not exist on the desktop, call
arm_shaketo control the robotic arm to shake its head, indicating that the arithmetic result number is not on the desktop.