diff --git a/README.md b/README.md index 7d48bd5..e494591 100644 --- a/README.md +++ b/README.md @@ -48,6 +48,10 @@ [2023/11/20] airllm Initial verion! +## Star History + +[![Star History Chart](https://api.star-history.com/svg?repos=lyogavin/airllm&type=Timeline)](https://star-history.com/#lyogavin/airllm&Timeline) + ## Table of Contents * [Quick start](#quickstart) diff --git a/air_llm/setup.py b/air_llm/setup.py index 61d3aed..fcfead4 100644 --- a/air_llm/setup.py +++ b/air_llm/setup.py @@ -1,3 +1,4 @@ +import sys import setuptools from setuptools.command.install import install import subprocess @@ -6,7 +7,10 @@ import subprocess class PostInstallCommand(install): def run(self): install.run(self) - subprocess.check_call(["pip", "install", "--upgrade", "transformers"]) + try: + subprocess.check_call([sys.executable, "-m", "pip", "install", "--upgrade", "transformers"]) + except subprocess.CalledProcessError: + print("Warning: Unable to upgrade transformers package. Please upgrade manually.") # Windows uses a different default encoding (use a consistent encoding) with open("README.md", "r", encoding="utf-8") as fh: