Skip to content

Commit 24dca60

Browse files
committed
ruby and java tweeks
1 parent 41c8471 commit 24dca60

File tree

2 files changed

+8
-7
lines changed

2 files changed

+8
-7
lines changed

articles/cognitive-services/LUIS/luis-get-started-java-get-intent.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ ms.author: diberry
1919

2020
## Prerequisites
2121

22-
* [JDK SE)](http://www.oracle.com/technetwork/java/javase/downloads/index.html) (Java Development Kit, Standard Edition
22+
* [JDK SE](http://www.oracle.com/technetwork/java/javase/downloads/index.html) (Java Development Kit, Standard Edition)
2323
* [Visual Studio Code](https://code.visualstudio.com/)
2424
* Public app ID: df67dcdb-c37d-46af-88e1-8b97951ca1c2
2525

@@ -38,15 +38,15 @@ ms.author: diberry
3838

3939
You can use Java to access the same results you saw in the browser window in the previous step.
4040

41-
1. Copy the following code to create a class in your IDE:
41+
1. Copy the following code to create a class in a file named `LuisGetRequest.java`:
4242

4343
[!code-java[Console app code that calls a LUIS endpoint](~/samples-luis/documentation-samples/quickstarts/analyze-text/java/call-endpoint.java)]
4444

4545
2. Replace the value of the `YOUR-KEY` variable with your LUIS key.
4646

47-
3. In your IDE, add references to `httpclient` and `httpcore` libraries. Compile the java program.
47+
3. Compile the java program with `javac -cp ":lib/*" LuisGetRequest.java`.
4848

49-
4. Run the application. It displays the same JSON that you saw earlier in the browser window.
49+
4. Run the application with `java -cp ":lib/*" LuisGetRequest.java`. It displays the same JSON that you saw earlier in the browser window.
5050

5151
![Console window displays JSON result from LUIS](./media/luis-get-started-java-get-intent/console-turn-on.png)
5252

articles/cognitive-services/LUIS/luis-get-started-python-get-intent.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -58,16 +58,17 @@ To understand what a LUIS app returns, you can paste the URL of a sample LUIS ap
5858

5959
You can use Python to access the same results you saw in the browser window in the previous step.
6060

61-
1. Copy one of the following code snippets:
61+
1. Copy one of the following code snippets to a file called `quickstart-call-endpoint.py`:
6262

6363
[!code-python[Console app code that calls a LUIS endpoint for Python 2.7](~/samples-luis/documentation-samples/quickstarts/analyze-text/python/2.x/quickstart-call-endpoint-2-7.py)]
6464

6565
[!code-python[Console app code that calls a LUIS endpoint for Python 3.6](~/samples-luis/documentation-samples/quickstarts/analyze-text/python/3.x/quickstart-call-endpoint-3-6.py)]
6666

67-
6867
2. Replace the value of the `Ocp-Apim-Subscription-Key` field with your LUIS endpoint key.
6968

70-
3. Run the script. It displays the same JSON that you saw earlier in the browser window.
69+
3. Install dependencies with `pip install requests`.
70+
71+
4. Run the script with `python ./quickstart-call-endpoint.py`. It displays the same JSON that you saw earlier in the browser window.
7172
<!--
7273
![Console window displays JSON result from LUIS](./media/luis-get-started-python-get-intent/console-turn-on.png)
7374
-->

0 commit comments

Comments
 (0)