All script paths are relative to this Skill directory.
Prerequisites: You must be logged in and have selected a scan book (refer to the deepscan-login and deepscan-task Skills).
Scenario 1: View the current batch
python scripts/session.py current
- Returns successfully → inform the user of the name of the batch currently in progress and the scan book it belongs to.
- Exit code 1 → there is no batch yet, and one needs to be created.
Scenario 2: Start a new batch
Execute when the user says "start a new batch"/"create a new batch"/"start over":
python scripts/session.py create
Example return:
{
"session_id": "019cade8-4f13-7d6c-8930-2690fcc242f4",
"session_name": "20260302173648扫描列表",
"task_id": "019c30a1-d44f-7378-a373-6f7e77e4fd25",
"task_title": "默认扫码本"
}
Inform the user: A new batch "{session_name}" has been started under the scan book "{task_title}", and you can begin adding scan records.
Configuration file
Batch information is stored in ~/.deepscan/config.json:
{
"task_id": "...",
"task_title": "...",
"session_id": "019cade8-4f13-7d6c-8930-2690fcc242f4",
"session_name": "20260302173648扫描列表"
}
When other Skills obtain the current batch ID, execute:
python scripts/session.py current