We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 10dde0f commit 86cd890Copy full SHA for 86cd890
sdk/ai/azure-ai-generative/azure/ai/generative/evaluate/_local_code_handler.py
@@ -27,7 +27,16 @@ def generate_prediction_data(self):
27
prediction_data = []
28
test_data = self.get_test_data_as_jsonl()
29
30
+ import inspect
31
+ is_asset_async = False
32
+ if inspect.iscoroutinefunction(self.asset):
33
+ is_asset_async = True
34
+ import asyncio
35
+
36
for d in test_data:
- prediction_data.append(self.asset(**d))
37
+ prediction_data.append(
38
+ asyncio.run(self.asset(**d)) if is_asset_async else self.asset(**d)
39
+ )
40
41
42
return prediction_data
0 commit comments