GETTING STARTED / 09
Build an AI Passport app with Doubao
Open the app project in Doubao's Work mode on your own computer, let the agent build the firmware, and learn the limits of the free quota.
Get to know Doubao
Doubao's desktop app is ByteDance's AI assistant. Its Work mode runs tasks on your own computer: give it a project folder and the agent reads code, edits files, and runs commands in a background terminal.
- Developer: ByteDance
- Platforms: tested on macOS; see the official download page for other systems
- Requirements: a Doubao account. The official site offers new users a 30-day free trial. The free quota covers a rolling 7 days; once it's used up, wait for it to reset or subscribe.
- Version used in this guide: 2.34.6
Tested on macOS 26.6 (Apple silicon) on November 4, 2026, by installing the app and running this guide's example task.
Download and install Doubao
Download the installer from the official site: doubao.com. Use only the official download, not repackaged builds from other sources.

- On the download page, select the button to download the desktop app.
- macOS: open the .dmg, drag Doubao into Applications, and launch it from Applications, not from the installer disk.
- Eject the installer disk when you're done.
Sign in and check the model
Sign in to your Doubao account the first time you open it, then select New work task on the left. Below the message box, set where it runs to Local computer and keep the default permission, Confirm when needed. The model menu is at the bottom right. This guide used Auto with High reasoning.


- There are three permission levels. Always ask asks before editing outside files or using the internet. Confirm when needed asks only for risky actions. Allow all has unrestricted internet access and can edit any file on your computer, so we don't recommend it.
- The model menu lists Auto, Doubao 2.1 Lite, Doubao 2.1 Pro (requires an upgrade), and Reasoning (Low, Medium, High).
Open the AI Passport project
Select Project below the message box, choose Create project from local folder, pick the AI Passport project folder, and select Create in the Create project dialog. The folder then appears below the message box and under Projects on the left.

You can clone the project first with git clone https://gitee.com/FoloToy/ai-passport.git, or choose an empty folder and let the agent download the project from the prompt.
Send the build prompt
Start a new conversation, paste the prompt below, replace [ENTER APP REQUIREMENTS] with the app you want, and send it. This guide used the following example:
Build using the complete project at https://gitee.com/FoloToy/ai-passport; reuse a local checkout if available.
Read AGENTS.md and docs/README.md first, then consult relevant documentation, hardware interfaces, and examples as needed. Prepare the environment and install the Skills required by the project.
Preserve existing changes and develop on a new branch. Reuse the BSP and design a fresh application UI instead of copying the demo; check font coverage for Chinese text. Ask when key requirements are unclear and handle the rest autonomously.
Run project validation and deliver merged firmware flashable from 0x0. Report test results and anything unverified. When finished, proactively ask whether to test on hardware; do not flash without confirmation.
- a Pomodoro timer: start with a 25-minute focus countdown; Confirm starts or pauses it; before it starts, Up and Down change the length from 5 to 60 minutes in 5-minute steps; when time is up, show a clear alert and play a sound, and Confirm resets the timer
Let Doubao build and check the app
Doubao checks the local repository, installs and verifies the five Skills the project needs, and creates a feature/pomodoro-timer branch. It then reuses the ESP-IDF 5.5.3 already on the computer, sets up the missing Python environment, writes the countdown state machine and a Chinese UI, and runs the host tests and a full firmware build. On the right, Work progress lists the steps, and Background tasks opens the terminals that are running.

- It asked for confirmation only once, to list the remote demo and feature branches. Allow it.
- About four and a half minutes in, it warned that the quota was running low, but the task kept going.
Building a full app uses a lot of quota. In this example, the 7-day free quota ran out after 19 minutes 3 seconds, before Doubao wrote its final summary. Make sure you have enough quota before you start, or be ready to subscribe.
Review the result
This example took 19 minutes 3 seconds. The free quota ran out at the last step, so the chat only says the 7-day free quota is used up, but the build in the background terminal had already finished: Firmware build: PASS and Merged firmware: PASS (1,012,800 bytes, written at 0x0). The installable file is build/FoloToy-AI-Passport-full.bin in the project. The Pomodoro state machine's host tests passed too.


- Under Background tasks on the right, open the build terminal and check for Firmware build: PASS and Merged firmware: PASS.
- The terminal also prints a path under /tmp/ai-passport-firmware…, which is a temporary folder. Use build/FoloToy-AI-Passport-full.bin in the project.
- Doubao didn't commit the code. The changes are uncommitted on the feature/pomodoro-timer branch, and it didn't get to list what's untested.
- The Chinese font coverage check is built into the firmware and runs at startup, so check that all text displays correctly after you install it. The display, buttons, alert sound, and countdown haven't been tested on a device yet.
Install it on AI Passport and test
Open the web flasher, choose the merged firmware the agent delivered (the .bin file written at 0x0), connect AI Passport with a USB-C data cable, and install it. The device restarts when it finishes. Then check the display, buttons, and sound one by one.
- Installing a new app overwrites everything currently on the device. You can restore the default firmware at any time.
- Don't unplug the cable or close the page during installation.
- Describe anything that doesn't look or respond as expected, and ask the agent for another build.
Troubleshooting
Here are issues you may run into when building AI Passport apps with Doubao:
- The 7-day free quota is used up: the task stops replying, but a build already running in the background may have finished. Check the terminal output under Background tasks first. Then wait for the quota to reset or subscribe, and ask for the summary in the same task.
- Two copies of Doubao are running, for example one launched from the installer disk: quit that copy, eject the disk, and keep only the Doubao in Applications.
- ESP-IDF is installed but not activated or is missing its Python environment: Doubao sets it up on its own, so the first build takes longer.
- You can't find the firmware: don't use the temporary path under /tmp from the terminal. Use build/FoloToy-AI-Passport-full.bin in the project.