Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added number of entities as parameter for message #100

Merged
merged 5 commits into from
Oct 16, 2017

Conversation

oniken
Copy link
Contributor

@oniken oniken commented Oct 12, 2017

Added number of entities returned as a parameter for .message()

Copy link
Contributor

@blandinw blandinw left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for working on this!

wit/wit.py Outdated
@@ -71,10 +71,12 @@ def __init__(self, access_token, actions=None, logger=None):
self.logger.error('Stories and POST /converse have been deprecated. This will break in February 2018!')
self.actions = validate_actions(self.logger, actions)

def message(self, msg, context=None, verbose=None):
def message(self, msg, context=None, num=None, verbose=None):
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

num -> n, let's keep the naming consistent between the Python keyword arguments and the HTTP API

wit/wit.py Outdated
params = {}
if verbose:
params['verbose'] = True
if num:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

let's test for is not None instead, to allow 0

@blandinw blandinw merged commit e11e55a into wit-ai:master Oct 16, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants