Bootstrap knowledge of LLMs ASAP. With a bias/focus to GPT.
Avoid being a link dump. Try to provide only valuable well tuned information.
Neural network links before starting with transformers.
| from transformers import PreTrainedTokenizerFast | |
| fast_tokenizer = PreTrainedTokenizerFast(tokenizer_file="/home/ubuntu/LLM/module/claude-v1-tokenization.json") | |
| text = "Hello, this is a test input." | |
| tokens = fast_tokenizer.tokenize(text) | |
| tokens |
Maybe you've heard about this technique but you haven't completely understood it, especially the PPO part. This explanation might help.
We will focus on text-to-text language models ๐, such as GPT-3, BLOOM, and T5. Models like BERT, which are encoder-only, are not addressed.
Reinforcement Learning from Human Feedback (RLHF) has been successfully applied in ChatGPT, hence its major increase in popularity. ๐
RLHF is especially useful in two scenarios ๐:
| import cv2 | |
| import numpy as np | |
| def deskew(im, max_skew=10): | |
| height, width = im.shape | |
| # Create a grayscale image and denoise it | |
| im_gs = cv2.cvtColor(im, cv2.COLOR_BGR2GRAY) | |
| im_gs = cv2.fastNlMeansDenoising(im_gs, h=3) |
| # Author: Zameer Ansari | |
| # You should look at the following URL's in order to grasp a solid understanding | |
| # of Nginx configuration files in order to fully unleash the power of Nginx. | |
| # http://wiki.nginx.org/Pitfalls | |
| # http://wiki.nginx.org/QuickStart | |
| # http://wiki.nginx.org/Configuration | |
| # | |
| # Generally, you will want to move this file somewhere, and start with a clean | |
| # file but keep this around for reference. Or just disable in sites-enabled. | |
| # |
| #!/usr/bin/env python | |
| # -*- coding: utf-8 -*- | |
| """ | |
| Outputs some information on CUDA-enabled devices on your computer, | |
| including current memory usage. | |
| It's a port of https://gist.github.com/f0k/0d6431e3faa60bffc788f8b4daa029b1 | |
| from C to Python with ctypes, so it can run without compiling anything. Note | |
| that this is a direct translation with no attempt to make the code Pythonic. |
์์ด์ง๋ง, ์กฐ๊ธ ๋ ์์ธํ๊ฒ ๋งํฌ๋ค์ด ์ฌ์ฉ๋ฒ์ ์๋ดํ๊ณ ์๋
"Markdown Guide (https://www.markdownguide.org/)" ๋ฅผ ๋ณด์๋ ๊ฒ์ ์ถ์ฒํฉ๋๋ค. ^^
์, ๊ทธ๋ฆฌ๊ณ ๋งํฌ๋ค์ด๋ง์ผ๋ก ํํ์ด ๋ถ์กฑํ๋ค๊ณ ๋๋ผ์ ๋ค๋ฉด, HTML ํ๊ทธ๋ฅผ ํ์ฉํ์๋ ๊ฒ๋ ์ข์ต๋๋ค.