---
title: "質問インターフェース"
slug: "the-questions-interface"
abstract: "JS Dataパッケージの質問インターフェースSitecore Searchキーワードに関連する質問や回答のリクエストに使用されます。"
---
# 質問インターフェース

Sitecore Searchでは、検索クエリがキーワードに関連する質問や回答を返すことが可能です。AI生成コンテンツには以下のオブジェクトと方法を使いましょう。

## 質問インターフェース

名称

種類

概要

keyphrase

ストリング

返す質問を検索するためのフレーズ。

exact\_answer

アコクトアンサー

返すべき値の種類を記述するObject。

related\_questions

関連質問

回答に何つ、どの質問を含めるかを説明するObject。

## RelatedQuestions interface

名称

種類

概要

limit

番号

質問と回答のペア数の上限。  
  
デフォルト:5

offset

番号

セット開始前に戻る前に省略すべき質問と回答のペアの数。

## ExactAnswer interface

名称

種類

概要

query\_types

ストリング

生成すべき値の種類を記述します。  
  
*質問*、 *発言*、 *またはキーワード*。

> !注特に明記がない限り、すべての値は任意です。

## ISearchRequest methods

以下のコードブロックはQuestionsインターフェースに関連するさまざまなメソッドを一覧にしており、WidgetRequestオブジェクトを通じてアクセス可能です。JS Dataパッケージをプロジェクトにインストールした後、これらのメソッドとそのドキュメントはIDE上で利用可能です。

/\*\* questions \*/
getQuestions(): Questions;
setQuestions(value: Questions): IWidgetItem;
resetQuestions(): IWidgetItem;
updateQuestions(value: Questions): IWidgetItem;

/\*\* questions.exact\_answer \*/
getQuestionsExactAnswer(): ExactAnswer;
setQuestionsExactAnswer(value: ExactAnswer): IWidgetItem;
resetQuestionsExactAnswer(): IWidgetItem;
updateQuestionsExactAnswer(value: ExactAnswer): IWidgetItem;

/\*\* questions.exact\_answer.query\_types \*/
getQuestionsExactAnswerQueryTypes(): string;
setQuestionsExactAnswerQueryTypes(value: string): IWidgetItem;
resetQuestionsExactAnswerQueryTypes(): IWidgetItem;

/\*\* questions.keyphrase \*/
getQuestionsKeyphrase(): string;
setQuestionsKeyphrase(value: string): IWidgetItem;
resetQuestionsKeyphrase(): IWidgetItem;

/\*\* questions.related\_questions \*/
getQuestionsRelatedQuestions(): RelatedQuestions;
setQuestionsRelatedQuestions(value: RelatedQuestions): IWidgetItem;
resetQuestionsRelatedQuestions(): IWidgetItem;
updateQuestionsRelatedQuestions(value: RelatedQuestions): IWidgetItem;

/\*\* questions.related\_questions.limit \*/
getQuestionsRelatedQuestionsLimit(): number;
setQuestionsRelatedQuestionsLimit(value: number): IWidgetItem;
resetQuestionsRelatedQuestionsLimit(): IWidgetItem;

/\*\* questions.related\_questions.offset \*/
getQuestionsRelatedQuestionsOffset(): number;
setQuestionsRelatedQuestionsOffset(value: number): IWidgetItem;
resetQuestionsRelatedQuestionsOffset(): IWidgetItem;