Skip to content

Update LLM section for winter kickstart#761

Merged
ruokolt merged 8 commits intomasterfrom
update_llms_for_winter_kickstart
Feb 25, 2025
Merged

Update LLM section for winter kickstart#761
ruokolt merged 8 commits intomasterfrom
update_llms_for_winter_kickstart

Conversation

@ruokolt
Copy link
Copy Markdown
Contributor

@ruokolt ruokolt commented Feb 21, 2025

WIP.

Suggestion to make the LLM page more concise, removing obsolete sections (llama checkpoint sections).

@ruokolt ruokolt requested a review from YuTian8328 February 21, 2025 08:40
@ruokolt
Copy link
Copy Markdown
Contributor Author

ruokolt commented Feb 21, 2025

TODO: Add a brief description (or link to instructions) how to get a Jupyter session on Triton.

@ruokolt ruokolt changed the title simplify instructions, discard llama checkpoint section (obsolete) Update LLM section for winter kickstart Feb 21, 2025


Here is a Python script using huggingface model.
Below is a Python script using a HuggingFace model (``mistralai/Mistral-7B-v0.1``) for text generation.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can use this one: https://github.com/AaltoSciComp/llm-examples/blob/main/huggingface-models/your_script.py, with a newer model, explicit dtype specification and device mapping.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, let's use that script.

- ``MODEL_WEIGHTS`` - Path to the model weights in GGUF file format.

This Python code snippet is part of a 'Chat with Your PDF Documents' example, utilizing LangChain and leveraging model weights stored in a .gguf file. For detailed environment setting up and Python code, please check out `this repo <https://github.com/AaltoSciComp/llm-examples/tree/main/chat-with-pdf>`__.
NOTE: this example repo is mainly meant to run on CPUs, if you want to run on GPUs, you can checkout a branch "llamacpp-gpu" of this repo for details.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agree with the deletion, too old models. But maybe add a line: "If you need assistance running LLMs in formats other than HuggingFace's, please contact the RSEs.

.. group-tab:: jupyter notebook
.. group-tab:: Jupyter notebook

TODO: How to get Jupyter session with GPU on Triton?
Copy link
Copy Markdown
Contributor

@YuTian8328 YuTian8328 Feb 24, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure if we recommend this, I had an example before: https://github.com/AaltoSciComp/triton-llm-tutorial/tree/main/triton-examples though.

Here is a Python script using huggingface model.
Below is a Python script using a HuggingFace model (``mistralai/Mistral-7B-v0.1``) for text generation.

Use it as the content of ``your_script.py`` in the Slurm script example above or a Jupyter notebook cell.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If we recommend the same content for jupyter notebook, a gpu session is needed.

@YuTian8328 YuTian8328 marked this pull request as ready for review February 24, 2025 13:56
@ruokolt ruokolt merged commit 2385328 into master Feb 25, 2025
1 check failed
@ruokolt ruokolt deleted the update_llms_for_winter_kickstart branch February 25, 2025 09:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants