Skip to content

Commit d0a84b1

Browse files
author
Drew Kerrigan
committed
Formatting readme
1 parent 7b544b3 commit d0a84b1

File tree

1 file changed

+40
-40
lines changed

1 file changed

+40
-40
lines changed

README.md

Lines changed: 40 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -2,40 +2,6 @@
22

33
This project contains a custom processor for [Apache Nifi](https://nifi.apache.org/) which implements a subset of the functionality in the [Stanford CoreNLP](https://stanfordnlp.github.io/CoreNLP/) toolkit.
44

5-
## Installation
6-
7-
Create a directory for custom nifi processors if it doesn't exist:
8-
9-
```
10-
mkdir -p $NIFI_HOME/nars/lib1
11-
```
12-
13-
Copy `nifi-stanfordcorenlp-nar-1.0.nar` to `$NIFI_HOME/nars/lib1`
14-
15-
Update your `$NIFI_HOME/conf/nifi.properties` to include the following:
16-
17-
```
18-
nifi.nar.library.directory.lib1=/nars/lib1
19-
```
20-
21-
Update your `$NIFI_HOME/conf/bootstrap.conf` with increased memory needed for CoreNLP:
22-
23-
```
24-
# JVM memory settings
25-
#java.arg.2=-Xms512m
26-
#java.arg.3=-Xmx512m
27-
java.arg.2=-Xms4g
28-
java.arg.3=-Xmx4g
29-
```
30-
31-
Start nifi as usual
32-
33-
```
34-
nifi start
35-
```
36-
37-
For more information on how to configure custom nar files, visit the [Nifi Documentation](https://nifi.apache.org/docs/nifi-docs/html/administration-guide.html#core-properties-br).
38-
395
## Usage
406

417
### Create Input File
@@ -55,14 +21,12 @@ In this example I'm using the standard `GetFile` and `PutFile` processors. They
5521

5622
### Add Custom Processor
5723

58-
![Add Processor](./doc/add_processor.png "Add Processor")
24+
Assuming the nar file was configured properly in the [Installation](#installation) step, you should be able to search for `Core` or `NLP` to find the `StanfordCoreNLPProcessor`.
5925

60-
Assuming the nar file was configured properly in the installation step, you should be able to search for `Core` or `NLP` to find the `StanfordCoreNLPProcessor`.
26+
![Add Processor](./doc/add_processor.png "Add Processor")
6127

6228
### Configure Properties
6329

64-
![Configure Properties](./doc/configure_local.png "Configure Properties")
65-
6630
In the Properties tab of the processor configuration, you will need to configure the entity types that you want to extract from the input as a comma separated list. Here is a brief summary of the configuration options:
6731

6832
* `Entity Types`
@@ -86,12 +50,14 @@ In the Properties tab of the processor configuration, you will need to configure
8650
* `StanfordCoreNLPClient API Secret`
8751
* Description: StanfordCoreNLPClient API Secret for servers that have authentication configured, not required.
8852

89-
### Add Connections
53+
![Configure Properties](./doc/configure_local.png "Configure Properties")
9054

91-
![Add Connections](./doc/running.png "Add Connections")
55+
### Add Connections
9256

9357
After the `StanfordCoreNLPProcessor` is configured, connect it with inputs and outputs. The processor can terminate with `success` or `failure` relationships.
9458

59+
![Add Connections](./doc/running.png "Add Connections")
60+
9561
### Verify Output
9662

9763
Start all of the processors in your Nifi flow. In the configured output folder for the `PutFile` component, you should see the updated json file:
@@ -115,6 +81,40 @@ Start all of the processors in your Nifi flow. In the configured output folder f
11581
}
11682
```
11783

84+
## Installation
85+
86+
Create a directory for custom nifi processors if it doesn't exist:
87+
88+
```
89+
mkdir -p $NIFI_HOME/nars/lib1
90+
```
91+
92+
Copy `nifi-stanfordcorenlp-nar-1.0.nar` to `$NIFI_HOME/nars/lib1`
93+
94+
Update your `$NIFI_HOME/conf/nifi.properties` to include the following:
95+
96+
```
97+
nifi.nar.library.directory.lib1=/nars/lib1
98+
```
99+
100+
Update your `$NIFI_HOME/conf/bootstrap.conf` with increased memory needed for CoreNLP:
101+
102+
```
103+
# JVM memory settings
104+
#java.arg.2=-Xms512m
105+
#java.arg.3=-Xmx512m
106+
java.arg.2=-Xms4g
107+
java.arg.3=-Xmx4g
108+
```
109+
110+
Start nifi as usual
111+
112+
```
113+
nifi start
114+
```
115+
116+
For more information on how to configure custom nar files, visit the [Nifi Documentation](https://nifi.apache.org/docs/nifi-docs/html/administration-guide.html#core-properties-br).
117+
118118
## Build
119119

120120
### Maven

0 commit comments

Comments
 (0)