-
Notifications
You must be signed in to change notification settings - Fork 4.4k
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
Integration with Microsoft Bot Framework #381
Conversation
class Microsoft(OutputAdapter): | ||
""" | ||
An output adapter that allows a ChatterBot instance to send | ||
responses to a HipChat room. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Copy paste error
@vkosuri Looks good, is this ready to be reviewed? |
Thanks , I am working on documentation part also, i will push some more On 05-Nov-2016 6:40 PM, "Gunther Cox" [email protected] wrote:
|
@gunthercox i haven't added tests for this PR, i will add soon, do you have any comments/suggestions on this PR? |
@vkosuri From what I can see, this looks fantastic. In the examples, is the value for |
@gunthercox any comments/suggestions? |
Comments & feedback
I would be happy to help write tests for this, let me know. |
|
@gunthercox any comments/suggestions? |
How did you get the value to use for the |
You eill get it from here
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've left comments on a few lines where some very minor changes/improvements could be made.
def __init__(self, **kwargs): | ||
super(Microsoft, self).__init__(**kwargs) | ||
|
||
self.directline_host = kwargs.get('directline_host') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It might be a good idea to add a default value here so that directline_host
does not always need to be specified. I'm fairly certain that the direct line host endpoint will usually be the same for every developer.
kwargs.get('directline_host', 'https://directline.botframework.com')
def __init__(self, **kwargs): | ||
super(Microsoft, self).__init__(**kwargs) | ||
|
||
self.directline_host = kwargs.get("directline_host") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This get method should also have the default set.
kwargs.get('directline_host', 'https://directline.botframework.com')
input_adapter="chatterbot.adapters.input.Microsoft", | ||
directline_host="https://directline.botframework.com", | ||
dirctline_conversation_id="IEyJvnDULgn", | ||
directline_access_token_or_secret="RCurR_XV9ZA.cwA.BKA.iaJrC8xpy8qbOF5xnR2vtCX7CZj0LdjAPGfiCpg4Fv0", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It looks like the directline_access_token_or_secret
parameter was changed to direct_line_token_or_secret
in the code.
output_adapter="chatterbot.adapters.output.Microsoft", | ||
direct_line_host="https://directline.botframework.com", | ||
direct_line_conservationId="IEyJvnDULgn", | ||
direct_line_access_token_or_secret="RCurR_XV9ZA.cwA.BKA.iaJrC8xpy8qbOF5xnR2vtCX7CZj0LdjAPGfiCpg4Fv0", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I believe in this example, direct_line_access_token_or_secret
should also be changed to direct_line_token_or_secret
.
I believe all the changes here look good. |
Closes #290