# Gemini AI分析で画像付き投稿を使用する際に「ArrayからStringへの暗黙的な変換なし」エラーが発生

**URL:** https://meta.discourse.org/t/error-no-implicit-conversion-of-array-into-string-when-using-gemini-ai-analysis-on-posts-with-images/372015
**Category:** Bug
**Tags:** ai
**Created:** [2025 年 6 月 27 日午後 3:22 UTC](https://meta.discourse.org/t/error-no-implicit-conversion-of-array-into-string-when-using-gemini-ai-analysis-on-posts-with-images/372015 "2025-06-27T15:22:35Z")
**Posts on this page:** 7
**Page:** 1

<div class="post-metadata">

### Author: ![hel\_Sinki](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/hel_sinki/32/525916_2.png) [@hel\_Sinki](https://meta.discourse.org/u/hel_Sinki)
#### Post date: [2025 年 6 月 27 日午後 3:22 UTC](https://meta.discourse.org/t/error-no-implicit-conversion-of-array-into-string-when-using-gemini-ai-analysis-on-posts-with-images/372015/1 "2025-06-27T15:22:35Z")

</div>

皆さん、こんにちは。

Gemini連携で **Discourse AIプラグイン** を使用中に問題が発生しました。画像を含む投稿を分析しようとすると、以下のエラーメッセージが表示されます。

> 文字列への配列の暗黙的な変換ができません

 ![Screenshot 2025-06-27 at 08.20.23](https://global.discourse-cdn.com/meta/original/4X/3/8/2/3823376649f99b412fea517362b101d46199d62d.png)

### **何が起こるか**

- 投稿にテキストのみが含まれている場合、すべて期待どおりに機能します。
- 投稿に画像が含まれている場合、このエラーで分析が失敗します。

### **環境**

#### インストール済み 3.5.0.beta8-dev ([70dbb95041](https://github.com/discourse/discourse/commits/70dbb95041286abbe39accbd679f1ff100f9946d))

ご協力ありがとうございます！

---

<div class="post-metadata">

### Author: ![hel\_Sinki](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/hel_sinki/32/525916_2.png) [@hel\_Sinki](https://meta.discourse.org/u/hel_Sinki)
#### Post date: [2025 年 6 月 28 日午前 12:40 UTC](https://meta.discourse.org/t/error-no-implicit-conversion-of-array-into-string-when-using-gemini-ai-analysis-on-posts-with-images/372015/2 "2025-06-28T00:40:51Z")

</div>

公開投稿に画像を含めるとGeminiは応答せず、プライベートメッセージで送信するとAIは上記のエラーを報告します。

---

<div class="post-metadata">

### Author: ![Michael12](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/michael12/32/507366_2.png) [@Michael12](https://meta.discourse.org/u/Michael12)
#### Post date: [2025 年 6 月 28 日午前 3:22 UTC](https://meta.discourse.org/t/error-no-implicit-conversion-of-array-into-string-when-using-gemini-ai-analysis-on-posts-with-images/372015/3 "2025-06-28T03:22:16Z")

</div>

私も同じ問題に直面しています。テキストのみの投稿は問題なく動作しますが、投稿に画像が含まれている場合、「配列から文字列への暗黙的な変換はありません」という同じエラーが発生します。

エラーメッセージから、画像データ内の何かがプラグインまたはGeminiを混乱させているようです。おそらく、APIが予期しない方法で画像情報を送信しているのでしょう。

特定のボットでのみ発生することを知っておくと良いでしょう。これがすぐに解決されることを願っています。

---

<div class="post-metadata">

### Author: ![sam](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sam/32/102149_2.png) [@sam](https://meta.discourse.org/u/sam)
#### Post date: [2025 年 7 月 2 日午前 1:56 UTC](https://meta.discourse.org/t/error-no-implicit-conversion-of-array-into-string-when-using-gemini-ai-analysis-on-posts-with-images/372015/4 "2025-07-02T01:56:49Z")

</div>

ここで再現するのに問題があります。画像が有効になっているクリエイティブを使用しています。

 ![このスクリーンショットは、Gemini AI システムが画像を文字起こししようとした際に表示されるエラーメッセージを示しており、システムエラーに関する技術的な詳細が表示され、招待や返信オプションなどの会話要素が含まれています。(AIによるキャプション)](https://global.discourse-cdn.com/meta/original/4X/0/9/5/095a63c1f88ce4c26b74f92a30dd29187c1dadca.png)

LLM がどのように構成されているか教えていただけますか。リリースされたばかりの非プレビュー 2.0 / 2.5 フラッシュ モデルを使用してください。

---

<div class="post-metadata">

### Author: ![hel\_Sinki](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/hel_sinki/32/525916_2.png) [@hel\_Sinki](https://meta.discourse.org/u/hel_Sinki)
#### Post date: [2025 年 7 月 2 日午前 2:34 UTC](https://meta.discourse.org/t/error-no-implicit-conversion-of-array-into-string-when-using-gemini-ai-analysis-on-posts-with-images/372015/5 "2025-07-02T02:34:31Z")

</div>

確認しました。RAGの設定を削除したところ、画像分析機能は正常に戻りました。助かりました！

---

<div class="post-metadata">

### Author: ![sam](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sam/32/102149_2.png) [@sam](https://meta.discourse.org/u/sam)
#### Post date: [2025 年 7 月 2 日午前 2:38 UTC](https://meta.discourse.org/t/error-no-implicit-conversion-of-array-into-string-when-using-gemini-ai-analysis-on-posts-with-images/372015/6 "2025-07-02T02:38:39Z")

</div>

@Roman_Rizzi RAGの問題を修正しましたので、これで問題ないはずです。ご報告ありがとうございました！

---

<div class="post-metadata">

### Author: ![sam](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sam/32/102149_2.png) [@sam](https://meta.discourse.org/u/sam)
#### Post date: [2025 年 7 月 2 日午前 2:38 UTC](https://meta.discourse.org/t/error-no-implicit-conversion-of-array-into-string-when-using-gemini-ai-analysis-on-posts-with-images/372015/7 "2025-07-02T02:38:45Z")

</div>


