This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/examples/Customizing_embeddings.ipynb b/examples/Customizing_embeddings.ipynb | |
index 4068254..eaaa871 100644 | |
--- a/examples/Customizing_embeddings.ipynb | |
+++ b/examples/Customizing_embeddings.ipynb | |
@@ -51,7 +51,7 @@ | |
"from sklearn.model_selection import train_test_split # for splitting train & test data\n", | |
"import torch # for matrix optimization\n", | |
"\n", | |
- "from openai.embeddings_utils import get_embedding, cosine_similarity # for embeddings\n" | |
+ "from utils.embeddings_utils import get_embedding, cosine_similarity # for embeddings\n" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import openai | |
import json | |
#TODO: Add your OpenAI key here. | |
openai.api_key = "" | |
""" | |
The new OpenAI's new parallel function calling API launched at Dev Day in Nov 2023 | |
can coordinate multiple function calls and feed the results back to the model. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import openai | |
import json | |
# Crudely patched version of: https://platform.openai.com/docs/guides/function-calling | |
# TOOD: Add your open key here. | |
openai.api_key = "" | |
# Example dummy function hard coded to return the same weather | |
# In production, this could be your backend API or an external API |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// MoPub MPTableViewAdPlacer integration overview | |
// In table view controller: | |
self.adPlacer = [MPTableViewAdPlacer placerWithTableView:self.tableView | |
viewController:self | |
defaultAdRenderingClass:[SomeTableViewAdCell class]]; | |
... | |
[self.adPlacer loadAdsForAdUnitID:@"mopub_ad_unit_id"]; | |
// In format definition: |