pyrit.models.construct_response_from_request#
- construct_response_from_request(request: PromptRequestPiece, response_text_pieces: list[str], response_type: Literal['text', 'image_path', 'audio_path', 'url', 'error'] = 'text', prompt_metadata: str | None = None, error: Literal['blocked', 'none', 'processing', 'unknown'] = 'none') PromptRequestResponse [source]#
Constructs a response entry from a request.