From 34d0e6d71b432fcb7db3a7d60bf9253b44672a7c Mon Sep 17 00:00:00 2001 From: thesai <1021828630@qq.com> Date: Fri, 2 Feb 2024 15:30:26 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E7=AB=9E=E8=B5=9Bproto?= =?UTF-8?q?=E5=AE=9A=E4=B9=890.1=E7=89=88?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/scoring_rule.proto | 13 +++++++++++++ src/task_setting.proto | 29 +++++++++++++++++++++++++++++ 2 files changed, 42 insertions(+) create mode 100644 src/scoring_rule.proto create mode 100644 src/task_setting.proto diff --git a/src/scoring_rule.proto b/src/scoring_rule.proto new file mode 100644 index 0000000..e79a212 --- /dev/null +++ b/src/scoring_rule.proto @@ -0,0 +1,13 @@ +syntax = "proto3"; +package task; + +message Rule { + repeated Unit units = 1; +} + +//最小评分单元 +message Unit { + string text = 1; //文字描述 + uint32 sceneStepId = 2; //场景步骤ID + uint32 score = 3; //扣分分值 +} \ No newline at end of file diff --git a/src/task_setting.proto b/src/task_setting.proto new file mode 100644 index 0000000..f8936c5 --- /dev/null +++ b/src/task_setting.proto @@ -0,0 +1,29 @@ +syntax = "proto3"; +package task; + +message TaskSetting { + // repeated RandomItem randoms = 1; + repeated TimeItem timeItems = 1; + repeated GroupItem groupItems = 2; +} + +//任务随机抽取设置项 +message RandomItem { + string name = 1; //设置项名称 + repeated uint64 taskIds = 2; //任务列表 + uint32 number = 3; //抽取题数 +} + +//任务时间设置项 +message TimeItem { + repeated uint64 taskIds = 1; //任务列表 + repeated RandomItem randomItems = 2; //随机抽题设置项 + uint32 time = 3; //时间(分钟) +} + +//任务分组设置项(仅是打包称呼而已) +message GroupItem { + repeated uint64 taskIds = 1; //任务列表 + string name = 2; //名称 +} +