## Inspiration

We choose to create Serenity to create a safe space for people to express their thoughts and reflect, as well as work on, their overall mental state.
To maintain a healthy mindset it is very important to express your thoughts and reflect on why you feel a certain way, and by creating an application dedicated to this that is accessible, portable, and has built-in features to give an overview of your mental state, we aimed to create a convenient resource for people to practice mindfulness on a daily basis and bring more attention to their mental wellbeing.

## What it does

The user can create one or multiple daily journal entries in the app, and they will be saved and categorized by the date of creation.
The app then analyzes the journal entries, assigns them a sentiment score based on the mood portrayed in the entries, and assigns a score to each day by taking the average of the individual entry scores.
In the calendar view, the result of this sentiment analysis is displayed by coloring each day according to the score. The more red a day is, the worse the mood of the journal entries on that day, and the more green, the better the mood. The color fades from one color to the other, giving a nuanced view of what each day's mood was.

## How we built it

To build this project, we used Flutter, Google Cloud, Google Cloud Natural Language API, and Flask.

## Challenges we ran into

Some challenges we ran into included creating a database to connect with the backend of our application. We started off with the idea of transferring the storage of the journal entries from a local file to a database, but we found that it would have been too complicated and time-consuming within the short amount of time we had.
We also had challenges when trying to set up a virtual machine to post the backend on Google Compute Engine. After much trial and error, it was simply not working and we decided to pivot to a new strategy. Our solution was to host the backend locally and access it through Ngrok. This was much more efficient and served the purpose we needed it for.
The final challenge our group faced was the fact that two of our members were new to the Dart programming language. For this reason, the development process involved a lot of learning, watching tutorials, and trial and error.

## Accomplishments that we're proud of

First of all, we are proud of completing the project we set out to make. The application runs smoothly and performs the tasks we intended. While it may not be perfect and does not implement every feature in the exact way we imagined, it is a great representation of our idea.
We are also proud of having worked past the challenges and setbacks we experienced by thinking creatively and finding new solutions to these problems.

## What we learned

Two of our team members were new to Flutter and app development before Hack Western, and through this project, they learned the basics of these topics. We also learned how to communicate with a Google Cloud API through our backend and incorporate this functionality into our application.
Another major learning point for us was asynchronous programming. Flutter involves a lot of asynchronous programming, which none of us had a lot of experience with, and through this project we used this concept extensively.
Finally, we learned a lot about the process of trial and error in app development, and how to get past hurdles by thinking creatively and finding effective solutions that suit our current needs.

## What's next for Serenity

The next feature we would like to implement to improve Serenity would be to connect it to a database to store journal entries in rather than storing them locally in a file. This will allow user authentication, multiple device access, and it will allow Flutter to make full use of its ability to run on multiple platforms, making the application very accessible for those in need.
We would also like to provide more resources to users within the app, such as links to mental health blogs, emergency hotlines, and information on available mental health services.
Lastly, we would like to improve the app's UI/UX by adding more features for notes such as stickers, filters to sort through existing entries, an option for confidential sharing of notes with a personal therapist, and creating an overall more intuitive and aesthetic design for note previews.
## Inspiration

A moment of anxiety can throw off a whole day. And for some, those moments come more frequently than others. Anxiety disorders are the most common mental illness in the U.S., affecting 40 million adults in the United States age 18 and older, or 18.1% of the population every year. Anxiety disorders are highly treatable, yet only 36.9% of those suffering receive treatment. Currently, there are various apps that attempt to manage anxious occurrences, as well as mental health and well-being as a whole. But we have found that very few incorporate features that aim to aid individuals in the midst of anxiety or facilitate therapy sessions for those in need of counseling. Our first goal with Serenity was to create a tool that any user would feel compelled to use as it provides simple, yet effective anxiety or stress management techniques (yoga, writing, meditating/breathing exercises, etc.) Our next focus was to aid users who are currently in counseling, providing them with a record of their experience to facilitate their therapy sessions.

## What it does

During each use of the app, users complete the exercise with a short follow up a questionnaire to reflect upon why they were anxious, and whether the particular exercise was helpful, and how. Users can then search instances on the app by date, and provide accurate recollections during their therapy sessions. Whether a user is in therapy or not, access to this information will certainly help them cope with similar situations in the future. We also incorporated an “SOS” button on the dashboard to allow users to quickly and easily let a friend, or their therapist, know they’re feeling particularly distressed.

## How I built it

We designed the app on Sketch, using Invision to demonstrate user flow through the app. We implemented basic HTML and CSS to bring the tool to life, based off of the Sketch templates. We also attempted to integrate this as a Python-based app using Flask framework with MySQL, but chose to continue with simplified HTML/CSS artifacts.

## Challenges I ran into

