Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

BUG: Inferred objective is empty when tool calls come between the request and the answer

オープン
#3,515 コメント 0 件 リアクション 0 件 担当者 1 名 GitHub で見る

メンテナーはふだん 2 日以内に返信

@Shizoqua がすでに取り組んでいます。

2026年10月26日 から。

  • #3517 @Shizoqua による — オープン

評価

難易度
2/5
見積もり時間
1〜3時間
初心者へのやさしさ
25/100
issue の種類
バグ
明瞭さ
明確に書かれている
活発さ
停滞
技術スタック
python
領域
ai, backend

調査の方向性

Read extract_objective_from_previous_turn_async and compare its lookup with MemoryInterface.get_request_from_response_async and WildGuardScorer, which the issue cites. Reproduce with the described sequence of user, function call, tool output, and answer turns; done means the inferred objective is the original user question. Pull request #3517 is already open for this issue.

索引モデルが issue の本文から書いたものです。

説明

Describe the bug

extract_objective_from_previous_turn_async (used when a scorer infers the objective from the request) only reads the turn at sequence - 1. When a target runs a tool loop, memory stores the user request, the function_call, the function_call_output and then the answer, so the turn before the answer is the tool output. It has no user text, and the scorer ends up with an empty objective.

#3410 fixed the same problem in MemoryInterface.get_request_from_response_async, and WildGuardScorer already looks back to the latest earlier user turn.

Steps to Reproduce

Store a conversation of user question (seq 2), assistant function_call (seq 3), tool function_call_output (seq 4) and assistant answer (seq 5), then call extract_objective_from_previous_turn_async on the answer.

Expected Results

The objective is the user question from seq 2.

Actual Results

An empty string.

Versions

Linux, Python 3.13.16, PyRIT 1.2.0.dev0 from main (96de757e)

主要言語
Python
スター
4.7k
フォーク
980
平均マージ
2日 9時間
マージ済み PR(30日)
433

環境構築

Codespaces で開く

このプロジェクトの開発コンテナを、あなたの GitHub アカウントでブラウザ上に起動します。

  • Dockerfile・Docker Compose ファイルなし
  • プルリクエストのテンプレートあり
  • コントリビューションガイドなし

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

microsoft/PyRIT のほかの issue

microsoft/PyRIT の issue をすべて見る

似ている issue

Python の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。