slate.length) {
        this.errorMsg = '没有需要翻译的差异项。';
        return;
      }

      let translationSucceeded = false;

      // 分批翻译
      const batchSize = 20;
      for (let i = 0; i < toTranslate.length; i += batchSize) {
        const batch = toTranslate.slice(i, i + batchSize);
        const query = batch.map(item => item.newValue).join('\n');
        let translations = [];
        if (this.selectedApi === 'openai') {
          translations = await this.translateOpenAI(q