Houve alguma modificação na OpenAI? Ao tentar executar o script, obtive o seguinte erro:
You tried to access openai.Audio, but this is no longer supported in openai>=1.0.0 - see the README at https://github.com/openai/openai-python for the API.
You can run openai migrate
to automatically upgrade your codebase to use the 1.0.0 interface.
Alternatively, you can pin your installation to the old version, e.g. pip install openai==0.28
A detailed migration guide is available here: https://github.com/openai/openai-python/discussions/742
codigo_alura) PS C:\Users\XXX\Documents\podcasts> openai migrate Error: Windows is not supported yet in the migration CLI
...
(codigo_alura) PS C:\Users\XXX\Documents\podcasts> pip install openai==0.28 Collecting openai==0.28 Using cached openai-0.28.0-py3-none-any.whl.metadata (13 kB) Collecting requests>=2.20 (from openai==0.28) Using cached requests-2.31.0-py3-none-any.whl.metadata (4.6 kB) Requirement already satisfied: tqdm in c:\users\XXX\documents\podcasts\codigo_alura\lib\site-packages (from openai==0.28) (4.66.1) Collecting aiohttp (from openai==0.28) Using cached aiohttp-3.9.1-cp312-cp312-win_amd64.whl.metadata (7.6 kB)
Building wheel for frozenlist (pyproject.toml) ... error error: subprocess-exited-with-error
× Building wheel for frozenlist (pyproject.toml) did not run successfully. │ exit code: 1 ╰─> [33 lines of output]
no previously-included directories found matching 'docs_build' adding license file 'LICENSE' writing manifest file 'frozenlist.egg-info\SOURCES.txt' copying frozenlist_init_.pyi -> build\lib.win-amd64-cpython-312\frozenlist copying frozenlist_frozenlist.pyx -> build\lib.win-amd64-cpython-312\frozenlist copying frozenlist\py.typed -> build\lib.win-amd64-cpython-312\frozenlist running build_ext building 'frozenlist._frozenlist' extension error: Microsoft Visual C++ 14.0 or greater is required. Get it with "Microsoft C++ Build Tools": https://visualstudio.microsoft.com/visual-cpp-build-tools/ [end of output]
note: This error originates from a subprocess, and is likely not a problem with pip. ERROR: Failed building wheel for frozenlist Building wheel for multidict (pyproject.toml) ... error error: subprocess-exited-with-error