> **Experimental**
>
> `@aws-cdk/aws-bedrock-alpha` is an [**experimental**](/stability) (alpha) package: its API may change in any release, without a major version bump.
# TextPromptVariantProps

Properties for creating a text prompt variant.

Extends: TextPromptVariantProps
Extends: CommonPromptVariantProps

- Stability: [Experimental](/cdk/api/stability.html)
- Source: [`bedrock/prompts/text-prompt-variant.ts`](https://github.com/aws/aws-cdk/blob/v2.275.0-alpha.0/packages/@aws-cdk/aws-bedrock-alpha/bedrock/prompts/text-prompt-variant.ts#L11)

## Example

```ts
const cmk = new kms.Key(this, 'cmk', {});
const claudeModel = bedrock.BedrockFoundationModel.ANTHROPIC_CLAUDE_SONNET_V1_0;

const variant1 = bedrock.PromptVariant.text({
  variantName: 'variant1',
  model: claudeModel,
  promptVariables: ['topic'],
  promptText: 'This is my first text prompt. Please summarize our conversation on: {{topic}}.',
  inferenceConfiguration: bedrock.PromptInferenceConfiguration.text({
    temperature: 1.0,
    topP: 0.999,
    maxTokens: 2000,
  }),
});

const prompt1 = new bedrock.Prompt(this, 'prompt1', {
  promptName: 'prompt1',
  description: 'my first prompt',
  defaultVariant: variant1,
  variants: [variant1],
  kmsKey: cmk,
});
```

## Properties

- `inferenceConfiguration`: [PromptInferenceConfiguration](/cdk/api/v2/docs/@aws-cdk_aws-bedrock-alpha.PromptInferenceConfiguration.html) — Inference configuration for the Text Prompt.

  **Default:** No inference configuration provided.

- `model`: [IBedrockInvokable](/cdk/api/v2/docs/@aws-cdk_aws-bedrock-alpha.IBedrockInvokable.html) (required) — The model which is used to run the prompt.

  The model could be a foundation
  model, a custom model, or a provisioned model.

- `promptText`: string (required) — The text prompt.

  Variables are used by enclosing its name with double curly braces
  as in `{{variable_name}}`.

- `promptVariables`: string[] — The variables in the prompt template that can be filled in at runtime.

  **Default:** No variables defined.

- `variantName`: string (required) — The name of the prompt variant.
