Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
Denis2054 authored Dec 6, 2023
1 parent dad5d78 commit f479747
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,13 +22,16 @@ Just look for the Dolphin 🐬 and enjoy your ride into the future of AI!
You can run these notebooks on cloud platforms like [Google Colab](https://colab.research.google.com/) or your local machine. Note that some chapters require a GPU to run in a reasonable amount of time, so we recommend one of the cloud platforms as they come pre-installed with CUDA.

## Getting started with OpenAI API
December 6,2023. The notebooks in this repository were updated. **Note**: Watch for more changes in 2024 Q1.
December 6, 2023. OpenAI is currently updating its platform. If you encounter issues with the notebooks of this repository, you can implement the following tips:
- As of January 4,2024, [OpenAI deprecations](https://platform.openai.com/docs/deprecations) apply to 'davinci'. The recommended replacement is 'davinci-002'
- Google Colab: Cohere(language functions) and tiktoken(BPE tokenizer) required to install OpenAI(!pip install tiktoken and !pip install --upgrade cohere)
- API call changed from "openai.Completion.create" to "client.chat.completions.create" with client= [YOUR OPENAI CLIENT]
- API call changed from engine=[model name] to model=[model name]
- Response object is evolving. Recommendation: first print "response", then analyze the object to then access what you need.

You can find examples of these update tips in thee following notebooks that you can apply to other notebooks if necessary:
-[Getting_Started_GPT_3.ipynb)](https://github.com/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter07/Getting_Started_GPT_3.ipynb), [Summarizing_with_ChatGPT.ipynb](https://github.com/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter09/Summarizing_with_ChatGPT.ipynb), and [Semantic_Role_Labeling_with_ChatGPT.ipynb](https://github.com/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter10/Semantic_Role_Labeling_with_ChatGPT.ipynb)

### Running on a cloud platform or in your environment

To run these notebooks on a cloud platform, just click on one of the badges in the table below or run them on your environment.
Expand Down Expand Up @@ -65,15 +68,18 @@ To run these notebooks on a cloud platform, just click on one of the badges in t
**Chapter 15: From NLP to Task-Agnostic Transformer Models**
| <ul><li>Vision_Transformers.ipynb</li><li>DALL_E.ipynb</li></ul> | [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter15/Vision_Transformers.ipynb) [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter15/DALL_E.ipynb) | [![Kaggle](https://kaggle.com/static/images/open-in-kaggle.svg)](https://kaggle.com/kernels/welcome?src=https://github.com/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter15/Vision_Transformers.ipynb) [![Kaggle](https://kaggle.com/static/images/open-in-kaggle.svg)](https://kaggle.com/kernels/welcome?src=https://github.com/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter15/DALL_E.ipynb) | [![Gradient](https://assets.paperspace.io/img/gradient-badge.svg)](https://console.paperspace.com/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter15/Vision_Transformers.ipynb) [![Gradient](https://assets.paperspace.io/img/gradient-badge.svg)](https://console.paperspace.com/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter15/DALL_E.ipynb) | [![Open In SageMaker Studio Lab](https://studiolab.sagemaker.aws/studiolab.svg)](https://studiolab.sagemaker.aws/import/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter15/Vision_Transformers.ipynb) [![Open In SageMaker Studio Lab](https://studiolab.sagemaker.aws/studiolab.svg)](https://studiolab.sagemaker.aws/import/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter15/DALL_E.ipynb) |
**Chapter 16 : The Emergence of Transformer-Driven Copilots**
December 6,2024 information: OpenAI is currently updating its platform. If you encounter issues with the notebooks in this chapter,read the tips in [changelog of this repository](https://github.com/Denis2054/Transformers-for-NLP-2nd-Edition#getting-started-with-openai-api)
| <ul><li>Domain_Specific_GPT_3_Functionality.ipynb</li><li>KantaiBERT_Recommender.ipynb</li><li>Vision_Transformer_MLP_Mixer.ipynb</li><li>Compact_Convolutional_Transformers.ipynb</li></ul>| [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter16/Domain_Specific_GPT_3_Functionality.ipynb) [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter16/KantaiBERT_Recommender.ipynb) [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter16/Vision_Transformer_MLP_Mixer.ipynb) [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter16/Compact_Convolutional_Transformers.ipynb) | [![Kaggle](https://kaggle.com/static/images/open-in-kaggle.svg)](https://kaggle.com/kernels/welcome?src=https://github.com/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter16/Domain_Specific_GPT_3_Functionality.ipynb) [![Kaggle](https://kaggle.com/static/images/open-in-kaggle.svg)](https://kaggle.com/kernels/welcome?src=https://github.com/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter16/KantaiBERT_Recommender.ipynb) [![Kaggle](https://kaggle.com/static/images/open-in-kaggle.svg)](https://kaggle.com/kernels/welcome?src=https://github.com/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter16/Vision_Transformer_MLP_Mixer.ipynb)[![Kaggle](https://kaggle.com/static/images/open-in-kaggle.svg)](https://kaggle.com/kernels/welcome?src=https://github.com/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter16/Compact_Convolutional_Transformers.ipynb) | [![Gradient](https://assets.paperspace.io/img/gradient-badge.svg)](https://console.paperspace.com/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter16/Domain_Specific_GPT_3_Functionality.ipynb) [![Gradient](https://assets.paperspace.io/img/gradient-badge.svg)](https://console.paperspace.com/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter16/KantaiBERT_Recommender.ipynb) [![Gradient](https://assets.paperspace.io/img/gradient-badge.svg)](https://console.paperspace.com/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter16/Vision_Transformer_MLP_Mixer.ipynb) [![Gradient](https://assets.paperspace.io/img/gradient-badge.svg)](https://console.paperspace.com/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter16/Compact_Convolutional_Transformers.ipynb)| [![Open In SageMaker Studio Lab](https://studiolab.sagemaker.aws/studiolab.svg)](https://studiolab.sagemaker.aws/import/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter16/Domain_Specific_GPT_3_Functionality.ipynb) [![Open In SageMaker Studio Lab](https://studiolab.sagemaker.aws/studiolab.svg)](https://studiolab.sagemaker.aws/import/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter16/KantaiBERT_Recommender.ipynb) [![Open In SageMaker Studio Lab](https://studiolab.sagemaker.aws/studiolab.svg)](https://studiolab.sagemaker.aws/import/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter16/Vision_Transformer_MLP_Mixer.ipynb) [![Open In SageMaker Studio Lab](https://studiolab.sagemaker.aws/studiolab.svg)](https://studiolab.sagemaker.aws/import/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter16/Compact_Convolutional_Transformers.ipynb) |
**Chapter 17 :🐬 Consolidation of Suprahuman Transformers with OpenAI ChatGPT and GPT-4**
December 6,2024 information: OpenAI is currently updating its platform. If you encounter issues with the notebooks in this chapter,read the tips in [changelog of this repository](https://github.com/Denis2054/Transformers-for-NLP-2nd-Edition#getting-started-with-openai-api)
| <ul><li>Jump_Starting_ChatGPT_with_the_OpenAI_API.ipynb</li><li>ChatGPT_Plus_writes_and_explains_classification.ipynb</li><li>Getting_Started_OpenAI_GPT_4.ipynb</li><li>Prompt_Engineering_as_an_alternative_to_fine_tuning.ipynb</li><li>Getting_Started_with_the_DALL_E_2_API.ipynb</li><li>Speaking_with_ChatGPT.ipynb</li><li>ALL_in_One.ipynb</li></ul>| [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter17/Jump_Starting_ChatGPT_with_the_OpenAI_API.ipynb) [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter17/ChatGPT_Plus_writes_and_explains_classification.ipynb) [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter17/Getting_Started_OpenAI_GPT_4.ipynb) [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter17/Prompt_Engineering_as_an_alternative_to_fine_tuning.ipynb) [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter17/Getting_Started_with_the_DALL_E_2_API.ipynb) [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter17/Speaking_with_ChatGPT.ipynb) [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter17/ALL_in_One.ipynb)| [![Kaggle](https://kaggle.com/static/images/open-in-kaggle.svg)](https://kaggle.com/kernels/welcome?src=https://github.com/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter17/Jump_Starting_ChatGPT_with_the_OpenAI_API.ipynb) [![Kaggle](https://kaggle.com/static/images/open-in-kaggle.svg)](https://kaggle.com/kernels/welcome?src=https://github.com/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter17/ChatGPT_Plus_writes_and_explains_classification.ipynb) [![Kaggle](https://kaggle.com/static/images/open-in-kaggle.svg)](https://kaggle.com/kernels/welcome?src=https://github.com/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter17/Getting_Started_with_GPT_4.ipynb)[![Kaggle](https://kaggle.com/static/images/open-in-kaggle.svg)](https://kaggle.com/kernels/welcome?src=https://github.com/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter17/Prompt_Engineering_as_an_alternative_to_fine_tuning.ipynb)[![Kaggle](https://kaggle.com/static/images/open-in-kaggle.svg)](https://kaggle.com/kernels/welcome?src=https://github.com/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter17/Getting_Started_with_the_DALL_E_2_API.ipynb)[![Kaggle](https://kaggle.com/static/images/open-in-kaggle.svg)](https://kaggle.com/kernels/welcome?src=https://github.com/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter17/Speaking_with_ChatGPT.ipynb)[![Kaggle](https://kaggle.com/static/images/open-in-kaggle.svg)](https://kaggle.com/kernels/welcome?src=https://github.com/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter17/ALL_in_One.ipynb) | [![Gradient](https://assets.paperspace.io/img/gradient-badge.svg)](https://console.paperspace.com/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter17/Jump_Starting_ChatGPT_with_the_OpenAI_API.ipynb) [![Gradient](https://assets.paperspace.io/img/gradient-badge.svg)](https://console.paperspace.com/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter17/ChatGPT_Plus_writes_and_explains_classification.ipynb) [![Gradient](https://assets.paperspace.io/img/gradient-badge.svg)](https://console.paperspace.com/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter17/Getting_Started_with_GPT_4.ipynb) [![Gradient](https://assets.paperspace.io/img/gradient-badge.svg)](https://console.paperspace.com/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter17/Prompt_Engineering_as_an_alternative_to_fine_tuning.ipynb) [![Gradient](https://assets.paperspace.io/img/gradient-badge.svg)](https://console.paperspace.com/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter17/Getting_Started_with_the_DALL_E_2_API.ipynb) [![Gradient](https://assets.paperspace.io/img/gradient-badge.svg)](https://console.paperspace.com/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter17/Speaking_with_ChatGPT.ipynb)[![Gradient](https://assets.paperspace.io/img/gradient-badge.svg)](https://console.paperspace.com/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter17/ALL_in_One.ipynb)| [![Open In SageMaker Studio Lab](https://studiolab.sagemaker.aws/studiolab.svg)](https://studiolab.sagemaker.aws/import/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter17/Jump_Starting_ChatGPT_with_the_OpenAI_API.ipynb) [![Open In SageMaker Studio Lab](https://studiolab.sagemaker.aws/studiolab.svg)](https://studiolab.sagemaker.aws/import/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter17/ChatGPT_Plus_writes_and_explains_classification.ipynb) [![Open In SageMaker Studio Lab](https://studiolab.sagemaker.aws/studiolab.svg)](https://studiolab.sagemaker.aws/import/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter17/Getting_Started_with_GPT_4.ipynb) [![Open In SageMaker Studio Lab](https://studiolab.sagemaker.aws/studiolab.svg)](https://studiolab.sagemaker.aws/import/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter17/Prompt_Engineering_as_an_alternative_to_fine_tuning.ipynb) [![Open In SageMaker Studio Lab](https://studiolab.sagemaker.aws/studiolab.svg)](https://studiolab.sagemaker.aws/import/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter17/Getting_Started_with_the_DALL_E_2_API.ipynb) [![Open In SageMaker Studio Lab](https://studiolab.sagemaker.aws/studiolab.svg)](https://studiolab.sagemaker.aws/import/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter17/Speaking_with_ChatGPT.ipynb) [![Open In SageMaker Studio Lab](https://studiolab.sagemaker.aws/studiolab.svg)](https://studiolab.sagemaker.aws/import/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/Chapter17/ALL_in_One.ipynb) |
**Appendix III: Generic Text Completion with GPT-2**
|<ul><li>OpenAI_GPT_2.ipynb</li></ul> | [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/AppendixIII/OpenAI_GPT_2.ipynb) | [![Kaggle](https://kaggle.com/static/images/open-in-kaggle.svg)](https://kaggle.com/kernels/welcome?src=https://github.com/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/AppendixIII/OpenAI_GPT_2.ipynb) | [![Gradient](https://assets.paperspace.io/img/gradient-badge.svg)](https://console.paperspace.com/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/AppendixIII/OpenAI_GPT_2.ipynb) | [![Open In SageMaker Studio Lab](https://studiolab.sagemaker.aws/studiolab.svg)](https://studiolab.sagemaker.aws/import/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/AppendixIII/OpenAI_GPT_2.ipynb) |
**Appendix IV: Custom Text Completion with GPT-2**
|<ul><li>Training_OpenAI_GPT_2.ipynb</li></ul> | [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/AppendixIV/Training_OpenAI_GPT_2.ipynb) | [![Kaggle](https://kaggle.com/static/images/open-in-kaggle.svg)](https://kaggle.com/kernels/welcome?src=https://github.com/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/AppendixIV/Training_OpenAI_GPT_2.ipynb) | [![Gradient](https://assets.paperspace.io/img/gradient-badge.svg)](https://console.paperspace.com/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/AppendixIV/Training_OpenAI_GPT_2.ipynb) | [![Open In SageMaker Studio Lab](https://studiolab.sagemaker.aws/studiolab.svg)](https://studiolab.sagemaker.aws/import/github/Denis2054/Transformers-for-NLP-2nd-Edition/blob/main/AppendixIV/Training_OpenAI_GPT_2.ipynb) |

## Additional OpenAI Bonus Notebooks
December 6,2024 information: OpenAI is currently updating its platform. If you encounter issues with the notebooks in this section,read the tips in [changelog of this repository](https://github.com/Denis2054/Transformers-for-NLP-2nd-Edition#getting-started-with-openai-api)

| Bonus | Colab | Kaggle | Gradient | SageMaker Studio Lab |
| ----- | ----- | ------ | -------- | ------------------- |
Expand Down

0 comments on commit f479747

Please sign in to comment.