MacBook Pro (15 英寸,2018) 运行 ChatGLM3-6B 大模型

接上篇 在 Mac 上加速 PyTorch 训练,准备完 MPS 环境之后,开始在本地体验 ChatGLM3-6B 模型。

一、下载本仓库:

(base) markvivv@MBP dev % git clone https://github.com/THUDM/ChatGLM3

Cloning into 'ChatGLM3'...
remote: Enumerating objects: 1053, done.
remote: Counting objects: 100% (634/634), done.
remote: Compressing objects: 100% (240/240), done.
remote: Total 1053 (delta 461), reused 466 (delta 393), pack-reused 419
Receiving objects: 100% (1053/1053), 17.22 MiB | 983.00 KiB/s, done.
Resolving deltas: 100% (608/608), done.

(base) markvivv@MBP dev % cd ChatGLM3

二、然后使用 pip 安装依赖:

(base) markvivv@MBP ChatGLM3 % pip install -r requirements.txt
Collecting protobuf>=4.25.2 (from -r requirements.txt (line 3))
  Downloading protobuf-4.25.2-cp37-abi3-macosx_10_9_universal2.whl.metadata (541 bytes)
Collecting transformers>=4.37.1 (from -r requirements.txt (line 4))
  Downloading transformers-4.37.2-py3-none-any.whl.metadata (129 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 129.4/129.4 kB 183.4 kB/s eta 0:00:00
Collecting tokenizers>=0.15.0 (from -r requirements.txt (line 5))
  Downloading tokenizers-0.15.1-cp311-cp311-macosx_10_12_x86_64.whl.metadata (6.7 kB)
Collecting cpm_kernels>=1.0.11 (from -r requirements.txt (line 6))
  Downloading cpm_kernels-1.0.11-py3-none-any.whl (416 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 416.6/416.6 kB 764.4 kB/s eta 0:00:00
Requirement already satisfied: torch>=2.1.0 in /Users/markvivv/dev/miniconda3/lib/python3.11/site-packages (from -r requirements.txt (line 7)) (2.3.0.dev20240129)
Collecting gradio>=4.16.0 (from -r requirements.txt (line 8))
  Downloading gradio-4.16.0-py3-none-any.whl.metadata (15 kB)
Collecting sentencepiece>=0.1.99 (from -r requirements.txt (line 9))
  Downloading sentencepiece-0.1.99-cp311-cp311-macosx_10_9_x86_64.whl (1.2 MB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 1.2/1.2 MB 749.3 kB/s eta 0:00:00
Collecting sentence_transformers>=2.2.2 (from -r requirements.txt (line 10))
  Downloading sentence_transformers-2.3.1-py3-none-any.whl.metadata (11 kB)
Collecting accelerate>=0.26.1 (from -r requirements.txt (line 11))
  Downloading accelerate-0.26.1-py3-none-any.whl.metadata (18 kB)
Collecting streamlit>=1.30.0 (from -r requirements.txt (line 12))
  Downloading streamlit-1.30.0-py2.py3-none-any.whl.metadata (8.2 kB)
Collecting fastapi>=0.109.0 (from -r requirements.txt (line 13))
  Downloading fastapi-0.109.0-py3-none-any.whl.metadata (24 kB)
Collecting loguru~=0.7.2 (from -r requirements.txt (line 14))
  Downloading loguru-0.7.2-py3-none-any.whl.metadata (23 kB)
Collecting mdtex2html>=1.3.0 (from -r requirements.txt (line 15))
  Downloading mdtex2html-1.3.0-py3-none-any.whl.metadata (4.1 kB)
Collecting latex2mathml>=3.77.0 (from -r requirements.txt (line 16))
  Downloading latex2mathml-3.77.0-py3-none-any.whl.metadata (14 kB)
Collecting openai>=1.10.0 (from -r requirements.txt (line 20))
  Downloading openai-1.10.0-py3-none-any.whl.metadata (18 kB)
Collecting zhipuai>=2.0.1 (from -r requirements.txt (line 21))
  Downloading zhipuai-2.0.1-py3-none-any.whl.metadata (2.7 kB)
Collecting pydantic>=2.5.3 (from -r requirements.txt (line 23))
  Downloading pydantic-2.6.0-py3-none-any.whl.metadata (81 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 81.8/81.8 kB 86.5 kB/s eta 0:00:00
Collecting sse-starlette>=2.0.0 (from -r requirements.txt (line 24))
  Downloading sse_starlette-2.0.0-py3-none-any.whl.metadata (5.4 kB)
Collecting uvicorn>=0.27.0 (from -r requirements.txt (line 25))
  Downloading uvicorn-0.27.0.post1-py3-none-any.whl.metadata (6.4 kB)
Collecting timm>=0.9.12 (from -r requirements.txt (line 26))
  Downloading timm-0.9.12-py3-none-any.whl.metadata (60 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 60.6/60.6 kB 139.8 kB/s eta 0:00:00
Collecting tiktoken>=0.5.2 (from -r requirements.txt (line 27))
  Downloading tiktoken-0.5.2-cp311-cp311-macosx_10_9_x86_64.whl.metadata (6.6 kB)
Collecting langchain>=0.1.4 (from -r requirements.txt (line 31))
  Downloading langchain-0.1.4-py3-none-any.whl.metadata (13 kB)
Collecting langchainhub>=0.1.14 (from -r requirements.txt (line 32))
  Downloading langchainhub-0.1.14-py3-none-any.whl.metadata (478 bytes)
Collecting arxiv>=2.1.0 (from -r requirements.txt (line 33))
  Downloading arxiv-2.1.0-py3-none-any.whl.metadata (6.1 kB)
Requirement already satisfied: filelock in /Users/markvivv/dev/miniconda3/lib/python3.11/site-packages (from transformers>=4.37.1->-r requirements.txt (line 4)) (3.13.1)
Collecting huggingface-hub<1.0,>=0.19.3 (from transformers>=4.37.1->-r requirements.txt (line 4))
  Downloading huggingface_hub-0.20.3-py3-none-any.whl.metadata (12 kB)
Requirement already satisfied: numpy>=1.17 in /Users/markvivv/dev/miniconda3/lib/python3.11/site-packages (from transformers>=4.37.1->-r requirements.txt (line 4)) (1.26.3)
Requirement already satisfied: packaging>=20.0 in /Users/markvivv/dev/miniconda3/lib/python3.11/site-packages (from transformers>=4.37.1->-r requirements.txt (line 4)) (23.1)
Requirement already satisfied: pyyaml>=5.1 in /Users/markvivv/dev/miniconda3/lib/python3.11/site-packages (from transformers>=4.37.1->-r requirements.txt (line 4)) (6.0.1)
Collecting regex!=2019.12.17 (from transformers>=4.37.1->-r requirements.txt (line 4))
  Downloading regex-2023.12.25-cp311-cp311-macosx_10_9_x86_64.whl.metadata (40 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 40.9/40.9 kB 53.9 kB/s eta 0:00:00
Requirement already satisfied: requests in /Users/markvivv/dev/miniconda3/lib/python3.11/site-packages (from transformers>=4.37.1->-r requirements.txt (line 4)) (2.31.0)
Collecting safetensors>=0.4.1 (from transformers>=4.37.1->-r requirements.txt (line 4))
  Downloading safetensors-0.4.2-cp311-cp311-macosx_10_12_x86_64.whl.metadata (3.8 kB)
Requirement already satisfied: tqdm>=4.27 in /Users/markvivv/dev/miniconda3/lib/python3.11/site-packages (from transformers>=4.37.1->-r requirements.txt (line 4)) (4.65.0)
Requirement already satisfied: typing-extensions>=4.8.0 in /Users/markvivv/dev/miniconda3/lib/python3.11/site-packages (from torch>=2.1.0->-r requirements.txt (line 7)) (4.9.0)
Requirement already satisfied: sympy in /Users/markvivv/dev/miniconda3/lib/python3.11/site-packages (from torch>=2.1.0->-r requirements.txt (line 7)) (1.12)
Requirement already satisfied: networkx in /Users/markvivv/dev/miniconda3/lib/python3.11/site-packages (from torch>=2.1.0->-r requirements.txt (line 7)) (3.1)
Requirement already satisfied: jinja2 in /Users/markvivv/dev/miniconda3/lib/python3.11/site-packages (from torch>=2.1.0->-r requirements.txt (line 7)) (3.1.2)
Collecting fsspec (from torch>=2.1.0->-r requirements.txt (line 7))
  Downloading fsspec-2023.12.2-py3-none-any.whl.metadata (6.8 kB)
Collecting aiofiles<24.0,>=22.0 (from gradio>=4.16.0->-r requirements.txt (line 8))
  Downloading aiofiles-23.2.1-py3-none-any.whl.metadata (9.7 kB)
Collecting altair<6.0,>=4.2.0 (from gradio>=4.16.0->-r requirements.txt (line 8))
  Downloading altair-5.2.0-py3-none-any.whl.metadata (8.7 kB)
Collecting ffmpy (from gradio>=4.16.0->-r requirements.txt (line 8))
  Downloading ffmpy-0.3.1.tar.gz (5.5 kB)
  Preparing metadata (setup.py) ... done
Collecting gradio-client==0.8.1 (from gradio>=4.16.0->-r requirements.txt (line 8))
  Downloading gradio_client-0.8.1-py3-none-any.whl.metadata (7.1 kB)
Collecting httpx (from gradio>=4.16.0->-r requirements.txt (line 8))
  Downloading httpx-0.26.0-py3-none-any.whl.metadata (7.6 kB)
Collecting importlib-resources<7.0,>=1.3 (from gradio>=4.16.0->-r requirements.txt (line 8))
  Downloading importlib_resources-6.1.1-py3-none-any.whl.metadata (4.1 kB)
Requirement already satisfied: markupsafe~=2.0 in /Users/markvivv/dev/miniconda3/lib/python3.11/site-packages (from gradio>=4.16.0->-r requirements.txt (line 8)) (2.1.3)
Collecting matplotlib~=3.0 (from gradio>=4.16.0->-r requirements.txt (line 8))
  Downloading matplotlib-3.8.2-cp311-cp311-macosx_10_12_x86_64.whl.metadata (5.8 kB)
Collecting orjson~=3.0 (from gradio>=4.16.0->-r requirements.txt (line 8))
  Downloading orjson-3.9.12-cp311-cp311-macosx_10_15_x86_64.macosx_11_0_arm64.macosx_10_15_universal2.whl.metadata (49 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 49.4/49.4 kB 181.3 kB/s eta 0:00:00
Collecting pandas<3.0,>=1.0 (from gradio>=4.16.0->-r requirements.txt (line 8))
  Downloading pandas-2.2.0-cp311-cp311-macosx_10_9_x86_64.whl.metadata (19 kB)
Requirement already satisfied: pillow<11.0,>=8.0 in /Users/markvivv/dev/miniconda3/lib/python3.11/site-packages (from gradio>=4.16.0->-r requirements.txt (line 8)) (9.3.0)
Collecting pydub (from gradio>=4.16.0->-r requirements.txt (line 8))
  Downloading pydub-0.25.1-py2.py3-none-any.whl (32 kB)
Collecting python-multipart (from gradio>=4.16.0->-r requirements.txt (line 8))
  Downloading python_multipart-0.0.6-py3-none-any.whl (45 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 45.7/45.7 kB 316.1 kB/s eta 0:00:00
Collecting ruff>=0.1.7 (from gradio>=4.16.0->-r requirements.txt (line 8))
  Downloading ruff-0.1.15-py3-none-macosx_10_12_x86_64.whl.metadata (22 kB)
Collecting semantic-version~=2.0 (from gradio>=4.16.0->-r requirements.txt (line 8))
  Downloading semantic_version-2.10.0-py2.py3-none-any.whl (15 kB)
Collecting tomlkit==0.12.0 (from gradio>=4.16.0->-r requirements.txt (line 8))
  Downloading tomlkit-0.12.0-py3-none-any.whl.metadata (2.7 kB)
Collecting typer<1.0,>=0.9 (from typer[all]<1.0,>=0.9->gradio>=4.16.0->-r requirements.txt (line 8))
  Downloading typer-0.9.0-py3-none-any.whl (45 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 45.9/45.9 kB 285.8 kB/s eta 0:00:00
Collecting websockets<12.0,>=10.0 (from gradio-client==0.8.1->gradio>=4.16.0->-r requirements.txt (line 8))
  Downloading websockets-11.0.3-cp311-cp311-macosx_10_9_x86_64.whl (120 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 121.0/121.0 kB 227.9 kB/s eta 0:00:00
Collecting scikit-learn (from sentence_transformers>=2.2.2->-r requirements.txt (line 10))
  Downloading scikit_learn-1.4.0-1-cp311-cp311-macosx_10_9_x86_64.whl.metadata (11 kB)
Collecting scipy (from sentence_transformers>=2.2.2->-r requirements.txt (line 10))
  Downloading scipy-1.12.0-cp311-cp311-macosx_10_9_x86_64.whl.metadata (60 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 60.4/60.4 kB 638.2 kB/s eta 0:00:00
Collecting nltk (from sentence_transformers>=2.2.2->-r requirements.txt (line 10))
  Downloading nltk-3.8.1-py3-none-any.whl (1.5 MB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 1.5/1.5 MB 640.4 kB/s eta 0:00:00
Collecting psutil (from accelerate>=0.26.1->-r requirements.txt (line 11))
  Downloading psutil-5.9.8-cp36-abi3-macosx_10_9_x86_64.whl.metadata (21 kB)
Collecting blinker<2,>=1.0.0 (from streamlit>=1.30.0->-r requirements.txt (line 12))
  Downloading blinker-1.7.0-py3-none-any.whl.metadata (1.9 kB)
Collecting cachetools<6,>=4.0 (from streamlit>=1.30.0->-r requirements.txt (line 12))
  Downloading cachetools-5.3.2-py3-none-any.whl.metadata (5.2 kB)
Collecting click<9,>=7.0 (from streamlit>=1.30.0->-r requirements.txt (line 12))
  Downloading click-8.1.7-py3-none-any.whl.metadata (3.0 kB)
Collecting importlib-metadata<8,>=1.4 (from streamlit>=1.30.0->-r requirements.txt (line 12))
  Downloading importlib_metadata-7.0.1-py3-none-any.whl.metadata (4.9 kB)
Collecting pyarrow>=6.0 (from streamlit>=1.30.0->-r requirements.txt (line 12))
  Downloading pyarrow-15.0.0-cp311-cp311-macosx_10_15_x86_64.whl.metadata (3.0 kB)
Collecting python-dateutil<3,>=2.7.3 (from streamlit>=1.30.0->-r requirements.txt (line 12))
  Downloading python_dateutil-2.8.2-py2.py3-none-any.whl (247 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 247.7/247.7 kB 1.0 MB/s eta 0:00:00
Collecting rich<14,>=10.14.0 (from streamlit>=1.30.0->-r requirements.txt (line 12))
  Downloading rich-13.7.0-py3-none-any.whl.metadata (18 kB)
Collecting tenacity<9,>=8.1.0 (from streamlit>=1.30.0->-r requirements.txt (line 12))
  Downloading tenacity-8.2.3-py3-none-any.whl.metadata (1.0 kB)
Collecting toml<2,>=0.10.1 (from streamlit>=1.30.0->-r requirements.txt (line 12))
  Downloading toml-0.10.2-py2.py3-none-any.whl (16 kB)
Collecting tzlocal<6,>=1.1 (from streamlit>=1.30.0->-r requirements.txt (line 12))
  Downloading tzlocal-5.2-py3-none-any.whl.metadata (7.8 kB)
Collecting validators<1,>=0.2 (from streamlit>=1.30.0->-r requirements.txt (line 12))
  Downloading validators-0.22.0-py3-none-any.whl.metadata (4.7 kB)
Collecting gitpython!=3.1.19,<4,>=3.0.7 (from streamlit>=1.30.0->-r requirements.txt (line 12))
  Downloading GitPython-3.1.41-py3-none-any.whl.metadata (14 kB)
Collecting pydeck<1,>=0.8.0b4 (from streamlit>=1.30.0->-r requirements.txt (line 12))
  Downloading pydeck-0.8.1b0-py2.py3-none-any.whl (4.8 MB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 4.8/4.8 MB 1.8 MB/s eta 0:00:00
Collecting tornado<7,>=6.0.3 (from streamlit>=1.30.0->-r requirements.txt (line 12))
  Downloading tornado-6.4-cp38-abi3-macosx_10_9_x86_64.whl.metadata (2.5 kB)
Collecting starlette<0.36.0,>=0.35.0 (from fastapi>=0.109.0->-r requirements.txt (line 13))
  Downloading starlette-0.35.1-py3-none-any.whl.metadata (5.8 kB)
Collecting markdown (from mdtex2html>=1.3.0->-r requirements.txt (line 15))
  Downloading Markdown-3.5.2-py3-none-any.whl.metadata (7.0 kB)
Collecting anyio<5,>=3.5.0 (from openai>=1.10.0->-r requirements.txt (line 20))
  Downloading anyio-4.2.0-py3-none-any.whl.metadata (4.6 kB)
Requirement already satisfied: distro<2,>=1.7.0 in /Users/markvivv/dev/miniconda3/lib/python3.11/site-packages (from openai>=1.10.0->-r requirements.txt (line 20)) (1.8.0)
Collecting sniffio (from openai>=1.10.0->-r requirements.txt (line 20))
  Downloading sniffio-1.3.0-py3-none-any.whl (10 kB)
Collecting pyjwt~=2.8.0 (from zhipuai>=2.0.1->-r requirements.txt (line 21))
  Downloading PyJWT-2.8.0-py3-none-any.whl.metadata (4.2 kB)
Collecting annotated-types>=0.4.0 (from pydantic>=2.5.3->-r requirements.txt (line 23))
  Downloading annotated_types-0.6.0-py3-none-any.whl.metadata (12 kB)
Collecting pydantic-core==2.16.1 (from pydantic>=2.5.3->-r requirements.txt (line 23))
  Downloading pydantic_core-2.16.1-cp311-cp311-macosx_10_12_x86_64.whl.metadata (6.5 kB)
Collecting h11>=0.8 (from uvicorn>=0.27.0->-r requirements.txt (line 25))
  Downloading h11-0.14.0-py3-none-any.whl (58 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 58.3/58.3 kB 135.9 kB/s eta 0:00:00
Requirement already satisfied: torchvision in /Users/markvivv/dev/miniconda3/lib/python3.11/site-packages (from timm>=0.9.12->-r requirements.txt (line 26)) (0.18.0.dev20240129)
Collecting SQLAlchemy<3,>=1.4 (from langchain>=0.1.4->-r requirements.txt (line 31))
  Downloading SQLAlchemy-2.0.25-cp311-cp311-macosx_10_9_x86_64.whl.metadata (9.6 kB)
Collecting aiohttp<4.0.0,>=3.8.3 (from langchain>=0.1.4->-r requirements.txt (line 31))
  Downloading aiohttp-3.9.3-cp311-cp311-macosx_10_9_x86_64.whl.metadata (7.4 kB)
Collecting dataclasses-json<0.7,>=0.5.7 (from langchain>=0.1.4->-r requirements.txt (line 31))
  Downloading dataclasses_json-0.6.3-py3-none-any.whl.metadata (25 kB)
Collecting jsonpatch<2.0,>=1.33 (from langchain>=0.1.4->-r requirements.txt (line 31))
  Downloading jsonpatch-1.33-py2.py3-none-any.whl.metadata (3.0 kB)
Collecting langchain-community<0.1,>=0.0.14 (from langchain>=0.1.4->-r requirements.txt (line 31))
  Downloading langchain_community-0.0.16-py3-none-any.whl.metadata (7.8 kB)
Collecting langchain-core<0.2,>=0.1.16 (from langchain>=0.1.4->-r requirements.txt (line 31))
  Downloading langchain_core-0.1.17-py3-none-any.whl.metadata (6.0 kB)
Collecting langsmith<0.1,>=0.0.83 (from langchain>=0.1.4->-r requirements.txt (line 31))
  Downloading langsmith-0.0.85-py3-none-any.whl.metadata (10 kB)
Collecting types-requests<3.0.0.0,>=2.31.0.2 (from langchainhub>=0.1.14->-r requirements.txt (line 32))
  Downloading types_requests-2.31.0.20240125-py3-none-any.whl.metadata (1.8 kB)
Collecting feedparser==6.0.10 (from arxiv>=2.1.0->-r requirements.txt (line 33))
  Downloading feedparser-6.0.10-py3-none-any.whl (81 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 81.1/81.1 kB 243.9 kB/s eta 0:00:00
Collecting sgmllib3k (from feedparser==6.0.10->arxiv>=2.1.0->-r requirements.txt (line 33))
  Downloading sgmllib3k-1.0.0.tar.gz (5.8 kB)
  Preparing metadata (setup.py) ... done
Requirement already satisfied: charset-normalizer<4,>=2 in /Users/markvivv/dev/miniconda3/lib/python3.11/site-packages (from requests->transformers>=4.37.1->-r requirements.txt (line 4)) (2.0.4)
Requirement already satisfied: idna<4,>=2.5 in /Users/markvivv/dev/miniconda3/lib/python3.11/site-packages (from requests->transformers>=4.37.1->-r requirements.txt (line 4)) (3.4)
Requirement already satisfied: urllib3<3,>=1.21.1 in /Users/markvivv/dev/miniconda3/lib/python3.11/site-packages (from requests->transformers>=4.37.1->-r requirements.txt (line 4)) (1.26.18)
Requirement already satisfied: certifi>=2017.4.17 in /Users/markvivv/dev/miniconda3/lib/python3.11/site-packages (from requests->transformers>=4.37.1->-r requirements.txt (line 4)) (2023.11.17)
Collecting aiosignal>=1.1.2 (from aiohttp<4.0.0,>=3.8.3->langchain>=0.1.4->-r requirements.txt (line 31))
  Downloading aiosignal-1.3.1-py3-none-any.whl (7.6 kB)
Collecting attrs>=17.3.0 (from aiohttp<4.0.0,>=3.8.3->langchain>=0.1.4->-r requirements.txt (line 31))
  Downloading attrs-23.2.0-py3-none-any.whl.metadata (9.5 kB)
Collecting frozenlist>=1.1.1 (from aiohttp<4.0.0,>=3.8.3->langchain>=0.1.4->-r requirements.txt (line 31))
  Downloading frozenlist-1.4.1-cp311-cp311-macosx_10_9_x86_64.whl.metadata (12 kB)
Collecting multidict<7.0,>=4.5 (from aiohttp<4.0.0,>=3.8.3->langchain>=0.1.4->-r requirements.txt (line 31))
  Downloading multidict-6.0.4-cp311-cp311-macosx_10_9_x86_64.whl (29 kB)
Collecting yarl<2.0,>=1.0 (from aiohttp<4.0.0,>=3.8.3->langchain>=0.1.4->-r requirements.txt (line 31))
  Downloading yarl-1.9.4-cp311-cp311-macosx_10_9_x86_64.whl.metadata (31 kB)
Collecting jsonschema>=3.0 (from altair<6.0,>=4.2.0->gradio>=4.16.0->-r requirements.txt (line 8))
  Downloading jsonschema-4.21.1-py3-none-any.whl.metadata (7.8 kB)
Collecting toolz (from altair<6.0,>=4.2.0->gradio>=4.16.0->-r requirements.txt (line 8))
  Downloading toolz-0.12.1-py3-none-any.whl.metadata (5.1 kB)
Collecting marshmallow<4.0.0,>=3.18.0 (from dataclasses-json<0.7,>=0.5.7->langchain>=0.1.4->-r requirements.txt (line 31))
  Downloading marshmallow-3.20.2-py3-none-any.whl.metadata (7.5 kB)
Collecting typing-inspect<1,>=0.4.0 (from dataclasses-json<0.7,>=0.5.7->langchain>=0.1.4->-r requirements.txt (line 31))
  Downloading typing_inspect-0.9.0-py3-none-any.whl.metadata (1.5 kB)
Collecting gitdb<5,>=4.0.1 (from gitpython!=3.1.19,<4,>=3.0.7->streamlit>=1.30.0->-r requirements.txt (line 12))
  Downloading gitdb-4.0.11-py3-none-any.whl.metadata (1.2 kB)
Collecting httpcore==1.* (from httpx->gradio>=4.16.0->-r requirements.txt (line 8))
  Downloading httpcore-1.0.2-py3-none-any.whl.metadata (20 kB)
Collecting zipp>=0.5 (from importlib-metadata<8,>=1.4->streamlit>=1.30.0->-r requirements.txt (line 12))
  Downloading zipp-3.17.0-py3-none-any.whl.metadata (3.7 kB)
Requirement already satisfied: jsonpointer>=1.9 in /Users/markvivv/dev/miniconda3/lib/python3.11/site-packages (from jsonpatch<2.0,>=1.33->langchain>=0.1.4->-r requirements.txt (line 31)) (2.1)
Collecting packaging>=20.0 (from transformers>=4.37.1->-r requirements.txt (line 4))
  Downloading packaging-23.2-py3-none-any.whl.metadata (3.2 kB)
Collecting contourpy>=1.0.1 (from matplotlib~=3.0->gradio>=4.16.0->-r requirements.txt (line 8))
  Downloading contourpy-1.2.0-cp311-cp311-macosx_10_9_x86_64.whl.metadata (5.8 kB)
Collecting cycler>=0.10 (from matplotlib~=3.0->gradio>=4.16.0->-r requirements.txt (line 8))
  Downloading cycler-0.12.1-py3-none-any.whl.metadata (3.8 kB)
Collecting fonttools>=4.22.0 (from matplotlib~=3.0->gradio>=4.16.0->-r requirements.txt (line 8))
  Downloading fonttools-4.47.2-cp311-cp311-macosx_10_9_x86_64.whl.metadata (157 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 157.6/157.6 kB 109.2 kB/s eta 0:00:00
Collecting kiwisolver>=1.3.1 (from matplotlib~=3.0->gradio>=4.16.0->-r requirements.txt (line 8))
  Downloading kiwisolver-1.4.5-cp311-cp311-macosx_10_9_x86_64.whl.metadata (6.4 kB)
Collecting pyparsing>=2.3.1 (from matplotlib~=3.0->gradio>=4.16.0->-r requirements.txt (line 8))
  Downloading pyparsing-3.1.1-py3-none-any.whl.metadata (5.1 kB)
Collecting pytz>=2020.1 (from pandas<3.0,>=1.0->gradio>=4.16.0->-r requirements.txt (line 8))
  Downloading pytz-2023.4-py2.py3-none-any.whl.metadata (22 kB)
Collecting tzdata>=2022.7 (from pandas<3.0,>=1.0->gradio>=4.16.0->-r requirements.txt (line 8))
  Downloading tzdata-2023.4-py2.py3-none-any.whl.metadata (1.4 kB)
Collecting six>=1.5 (from python-dateutil<3,>=2.7.3->streamlit>=1.30.0->-r requirements.txt (line 12))
  Downloading six-1.16.0-py2.py3-none-any.whl (11 kB)
Collecting markdown-it-py>=2.2.0 (from rich<14,>=10.14.0->streamlit>=1.30.0->-r requirements.txt (line 12))
  Downloading markdown_it_py-3.0.0-py3-none-any.whl.metadata (6.9 kB)
Collecting pygments<3.0.0,>=2.13.0 (from rich<14,>=10.14.0->streamlit>=1.30.0->-r requirements.txt (line 12))
  Downloading pygments-2.17.2-py3-none-any.whl.metadata (2.6 kB)
Collecting greenlet!=0.4.17 (from SQLAlchemy<3,>=1.4->langchain>=0.1.4->-r requirements.txt (line 31))
  Downloading greenlet-3.0.3.tar.gz (182 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 182.0/182.0 kB 303.3 kB/s eta 0:00:00
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
  Installing backend dependencies ... done
  Preparing metadata (pyproject.toml) ... done
Collecting colorama<0.5.0,>=0.4.3 (from typer[all]<1.0,>=0.9->gradio>=4.16.0->-r requirements.txt (line 8))
  Downloading colorama-0.4.6-py2.py3-none-any.whl (25 kB)
Collecting shellingham<2.0.0,>=1.3.0 (from typer[all]<1.0,>=0.9->gradio>=4.16.0->-r requirements.txt (line 8))
  Downloading shellingham-1.5.4-py2.py3-none-any.whl.metadata (3.5 kB)
Collecting urllib3<3,>=1.21.1 (from requests->transformers>=4.37.1->-r requirements.txt (line 4))
  Downloading urllib3-2.2.0-py3-none-any.whl.metadata (6.4 kB)
Collecting joblib (from nltk->sentence_transformers>=2.2.2->-r requirements.txt (line 10))
  Downloading joblib-1.3.2-py3-none-any.whl.metadata (5.4 kB)
Collecting threadpoolctl>=2.0.0 (from scikit-learn->sentence_transformers>=2.2.2->-r requirements.txt (line 10))
  Downloading threadpoolctl-3.2.0-py3-none-any.whl.metadata (10.0 kB)
Requirement already satisfied: mpmath>=0.19 in /Users/markvivv/dev/miniconda3/lib/python3.11/site-packages (from sympy->torch>=2.1.0->-r requirements.txt (line 7)) (1.2.1)
Collecting smmap<6,>=3.0.1 (from gitdb<5,>=4.0.1->gitpython!=3.1.19,<4,>=3.0.7->streamlit>=1.30.0->-r requirements.txt (line 12))
  Downloading smmap-5.0.1-py3-none-any.whl.metadata (4.3 kB)
Collecting jsonschema-specifications>=2023.03.6 (from jsonschema>=3.0->altair<6.0,>=4.2.0->gradio>=4.16.0->-r requirements.txt (line 8))
  Downloading jsonschema_specifications-2023.12.1-py3-none-any.whl.metadata (3.0 kB)
Collecting referencing>=0.28.4 (from jsonschema>=3.0->altair<6.0,>=4.2.0->gradio>=4.16.0->-r requirements.txt (line 8))
  Downloading referencing-0.33.0-py3-none-any.whl.metadata (2.7 kB)
Collecting rpds-py>=0.7.1 (from jsonschema>=3.0->altair<6.0,>=4.2.0->gradio>=4.16.0->-r requirements.txt (line 8))
  Downloading rpds_py-0.17.1-cp311-cp311-macosx_10_12_x86_64.whl.metadata (4.1 kB)
Collecting mdurl~=0.1 (from markdown-it-py>=2.2.0->rich<14,>=10.14.0->streamlit>=1.30.0->-r requirements.txt (line 12))
  Downloading mdurl-0.1.2-py3-none-any.whl (10.0 kB)
Collecting mypy-extensions>=0.3.0 (from typing-inspect<1,>=0.4.0->dataclasses-json<0.7,>=0.5.7->langchain>=0.1.4->-r requirements.txt (line 31))
  Downloading mypy_extensions-1.0.0-py3-none-any.whl (4.7 kB)
Downloading protobuf-4.25.2-cp37-abi3-macosx_10_9_universal2.whl (394 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 394.2/394.2 kB 489.0 kB/s eta 0:00:00
Downloading transformers-4.37.2-py3-none-any.whl (8.4 MB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 8.4/8.4 MB 1.1 MB/s eta 0:00:00
Downloading tokenizers-0.15.1-cp311-cp311-macosx_10_12_x86_64.whl (2.6 MB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 2.6/2.6 MB 710.7 kB/s eta 0:00:00
Downloading gradio-4.16.0-py3-none-any.whl (16.7 MB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 16.7/16.7 MB 2.0 MB/s eta 0:00:00
Downloading gradio_client-0.8.1-py3-none-any.whl (305 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 305.2/305.2 kB 1.1 MB/s eta 0:00:00
Downloading tomlkit-0.12.0-py3-none-any.whl (37 kB)
Downloading sentence_transformers-2.3.1-py3-none-any.whl (132 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 132.8/132.8 kB 1.8 MB/s eta 0:00:00
Downloading accelerate-0.26.1-py3-none-any.whl (270 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 270.9/270.9 kB 1.5 MB/s eta 0:00:00
Downloading streamlit-1.30.0-py2.py3-none-any.whl (8.4 MB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 8.4/8.4 MB 1.8 MB/s eta 0:00:00
Downloading fastapi-0.109.0-py3-none-any.whl (92 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 92.0/92.0 kB 1.3 MB/s eta 0:00:00
Downloading loguru-0.7.2-py3-none-any.whl (62 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 62.5/62.5 kB 1.1 MB/s eta 0:00:00
Downloading mdtex2html-1.3.0-py3-none-any.whl (13 kB)
Downloading latex2mathml-3.77.0-py3-none-any.whl (73 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 73.7/73.7 kB 1.2 MB/s eta 0:00:00
Downloading openai-1.10.0-py3-none-any.whl (225 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 225.1/225.1 kB 1.6 MB/s eta 0:00:00
Downloading zhipuai-2.0.1-py3-none-any.whl (26 kB)
Downloading pydantic-2.6.0-py3-none-any.whl (394 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 394.2/394.2 kB 3.1 MB/s eta 0:00:00
Downloading pydantic_core-2.16.1-cp311-cp311-macosx_10_12_x86_64.whl (1.9 MB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 1.9/1.9 MB 1.2 MB/s eta 0:00:00
Downloading sse_starlette-2.0.0-py3-none-any.whl (9.0 kB)
Downloading uvicorn-0.27.0.post1-py3-none-any.whl (60 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 60.7/60.7 kB 1.3 MB/s eta 0:00:00
Downloading timm-0.9.12-py3-none-any.whl (2.2 MB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 2.2/2.2 MB 1.5 MB/s eta 0:00:00
Downloading tiktoken-0.5.2-cp311-cp311-macosx_10_9_x86_64.whl (1.0 MB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 1.0/1.0 MB 965.3 kB/s eta 0:00:00
Downloading langchain-0.1.4-py3-none-any.whl (803 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 803.6/803.6 kB 1.9 MB/s eta 0:00:00
Downloading langchainhub-0.1.14-py3-none-any.whl (3.4 kB)
Downloading arxiv-2.1.0-py3-none-any.whl (11 kB)
Downloading aiofiles-23.2.1-py3-none-any.whl (15 kB)
Downloading aiohttp-3.9.3-cp311-cp311-macosx_10_9_x86_64.whl (398 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 398.5/398.5 kB 1.9 MB/s eta 0:00:00
Downloading altair-5.2.0-py3-none-any.whl (996 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 996.9/996.9 kB 1.4 MB/s eta 0:00:00
Downloading annotated_types-0.6.0-py3-none-any.whl (12 kB)
Downloading anyio-4.2.0-py3-none-any.whl (85 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 85.5/85.5 kB 1.3 MB/s eta 0:00:00
Downloading blinker-1.7.0-py3-none-any.whl (13 kB)
Downloading cachetools-5.3.2-py3-none-any.whl (9.3 kB)
Downloading click-8.1.7-py3-none-any.whl (97 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 97.9/97.9 kB 205.8 kB/s eta 0:00:00
Downloading dataclasses_json-0.6.3-py3-none-any.whl (28 kB)
Downloading GitPython-3.1.41-py3-none-any.whl (196 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 196.4/196.4 kB 1.4 MB/s eta 0:00:00
Downloading httpx-0.26.0-py3-none-any.whl (75 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 75.9/75.9 kB 1.2 MB/s eta 0:00:00
Downloading httpcore-1.0.2-py3-none-any.whl (76 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 76.9/76.9 kB 1.1 MB/s eta 0:00:00
Downloading huggingface_hub-0.20.3-py3-none-any.whl (330 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 330.1/330.1 kB 385.8 kB/s eta 0:00:00
Downloading fsspec-2023.12.2-py3-none-any.whl (168 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 169.0/169.0 kB 996.0 kB/s eta 0:00:00
Downloading importlib_metadata-7.0.1-py3-none-any.whl (23 kB)
Downloading importlib_resources-6.1.1-py3-none-any.whl (33 kB)
Downloading jsonpatch-1.33-py2.py3-none-any.whl (12 kB)
Downloading langchain_community-0.0.16-py3-none-any.whl (1.6 MB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 1.6/1.6 MB 1.6 MB/s eta 0:00:00
Downloading langchain_core-0.1.17-py3-none-any.whl (235 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 235.9/235.9 kB 1.8 MB/s eta 0:00:00
Downloading langsmith-0.0.85-py3-none-any.whl (54 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 54.0/54.0 kB 735.7 kB/s eta 0:00:00
Downloading matplotlib-3.8.2-cp311-cp311-macosx_10_12_x86_64.whl (7.6 MB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 7.6/7.6 MB 1.5 MB/s eta 0:00:00
Downloading orjson-3.9.12-cp311-cp311-macosx_10_15_x86_64.macosx_11_0_arm64.macosx_10_15_universal2.whl (250 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 250.6/250.6 kB 2.2 MB/s eta 0:00:00
Downloading packaging-23.2-py3-none-any.whl (53 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 53.0/53.0 kB 1.1 MB/s eta 0:00:00
Downloading pandas-2.2.0-cp311-cp311-macosx_10_9_x86_64.whl (12.5 MB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 12.5/12.5 MB 1.8 MB/s eta 0:00:00
Downloading pyarrow-15.0.0-cp311-cp311-macosx_10_15_x86_64.whl (27.2 MB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 27.2/27.2 MB 1.1 MB/s eta 0:00:00
Downloading PyJWT-2.8.0-py3-none-any.whl (22 kB)
Downloading regex-2023.12.25-cp311-cp311-macosx_10_9_x86_64.whl (296 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 296.5/296.5 kB 2.0 MB/s eta 0:00:00
Downloading rich-13.7.0-py3-none-any.whl (240 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 240.6/240.6 kB 957.1 kB/s eta 0:00:00
Downloading ruff-0.1.15-py3-none-macosx_10_12_x86_64.whl (7.3 MB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 7.3/7.3 MB 1.7 MB/s eta 0:00:00
Downloading safetensors-0.4.2-cp311-cp311-macosx_10_12_x86_64.whl (426 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 426.3/426.3 kB 1.5 MB/s eta 0:00:00
Downloading SQLAlchemy-2.0.25-cp311-cp311-macosx_10_9_x86_64.whl (2.1 MB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 2.1/2.1 MB 1.3 MB/s eta 0:00:00
Downloading starlette-0.35.1-py3-none-any.whl (71 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 71.1/71.1 kB 2.2 MB/s eta 0:00:00
Downloading tenacity-8.2.3-py3-none-any.whl (24 kB)
Downloading tornado-6.4-cp38-abi3-macosx_10_9_x86_64.whl (431 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 431.1/431.1 kB 1.4 MB/s eta 0:00:00
Downloading types_requests-2.31.0.20240125-py3-none-any.whl (14 kB)
Downloading tzlocal-5.2-py3-none-any.whl (17 kB)
Downloading validators-0.22.0-py3-none-any.whl (26 kB)
Downloading Markdown-3.5.2-py3-none-any.whl (103 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 103.9/103.9 kB 1.3 MB/s eta 0:00:00
Downloading psutil-5.9.8-cp36-abi3-macosx_10_9_x86_64.whl (248 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 248.7/248.7 kB 1.3 MB/s eta 0:00:00
Downloading scikit_learn-1.4.0-1-cp311-cp311-macosx_10_9_x86_64.whl (11.5 MB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 11.5/11.5 MB 1.5 MB/s eta 0:00:00
Downloading scipy-1.12.0-cp311-cp311-macosx_10_9_x86_64.whl (38.9 MB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 38.9/38.9 MB 1.9 MB/s eta 0:00:00
Downloading attrs-23.2.0-py3-none-any.whl (60 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 60.8/60.8 kB 992.9 kB/s eta 0:00:00
Downloading contourpy-1.2.0-cp311-cp311-macosx_10_9_x86_64.whl (258 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 258.2/258.2 kB 1.3 MB/s eta 0:00:00
Downloading cycler-0.12.1-py3-none-any.whl (8.3 kB)
Downloading fonttools-4.47.2-cp311-cp311-macosx_10_9_x86_64.whl (2.3 MB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 2.3/2.3 MB 2.0 MB/s eta 0:00:00
Downloading frozenlist-1.4.1-cp311-cp311-macosx_10_9_x86_64.whl (55 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 55.3/55.3 kB 1.0 MB/s eta 0:00:00
Downloading gitdb-4.0.11-py3-none-any.whl (62 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 62.7/62.7 kB 1.3 MB/s eta 0:00:00
Downloading joblib-1.3.2-py3-none-any.whl (302 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 302.2/302.2 kB 927.0 kB/s eta 0:00:00
Downloading jsonschema-4.21.1-py3-none-any.whl (85 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 85.5/85.5 kB 1.2 MB/s eta 0:00:00
Downloading kiwisolver-1.4.5-cp311-cp311-macosx_10_9_x86_64.whl (68 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 68.2/68.2 kB 1.4 MB/s eta 0:00:00
Downloading markdown_it_py-3.0.0-py3-none-any.whl (87 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 87.5/87.5 kB 1.6 MB/s eta 0:00:00
Downloading marshmallow-3.20.2-py3-none-any.whl (49 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 49.4/49.4 kB 1.0 MB/s eta 0:00:00
Downloading pygments-2.17.2-py3-none-any.whl (1.2 MB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 1.2/1.2 MB 1.5 MB/s eta 0:00:00
Downloading pyparsing-3.1.1-py3-none-any.whl (103 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 103.1/103.1 kB 1.3 MB/s eta 0:00:00
Downloading pytz-2023.4-py2.py3-none-any.whl (506 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 506.5/506.5 kB 1.2 MB/s eta 0:00:00
Downloading shellingham-1.5.4-py2.py3-none-any.whl (9.8 kB)
Downloading threadpoolctl-3.2.0-py3-none-any.whl (15 kB)
Downloading typing_inspect-0.9.0-py3-none-any.whl (8.8 kB)
Downloading tzdata-2023.4-py2.py3-none-any.whl (346 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 346.6/346.6 kB 1.2 MB/s eta 0:00:00
Downloading urllib3-2.2.0-py3-none-any.whl (120 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 120.9/120.9 kB 1.8 MB/s eta 0:00:00
Downloading yarl-1.9.4-cp311-cp311-macosx_10_9_x86_64.whl (83 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 83.2/83.2 kB 443.8 kB/s eta 0:00:00
Downloading zipp-3.17.0-py3-none-any.whl (7.4 kB)
Downloading toolz-0.12.1-py3-none-any.whl (56 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 56.1/56.1 kB 1.2 MB/s eta 0:00:00
Downloading jsonschema_specifications-2023.12.1-py3-none-any.whl (18 kB)
Downloading referencing-0.33.0-py3-none-any.whl (26 kB)
Downloading rpds_py-0.17.1-cp311-cp311-macosx_10_12_x86_64.whl (353 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 354.0/354.0 kB 1.1 MB/s eta 0:00:00
Downloading smmap-5.0.1-py3-none-any.whl (24 kB)
Building wheels for collected packages: ffmpy, greenlet, sgmllib3k
  Building wheel for ffmpy (setup.py) ... done
  Created wheel for ffmpy: filename=ffmpy-0.3.1-py3-none-any.whl size=5579 sha256=2da41c8a484b0216a795b6762618a78078b9ee0dd763cf2e1ca40f51b0b90cb6
  Stored in directory: /Users/markvivv/Library/Caches/pip/wheels/99/3b/84/22ac1eab7a10222ac6bbc3f7e69b04f3980db328978c533a3f
  Building wheel for greenlet (pyproject.toml) ... done
  Created wheel for greenlet: filename=greenlet-3.0.3-cp311-cp311-macosx_10_9_x86_64.whl size=214633 sha256=14b61d6f09dad9bc5af1feda5eb76510c613612680bbc330044443f825ce82b9
  Stored in directory: /Users/markvivv/Library/Caches/pip/wheels/56/08/ca/e0bd72a4cd850a40d2a51ee67fbd2f3efe5332fe5fe00e2c53
  Building wheel for sgmllib3k (setup.py) ... done
  Created wheel for sgmllib3k: filename=sgmllib3k-1.0.0-py3-none-any.whl size=6047 sha256=ae3bad9422d7de25be119b223c83a2476aaeba9aecbc0cbc97e61b8a95ca1fb8
  Stored in directory: /Users/markvivv/Library/Caches/pip/wheels/3b/25/2a/105d6a15df6914f4d15047691c6c28f9052cc1173e40285d03
Successfully built ffmpy greenlet sgmllib3k
Installing collected packages: sgmllib3k, sentencepiece, pytz, pydub, ffmpy, cpm_kernels, zipp, websockets, validators, urllib3, tzlocal, tzdata, tornado, toolz, tomlkit, toml, threadpoolctl, tenacity, sniffio, smmap, six, shellingham, semantic-version, scipy, safetensors, ruff, rpds-py, regex, python-multipart, pyparsing, pyjwt, pygments, pydantic-core, pyarrow, psutil, protobuf, packaging, orjson, mypy-extensions, multidict, mdurl, markdown, loguru, latex2mathml, kiwisolver, jsonpatch, joblib, importlib-resources, h11, greenlet, fsspec, frozenlist, fonttools, feedparser, cycler, contourpy, colorama, click, cachetools, blinker, attrs, annotated-types, aiofiles, yarl, uvicorn, typing-inspect, types-requests, typer, SQLAlchemy, scikit-learn, referencing, python-dateutil, pydeck, pydantic, nltk, mdtex2html, marshmallow, markdown-it-py, importlib-metadata, httpcore, gitdb, anyio, aiosignal, tiktoken, starlette, rich, pandas, matplotlib, langsmith, langchainhub, jsonschema-specifications, huggingface-hub, httpx, gitpython, dataclasses-json, arxiv, aiohttp, zhipuai, tokenizers, timm, sse-starlette, openai, langchain-core, jsonschema, gradio-client, fastapi, accelerate, transformers, langchain-community, altair, streamlit, sentence_transformers, langchain, gradio
  Attempting uninstall: urllib3
    Found existing installation: urllib3 1.26.18
    Uninstalling urllib3-1.26.18:
      Successfully uninstalled urllib3-1.26.18
  Attempting uninstall: packaging
    Found existing installation: packaging 23.1
    Uninstalling packaging-23.1:
      Successfully uninstalled packaging-23.1
  Attempting uninstall: jsonpatch
    Found existing installation: jsonpatch 1.32
    Uninstalling jsonpatch-1.32:
      Successfully uninstalled jsonpatch-1.32
Successfully installed SQLAlchemy-2.0.25 accelerate-0.26.1 aiofiles-23.2.1 aiohttp-3.9.3 aiosignal-1.3.1 altair-5.2.0 annotated-types-0.6.0 anyio-4.2.0 arxiv-2.1.0 attrs-23.2.0 blinker-1.7.0 cachetools-5.3.2 click-8.1.7 colorama-0.4.6 contourpy-1.2.0 cpm_kernels-1.0.11 cycler-0.12.1 dataclasses-json-0.6.3 fastapi-0.109.0 feedparser-6.0.10 ffmpy-0.3.1 fonttools-4.47.2 frozenlist-1.4.1 fsspec-2023.12.2 gitdb-4.0.11 gitpython-3.1.41 gradio-4.16.0 gradio-client-0.8.1 greenlet-3.0.3 h11-0.14.0 httpcore-1.0.2 httpx-0.26.0 huggingface-hub-0.20.3 importlib-metadata-7.0.1 importlib-resources-6.1.1 joblib-1.3.2 jsonpatch-1.33 jsonschema-4.21.1 jsonschema-specifications-2023.12.1 kiwisolver-1.4.5 langchain-0.1.4 langchain-community-0.0.16 langchain-core-0.1.17 langchainhub-0.1.14 langsmith-0.0.85 latex2mathml-3.77.0 loguru-0.7.2 markdown-3.5.2 markdown-it-py-3.0.0 marshmallow-3.20.2 matplotlib-3.8.2 mdtex2html-1.3.0 mdurl-0.1.2 multidict-6.0.4 mypy-extensions-1.0.0 nltk-3.8.1 openai-1.10.0 orjson-3.9.12 packaging-23.2 pandas-2.2.0 protobuf-4.25.2 psutil-5.9.8 pyarrow-15.0.0 pydantic-2.6.0 pydantic-core-2.16.1 pydeck-0.8.1b0 pydub-0.25.1 pygments-2.17.2 pyjwt-2.8.0 pyparsing-3.1.1 python-dateutil-2.8.2 python-multipart-0.0.6 pytz-2023.4 referencing-0.33.0 regex-2023.12.25 rich-13.7.0 rpds-py-0.17.1 ruff-0.1.15 safetensors-0.4.2 scikit-learn-1.4.0 scipy-1.12.0 semantic-version-2.10.0 sentence_transformers-2.3.1 sentencepiece-0.1.99 sgmllib3k-1.0.0 shellingham-1.5.4 six-1.16.0 smmap-5.0.1 sniffio-1.3.0 sse-starlette-2.0.0 starlette-0.35.1 streamlit-1.30.0 tenacity-8.2.3 threadpoolctl-3.2.0 tiktoken-0.5.2 timm-0.9.12 tokenizers-0.15.1 toml-0.10.2 tomlkit-0.12.0 toolz-0.12.1 tornado-6.4 transformers-4.37.2 typer-0.9.0 types-requests-2.31.0.20240125 typing-inspect-0.9.0 tzdata-2023.4 tzlocal-5.2 urllib3-2.2.0 uvicorn-0.27.0.post1 validators-0.22.0 websockets-11.0.3 yarl-1.9.4 zhipuai-2.0.1 zipp-3.17.0

三、进入 base_demo,准备启动 streamlit 示例程序

(base) markvivv@MBP ChatGLM3 % cd base_demo

本人笔记本带独立显卡,4G 显存,16G 内存,默认参数可以启动示例程序,但是对大模型提任何问题都会提示如下错误:

RuntimeError: MPS backend out of memory (MPS allocated: 5.44 GB, other allocations: 1.17 GB, max allowed: 6.80 GB). Tried to allocate 428.00 MB on private pool. Use PYTORCH_MPS_HIGH_WATERMARK_RATIO=0.0 to disable upper limit for memory allocations (may cause system failure).

按 Ctrl + C 结束正在运行的模型,冒着机器可能突然崩溃的风险,按照提示信息执行命令取消内存限制

(base) markvivv@MBP basic_demo % PYTORCH_MPS_HIGH_WATERMARK_RATIO=0.0

内存限制错误提示信息如下:

(base) markvivv@MBP basic_demo % streamlit run web_demo_streamlit.py 

      👋 Welcome to Streamlit!

      If you’d like to receive helpful onboarding emails, news, offers, promotions,
      and the occasional swag, please enter your email address below. Otherwise,
      leave this field blank.

      Email:  

  You can find our privacy policy at https://streamlit.io/privacy-policy

  Summary:
  - This open source library collects usage statistics.
  - We cannot see and do not store information contained inside Streamlit apps,
    such as text, charts, images, etc.
  - Telemetry data is stored in servers in the United States.
  - If you'd like to opt out, add the following to ~/.streamlit/config.toml,
    creating that file if necessary:

    [browser]
    gatherUsageStats = false


  You can now view your Streamlit app in your browser.

  Local URL: http://localhost:8501
  Network URL: http://10.8.0.2:8501

  For better performance, install the Watchdog module:

  $ xcode-select --install
  $ pip install watchdog
            
tokenizer_config.json: 100%|████████████████████████████████████████████████████████████| 518/518 [00:00<00:00, 451kB/s]
tokenization_chatglm.py: 100%|█████████████████████████████████████████████████████| 13.0k/13.0k [00:00<00:00, 37.3MB/s]
A new version of the following files was downloaded from https://huggingface.co/THUDM/chatglm3-6b:
- tokenization_chatglm.py
. Make sure to double-check they do not contain any added malicious code. To avoid downloading new versions of the code file, you can pin a revision.
tokenizer.model: 100%|█████████████████████████████████████████████████████████████| 1.02M/1.02M [00:00<00:00, 3.52MB/s]
config.json: 100%|█████████████████████████████████████████████████████████████████| 1.32k/1.32k [00:00<00:00, 4.47MB/s]
configuration_chatglm.py: 100%|████████████████████████████████████████████████████| 2.33k/2.33k [00:00<00:00, 13.2MB/s]
A new version of the following files was downloaded from https://huggingface.co/THUDM/chatglm3-6b:
- configuration_chatglm.py
. Make sure to double-check they do not contain any added malicious code. To avoid downloading new versions of the code file, you can pin a revision.
modeling_chatglm.py: 100%|█████████████████████████████████████████████████████████| 55.7k/55.7k [00:00<00:00, 1.00MB/s]
quantization.py: 100%|█████████████████████████████████████████████████████████████| 14.7k/14.7k [00:00<00:00, 51.6MB/s]
A new version of the following files was downloaded from https://huggingface.co/THUDM/chatglm3-6b:
- quantization.py
. Make sure to double-check they do not contain any added malicious code. To avoid downloading new versions of the code file, you can pin a revision.
A new version of the following files was downloaded from https://huggingface.co/THUDM/chatglm3-6b:
- modeling_chatglm.py
- quantization.py
. Make sure to double-check they do not contain any added malicious code. To avoid downloading new versions of the code file, you can pin a revision.
model.safetensors.index.json: 100%|████████████████████████████████████████████████| 21.2k/21.2k [00:00<00:00, 7.74MB/s]
model-00001-of-00007.safetensors: 100%|████████████████████████████████████████████| 1.83G/1.83G [15:17<00:00, 1.99MB/s]
Downloading shards:  14%|████████▊                                                     | 1/7 [15:17<1:31:44, 917.50s/itError while downloading from https://cdn-lfs-us-1.huggingface.co/repos/01/5a/015a4eda6314fbcdb0aecc00e73f604e0f398b10ef843cf3e7bfcf8d0b9c1d7d/f88d7f69a3940711b87308eb20dd0544df22aff81134fa0d5160d3c859f5d321?response-content-disposition=attachment%3B+filename*%3DUTF-8%27%27model-00002-of-00007.safetensors%3B+filename%3D%22model-00002-of-00007.safetensors%22%3B&Expires=1707015811&Policy=eyJTdGF0ZW1lbnQiOlt7IkNvbmRpdGlvbiI6eyJEYXRlTGVzc1RoYW4iOnsiQVdTOkVwb2NoVGltZSI6MTcwNzAxNTgxMX19LCJSZXNvdXJjZSI6Imh0dHBzOi8vY2RuLWxmcy11cy0xLmh1Z2dpbmdmYWNlLmNvL3JlcG9zLzAxLzVhLzAxNWE0ZWRhNjMxNGZiY2RiMGFlY2MwMGU3M2Y2MDRlMGYzOThiMTBlZjg0M2NmM2U3YmZjZjhkMGI5YzFkN2QvZjg4ZDdmNjlhMzk0MDcxMWI4NzMwOGViMjBkZDA1NDRkZjIyYWZmODExMzRmYTBkNTE2MGQzYzg1OWY1ZDMyMT9yZXNwb25zZS1jb250ZW50LWRpc3Bvc2l0aW9uPSoifV19&Signature=WrIM24-FutGC5aTXW55Ff4g-z5MO8K2NsIFjc7eRvXokY7fdHy4AdMQnVafWlpLWzEFBAosLvPSlR4VpXBUqBR%7EzSJZ7MEMqX6mT32Rj0eX0x8CfTVPUsOFu2T0nM1MNb0B7BYjDirjkjm2LUNnligb9znWwxYlchj6wEVV3I2UHh3IwmLdcUujmXiq9t07ZIzJ3tf39DEgRbjDgufdOHUO-gHQ%7Eb6bGWYhGRjpAog2U6P9CrzGNwIEIz6a6muh-raFzOukyi8Wxz2sys-HNprB5F1nsjahI3YhFLb6M6XyxWCFTCbPtTI8Yi24glkKArXD%7EZnyFcmZnNtGsnplEQg__&Key-Pair-Id=KCD77M1F0VK2B: HTTPSConnectionPool(host='cdn-lfs-us-1.huggingface.co', port=443): Read timed out.
Trying to resume download...
model-00002-of-00007.safetensors: 100%|████████████████████████████████████████████| 1.97G/1.97G [09:01<00:00, 3.21MB/s]
model-00002-of-00007.safetensors:  12%|█████▏                                      | 231M/1.97G [11:06<1:23:42, 346kB/s]
model-00003-of-00007.safetensors: 100%|████████████████████████████████████████████| 1.93G/1.93G [09:47<00:00, 3.28MB/s]
Downloading shards:  43%|███████████████████████████▍                                    | 3/7 [36:13<45:49, 687.47s/it]
model-00004-of-00007.safetensors:  42%|██████████████████▋                          | 755M/1.82G [04:13<05:18, 3.33MB/s]
model-00004-of-00007.safetensors: 100%|████████████████████████████████████████████| 1.82G/1.82G [09:31<00:00, 3.17MB/s]
model-00005-of-00007.safetensors: 100%|████████████████████████████████████████████| 1.97G/1.97G [10:47<00:00, 3.04MB/s]
model-00006-of-00007.safetensors: 100%|████████████████████████████████████████████| 1.93G/1.93G [09:40<00:00, 3.32MB/s]
model-00007-of-00007.safetensors: 100%|████████████████████████████████████████████| 1.05G/1.05G [05:37<00:00, 3.12MB/s]
Downloading shards: 100%|██████████████████████████████████████████████████████████████| 7/7 [1:11:55<00:00, 616.55s/it]
Loading checkpoint shards: 100%|██████████████████████████████████████████████████████████| 7/7 [00:20<00:00,  2.88s/it]
WARNING:root:Some parameters are on the meta device device because they were offloaded to the disk.

正常启动后,会自动使用浏览器打开 http://localhost:8501,然后就可以正常通过浏览器和大模型交互了,受限于硬件水平,响应非常慢。

四、运行情况

交互界面,注意红色内存报警,截图时已结束大模型进程,太慢了
交互界面,注意红色内存报警,截图时已结束大模型进程,太慢了
响应问题时,16G 的内存,使用量超过12G,GPU 功率10W 左右,可能 GPU 显存太小,没用起来
响应问题时,16G 的内存,使用量超过12G,GPU 功率10W 左右,可能 GPU 显存太小,没用起来

  • 7
    点赞
  • 7
    收藏
    觉得还不错? 一键收藏
  • 打赏
    打赏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

markvivv

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值