Use enum for type definition

This commit is contained in:
AbdBarho
2023-01-08 12:11:47 +01:00
parent c9a3813b8f
commit d99c0e2d2f
4 changed files with 5 additions and 4 deletions
+2 -1
View File
@@ -69,7 +69,8 @@ export const TaskTypes = [
category: TaskCategory.Label,
pathname: "/label/label_prompter_reply",
type: "label_prompter_reply",
},{
},
{
label: "Label Assistant Reply",
desc: "Provide labels for a prompt.",
category: TaskCategory.Label,
@@ -3,7 +3,7 @@ import { LabelingTaskType, useLabelingTask } from "./useLabelingTask";
export interface LabelAssistantReplyTask {
id: string;
type: "label_prompter_reply";
type: LabelingTaskType.label_assistant_reply;
message_id: string;
valid_labels: string[];
reply: string;
@@ -3,7 +3,7 @@ import { LabelingTaskType, useLabelingTask } from "./useLabelingTask";
export interface LabelInitialPromptTask {
id: string;
type: "label_initial_prompt";
type: LabelingTaskType.label_initial_prompt;
message_id: string;
valid_labels: string[];
prompt: string;
@@ -3,7 +3,7 @@ import { LabelingTaskType, useLabelingTask } from "./useLabelingTask";
export interface LabelPrompterReplyTask {
id: string;
type: "label_prompter_reply";
type: LabelingTaskType.label_prompter_reply;
message_id: string;
valid_labels: string[];
reply: string;