Skip to content

Commit

Permalink
Merge branch 'master' into tf_py3
Browse files Browse the repository at this point in the history
  • Loading branch information
ricwo committed Oct 4, 2018
2 parents e19cb91 + 237ea80 commit 5f79c93
Show file tree
Hide file tree
Showing 8 changed files with 28 additions and 8 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.rst
Expand Up @@ -14,6 +14,7 @@ Added

Changed
-------
- ``boto3`` is now loaded lazily in ``AWSPersistor`` and is not included in ``requirements_bare.txt`` anymore

Removed
-------
Expand Down
1 change: 0 additions & 1 deletion alt_requirements/requirements_bare.txt
@@ -1,7 +1,6 @@
gevent==1.2.2
klein==17.10.0
hyperlink==17.3.1
boto3==1.5.20
typing==3.6.2
future==0.16.0
six==1.11.0
Expand Down
1 change: 1 addition & 0 deletions alt_requirements/requirements_dev.txt
Expand Up @@ -16,3 +16,4 @@ httpretty==0.9.5
# other
google-cloud-storage==1.7.0
azure-storage-blob==1.0.0
boto3==1.5.20
13 changes: 13 additions & 0 deletions docs/faq.rst
Expand Up @@ -4,6 +4,19 @@
Frequently Asked Questions
==========================

Which languages does the Rasa NLU support?
------------------------------------------
Rasa NLU can be used to understand any language that can be tokenized (on whitespace or using a custom tokenizer),
but some backends are restricted to specific languages.

The ``tensorflow_embedding`` pipeline can be used for any language because it trains custom word embeddings for your domain using the data you provide in the NLU training examples.

Other backends use pre-trained word vectors and therefore are restricted to languages which have pre-trained
vectors available.

You can read more about the Rasa NLU supported languages in :ref:`section_languages`.


How many training examples do I need?
-------------------------------------
Unfortunately, the answer is *it depends*.
Expand Down
2 changes: 1 addition & 1 deletion docs/index.rst
Expand Up @@ -55,8 +55,8 @@ You can see an independent benchmark comparing Rasa NLU to closed source alterna
:hidden:

choosing_pipeline
entities
languages
entities
evaluation
fallback
faq
Expand Down
11 changes: 7 additions & 4 deletions docs/languages.rst
Expand Up @@ -4,11 +4,14 @@
Language Support
================

Rasa NLU can be used to understand any language, but some backends are
restricted to specific languages.
**You can use Rasa NLU to build assistants in any language you want!** The
``tensorflow_embedding`` pipeline can be used for **any language** because
it trains custom word embeddings for your domain. Read more about this
pipeline in :ref:`choosing_pipeline`.

Other backends have some restrictions and support those languages
which have pre-trained word vectors available.

The ``tensorflow_embedding`` pipeline can be used for any language, because
it trains custom word embeddings for your domain.

Pre-trained Word Vectors
------------------------
Expand Down
5 changes: 3 additions & 2 deletions rasa_nlu/persistor.py
Expand Up @@ -9,8 +9,6 @@
import shutil
import tarfile

import boto3
import botocore
from builtins import object
from typing import Optional, Tuple, List, Text

Expand Down Expand Up @@ -143,6 +141,7 @@ class AWSPersistor(Persistor):

def __init__(self, bucket_name, endpoint_url=None):
# type: (Text, Optional[Text]) -> None
import boto3
super(AWSPersistor, self).__init__()
self.s3 = boto3.resource('s3', endpoint_url=endpoint_url)
self._ensure_bucket_exists(bucket_name)
Expand Down Expand Up @@ -173,6 +172,8 @@ def list_projects(self):
return []

def _ensure_bucket_exists(self, bucket_name):
import boto3
import botocore
bucket_config = {
'LocationConstraint': boto3.DEFAULT_SESSION.region_name}
try:
Expand Down
2 changes: 2 additions & 0 deletions tests/base/test_persistor.py
Expand Up @@ -7,6 +7,8 @@

import mock
import pytest
import boto3
import botocore
from moto import mock_s3

from tests import utilities
Expand Down

0 comments on commit 5f79c93

Please sign in to comment.