approvers / approvers/ichiyoAI

Gemini に関するリクエストが部分的にうまく行かない

Open
#208 3 comments 0 reactions 0 assignees View on GitHub
bug wrapper
Dominant language
Rust
Stars
7
Forks
1
PR merge metrics
No merged PRs in 30d

Description

**formal な詳細提供は保留**しています

---

このようなエラーが表示される

![image](https://github.com/approvers/ichiyoAI/assets/62282295/83dfd25c-2f29-4002-a993-9f039df91e8c)

Gemini は確かに messages の両端がユーザロールでない場合 (つまり LLM 側) に生成を拒否する仕様なのだが, どうにもユーザのメッセージを 2 つ繋げただけでもエラーが出力されている様子.

推測しているのは, 奇数個のメッセージ長さでないといけないか, 同一ロールのメッセージを連続して配置できないかのどちらかではないかと考えている.

---

ざっくりやること

- [ ] 原因究明
- [ ] エラー種別としてデータ型の定義に加える
- [ ] 事前に検査し実装側から弾く
- [ ] よりユーザフレンドリなエラーメッセージを提供する
- [ ] (或いは) 無視できる範囲であればメッセージを矯正し返答可能な形式へ変換する様に実装を変更する

Contributor guide

No contributing guide indexed for this repository

Research direction

No file, test, or entry point is named in the issue. Begin by reproducing the Gemini request failure with consecutive user messages and inspect how message roles are sent; done means the cause is identified and the behavior is validated through a defined error, friendly message, safe normalization, or documented reason not to normalize.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
api, backend
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.