Overarching goal is to provide a system that summarizes life events automatically, to augment your memory and allow for further analysis if desired.
This library is obselete, I have switched to using and developing https://github.com/kovasap/autojournal-on-gas.
Autojournal fundamentally moves personal data around between different services. The most supported place for data to end up is Google calendar. Here are some examples of what that looks like. Each block on the calendar corresponds to a single "event" that I've tracked. For sleep, this would be time asleep. For location, this would be time at a specific location, or time travelling. For computer usage, this would be active time interacting with a computer (not AFK).
An excellent example of someone else doing exactly what autojournal does can be found at https://miguelrochefort.com/blog/calendar/.
Just the location events from a trip I went on:
All events before the trip, showing usage of multiple different computers, and sleep:
These were generated with the help of this blurring script.
Run:
# Required for selfspy dependency.
sudo apt-get install python-tk
poetry install
Then, run:
source $(poetry env info --path)/bin/activate
to get into the poetry virtualenv to run scripts.
You'll also need to get a credentials.json
file from
https://developers.google.com/calendar/quickstart/python#step_1_turn_on_the.
If you already have a client ID, you can just press the download button and save
the file as credentials.json
.
To run once a day at 10pm, run crontab -e
and add this snippet (assuming you
cloned autojournal into your home directory ~/):
0 22 * * * (cd ~/autojournal; nohup poetry run gcal_aggregator --update all &> ~/autojournal.log &)
Requires additional installs before poetry install:
sudo apt-get install python-dev libatlas-base-dev
- Setup couchdb on your machine (for me it's a raspberry pi: https://andyfelong.com/2019/07/couchdb-2-1-on-raspberry-pi-raspbian-stretch/, https://github.com/jguillod/couchdb-on-raspberry-pi#5-script-for-running-couchdb-on-boot).
- Follow https://github.com/happydata/nomie-docs/blob/master/development/couchdb-setup.md
Checkout this for coding help: https://colab.research.google.com/drive/1vKOHtu1cLgky6I_4W-aFBqq6e6Hb4qBA
Could use ML to judge mode of travel better like these guys: https://www.ncbi.nlm.nih.gov/pmc/articles/PMC5620731/.
Generate a report with the timeline that is already implemented, plus something like https://stackoverflow.com/questions/21604997/how-to-find-significant-correlations-in-a-large-dataset. Email this regularly.
Create a histogram-timeline using d3js that all data gets plotted on. Have checkboxes to turn on/off data series. Idea here is to plot lots of stuff (keystrokes, temperature, heartrate, stock market, etc.) and have a each way to check on whatever. Could use Joy plot for this.
Some ideas to explore in this space:
- patternfly-timeline
- d3 line chart with zoom
- plotly stacked range slider chart
- d3 ridgeline/joy plot
- d3 pannable chart
For plotting GPS logs:
This could generate an HTML report that would be automatically emailed to me every week.
Uses https://gpslogger.app/. Note to make this work consistently, refer to https://gpslogger.app/#sometimestheappwillnotlogforlongperiodsoftime.
When run, will make a calendar entry for every photo that exists in a given album.
Check out https://github.com/ActivityWatch/activitywatch as a potential data source.
For long events (e.g. whole day), think about making the event name long with newlines, so that you get a "graph" in the calendar UI. For example:
Temperature event:
68
68
68
68
68
68
69
70
70
70
70
...
For complex events (e.g. selfspy activity tracking), try using a word cloud type program to extract out representative words to put into the calendar event summary.
Calculate total daily calories vs time of first meal.
Try https://blog.luap.info/how-i-track-my-life.html.
Add this command to run every other hour, assuming you cloned this project to ~/autojournal
.
0 */2 * * * ~/autojournal/run_gcal_aggregator.bash
Check out this article for ideas about other kinds of tracking on Google Calendar: https://towardsdatascience.com/andorid-activity-1ecc454c636c
Set up a free tier compute engine instance. Then do https://cloud.google.com/compute/docs/gcloud-compute#default-properties and you should be able to ssh into the instance with:
gcloud compute ssh kovas
Currently a free tier instance does not have enough memory to support running this tool. I might be able to fix this by reducing memory usage by not keeping all events in memeory at once, but that would require some serious code changes.
https://karpathy.github.io/2014/08/03/quantifying-productivity/