Code Monkey home page Code Monkey logo

logreader's Introduction

LogReader

LogReader: Leveraging Large Language Models for General-Purpose Log Analysis

Run Environment

Train

conda create -n xtuner python=3.11.4
pip install xtuner
# deepspeed support
pip install deepspeed
conda install mpi4py-mpich

Inference

pip install --upgrade ray
pip install --upgrade pyarrow
pip install pandas
pip install vllm
pip install ray

ChatGLM2 support

  • Modify the source code according to the commit below. Only single card is supported. vllm-project/vllm#649
  • Models after SFT need to be added to the following file. ~/miniconda3/envs/llm_eval/lib/python3.11/site-packages/vllm/model_executor/model_loader.py Alt text

If occur error like:

"tansformers_module" ModuleNotFoundError when load model with trust_remote_code=True

Distributed support requires changing the following code: Alt text

Train step

export NPROC_PER_NODE=4
nohup xtuner train train/llama2_7b_qlora_logQA.py >tunning_llama2-chat-7b.log 2>&1 &
nohup xtuner train train/qwen_7b_qlora_ad.py --work-dir /mnt/qjx/qwen_chat_7b_qlora_ad  > tunning_qwen-chat-7b.log 2>&1 &
# Merge LoRA adapter
xtuner convert merge_adapter ../../train/baichuan_7b_qlora_logQA.py  ./epoch_20.pth  ./baichuan-chat-7b-ft_log_20.pth --max-shard-size 5GB

Inference

python inference/demo.py

logreader's People

Contributors

xichie avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.