We can use the following method to dynamically install and use third party libraries and packges during AutoProgram. We should also add a flag to from_precompiled that specifies whether we should try to install third party modules or assume they are already imported.
import importlib
import subprocess
import sys
cmd = ["uv", "pip", "install", "-r", "scratch/pyproject.toml"]
subprocess.run(cmd, check=True)
importlib.invalidate_caches()
import dotenv
import humanize
print(humanize.intcomma(12345))
We can use the following method to dynamically install and use third party libraries and packges during AutoProgram. We should also add a flag to
from_precompiledthat specifies whether we should try to install third party modules or assume they are already imported.