// stores/argumentStore.ts import { defineStore } from "pinia"; export const useArgumentStore = defineStore("argument", { state: () => ({ conversationId: -1, selectedArgument: "", conversation: [ { role: "ai", content: "哈喽~ 我是辩论助手,很高兴为你服务!请告诉我你想立论的立场和题目。", }, ], }), actions: { setArgument(arg) { this.selectedArgument = arg; }, setConversationId(id) { this.conversationId = id; }, setConversation(conversation) { this.conversation = conversation; }, }, });