Skip to content
This repository was archived by the owner on Nov 8, 2022. It is now read-only.

Commit 30591cc

Browse files
author
Peter Izsak
authored
Merge pull request #83 from NervanaSystems/peter/documentation
Update documentation to reflect 0.5
2 parents 52ab9cf + 2deab17 commit 30591cc

File tree

455 files changed

+89428
-14249
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

455 files changed

+89428
-14249
lines changed

.gitignore

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,14 +8,12 @@
88
.styleenv
99
.coverage
1010
flake8.txt
11-
/build/
11+
**/build/*
1212
generated
1313
/dist/
1414
*.hdf5
1515
*.h5
16-
#!nlp_architect/server/angular-ui/dist/angular-ui/*.html
17-
#*.html
18-
docs-sources/build/**
16+
docs-source/_build/**
1917
!nlp_architect/solutions/set_expansion/ui/templates/*.html
2018
.vscode
2119
!tests/fixtures/data/server/*.gz

README.md

Lines changed: 25 additions & 60 deletions
Original file line numberDiff line numberDiff line change
@@ -41,24 +41,33 @@ Features:
4141
* Core NLP models used in many NLP tasks and useful in many NLP applications
4242
* Novel NLU models showcasing novel topologies and techniques
4343
* Optimized NLP/NLU models showcasing different optimization algorithms on neural NLP/NLU models
44-
* Simple REST API server ([doc](http://nlp_architect.nervanasys.com/service.html)):
45-
* serving trained models (for inference)
46-
* plug-in system for adding your own model
47-
* 4 Demos of models (pre-trained by us) showcasing NLP Architect (Dependency parser, NER, Intent Extraction, Q&A)
44+
* Model-oriented design:
45+
* Train and run models from command-line.
46+
* API for using models for inference in python.
47+
* Procedures to define custom processes for training, inference or anything related to processing.
48+
* CLI sub-system for running procedures
4849
* Based on optimized Deep Learning frameworks:
4950

5051
* [TensorFlow]
5152
* [PyTorch]
5253
* [Intel-Optimized TensorFlow with MKL-DNN]
5354
* [Dynet]
5455

55-
* Documentation [website](http://nlp_architect.nervanasys.com/) and [tutorials](http://nlp_architect.nervanasys.com/tutorials.html)
5656
* Essential utilities for working with NLP models - Text/String pre-processing, IO, data-manipulation, metrics, embeddings.
57+
* Plug-able REST API server to serve models via REST API
5758

5859
## Installing NLP Architect
5960

6061
We recommend to install NLP Architect in a new python environment, to use python 3.6+ with up-to-date `pip`, `setuptools` and `h5py`.
6162

63+
### Install using `pip`
64+
65+
Includes only core library (without `examples/` directory)
66+
67+
```sh
68+
pip install nlp-architect
69+
```
70+
6271
### Install from source (Github)
6372

6473
Includes core library and all content (example scripts, datasets, tutorials)
@@ -76,14 +85,6 @@ Install (in develop mode)
7685
pip install -e .
7786
```
7887

79-
### Install from pypi (using `pip install`)
80-
81-
Includes only core library
82-
83-
```sh
84-
pip install nlp-architect
85-
```
86-
8788
### Further installation options
8889

8990
Refer to our full [installation instructions](http://nlp_architect.nervanasys.com/installation.html) page on our website for complete details on how to install NLP Architect and other backend installations such as MKL-DNN or GPU backends.
@@ -93,40 +94,30 @@ Users can install any deep learning backends manually before/after they install
9394

9495
NLP models that provide best (or near) in class performance:
9596

96-
* [Word chunking](http://nlp_architect.nervanasys.com/chunker.html)
97-
* [Named Entity Recognition](http://nlp_architect.nervanasys.com/ner_crf.html)
97+
* [Word chunking](http://nlp_architect.nervanasys.com/tagging/sequence_tagging.html#word-chunker)
98+
* [Named Entity Recognition](http://nlp_architect.nervanasys.com/tagging/sequence_tagging.html#named-entity-recognition)
9899
* [Dependency parsing](http://nlp_architect.nervanasys.com/bist_parser.html)
99100
* [Intent Extraction](http://nlp_architect.nervanasys.com/intent.html)
100-
* [Sentiment classification](http://nlp_architect.nervanasys.com/supervised_sentiment.html)
101-
* [Language models](http://nlp_architect.nervanasys.com/tcn.html)
102-
* [Transformers](http://nlp_architect.nervanasys.com/) (for most NLP tasks)
101+
* [Sentiment classification](http://nlp_architect.nervanasys.com/sentiment.html#supervised-sentiment)
102+
* [Language models](http://nlp_architect.nervanasys.com/lm.html#language-modeling-with-tcn)
103+
* [Transformers](http://nlp_architect.nervanasys.com/transformers.html) (for NLP tasks)
103104

104105
Natural Language Understanding (NLU) models that address semantic understanding:
105106

106107
* [Aspect Based Sentiment Analysis (ABSA)](http://nlp_architect.nervanasys.com/absa.html)
108+
* [Joint intent detection and slot tagging](http://nlp_architect.nervanasys.com/intent.html)
107109
* [Noun phrase embedding representation (NP2Vec)](http://nlp_architect.nervanasys.com/np2vec.html)
108110
* [Most common word sense detection](http://nlp_architect.nervanasys.com/word_sense.html)
109111
* [Relation identification](http://nlp_architect.nervanasys.com/identifying_semantic_relation.html)
110112
* [Cross document coreference](http://nlp_architect.nervanasys.com/cross_doc_coref.html)
111113
* [Noun phrase semantic segmentation](http://nlp_architect.nervanasys.com/np_segmentation.html)
112114

113-
Components instrumental for conversational AI:
114-
115-
* [Joint intent detection and slot tagging](http://nlp_architect.nervanasys.com/intent.html)
116-
* [Memory Networks for goal oriented dialog](http://nlp_architect.nervanasys.com/memn2n.html)
117-
118115
Optimizing NLP/NLU models and misc. optimization techniques:
119116

120-
* [Quantized BERT (8bit)](http://nlp_architect.nervanasys.com/)
121-
* [Knowledge Distillation using BERT](http://nlp_architect.nervanasys.com/)
117+
* [Quantized BERT (8bit)](http://nlp_architect.nervanasys.com/quantized_bert.html)
118+
* [Knowledge Distillation using Transformers](http://nlp_architect.nervanasys.com/transformers_distillation.html)
122119
* [Sparse and Quantized Neural Machine Translation (GNMT)](http://nlp_architect.nervanasys.com/sparse_gnmt.html)
123120

124-
End-to-end Deep Learning-based NLP models:
125-
126-
* [Reading comprehension](http://nlp_architect.nervanasys.com/reading_comprehension.html)
127-
* [Language Modeling using Temporal Convolution Network (TCN)](http://nlp_architect.nervanasys.com/tcn.html)
128-
* [Unsupervised Cross-lingual embeddings](http://nlp_architect.nervanasys.com/crosslingual_emb.html)
129-
130121
Solutions (End-to-end applications) using one or more models:
131122

132123
* [Term Set expansion](http://nlp_architect.nervanasys.com/term_set_expansion.html) - uses the included word chunker as a noun phrase extractor and NP2Vec to create semantic term sets
@@ -155,34 +146,8 @@ The main design guidelines are:
155146
* REST API servers with ability to serve trained models via HTTP
156147
* Extensive model documentation and tutorials
157148

158-
## Demo UI examples
159-
160-
Dependency parser
161-
<p>
162-
<img src="https://raw.githubusercontent.com/NervanaSystems/nlp-architect/master/assets/bist-demo-small.png" height="375"/>
163-
</p>
164-
Intent Extraction
165-
<p>
166-
<img src="https://raw.githubusercontent.com/NervanaSystems/nlp-architect/master/assets/ie-demo-small.png" height="375"/>
167-
<p>
168-
169-
## Packages
170-
171-
| Package | Description |
172-
|------------------------- |------------------------------------------------------ |
173-
| `nlp_architect.api` | Model API interfaces |
174-
| `nlp_architect.common` | Common packages |
175-
| `nlp_architect.cli` | Command line module |
176-
| `nlp_architect.data` | Datasets, loaders and data processors |
177-
| `nlp_architect.models` | NLP, NLU and End-to-End models |
178-
| `nlp_architect.nn` | Topology related models and additions (per framework) |
179-
| `nlp_architect.pipelines` | End-to-end NLP apps |
180-
| `nlp_architect.procedures`| Procedure scripts |
181-
| `nlp_architect.server` | API Server and demos UI |
182-
| `nlp_architect.solutions` | Solution applications |
183-
| `nlp_architect.utils` | Misc. I/O, metric, pre-processing and text utilities |
184-
185149
### Note
150+
186151
NLP Architect is an active space of research and development; Throughout future
187152
releases new models, solutions, topologies and framework additions and changes
188153
will be made. We aim to make sure all models run with Python 3.6+. We
@@ -191,17 +156,17 @@ encourage researchers and developers to contribute their work into the library.
191156
## Citing
192157

193158
If you use NLP Architect in your research, please use the following citation:
194-
```
159+
195160
@misc{izsak_peter_2018_1477518,
196161
title = {NLP Architect by Intel AI Lab},
197162
month = nov,
198163
year = 2018,
199164
doi = {10.5281/zenodo.1477518},
200165
url = {https://doi.org/10.5281/zenodo.1477518}
201166
}
202-
```
203167

204168
## Disclaimer
169+
205170
The NLP Architect is released as reference code for research purposes. It is
206171
not an official Intel product, and the level of quality and support may not be
207172
as expected from an official product. NLP Architect is intended to be used

dev-requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
sphinx
1+
sphinx==1.8.5
22
sphinx_rtd_theme
33
flake8-html
44
pep8

docs-source/source/CONTRIBUTING.rst

Lines changed: 10 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,9 @@ Contribution Process
2222
* Create an issue on GitHub:
2323
https://github.com/NervanaSystems/nlp-architect/issues
2424

25-
2. Clone and/or update your checked out copy of nlp-architect to ensure you have the
26-
most recent commits from the master branch:
25+
2. Fork NLP Architect and/or update your checked out copy of
26+
nlp-architect to ensure you have the
27+
most recent commits from the master branch, for example:
2728

2829
.. code-block:: bash
2930
@@ -48,17 +49,16 @@ Contribution Process
4849

4950
.. code-block:: bash
5051
51-
nlp_architect test # ensure all are OK
52-
nlp_architect style # ensure there are no style related issues
52+
./scripts/run_tests.sh # ensure all are OK
53+
./scripts/check_style.sh # ensure there are no style related issues
5354
5455
5. If necessary you may want to update and/or rebuild the documentation.
5556
This all exists under docs-source/source and is in
5657
`Sphinx reStructuredText format <http://sphinx-doc.org/rest.html>`_:
5758

5859
.. code-block:: bash
5960
60-
cd scripts/
61-
sh create_docs.sh # builds the doc and starts a local server directly
61+
./scripts/create_docs.sh # builds the doc and starts a local server directly
6262
6363
6. Commit your changes and push your feature branch to your GitHub fork. Be
6464
sure to add a descriptive message and reference the GitHub issue associated
@@ -71,23 +71,10 @@ Contribution Process
7171
git commit -m "Added new awesome functionality. Closes issue #1"
7272
git push origin my_new_feature_branch
7373
74-
7. Create a new pull request to get your feature branch merged into master for
75-
others to use. You'll first need to ensure your feature branch contains the
76-
latest changes from master. Furthermore, internal devs will need to assign
77-
the request to someone else for a code review. You must also ensure there
78-
are no errors when run through the items defined in step 4.
79-
80-
.. code-block:: bash
81-
82-
# (external contribs): make a new pull request:
83-
https://github.com/NervanaSystems/nlp-architect/pulls
84-
85-
# merge latest master changes into your feature branch
86-
git fetch origin
87-
git checkout master
88-
git pull origin master
89-
git checkout my_new_feature_branch
90-
git merge master # you may need to manually resolve any merge conflicts
74+
7. Create a new `pull request <https://github.com/NervanaSystems/nlp-architect/pulls>`_
75+
to get your feature branch merged into master for others to use.
76+
You'll first need to ensure your feature branch contains the latest changes from
77+
master.
9178

9279
8. If there are issues you can continue to push commits to your feature branch
9380
by following step 6. They will automatically be added to this same merge

docs-source/source/api.rst

Lines changed: 0 additions & 138 deletions
This file was deleted.

0 commit comments

Comments
 (0)