CS224N Assignment 4
(a) MinGPT
任务(a) 要求阅读 mingpt-demo/play_char.ipynb 代码
1. 位置编码
GPT 用的位置编码不是正余弦函数,而是自训练的参数矩阵:
RoPE
Bilateral LSTM
CS224N Lecture 9: Pretraining
CS224N Lecture 8: Self-Attention and Transformers
CS224N Lecture 7: Attention, Final Project and LLM intro
CS224N Lecture 5: Recurrent Neural Networks
CS224N Lecture 6: Sequence to Sequence Models
CS224N Assignment 1
Part 1
Question 1.1: Implement distinct_words [code] (2 points)
Write a method to work out the distinct words (word types) that occur in the corpus.
You can use for loops to process the input corpus (a list of list of strings), but try using Python list comprehensions (which are generally faster). In particular, this may be useful to flatten a list of lists. If you’re not familiar with Python list comprehensions in general, here’s more information.
