Skip to content

Commit 0910a6f

Browse files
removing etags and updating inference testing section
1 parent 6105099 commit 0910a6f

File tree

1 file changed

+15
-3
lines changed

1 file changed

+15
-3
lines changed

AzureML-Custom-Skill/notebook/custom_skill_azureml.ipynb

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -232,7 +232,6 @@
232232
"source": [
233233
"skillset_name = f'{datasource_container}-ss'\n",
234234
"skillset_def = {\n",
235-
" '@odata.etag': '\\'0x8D7F6C769AC06B2\\'',\n",
236235
" 'name': f'{skillset_name}',\n",
237236
" 'description': 'Skillset to enrich hotel reviews with aspect based sentiment',\n",
238237
" 'skills': [\n",
@@ -1496,8 +1495,22 @@
14961495
"metadata": {},
14971496
"outputs": [],
14981497
"source": [
1499-
"docs = [ \"Great\", \"The bathroom sink splashes water, need to be fixed. The bathtub/shower make loud noises. Other than that, it was a good stay.\" ]\n",
1498+
"%pip install git+https://github.com/NervanaSystems/nlp-architect.git@absa --user"
1499+
]
1500+
},
1501+
{
1502+
"cell_type": "code",
1503+
"execution_count": null,
1504+
"metadata": {},
1505+
"outputs": [],
1506+
"source": [
1507+
"from nlp_architect.models.absa.inference.inference import SentimentInference\n",
1508+
"\n",
1509+
"aspect_lex_path = \"../models/hotel_aspect_lex.csv\"\n",
1510+
"opinion_lex_path = \"../models/hotel_opinion_lex_reranked.csv\"\n",
1511+
"inference = SentimentInference(aspect_lex_path, opinion_lex_path)\n",
15001512
"\n",
1513+
"docs = [ \"Great\", \"The bathroom sink splashes water, need to be fixed. The bathtub/shower make loud noises. Other than that, it was a good stay.\" ]\n",
15011514
"sentiment_docs = []\n",
15021515
"\n",
15031516
"for doc_raw in docs:\n",
@@ -1795,7 +1808,6 @@
17951808
"outputs": [],
17961809
"source": [
17971810
"skillset_def = {\n",
1798-
" '@odata.etag': '\\'0x8D7F6C769AC06B2\\'',\n",
17991811
" 'name': f'{skillset_name}',\n",
18001812
" 'description': 'Skillset to enrich hotel reviews with aspect based sentiment',\n",
18011813
" 'skills': [\n",

0 commit comments

Comments
 (0)