deepseek.apiKey) {
          this.errorMsg = '请填写 DeepSeek API 密钥。';
          return;
        }
      } else if (this.selectedApi === 'youdao') {
        if (!this.youdao.appKey || !this.youdao.appSecret) {
          this.errorMsg = '请填写有道 AppKey 和 AppSecret。';
          return;
        }
      }

      if (!this.diffItems.length) {
        this.compare();
      }

      const toTranslate = this.diffItems.filter(d => (d.type === 'added' || d.type === 'changed'));
      if (!toTran