Repository: confident-ai/deepeval
Issue: Unable to generate Red Teaming Data from Synthesizer using Azure as a model
Root cause: Interface Contract Mismatch

I am trying to use generate_red_teaming_goldens using deepeval synthesizer following the documentation (https://docs.confident-ai.com/docs/evaluation-datasets-synthetic-data#3-generating-adversarial-goldens-for-red-teaming), 
however it is not working with either Azure/ Ollama

This is the Traceback I'm getting while trying to run synthesizer for red teaming using Azure as a model..

Traceback (most recent call last):
  File "c:\users\sowvinna1\appdata\local\programs\python\python39\lib\site-packages\uvicorn\protocols\http\httptools_impl.py", line 401, in run_asgi
    result = await app(  # type: ignore[func-returns-value]
  File "c:\users\sowvinna1\appdata\local\programs\python\python39\lib\site-packages\uvicorn\middleware\proxy_headers.py", line 70, in __call__
    return await self.app(scope, receive, send)
  File "c:\users\sowvinna1\appdata\local\programs\python\python39\lib\site-packages\fastapi\applications.py", line 1054, in __call__
    await super().__call__(scope, receive, send)
  File "c:\users\sowvinna1\appdata\local\programs\python\python39\lib\site-packages\starlette\applications.py", line 123, in __call__
    await self.middleware_stack(scope, receive, send)
  File "c:\users\sowvinna1\appdata\local\programs\python\python39\lib\site-packages\starlette\middleware\errors.py", line 186, in __call__
    raise exc
  File "c:\users\sowvinna1\appdata\local\programs\python\python39\lib\site-packages\starlette\middleware\errors.py", line 164, in __call__
    await self.app(scope, receive, _send)
  File "c:\users\sowvinna1\appdata\local\programs\python\python39\lib\site-packages\starlette\middleware\cors.py", line 93, in __call__
    await self.simple_response(scope, receive, send, request_headers=headers)
  File "c:\users\sowvinna1\appdata\local\programs\python\python39\lib\site-packages\starlette\middleware\cors.py", line 148, in simple_response
    await self.app(scope, receive, send)
  File "c:\users\sowvinna1\appdata\local\programs\python\python39\lib\site-packages\starlette\middleware\exceptions.py", line 65, in __call__
    await wrap_app_handling_exceptions(self.app, conn)(scope, receive, send)
  File "c:\users\sowvinna1\appdata\local\programs\python\python39\lib\site-packages\starlette\_exception_handler.py", line 64, in wrapped_app
    raise exc
  File "c:\users\sowvinna1\appdata\local\programs\python\python39\lib\site-packages\starlette\_exception_handler.py", line 53, in wrapped_app
    await app(scope, receive, sender)
  File "c:\users\sowvinna1\appdata\local\programs\python\python39\lib\site-packages\starlette\routing.py", line 754, in __call__
    await self.middleware_stack(scope, receive, send)
  File "c:\users\sowvinna1\appdata\local\programs\python\python39\lib\site-packages\starlette\routing.py", line 774, in app  
    await route.handle(scope, receive, send)
  File "c:\users\sowvinna1\appdata\local\programs\python\python39\lib\site-packages\starlette\routing.py", line 295, in handle
    await self.app(scope, receive, send)
  File "c:\users\sowvinna1\appdata\local\programs\python\python39\lib\site-packages\starlette\routing.py", line 77, in app   
    await wrap_app_handling_exceptions(app, request)(scope, receive, send)
  File "c:\users\sowvinna1\appdata\local\programs\python\python39\lib\site-packages\starlette\_exception_handler.py", line 64, in wrapped_app
    raise exc
  File "c:\users\sowvinna1\appdata\local\programs\python\python39\lib\site-packages\starlette\_exception_handler.py", line 53, in wrapped_app
    await app(scope, receive, sender)
  File "c:\users\sowvinna1\appdata\local\programs\python\python39\lib\site-packages\starlette\routing.py", line 74, in app   
    response = await f(request)
  File "c:\users\sowvinna1\appdata\local\programs\python\python39\lib\site-packages\fastapi\routing.py", line 278, in app    
    raw_response = await run_endpoint_function(
  File "c:\users\sowvinna1\appdata\local\programs\python\python39\lib\site-packages\fastapi\routing.py", line 193, in run_endpoint_function
    return await run_in_threadpool(dependant.call, **values)
  File "c:\users\sowvinna1\appdata\local\programs\python\python39\lib\site-packages\starlette\concurrency.py", line 42, in run_in_threadpool
    return await anyio.to_thread.run_sync(func, *args)
  File "c:\users\sowvinna1\appdata\local\programs\python\python39\lib\site-packages\anyio\to_thread.py", line 33, in run_sync
    return await get_asynclib().run_sync_in_worker_thread(
  File "c:\users\sowvinna1\appdata\local\programs\python\python39\lib\site-packages\anyio\_backends\_asyncio.py", line 877, in run_sync_in_worker_thread
    return await future
  File "c:\users\sowvinna1\appdata\local\programs\python\python39\lib\site-packages\anyio\_backends\_asyncio.py", line 807, in run
    result = context.run(func, *args)
  File "C:\Users\sowvinna1\OneDrive - Publicis Groupe\SGAI\minervaa-deepeval-synthesizer-api\src\main\python\app\main.py", line 40, in synthesize_data
    dataset = synthesize(synthesize_request)
  File "C:\Users\sowvinna1\OneDrive - Publicis Groupe\SGAI\minervaa-deepeval-synthesizer-api\src\main\python\services\data_synthesizer.py", line 56, in synthesize
    adversarial_dataset = dataset_service.generate_adversarial_dataset_from_contexts(
  File "C:\Users\sowvinna1\OneDrive - Publicis Groupe\SGAI\minervaa-deepeval-synthesizer-api\src\main\python\deepeval_agent\datasets.py", line 144, in generate_adversarial_dataset_from_contexts
    dataset.generate_red_teaming_goldens(
  File "c:\users\sowvinna1\appdata\local\programs\python\python39\lib\site-packages\deepeval\dataset\dataset.py", line 459, in generate_red_teaming_goldens
    synthesizer.generate_red_teaming_goldens(
  File "c:\users\sowvinna1\appdata\local\programs\python\python39\lib\site-packages\deepeval\synthesizer\synthesizer.py", line 725, in generate_red_teaming_goldens
    **golden.expected_output, _ = self.a_generate(
TypeError: cannot unpack non-iterable coroutine object**

![image](https://github.com/user-attachments/assets/cc62c14a-2cea-4510-b302-7aa544d62ffe)
When I am trying to debug,
getting issue in line 125., from deepeval.synthesizer.