tests.system.amazon.aws.example_bedrock_batch_inference

属性

log

ROLE_ARN_KEY

sys_test_context_task

DAG_ID

CLAUDE_MODEL_ID

ANTHROPIC_VERSION

MIN_NUM_PROMPTS

PROMPT_TEMPLATE

test_context

test_run

函数

generate_prompts(_env_id, _bucket, _key)

Bedrock 批量推理需要 S3 存储桶中有一个或多个 jsonl 格式的文件。

stop_batch_inference(job_arn)

模块内容

tests.system.amazon.aws.example_bedrock_batch_inference.log[source]
tests.system.amazon.aws.example_bedrock_batch_inference.ROLE_ARN_KEY = 'ROLE_ARN'[source]
tests.system.amazon.aws.example_bedrock_batch_inference.sys_test_context_task[source]
tests.system.amazon.aws.example_bedrock_batch_inference.DAG_ID = 'example_bedrock_batch_inference'[source]
tests.system.amazon.aws.example_bedrock_batch_inference.CLAUDE_MODEL_ID = 'anthropic.claude-3-sonnet-20240229-v1:0'[source]
tests.system.amazon.aws.example_bedrock_batch_inference.ANTHROPIC_VERSION = 'bedrock-2023-05-31'[source]
tests.system.amazon.aws.example_bedrock_batch_inference.MIN_NUM_PROMPTS = 300[source]
tests.system.amazon.aws.example_bedrock_batch_inference.PROMPT_TEMPLATE = 'Even numbers are red. Odd numbers are blue. What color is {n}?'[source]
tests.system.amazon.aws.example_bedrock_batch_inference.generate_prompts(_env_id, _bucket, _key)[source]

Bedrock 批量推理需要 S3 存储桶中有一个或多个 jsonl 格式的文件。

JSONL 格式要求每行一个序列化的 JSON 对象,每个对象对应一个提示。

tests.system.amazon.aws.example_bedrock_batch_inference.stop_batch_inference(job_arn)[source]
tests.system.amazon.aws.example_bedrock_batch_inference.test_context[source]
tests.system.amazon.aws.example_bedrock_batch_inference.test_run[source]

此条目是否有帮助?