show code js

2023年10月21日 星期六

gpt4all-j and use streamlit

 modify on 2023/10/26

git clone https://github.com/ajvikram/streamlit-gpt.git

cd streamlit-gpt 

create model directory and  download https://gpt4all.io/models/ggml-gpt4all-j.bin in this directory

back to streamlit-gpt directory


run adconda

conda create -n gptj python=='3.11.5'

conda activate -n gptj


pip install -r requirement.txt

streamlit run main.py --server.port=8080 --server.address=0.0.0.0<-your ip

2023年10月17日 星期二

GPT4All test

 Local


  • Website https://github.com/nomic-ai/gpt4all#readme
  • Use conda on win, and git
  • git clone https://github.com/nomic-ai/gpt4all.git
  • down gpt4all-lora-quantized.bin from https://github.com/nomic-ai/gpt4all/issues/246
  • move bin file to gpt4all-training/chat
  • run exe to test

2023年10月3日 星期二

CHT GPT on Local with Win


Note

  • Env
    • install python
    • install Anaconda3, or Miniconda
      • conda update conda
      • conda install pip3
    • install Git, Git LFS
  • Go and Choose https://pytorch.org/get-started/locally/ , Get a url for next
  • Run Anaconda powershell mode
    • pip3 install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu118
  • Create Directory for GPT (ex:GPT)
    • Langchain-Chatchat: git clone https://github.com/chatchat-space/Langchain-Chatchat.git
    • chatglm2-6b: git clone https://huggingface.co/THUDM/chatglm2-6b
    • m3e-base: git clone https://huggingface.co/moka-ai/m3e-base
  • Langchain-Chatchat/configs
    • *.py.example copyto *.py
    • modify server_config.py
      DEFAULT_BIND_HOST = "your ip"
    • modify model_config.py
      find: modify:embedding_model_dict = {
      "m3e-base": "/your_path/GPT/m3e-base",
      check: EMBEDDING_MODEL = "m3e-base"
      find: modify:llm_model_dict = { "chatglm2-6b": {
      "local_model_path": "/your_path/GPT/chatglm2-6b",
      check: modify:LLM_MODEL = "chatglm2-6b"
  • install Langchain-Chatchat and Run (Anaconda powershell mode)
    cd Langchain-Chatchat
    conda create -n Chatchat python==3.10
    conda active Chatchat
    pip3 install -r requirements.txt
    python init_database.py --recreate-vs (for first)
  • run Langchain-Chatchat
    python startup.py -a (Run All)[Input Email for first, and active service]
  • Check
    • Firewall pass python
    • Firewall pass 8501/TCP
  • INFO
    https://zhuanlan.zhihu.com/p/645807338?utm_id=0
    https://zhuanlan.zhihu.com/p/652530137
    https://zhuanlan.zhihu.com/p/617208490
    https://zhuanlan.zhihu.com/p/630049721?utm_id=0