electorAll('.message');
            const existingCount = 0; //existingMessages.length;

            // 只添加新消息
            for (let i = existingCount; i < dialogue.length; i++) {
                const message = dialogue[i];
                const messageDiv = document.createElement('div');
                messageDiv.className = `message role-${message.role}`;

                // 获取当前时间
                const now = new Date();
                const timestamp = `${now.getHours().toString