Skip to content

Commit 95bdb7b

Browse files
Bernard Horanolyagpl
Bernard Horan
authored andcommitted
Update README.md
1 parent a069870 commit 95bdb7b

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

polyglot-chat-app/README.md

+9-9
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
# Polyglot Chat Application
22

3-
This example demonstrates how to integrate Python on GraalVM with a Micronaut application.
4-
The application uses the nltk module to analyze text sentiment.
5-
The application uses the Gradle build tool.
3+
This example demonstrates how to integrate Python in a Micronaut Java application using the Gradle build tool.
4+
The application uses the [Natural Language Toolkit (nltk)](https://www.nltk.org/) module to analyze the sentiment of user input.
5+
The example also shows how to create a native executable from the application using GraalVM.
66

77
## Preparation
88

@@ -14,11 +14,11 @@ The application uses the Gradle build tool.
1414
cd graalvm-demos/polyglot-chat-app
1515
```
1616

17-
2. Download and install the latest GraalPy as described in the [Getting Started guide](https://www.graalvm.org/latest/reference-manual/python/#installing-graalpy). For example on Linux:
17+
2. Download and install the latest GraalPy as described in the [Getting Started guide](https://www.graalvm.org/latest/reference-manual/python/#installing-graalpy). For example:
1818
```bash
1919
pyenv install graalpy-23.1.2
2020
pyenv shell graalpy-23.1.2
21-
``
21+
```
2222

2323
3. Create a virtual environment for the demo in the _resources_ directory, activate it, install the required package, and download a lexicon:
2424
```bash
@@ -34,8 +34,8 @@ The application uses the Gradle build tool.
3434
graalpy -c "import nltk; nltk.download('vader_lexicon')"
3535
```
3636

37-
4. (Optional) [Download and install GraalVM JDK for Java 21](https://www.graalvm.org/downloads/) or later to run Python with runtime compilation and to build a native image.
38-
The demo will work with any OpenJDK distribution, but will be much faster on GraalVM JDK.
37+
4. The demo will work with any OpenJDK distribution, but will be much faster on [GraalVM JDK for Java 21](https://www.graalvm.org/downloads/).
38+
3939

4040
## Building and Running the Application
4141

@@ -54,12 +54,12 @@ The demo will work with any OpenJDK distribution, but will be much faster on Gra
5454
```
5555
[bob 😀] awesome, GraalVM and GraalPy rock!
5656
[bob 🫥] are we done yet?
57-
[bob 💬] still loading the sentiment model I believe
57+
[bob 💬] Joined!
5858
```
5959

6060
## (Optional) Building a Native Executable
6161

62-
> Note: this requires [Download and install GraalVM JDK for Java 21](https://www.graalvm.org/downloads/) or later.
62+
> Note: this requires [GraalVM JDK for Java 21](https://www.graalvm.org/downloads/) or later.
6363

6464
The application can be compiled ahead-of-time to a native executable using GraalVM Native Image.
6565
The Python code must be copied to the _build/_ directory that is kept next to the native executable.

0 commit comments

Comments
 (0)