├── .devcontainer ├── Dockerfile └── devcontainer.json ├── .github ├── CODEOWNERS ├── ISSUE_TEMPLATE │ ├── ask-a-question.md │ ├── bug-report.yaml │ └── feature-request.md ├── dependabot.yml └── workflows │ ├── check-links.yml │ ├── cpu-tests.yml │ ├── mkdocs-deploy.yml │ └── publish-pkg.yml ├── .gitignore ├── .lightning └── workflows │ └── tests.yaml ├── .pre-commit-config.yaml ├── CITATION.cff ├── LICENSE ├── README.md ├── config_hub ├── finetune │ ├── README.md │ ├── falcon-7b │ │ ├── lora.yaml │ │ └── qlora.yaml │ ├── gemma-2b │ │ ├── full.yaml │ │ ├── lora.yaml │ │ └── qlora.yaml │ ├── gemma-7b │ │ ├── lora.yaml │ │ └── qlora.yaml │ ├── gemma2-2b │ │ ├── lora.yaml │ │ └── qlora.yaml │ ├── gemma2-9b │ │ ├── lora.yaml │ │ └── qlora.yaml │ ├── llama-2-7b │ │ ├── full.yaml │ │ ├── lora.yaml │ │ └── qlora.yaml │ ├── llama-3-8b │ │ ├── full.yaml │ │ ├── lora.yaml │ │ └── qlora.yaml │ ├── llama-3.1-8b │ │ ├── full.yaml │ │ ├── lora.yaml │ │ └── qlora.yaml │ ├── llama-3.2-1B │ │ ├── full.yaml │ │ ├── lora.yaml │ │ └── qlora.yaml │ ├── llama-3.2-3B │ │ ├── full.yaml │ │ ├── lora.yaml │ │ └── qlora.yaml │ ├── mistral-7b-v0.2 │ │ ├── lora.yaml │ │ └── qlora.yaml │ ├── mistral-7b │ │ ├── lora.yaml │ │ └── qlora.yaml │ ├── phi-2 │ │ ├── full.yaml │ │ ├── lora.yaml │ │ └── qlora.yaml │ ├── phi-3 │ │ ├── full.yaml │ │ ├── lora.yaml │ │ └── qlora.yaml │ ├── stablelm-base-alpha-3b │ │ ├── full.yaml │ │ ├── lora.yaml │ │ └── qlora.yaml │ └── tiny-llama │ │ ├── full.yaml │ │ ├── lora.yaml │ │ └── qlora.yaml └── pretrain │ ├── debug.yaml │ ├── microllama.yaml │ ├── tinyllama.yaml │ └── tinystories.yaml ├── extensions ├── thunder │ ├── README.md │ ├── __init__.py │ ├── pretrain.py │ ├── strategies │ │ ├── __init__.py │ │ ├── thunder_ddp.py │ │ └── thunder_fsdp.py │ └── unsloth │ │ ├── __init__.py │ │ ├── executor.py │ │ └── kernels │ │ ├── __init__.py │ │ ├── cross_entropy_loss.py │ │ ├── rope_embedding.py │ │ ├── swiglu.py │ │ └── utils.py └── xla │ ├── README.md │ ├── __init__ │ ├── finetune │ ├── __init__ │ └── adapter.py │ ├── generate │ ├── __init__ │ ├── adapter.py │ └── base.py │ ├── scripts │ ├── __init__ │ └── prepare_alpaca.py │ └── utils.py ├── litgpt ├── __init__.py ├── __main__.py ├── adapter.py ├── adapter_v2.py ├── api.py ├── args.py ├── chat │ ├── __init__.py │ └── base.py ├── config.py ├── data │ ├── __init__.py │ ├── alpaca.py │ ├── alpaca_2k.py │ ├── alpaca_gpt4.py │ ├── base.py │ ├── deita.py │ ├── flan.py │ ├── json_data.py │ ├── lima.py │ ├── lit_data.py │ ├── longform.py │ ├── microllama.py │ ├── openwebtext.py │ ├── prepare_slimpajama.py │ ├── prepare_starcoder.py │ ├── text_files.py │ ├── tinyllama.py │ └── tinystories.py ├── deploy │ ├── __init__.py │ └── serve.py ├── eval │ └── evaluate.py ├── finetune │ ├── __init__.py │ ├── adapter.py │ ├── adapter_v2.py │ ├── full.py │ ├── lora.py │ └── lora_legacy.py ├── generate │ ├── __init__.py │ ├── adapter.py │ ├── adapter_v2.py │ ├── base.py │ ├── full.py │ ├── sequentially.py │ ├── speculative_decoding.py │ └── tp.py ├── lora.py ├── model.py ├── pretrain.py ├── prompts.py ├── scripts │ ├── __init__.py │ ├── convert_hf_checkpoint.py │ ├── convert_lit_checkpoint.py │ ├── convert_pretrained_checkpoint.py │ ├── download.py │ └── merge_lora.py ├── tokenizer.py └── utils.py ├── pyproject.toml ├── tests ├── conftest.py ├── convert │ ├── __init__.py │ ├── test_hf_checkpoint.py │ ├── test_lit_checkpoint.py │ └── test_pretrained_checkpoint.py ├── data │ ├── __init__.py │ ├── _fixtures │ │ ├── alpaca.json │ │ ├── dolly.json │ │ ├── longform_train.json │ │ └── longform_val.json │ ├── test_alpaca.py │ ├── test_base.py │ ├── test_deita.py │ ├── test_json.py │ ├── test_lit_data.py │ ├── test_longform.py │ ├── test_openwebtext.py │ ├── test_textfiles.py │ ├── test_tinyllama.py │ └── test_tinystories.py ├── ext_thunder │ ├── __init__.py │ ├── test_thunder_distributed.py │ ├── test_thunder_networks.py │ ├── test_thunder_pretrain.py │ └── test_unsloth_executor.py ├── generate │ ├── __init__.py │ ├── test_adapter.py │ ├── test_main.py │ ├── test_sequentially.py │ ├── test_tp.py │ └── utils.py ├── test_adapter.py ├── test_adapter_v2.py ├── test_api.py ├── test_args.py ├── test_batch.py ├── test_chat.py ├── test_ci.py ├── test_cli.py ├── test_config.py ├── test_config_hub.py ├── test_deepseek_moe.py ├── test_distributed.py ├── test_evaluate.py ├── test_full.py ├── test_generate_speculatively.py ├── test_lora.py ├── test_merge_lora.py ├── test_model.py ├── test_multihead_latent_attention.py ├── test_pretrain.py ├── test_prompts.py ├── test_readme.py ├── test_rope.py ├── test_serve.py ├── test_tokenizer.py ├── test_trainer_support.py └── test_utils.py └── tutorials ├── 0_to_litgpt.md ├── convert_hf_checkpoint.md ├── convert_lit_models.md ├── deploy.md ├── developer-docs ├── README.md ├── adding-models.md └── python-api.md ├── download_model_weights.md ├── evaluation.md ├── examples └── ptl-trainer │ ├── README.md │ ├── litgpt_ptl_medium.py │ └── litgpt_ptl_small.py ├── finetune.md ├── finetune_adapter.md ├── finetune_full.md ├── finetune_lora.md ├── full_finetune_example.py ├── images ├── 0_to_litgpt │ ├── commands.webp │ ├── finetune.webp │ ├── instruction-1.webp │ ├── instruction-2.webp │ ├── pretrain.webp │ └── usage.webp └── prepare_dataset │ ├── alpaca-2k.jpg │ ├── alpaca.jpg │ ├── alpaca_libre.jpg │ ├── alpacagpt4.jpg │ ├── deita-multiturn.jpg │ ├── deita.jpg │ ├── dolly.jpg │ ├── lima.jpg │ └── longform.jpg ├── inference.md ├── mkdocs.yml ├── oom.md ├── prepare_dataset.md ├── pretrain.md ├── pretrain_tinyllama.md ├── python-api.md ├── quantize.md └── resource-tables.md /.devcontainer/Dockerfile: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/.devcontainer/Dockerfile -------------------------------------------------------------------------------- /.devcontainer/devcontainer.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/.devcontainer/devcontainer.json -------------------------------------------------------------------------------- /.github/CODEOWNERS: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/.github/CODEOWNERS -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/ask-a-question.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/.github/ISSUE_TEMPLATE/ask-a-question.md -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/bug-report.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/.github/ISSUE_TEMPLATE/bug-report.yaml -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/feature-request.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/.github/ISSUE_TEMPLATE/feature-request.md -------------------------------------------------------------------------------- /.github/dependabot.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/.github/dependabot.yml -------------------------------------------------------------------------------- /.github/workflows/check-links.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/.github/workflows/check-links.yml -------------------------------------------------------------------------------- /.github/workflows/cpu-tests.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/.github/workflows/cpu-tests.yml -------------------------------------------------------------------------------- /.github/workflows/mkdocs-deploy.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/.github/workflows/mkdocs-deploy.yml -------------------------------------------------------------------------------- /.github/workflows/publish-pkg.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/.github/workflows/publish-pkg.yml -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/.gitignore -------------------------------------------------------------------------------- /.lightning/workflows/tests.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/.lightning/workflows/tests.yaml -------------------------------------------------------------------------------- /.pre-commit-config.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/.pre-commit-config.yaml -------------------------------------------------------------------------------- /CITATION.cff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/CITATION.cff -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/LICENSE -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/README.md -------------------------------------------------------------------------------- /config_hub/finetune/README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/README.md -------------------------------------------------------------------------------- /config_hub/finetune/falcon-7b/lora.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/falcon-7b/lora.yaml -------------------------------------------------------------------------------- /config_hub/finetune/falcon-7b/qlora.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/falcon-7b/qlora.yaml -------------------------------------------------------------------------------- /config_hub/finetune/gemma-2b/full.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/gemma-2b/full.yaml -------------------------------------------------------------------------------- /config_hub/finetune/gemma-2b/lora.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/gemma-2b/lora.yaml -------------------------------------------------------------------------------- /config_hub/finetune/gemma-2b/qlora.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/gemma-2b/qlora.yaml -------------------------------------------------------------------------------- /config_hub/finetune/gemma-7b/lora.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/gemma-7b/lora.yaml -------------------------------------------------------------------------------- /config_hub/finetune/gemma-7b/qlora.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/gemma-7b/qlora.yaml -------------------------------------------------------------------------------- /config_hub/finetune/gemma2-2b/lora.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/gemma2-2b/lora.yaml -------------------------------------------------------------------------------- /config_hub/finetune/gemma2-2b/qlora.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/gemma2-2b/qlora.yaml -------------------------------------------------------------------------------- /config_hub/finetune/gemma2-9b/lora.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/gemma2-9b/lora.yaml -------------------------------------------------------------------------------- /config_hub/finetune/gemma2-9b/qlora.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/gemma2-9b/qlora.yaml -------------------------------------------------------------------------------- /config_hub/finetune/llama-2-7b/full.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/llama-2-7b/full.yaml -------------------------------------------------------------------------------- /config_hub/finetune/llama-2-7b/lora.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/llama-2-7b/lora.yaml -------------------------------------------------------------------------------- /config_hub/finetune/llama-2-7b/qlora.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/llama-2-7b/qlora.yaml -------------------------------------------------------------------------------- /config_hub/finetune/llama-3-8b/full.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/llama-3-8b/full.yaml -------------------------------------------------------------------------------- /config_hub/finetune/llama-3-8b/lora.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/llama-3-8b/lora.yaml -------------------------------------------------------------------------------- /config_hub/finetune/llama-3-8b/qlora.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/llama-3-8b/qlora.yaml -------------------------------------------------------------------------------- /config_hub/finetune/llama-3.1-8b/full.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/llama-3.1-8b/full.yaml -------------------------------------------------------------------------------- /config_hub/finetune/llama-3.1-8b/lora.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/llama-3.1-8b/lora.yaml -------------------------------------------------------------------------------- /config_hub/finetune/llama-3.1-8b/qlora.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/llama-3.1-8b/qlora.yaml -------------------------------------------------------------------------------- /config_hub/finetune/llama-3.2-1B/full.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/llama-3.2-1B/full.yaml -------------------------------------------------------------------------------- /config_hub/finetune/llama-3.2-1B/lora.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/llama-3.2-1B/lora.yaml -------------------------------------------------------------------------------- /config_hub/finetune/llama-3.2-1B/qlora.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/llama-3.2-1B/qlora.yaml -------------------------------------------------------------------------------- /config_hub/finetune/llama-3.2-3B/full.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/llama-3.2-3B/full.yaml -------------------------------------------------------------------------------- /config_hub/finetune/llama-3.2-3B/lora.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/llama-3.2-3B/lora.yaml -------------------------------------------------------------------------------- /config_hub/finetune/llama-3.2-3B/qlora.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/llama-3.2-3B/qlora.yaml -------------------------------------------------------------------------------- /config_hub/finetune/mistral-7b-v0.2/lora.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/mistral-7b-v0.2/lora.yaml -------------------------------------------------------------------------------- /config_hub/finetune/mistral-7b-v0.2/qlora.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/mistral-7b-v0.2/qlora.yaml -------------------------------------------------------------------------------- /config_hub/finetune/mistral-7b/lora.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/mistral-7b/lora.yaml -------------------------------------------------------------------------------- /config_hub/finetune/mistral-7b/qlora.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/mistral-7b/qlora.yaml -------------------------------------------------------------------------------- /config_hub/finetune/phi-2/full.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/phi-2/full.yaml -------------------------------------------------------------------------------- /config_hub/finetune/phi-2/lora.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/phi-2/lora.yaml -------------------------------------------------------------------------------- /config_hub/finetune/phi-2/qlora.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/phi-2/qlora.yaml -------------------------------------------------------------------------------- /config_hub/finetune/phi-3/full.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/phi-3/full.yaml -------------------------------------------------------------------------------- /config_hub/finetune/phi-3/lora.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/phi-3/lora.yaml -------------------------------------------------------------------------------- /config_hub/finetune/phi-3/qlora.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/phi-3/qlora.yaml -------------------------------------------------------------------------------- /config_hub/finetune/stablelm-base-alpha-3b/full.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/stablelm-base-alpha-3b/full.yaml -------------------------------------------------------------------------------- /config_hub/finetune/stablelm-base-alpha-3b/lora.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/stablelm-base-alpha-3b/lora.yaml -------------------------------------------------------------------------------- /config_hub/finetune/stablelm-base-alpha-3b/qlora.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/stablelm-base-alpha-3b/qlora.yaml -------------------------------------------------------------------------------- /config_hub/finetune/tiny-llama/full.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/tiny-llama/full.yaml -------------------------------------------------------------------------------- /config_hub/finetune/tiny-llama/lora.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/tiny-llama/lora.yaml -------------------------------------------------------------------------------- /config_hub/finetune/tiny-llama/qlora.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/finetune/tiny-llama/qlora.yaml -------------------------------------------------------------------------------- /config_hub/pretrain/debug.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/pretrain/debug.yaml -------------------------------------------------------------------------------- /config_hub/pretrain/microllama.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/pretrain/microllama.yaml -------------------------------------------------------------------------------- /config_hub/pretrain/tinyllama.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/pretrain/tinyllama.yaml -------------------------------------------------------------------------------- /config_hub/pretrain/tinystories.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/config_hub/pretrain/tinystories.yaml -------------------------------------------------------------------------------- /extensions/thunder/README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/extensions/thunder/README.md -------------------------------------------------------------------------------- /extensions/thunder/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/extensions/thunder/__init__.py -------------------------------------------------------------------------------- /extensions/thunder/pretrain.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/extensions/thunder/pretrain.py -------------------------------------------------------------------------------- /extensions/thunder/strategies/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/extensions/thunder/strategies/__init__.py -------------------------------------------------------------------------------- /extensions/thunder/strategies/thunder_ddp.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/extensions/thunder/strategies/thunder_ddp.py -------------------------------------------------------------------------------- /extensions/thunder/strategies/thunder_fsdp.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/extensions/thunder/strategies/thunder_fsdp.py -------------------------------------------------------------------------------- /extensions/thunder/unsloth/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /extensions/thunder/unsloth/executor.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/extensions/thunder/unsloth/executor.py -------------------------------------------------------------------------------- /extensions/thunder/unsloth/kernels/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/extensions/thunder/unsloth/kernels/__init__.py -------------------------------------------------------------------------------- /extensions/thunder/unsloth/kernels/cross_entropy_loss.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/extensions/thunder/unsloth/kernels/cross_entropy_loss.py -------------------------------------------------------------------------------- /extensions/thunder/unsloth/kernels/rope_embedding.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/extensions/thunder/unsloth/kernels/rope_embedding.py -------------------------------------------------------------------------------- /extensions/thunder/unsloth/kernels/swiglu.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/extensions/thunder/unsloth/kernels/swiglu.py -------------------------------------------------------------------------------- /extensions/thunder/unsloth/kernels/utils.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/extensions/thunder/unsloth/kernels/utils.py -------------------------------------------------------------------------------- /extensions/xla/README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/extensions/xla/README.md -------------------------------------------------------------------------------- /extensions/xla/__init__: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/extensions/xla/__init__ -------------------------------------------------------------------------------- /extensions/xla/finetune/__init__: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /extensions/xla/finetune/adapter.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/extensions/xla/finetune/adapter.py -------------------------------------------------------------------------------- /extensions/xla/generate/__init__: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /extensions/xla/generate/adapter.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/extensions/xla/generate/adapter.py -------------------------------------------------------------------------------- /extensions/xla/generate/base.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/extensions/xla/generate/base.py -------------------------------------------------------------------------------- /extensions/xla/scripts/__init__: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /extensions/xla/scripts/prepare_alpaca.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/extensions/xla/scripts/prepare_alpaca.py -------------------------------------------------------------------------------- /extensions/xla/utils.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/extensions/xla/utils.py -------------------------------------------------------------------------------- /litgpt/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/__init__.py -------------------------------------------------------------------------------- /litgpt/__main__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/__main__.py -------------------------------------------------------------------------------- /litgpt/adapter.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/adapter.py -------------------------------------------------------------------------------- /litgpt/adapter_v2.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/adapter_v2.py -------------------------------------------------------------------------------- /litgpt/api.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/api.py -------------------------------------------------------------------------------- /litgpt/args.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/args.py -------------------------------------------------------------------------------- /litgpt/chat/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /litgpt/chat/base.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/chat/base.py -------------------------------------------------------------------------------- /litgpt/config.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/config.py -------------------------------------------------------------------------------- /litgpt/data/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/data/__init__.py -------------------------------------------------------------------------------- /litgpt/data/alpaca.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/data/alpaca.py -------------------------------------------------------------------------------- /litgpt/data/alpaca_2k.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/data/alpaca_2k.py -------------------------------------------------------------------------------- /litgpt/data/alpaca_gpt4.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/data/alpaca_gpt4.py -------------------------------------------------------------------------------- /litgpt/data/base.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/data/base.py -------------------------------------------------------------------------------- /litgpt/data/deita.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/data/deita.py -------------------------------------------------------------------------------- /litgpt/data/flan.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/data/flan.py -------------------------------------------------------------------------------- /litgpt/data/json_data.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/data/json_data.py -------------------------------------------------------------------------------- /litgpt/data/lima.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/data/lima.py -------------------------------------------------------------------------------- /litgpt/data/lit_data.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/data/lit_data.py -------------------------------------------------------------------------------- /litgpt/data/longform.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/data/longform.py -------------------------------------------------------------------------------- /litgpt/data/microllama.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/data/microllama.py -------------------------------------------------------------------------------- /litgpt/data/openwebtext.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/data/openwebtext.py -------------------------------------------------------------------------------- /litgpt/data/prepare_slimpajama.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/data/prepare_slimpajama.py -------------------------------------------------------------------------------- /litgpt/data/prepare_starcoder.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/data/prepare_starcoder.py -------------------------------------------------------------------------------- /litgpt/data/text_files.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/data/text_files.py -------------------------------------------------------------------------------- /litgpt/data/tinyllama.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/data/tinyllama.py -------------------------------------------------------------------------------- /litgpt/data/tinystories.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/data/tinystories.py -------------------------------------------------------------------------------- /litgpt/deploy/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /litgpt/deploy/serve.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/deploy/serve.py -------------------------------------------------------------------------------- /litgpt/eval/evaluate.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/eval/evaluate.py -------------------------------------------------------------------------------- /litgpt/finetune/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /litgpt/finetune/adapter.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/finetune/adapter.py -------------------------------------------------------------------------------- /litgpt/finetune/adapter_v2.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/finetune/adapter_v2.py -------------------------------------------------------------------------------- /litgpt/finetune/full.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/finetune/full.py -------------------------------------------------------------------------------- /litgpt/finetune/lora.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/finetune/lora.py -------------------------------------------------------------------------------- /litgpt/finetune/lora_legacy.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/finetune/lora_legacy.py -------------------------------------------------------------------------------- /litgpt/generate/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /litgpt/generate/adapter.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/generate/adapter.py -------------------------------------------------------------------------------- /litgpt/generate/adapter_v2.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/generate/adapter_v2.py -------------------------------------------------------------------------------- /litgpt/generate/base.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/generate/base.py -------------------------------------------------------------------------------- /litgpt/generate/full.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/generate/full.py -------------------------------------------------------------------------------- /litgpt/generate/sequentially.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/generate/sequentially.py -------------------------------------------------------------------------------- /litgpt/generate/speculative_decoding.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/generate/speculative_decoding.py -------------------------------------------------------------------------------- /litgpt/generate/tp.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/generate/tp.py -------------------------------------------------------------------------------- /litgpt/lora.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/lora.py -------------------------------------------------------------------------------- /litgpt/model.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/model.py -------------------------------------------------------------------------------- /litgpt/pretrain.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/pretrain.py -------------------------------------------------------------------------------- /litgpt/prompts.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/prompts.py -------------------------------------------------------------------------------- /litgpt/scripts/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /litgpt/scripts/convert_hf_checkpoint.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/scripts/convert_hf_checkpoint.py -------------------------------------------------------------------------------- /litgpt/scripts/convert_lit_checkpoint.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/scripts/convert_lit_checkpoint.py -------------------------------------------------------------------------------- /litgpt/scripts/convert_pretrained_checkpoint.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/scripts/convert_pretrained_checkpoint.py -------------------------------------------------------------------------------- /litgpt/scripts/download.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/scripts/download.py -------------------------------------------------------------------------------- /litgpt/scripts/merge_lora.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/scripts/merge_lora.py -------------------------------------------------------------------------------- /litgpt/tokenizer.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/tokenizer.py -------------------------------------------------------------------------------- /litgpt/utils.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/litgpt/utils.py -------------------------------------------------------------------------------- /pyproject.toml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/pyproject.toml -------------------------------------------------------------------------------- /tests/conftest.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/conftest.py -------------------------------------------------------------------------------- /tests/convert/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/convert/test_hf_checkpoint.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/convert/test_hf_checkpoint.py -------------------------------------------------------------------------------- /tests/convert/test_lit_checkpoint.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/convert/test_lit_checkpoint.py -------------------------------------------------------------------------------- /tests/convert/test_pretrained_checkpoint.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/convert/test_pretrained_checkpoint.py -------------------------------------------------------------------------------- /tests/data/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/data/_fixtures/alpaca.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/data/_fixtures/alpaca.json -------------------------------------------------------------------------------- /tests/data/_fixtures/dolly.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/data/_fixtures/dolly.json -------------------------------------------------------------------------------- /tests/data/_fixtures/longform_train.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/data/_fixtures/longform_train.json -------------------------------------------------------------------------------- /tests/data/_fixtures/longform_val.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/data/_fixtures/longform_val.json -------------------------------------------------------------------------------- /tests/data/test_alpaca.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/data/test_alpaca.py -------------------------------------------------------------------------------- /tests/data/test_base.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/data/test_base.py -------------------------------------------------------------------------------- /tests/data/test_deita.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/data/test_deita.py -------------------------------------------------------------------------------- /tests/data/test_json.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/data/test_json.py -------------------------------------------------------------------------------- /tests/data/test_lit_data.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/data/test_lit_data.py -------------------------------------------------------------------------------- /tests/data/test_longform.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/data/test_longform.py -------------------------------------------------------------------------------- /tests/data/test_openwebtext.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/data/test_openwebtext.py -------------------------------------------------------------------------------- /tests/data/test_textfiles.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/data/test_textfiles.py -------------------------------------------------------------------------------- /tests/data/test_tinyllama.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/data/test_tinyllama.py -------------------------------------------------------------------------------- /tests/data/test_tinystories.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/data/test_tinystories.py -------------------------------------------------------------------------------- /tests/ext_thunder/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/ext_thunder/__init__.py -------------------------------------------------------------------------------- /tests/ext_thunder/test_thunder_distributed.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/ext_thunder/test_thunder_distributed.py -------------------------------------------------------------------------------- /tests/ext_thunder/test_thunder_networks.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/ext_thunder/test_thunder_networks.py -------------------------------------------------------------------------------- /tests/ext_thunder/test_thunder_pretrain.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/ext_thunder/test_thunder_pretrain.py -------------------------------------------------------------------------------- /tests/ext_thunder/test_unsloth_executor.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/ext_thunder/test_unsloth_executor.py -------------------------------------------------------------------------------- /tests/generate/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/generate/test_adapter.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/generate/test_adapter.py -------------------------------------------------------------------------------- /tests/generate/test_main.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/generate/test_main.py -------------------------------------------------------------------------------- /tests/generate/test_sequentially.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/generate/test_sequentially.py -------------------------------------------------------------------------------- /tests/generate/test_tp.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/generate/test_tp.py -------------------------------------------------------------------------------- /tests/generate/utils.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/generate/utils.py -------------------------------------------------------------------------------- /tests/test_adapter.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/test_adapter.py -------------------------------------------------------------------------------- /tests/test_adapter_v2.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/test_adapter_v2.py -------------------------------------------------------------------------------- /tests/test_api.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/test_api.py -------------------------------------------------------------------------------- /tests/test_args.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/test_args.py -------------------------------------------------------------------------------- /tests/test_batch.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/test_batch.py -------------------------------------------------------------------------------- /tests/test_chat.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/test_chat.py -------------------------------------------------------------------------------- /tests/test_ci.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/test_ci.py -------------------------------------------------------------------------------- /tests/test_cli.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/test_cli.py -------------------------------------------------------------------------------- /tests/test_config.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/test_config.py -------------------------------------------------------------------------------- /tests/test_config_hub.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/test_config_hub.py -------------------------------------------------------------------------------- /tests/test_deepseek_moe.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/test_deepseek_moe.py -------------------------------------------------------------------------------- /tests/test_distributed.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/test_distributed.py -------------------------------------------------------------------------------- /tests/test_evaluate.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/test_evaluate.py -------------------------------------------------------------------------------- /tests/test_full.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/test_full.py -------------------------------------------------------------------------------- /tests/test_generate_speculatively.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/test_generate_speculatively.py -------------------------------------------------------------------------------- /tests/test_lora.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/test_lora.py -------------------------------------------------------------------------------- /tests/test_merge_lora.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/test_merge_lora.py -------------------------------------------------------------------------------- /tests/test_model.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/test_model.py -------------------------------------------------------------------------------- /tests/test_multihead_latent_attention.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/test_multihead_latent_attention.py -------------------------------------------------------------------------------- /tests/test_pretrain.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/test_pretrain.py -------------------------------------------------------------------------------- /tests/test_prompts.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/test_prompts.py -------------------------------------------------------------------------------- /tests/test_readme.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/test_readme.py -------------------------------------------------------------------------------- /tests/test_rope.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/test_rope.py -------------------------------------------------------------------------------- /tests/test_serve.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/test_serve.py -------------------------------------------------------------------------------- /tests/test_tokenizer.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/test_tokenizer.py -------------------------------------------------------------------------------- /tests/test_trainer_support.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/test_trainer_support.py -------------------------------------------------------------------------------- /tests/test_utils.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tests/test_utils.py -------------------------------------------------------------------------------- /tutorials/0_to_litgpt.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/0_to_litgpt.md -------------------------------------------------------------------------------- /tutorials/convert_hf_checkpoint.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/convert_hf_checkpoint.md -------------------------------------------------------------------------------- /tutorials/convert_lit_models.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/convert_lit_models.md -------------------------------------------------------------------------------- /tutorials/deploy.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/deploy.md -------------------------------------------------------------------------------- /tutorials/developer-docs/README.md: -------------------------------------------------------------------------------- 1 | LitGPT developer documentation files. 2 | -------------------------------------------------------------------------------- /tutorials/developer-docs/adding-models.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/developer-docs/adding-models.md -------------------------------------------------------------------------------- /tutorials/developer-docs/python-api.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/developer-docs/python-api.md -------------------------------------------------------------------------------- /tutorials/download_model_weights.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/download_model_weights.md -------------------------------------------------------------------------------- /tutorials/evaluation.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/evaluation.md -------------------------------------------------------------------------------- /tutorials/examples/ptl-trainer/README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/examples/ptl-trainer/README.md -------------------------------------------------------------------------------- /tutorials/examples/ptl-trainer/litgpt_ptl_medium.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/examples/ptl-trainer/litgpt_ptl_medium.py -------------------------------------------------------------------------------- /tutorials/examples/ptl-trainer/litgpt_ptl_small.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/examples/ptl-trainer/litgpt_ptl_small.py -------------------------------------------------------------------------------- /tutorials/finetune.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/finetune.md -------------------------------------------------------------------------------- /tutorials/finetune_adapter.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/finetune_adapter.md -------------------------------------------------------------------------------- /tutorials/finetune_full.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/finetune_full.md -------------------------------------------------------------------------------- /tutorials/finetune_lora.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/finetune_lora.md -------------------------------------------------------------------------------- /tutorials/full_finetune_example.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/full_finetune_example.py -------------------------------------------------------------------------------- /tutorials/images/0_to_litgpt/commands.webp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/images/0_to_litgpt/commands.webp -------------------------------------------------------------------------------- /tutorials/images/0_to_litgpt/finetune.webp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/images/0_to_litgpt/finetune.webp -------------------------------------------------------------------------------- /tutorials/images/0_to_litgpt/instruction-1.webp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/images/0_to_litgpt/instruction-1.webp -------------------------------------------------------------------------------- /tutorials/images/0_to_litgpt/instruction-2.webp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/images/0_to_litgpt/instruction-2.webp -------------------------------------------------------------------------------- /tutorials/images/0_to_litgpt/pretrain.webp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/images/0_to_litgpt/pretrain.webp -------------------------------------------------------------------------------- /tutorials/images/0_to_litgpt/usage.webp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/images/0_to_litgpt/usage.webp -------------------------------------------------------------------------------- /tutorials/images/prepare_dataset/alpaca-2k.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/images/prepare_dataset/alpaca-2k.jpg -------------------------------------------------------------------------------- /tutorials/images/prepare_dataset/alpaca.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/images/prepare_dataset/alpaca.jpg -------------------------------------------------------------------------------- /tutorials/images/prepare_dataset/alpaca_libre.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/images/prepare_dataset/alpaca_libre.jpg -------------------------------------------------------------------------------- /tutorials/images/prepare_dataset/alpacagpt4.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/images/prepare_dataset/alpacagpt4.jpg -------------------------------------------------------------------------------- /tutorials/images/prepare_dataset/deita-multiturn.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/images/prepare_dataset/deita-multiturn.jpg -------------------------------------------------------------------------------- /tutorials/images/prepare_dataset/deita.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/images/prepare_dataset/deita.jpg -------------------------------------------------------------------------------- /tutorials/images/prepare_dataset/dolly.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/images/prepare_dataset/dolly.jpg -------------------------------------------------------------------------------- /tutorials/images/prepare_dataset/lima.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/images/prepare_dataset/lima.jpg -------------------------------------------------------------------------------- /tutorials/images/prepare_dataset/longform.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/images/prepare_dataset/longform.jpg -------------------------------------------------------------------------------- /tutorials/inference.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/inference.md -------------------------------------------------------------------------------- /tutorials/mkdocs.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/mkdocs.yml -------------------------------------------------------------------------------- /tutorials/oom.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/oom.md -------------------------------------------------------------------------------- /tutorials/prepare_dataset.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/prepare_dataset.md -------------------------------------------------------------------------------- /tutorials/pretrain.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/pretrain.md -------------------------------------------------------------------------------- /tutorials/pretrain_tinyllama.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/pretrain_tinyllama.md -------------------------------------------------------------------------------- /tutorials/python-api.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/python-api.md -------------------------------------------------------------------------------- /tutorials/quantize.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/quantize.md -------------------------------------------------------------------------------- /tutorials/resource-tables.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Lightning-AI/litgpt/HEAD/tutorials/resource-tables.md --------------------------------------------------------------------------------