Here’s a quick start guide to running Harmony, an open source tool for social science research. These instructions are for the complete version of Harmony including the graphical browser-based tool which is available online at https://harmonydata.ac.uk/app/. If you only need the Python or R libraries, or the REST API, please refer to our Github page.
You will need to first download and install a couple of programs that Harmony needs to run.
You need a computer with at least 16 GB RAM – in other words, a fairly high-end computer. This is because Harmony does two things that need some computational heavy lifting:
In addition, the browser-based front end is running in Node.js to make the nice graphics that you can see on our web tool.
If you don’t need all of this functionality, you may prefer to install the Harmony Python library, R library, REST API or even run our Docker container available from our DockerHub page.
Download and install Java, Node.js, and NPM if you don’t have them already.
If you are a Mac user and you use Homebrew, you can run this in the Terminal.
brew install java nodejs npm
If you use Ubuntu, you can run this in the console:
apt-get update
apt-get install default-jre npm nodejs
Please ensure you have Java version 11 or later, NPM version 6.14.4 or later, and Node.js version 10.19.0 or later
Download Apache Tika from this link: https://tika.apache.org/download.html
Then, in the console or Terminal, type:
java -jar tika-server-standard-2.3.0.jar
(the numbers at the end of the file name may change)
Please ensure you have Tika 2.3.0 or later.
If you don’t already have Python on your computer, we recommend to download it from Anaconda. Please ensure you have Python 3.9 or later.
Visit the API Github page and click Code -> Download ZIP. Unzip it on your computer.
In the terminal or console, type
pip install -r requirements.txt
python harmony/src/harmony/util/model_downloader.py
In the terminal or console, type
python main.py
Visit our front end Github page and click Code -> Download ZIP. Unzip it on your computer.
In the Terminal, go inside the folder and type
export REACT_APP_API_URL=http://localhost:8000/
npm install
npm start
Visit your browser at http://localhost:3000 and you should see Harmony running there.
For users who have been using Harmony in their research, we have created an example scripts repository here https://github.com/harmonydata/harmony_examples This contains example R notebooks and Jupyter notebooks. You can upload your own example script if you have something to share with the research community. Example problems that users have been solving included: R examples Walkthrough R notebook in R Studio: Walkthrough R notebook in Google Colab: R Markdown to Check for Correspondence between Differently Worded Versions of the Same Scale Item View on Github - credit to Deanna Varley R Script to Check for Matches between Items from Different Scales View on Github - credit to Deanna Varley Python examples Walkthrough Python notebook Example script to create a crosswalk table on real survey data Example script to strip prefixes from questions Documentation View the PDF documentation of the R package on CRAN
Upcoming Tech Talk: GenAI and LLMs night at Google London on 10 December 2024 We’re pleased to announce that the AI tool Harmony will be showcased at the upcoming GenAI and LLMs night at Google London on 10th December organised by AI Camp. Topic: Harmony, Open source AI tool for psychology research Speakers: Thomas Wood (Fast Data Science), Bettina Moltrecht (UCL) Date: 10th December 2024 Register RSVP to join the AI and LLMs night at the Google Campus on 10 December 2024 See other Harmony events 8 October 2024: Harmony: a free online tool using LLMs for research in psychology and social sciences at AI|DL London 11 and 12 September 2024: Harmony at MethodsCon Futures in Manchester 2 July 2024: Harmony: NLP and generative models for psychology research at Pydata London 3 June 2024: Harmony Hackathon at UCL 5 May 2024: Harmony: A global platform for harmonisation, translation and cooperation in mental health at Melbourne Children’s LifeCourse Initiative seminar series.