vincbeck commented on code in PR #72608:
URL: https://github.com/apache/airflow/pull/72608#discussion_r4094399242


##########
providers/amazon/src/airflow/providers/amazon/aws/operators/bedrock.py:
##########
@@ -762,10 +769,24 @@ def execute_complete(self, context: Context, event: 
dict[str, Any] | None = None
         return validated_event["knowledge_base_id"]
 
     def execute(self, context: Context) -> str:
-        knowledge_base_config = {
-            "type": "VECTOR",
-            "vectorKnowledgeBaseConfiguration": {"embeddingModelArn": 
self.embedding_model_arn},
-        }
+        if self.role_arn is None:
+            raise ValueError("`role_arn` must be specified to create a 
knowledge base.")

Review Comment:
   Why marking `role_arn` as optional parameter in its definition but not 
allowing it in the execution?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to