I’m feeding the prompt with a text and give it the job to correct this text. In der response there ist (mostly, not always) an introducing dialog phrase like “Here is the corrected text with the spelling and formatting errors fixed:…” or “Here is the provided text corrected:…” How can i disable this to only get the corrected text?
i’m using model amazon.titan-text-express-v1
Here is my code in php:
$request = (object) [
"inputText" => $prompt,
"textGenerationConfig" => (object) [
"maxTokenCount" => 3072,
"stopSequences" => [],
"temperature" => 0.7,
"topP" => 0.9,
]
];
$result = $this->bedrockRuntimeClient->invokeModel([
'contentType' => 'application/json',
'body' => json_encode($request),
'modelId' => $this->modelId,
]);
Simply give the instruction via the prompt did’t worked.