Giter VIP home page Giter VIP logo

contextio's Introduction

contextio

To deploy on local environment:

git clone https://github.com/ashnet16/contextio.git
cd context/app && python app.py

Then move to browser and open up

localhost:5000

contextio's People

Contributors

loryfelnunez avatar rankam avatar olivercox avatar mding5692 avatar shrutiappiah avatar

Watchers

 avatar  avatar  avatar  avatar  avatar Anmol Koul avatar

contextio's Issues

User personality display

The inbox.html view needs to be updated to display the user personality returned to the browser.

A D3 chart is proposed for displaying this data.

Allow user to search their contacts

When the initial mailbox sync is complete the application will show a list of 20 contacts for them to select from. This should be updated with paging and a search facility in addition to sorting (by name?)

Add support for reactivating disabled sources

When an source in context.io get disabled it can be reactivated by posting to acounts/[id]/sources/[label]
and passing { status: 1 }. A status_callback_url can be added to the source that context.io will call when the status of the source changes.

When the callback is called if the status is Disabled or Temp_Disabled then we can update the status. This is a belt and braces approach, the real solution to disabled accounts is proper use of the APIs :)

http://blog.context.io/2014/08/temp_disabled-qa/

Contacts page updates

The contacts page should be updated to allow adding and removing contact for analysis.

When a contact is removed the same logic that is applied in the route:

@app.route('/removeContact', methods=["POST"])
def removeContact():

When a contact is added, analysis for that contact should be performed but that is likely to require refactoring of the doAnalysis method.

Handle error in ajax requests

The ajax request initiated by Angular need to be handled correctly. There are blocks defined for when errors occur but there is no logic in there currently.

Contacts without name display as null

Contacts without a name display in the tone and personality dashboards as null. This should
be updated to display the email address instead when the name is null

User inbox view

The inbox.html view needs to be updated to display the list of messages/tone returned to the browser.

For now this can be very basic in terms of style as the styling and look and feel will be updated later.

User login issues

If a user enters incorrect login credentials the application incorrectly reports success. In some cases the application will display an error page.

We need to update the login click handler to correct respond the server returning login errors and display the correct messages to the user.

Merge conflict

Added new tested features to a branch... I'm experiencing conflicts when trying to merge with master. I will resolve conflicts and try merge again.

Issues with analysis and saveContactInfo

The analysis process has an issue whereby if no messages are exchanged either sent or received the saveContactInfo overwrites the relationship data for the previous contact in the loop.

This will be update to ensure that the correct relationship is created with limited info.

Add an account settings tab

To add an account settings tab where users can opt to delete their account which will remove their account from context.io and remove the necessary data from mongodb.

Sync contacts to MongoDB

In order to provide the best user experience with paging and search functionality I think we should sync the users entire contacts list to MongoDB.

Once sync'd this will allow #21 to be completed without repetitive API calls to context.

Personality dashboard fails when no email exchanged

If a contact is selected for no emails have been either sent or received the personality dashboard will fail.

We should update the getBig5 route called from the dashboard to correctly handle this scenario.

Sync message to to MongoDB

It's been identified that calling get_messages with include_body causes the source to be disabled every time. This occurs even with a limit of 20 being set on the API call, the documentation states:-

include_body: integer - Set to 1 to include message bodies in the
result. Since message bodies must be retrieved from the IMAP
server, expect a performance hit when setting this parameter.

With this in mind I think that we should not be storing the email body and only get n message bodies for the analysis. We can sync the message meta data and display this in the UI with a call to get each message body one at a time.

Authomatic Exception when Cancelling Login

  1. Logged in to my existing email
  2. connect to localhost:5000
  3. See Login Page, I click, Login with Google
  4. Next Page, NousEQ would like to access... blah, blah for current google account that I am currently logged in
  5. I changed my mind, don't want to test with that account, I click cancel

trace:
authomatic.exceptions.CancellationError
CancellationError: access_denied

Traceback (most recent call last)
File "c:\python27\lib\site-packages\flask\app.py", line 1836, in call
return self.wsgi_app(environ, start_response)
File "c:\python27\lib\site-packages\flask\app.py", line 1820, in wsgi_app
response = self.make_response(self.handle_exception(e))
File "c:\python27\lib\site-packages\flask\app.py", line 1403, in handle_exception
reraise(exc_type, exc_value, tb)
File "c:\python27\lib\site-packages\flask\app.py", line 1817, in wsgi_app
response = self.full_dispatch_request()
File "c:\python27\lib\site-packages\flask\app.py", line 1477, in full_dispatch_request
rv = self.handle_user_exception(e)
File "c:\python27\lib\site-packages\flask\app.py", line 1381, in handle_user_exception
reraise(exc_type, exc_value, tb)
File "c:\python27\lib\site-packages\flask\app.py", line 1475, in full_dispatch_request
rv = self.dispatch_request()
File "c:\python27\lib\site-packages\flask\app.py", line 1461, in dispatch_request
return self.view_functionsrule.endpoint
File "c:\Users\Lorenz\contextio\context\app\app.py", line 151, in login
session_saver=lambda: app.save_session(session, response)
File "c:\python27\lib\site-packages\authomatic\core.py", line 1331, in login
return provider.login()
File "c:\python27\lib\site-packages\authomatic\providers__init__.py", line 86, in

wrap
func(provider, _args, *_kwargs)
File "c:\python27\lib\site-packages\authomatic\providers\oauth2.py", line 379, in login
url=self.user_authorization_url)
CancellationError: access_denied

Deprecated Packages

Issue with module import in my virtualenv: pymongo.Connection is deprecated. This package will need to be updated. I will update this package when deploying and setting up mongoDB, test, and push to repo.

Update login screen to match landing page

The look and feel of the app login screen should be updated to match the look and feel of the landing page. A new background image has been added to static/img taken from the landing header.

Add web hook for new mail

When a user is created a web hook needs to be created in context.io to notify our app of new mail. When new mail is retrieved for a selected contact the tone api should be called and both message and tone saved to the db.

Create flask route for flattened user tone

It has been proposed that a flattened version with average tone be used to display average tone for the user and contacts.

A new route should be added that accepts { email: anEmailAddress } as json and returns the flattered tone selected from mongodb.

Displaying message tone

The inbox.html view needs to be updated to display the selected message tone as a D3 chart as proposed by Anmol.

Update add mailbox message for new users to reflect UI changes

Current message is:

Hey, you will need to add mailboxes before you can view contacts. Add a mailbox by navigating over to Mailboxes and entering an email address you want us to analyze

Mailboxes is under settings so I think that we should explicitly state where to find mailboxes by adding under settings to the message:

Hey, you will need to add mailboxes before you can view contacts. Add a mailbox by navigating over to Mailboxes under settings and entering an email address you want us to analyze.

Add remove contact

During the initial sync/analysis process the user can select contacts but removal doesn't work. This should be added so that when the remove button is clicked the contact is removed from the user.

In addition we should delete relationships for the contact where the user is the owner (hostemail), delete messages for the contact where user is the owner.

No recalculation for new messages - tone (all cases) and personality (very few cases)

New messages to an already registered knowus.io user are displayed in the home page, but mongodb is not updated with the new tone recalculation and personality recalculation (if applicable-- ie personality was blank before new message came in due to Watson not reaching max word threshold, but with the new messages, personality calculation is now possible)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.