Since this was our first hackathon, and none of us had a significant full-stack coding background, we had trouble getting started with things. We tried to use Flask and Django with Python to connect with a database, and managed to do that. However, because of the lack of UI coding experience in our team, all our time went to writing the HTML, CSS and JavaScript for the Sketch designs we created, and we couldn’t finish integration with the backend. We wanted to make a more dynamic website, but we struggled quite a bit.

## Accomplishments that I'm proud of

We’re proud of creating an app that is not just another way to send emojis or add filters but one that solves a very real and serious problem. Using principles of behavioral economics and human-centered design, our app tries to improve people’s lives. The color palette that we chose for the app is backed by research: blue and green colors have a calming effect on cognition and understanding.

## What I learned

With our prototype developed, we wanted to get feedback from people. In true, usability test fashion, each team member got out of the stadium and showed the prototype to one person each. Some of the questions we asked included: have you ever suffered an anxiety attack, what did you find most helpful when you were going through one, and how long did it take for you to get in touch with a therapist. And then we walked them through the app. 3 out of 4 people had a positive reaction to it, stating emphatically that this solution could in some capacity, actually help people suffering from stress or anxiety. 3 out of 4 people had a positive reaction to it, stating emphatically that this solution could in some capacity, help people suffering from stress or anxiety, especially the one-tap SOS button to notify friends and therapists. They also said that while it’s easy to solve this problem on the user’s end, it’s harder to do the same for therapists and that might make it harder to reach out to them. This was some useful feedback that we took note of.

We also learned how to use Heroku and use it with Python to create and deploy web apps.

## What's next for Serenity

There are many ways we would love to expand Serenity including creating a dashboard for therapists to access their client's instances of use in the app. There are also many other exercises and features we would like to include, especially those that extend beyond anxiety. We definitely aim to work on making the application dynamically compatible so user information can be stored for representation between screen-jumping.

The link to try out our app (<https://shaivya-rastogi.github.io/serenity/Home.html>) is accessible on iPhone 6 and 7.
## Inspiration

As post secondary students, our mental health is directly affected. Constantly being overwhelmed with large amounts of work causes us to stress over these large loads, in turn resulting in our efforts and productivity to also decrease. A common occurrence we as students continuously endure is this notion that there is a relationship and cycle between mental health and productivity; when we are unproductive, it results in us stressing, which further results in unproductivity.

## What it does

Moodivity is a web application that improves productivity for users while guiding users to be more in tune with their mental health, as well as aware of their own mental well-being.

Users can create a profile, setting daily goals for themselves, and different activities linked to the work they will be doing. They can then start their daily work, timing themselves as they do so. Once they are finished for the day, they are prompted to record an audio log to reflect on the work done in the day.

These logs are transcribed and analyzed using powerful Machine Learning models, and saved to the database so that users can reflect later on days they did better, or worse, and how their sentiment reflected that.

## How we built it

***Backend and Frontend connected through REST API***

**Frontend**

* React
	+ UI framework the application was written in
* JavaScript
	+ Language the frontend was written in
* Redux
	+ Library used for state management in React
* Redux-Sagas
	+ Library used for asynchronous requests and complex state management

**Backend**

* Django
	+ Backend framework the application was written in
* Python
	+ Language the backend was written in
* Django Rest Framework
	+ built in library to connect backend to frontend
* Google Cloud API
	+ Speech To Text API for audio transcription
	+ NLP Sentiment Analysis for mood analysis of transcription
	+ Google Cloud Storage to store audio files recorded by users

**Database**

* PostgreSQL
	+ used for data storage of Users, Logs, Profiles, etc.

## Challenges we ran into

Creating a full-stack application from the ground up was a huge challenge. In fact, we were almost unable to accomplish this. Luckily, with lots of motivation and some mentorship, we are comfortable with naming our application *full-stack*.

Additionally, many of our issues were niche and didn't have much documentation. For example, we spent a lot of time on figuring out how to send audio through HTTP requests and manipulating the request to be interpreted by Google-Cloud's APIs.

## Accomplishments that we're proud of

Many of our team members are unfamiliar with Django let alone Python. Being able to interact with the Google-Cloud APIs is an amazing accomplishment considering where we started from.

## What we learned

* How to integrate Google-Cloud's API into a full-stack application.
* Sending audio files over HTTP and interpreting them in Python.
* Using NLP to analyze text
* Transcribing audio through powerful Machine Learning Models

## What's next for Moodivity

The Moodivity team really wanted to implement visual statistics like graphs and calendars to really drive home visual trends between productivity and mental health. In a distant future, we would love to add a mobile app to make our tool more easily accessible for day to day use. Furthermore, the idea of email push notifications can make being productive and tracking mental health even easier.