Skip to content

Commit 1f29c36

Browse files
committed
docs: add comments and links
1 parent b102317 commit 1f29c36

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

adalflow/adalflow/components/model_client/bedrock_client.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,7 @@ class BedrockAPIClient(ModelClient):
5454
Setup:
5555
1. Install boto3: `pip install boto3`
5656
2. Ensure you have the AWS credentials set up. There are four variables you can optionally set:
57+
Either AWS_PROFILE_NAME or (AWS_REGION_NAME and AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY) are needed
5758
- AWS_PROFILE_NAME: The name of the AWS profile to use.
5859
- AWS_REGION_NAME: The name of the AWS region to use.
5960
- AWS_ACCESS_KEY_ID: The AWS access key ID.
@@ -80,10 +81,9 @@ class BedrockAPIClient(ModelClient):
8081
self.generator = Generator(
8182
model_client=BedrockAPIClient(),
8283
model_kwargs={
83-
"modelId": "anthropic.claude-3-sonnet-20240229-v1:0",
84-
"inferenceConfig": {
85-
"temperature": 0.8
86-
}
84+
"model": "mistral.mistral-7b-instruct-v0:2",
85+
"temperature": 0.8,
86+
"max_tokens": 100
8787
}, template=template
8888
)
8989
@@ -223,6 +223,7 @@ def track_completion_usage(self, completion: Dict) -> CompletionUsage:
223223

224224
def list_models(self, **kwargs):
225225
# Initialize Bedrock client (not runtime)
226+
# Reference: https://docs.aws.amazon.com/bedrock/latest/APIReference/API_ListFoundationModels.html
226227

227228
try:
228229
response = self._client.list_foundation_models(**kwargs)

0 commit comments

Comments
 (0)