Skip to content

Commit b58d53b

Browse files
committed
start rewrite node qs
1 parent 11a284d commit b58d53b

File tree

1 file changed

+2
-15
lines changed

1 file changed

+2
-15
lines changed

articles/cognitive-services/personalizer/includes/quickstart-sdk-nodejs.md

Lines changed: 2 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ ms.service: cognitive-services
77
ms.subservice: personalizer
88
ms.topic: include
99
ms.custom: cog-serv-seo-aug-2020
10-
ms.date: 08/27/2020
10+
ms.date: 02/02/2023
1111
---
1212

1313
You'll need to install the Personalizer client library forN ode.js to:
@@ -80,23 +80,10 @@ Install the remaining npm packages for this quickstart:
8080
npm install @azure/ms-rest-azure-js @azure/ms-rest-js readline-sync uuid --save
8181
```
8282

83-
## Object model
8483

85-
The Personalizer client is a [PersonalizerClient](/javascript/api/@azure/cognitiveservices-personalizer/personalizerclient) object that authenticates to Azure using Microsoft.Rest.ServiceClientCredentials, which contains your key.
84+
Personalizer is meant to run on applications that receive and interpret real-time data. For the purpose of this quickstart, you'll use sample code to generate imaginary customer actions on a grocery website. The following code block defines three key methods: **getActionsList**, **getContextFeaturesList** and **getReward**.
8685

87-
To ask for the single best item of the content, create a [RankRequest](/javascript/api/@azure/cognitiveservices-personalizer/rankrequest), then pass it to [client.Rank](/javascript/api/@azure/cognitiveservices-personalizer/personalizerclient#rank-rankrequest--msrest-requestoptionsbase-) method. The Rank method returns a RankResponse.
8886

89-
To send a reward to Personalizer, create a [RewardRequest](/javascript/api/@azure/cognitiveservices-personalizer/rewardrequest), then pass it to the [Reward](/javascript/api/@azure/cognitiveservices-personalizer/events#reward-string--rewardrequest--servicecallback-void--) method on the Events class.
90-
91-
The reward scoring in this quickstart is trivial. In a production system, the determination of what impacts the [reward score](../concept-rewards.md) and by how much can be a complex process, that you may decide to change over time. Reward scores should be one of the primary design decisions in your Personalizer architecture.
92-
93-
## Code examples
94-
95-
These code snippets show you how to do the following tasks with the Personalizer client library for Node.js:
96-
97-
* [Create a Personalizer client](#authenticate-the-client)
98-
* [Rank API](#request-the-best-action)
99-
* [Reward API](#send-a-reward)
10087

10188
## Authenticate the client
10289

0 commit comments

Comments
 (0)