Skip to content

Commit f32c699

Browse files
JasonWeill3coins
andauthored
Change sagemaker example to make more sense (jupyterlab#231)
* Change sagemaker example to make more sense * Makes example more neutral * Update sagemaker.ipynb Update the example for flan-xl. --------- Co-authored-by: Piyush Jain <[email protected]>
1 parent 68fdff1 commit f32c699

File tree

1 file changed

+8
-19
lines changed

1 file changed

+8
-19
lines changed

examples/sagemaker.ipynb

+8-19
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@
2929
]
3030
},
3131
{
32-
"attachments": {},
3332
"cell_type": "markdown",
3433
"id": "9f2b0270-1c33-4918-b534-4ec104f90141",
3534
"metadata": {},
@@ -49,24 +48,24 @@
4948
},
5049
{
5150
"cell_type": "code",
52-
"execution_count": 4,
51+
"execution_count": 2,
5352
"id": "31f3e6e3-48cf-4e60-96d3-8b8e1dd34bec",
5453
"metadata": {
5554
"tags": []
5655
},
5756
"outputs": [
5857
{
5958
"data": {
60-
"text/html": [
61-
"AI generated code inserted below &#11015;&#65039;"
59+
"text/markdown": [
60+
"What is the weather like in the US today?"
6261
],
6362
"text/plain": [
64-
"<IPython.core.display.HTML object>"
63+
"<IPython.core.display.Markdown object>"
6564
]
6665
},
67-
"execution_count": 4,
66+
"execution_count": 2,
6867
"metadata": {
69-
"text/html": {
68+
"text/markdown": {
7069
"jupyter_ai": {
7170
"model_id": "jumpstart-dft-hf-text2text-flan-t5-xl",
7271
"provider_id": "sagemaker-endpoint"
@@ -77,18 +76,8 @@
7776
}
7877
],
7978
"source": [
80-
"%%ai sagemaker-endpoint:jumpstart-dft-hf-text2text-flan-t5-xl --region-name=us-east-1 --request-schema={\"text_inputs\":\"<prompt>\"} --response-path=generated_texts.[0] -f code\n",
81-
"Write some Python code"
82-
]
83-
},
84-
{
85-
"cell_type": "code",
86-
"execution_count": null,
87-
"id": "42408ea8-7264-44bc-ac0c-6b5dd03134d6",
88-
"metadata": {},
89-
"outputs": [],
90-
"source": [
91-
"a = [] b = [] c = [] d = ["
79+
"%%ai sagemaker-endpoint:jumpstart-dft-hf-text2text-flan-t5-xl --region-name=us-east-1 --request-schema={\"text_inputs\":\"<prompt>\"} --response-path=generated_texts.[0]\n",
80+
"Generate a question about weather today."
9281
]
9382
},
9483
{

0 commit comments

Comments
 (0)