steveharoz / curate_science

Transparent and credible evidence.

Home Page:https://curatescience.org

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Curate Science

Build Status

Transparency Compliance for Science

Code base of Curate Science, a next-generation transparency compliance and accountability system for scientific articles. A central problem in research is determining whether reported evidence can be trusted. In science, evidence can only be trusted if it is transparently reported and has survived scrutiny from peers via follow-up replications/re-analyses. No platform, however, currently exists to verify (and track) the transparency and replication of research.

To solve this problem, we are developing curation tools that will allow researchers, journals, universities, and funders ensure that scientific articles (1) comply with the appropriate transparency standards and (2) are accountable to follow-up replication studies and re-analyses. This will create immense value for all research stakeholders (see list), which has large potential to accelerate scientific progress and applied innovations.

For more details about the platform, see:

  1. Falsifiability-informed framework that guides the design and implementation of our platform/tools.
  2. Current functionalities/features being designed and developed.
  3. Upcoming features and platform roadmap.

alt text

Figure 1: Basic layout of Curate Science’s article card displaying information about an article’s  transparency and follow-up commentaries, replications, and re-analyses. 

alt text

Figure 2: Curate Science transparency compliance and accountability system: An article’s transparency, result  reproducibility, and effect replicability are curated/verified over time (findings that survive scrutiny are treated as credible proportional to the extent of scrutiny achieved over that time period). 

Contributing

Application Structure

Curate Science is a web application written in Python 3 using the Django framework 2.1. with PostgreSQL 9.6, running on Google App Engine Standard Environment. The master branch is continuously deployed to production with Travis CI. The application features a REST API for interacting with the curated data programmatically.

  • Entity models are in curate/models.py (current entity-relationship diagram (v0.3.0) (entities to-be-added in blue))
  • REST API view controllers use Django REST Framework and are in views_api.py
  • REST API model serializers are in curate/serializers.py
  • HTML view controllers are in curate/views.py
  • HTML templates use the Django template engine and are in templates/
  • URL routes are in curate_science/urls.py
  • JS, CSS, and image files go in static/curate/
  • Application configurations are in curate_science/settings.py

Useful Documentation

Back-end

Front-end

Setup

To set up the app locally:

  1. Clone this repository
  2. Install Python >= 3.6
  3. Install PostgreSQL >= 9.4 (command may be sql or psql depending on install method)
  4. Create a .env file and set the environment variables DB_USER, DB_PASS, and SECRET_KEY
  5. Create a superuser to access Django admin: python manage.py createsuperuser and follow prompts
CREATE DATABASE curate;
CREATE USER [DB_USER] WITH PASSWORD '[DB_PASS]';
GRANT ALL PRIVILEGES ON DATABASE curate TO [DB_USER];
ALTER USER [DB_USER] CREATEDB;
pip install -r requirements.txt
python manage.py migrate
python manage.py runserver_plus

Running Tests

python manage.py test

Starting Local Server for Development

Ensure Postgres is running.

python manage.py runserver_plus
# In a new terminal (to compile JS bundle(s) and HTML)
yarn start

App should be running at localhost:8000. Django admin should be available at localhost:8000/admin.

DB migration instructions:

For staging: export GOOGLE_CLOUD_PROJECT=curate-science-staging-2

For production: export GOOGLE_CLOUD_PROJECT=curate

Then run python manage.py migrate

Then don’t forget to reset the env var: export GOOGLE_CLOUD_PROJECT=

(DB_NAME is set conditionally, based on the value of GOOGLE_CLOUD_PROJECT, here)

Core UI Regression Tests

  1. Create a new article
  2. Save a new article
  • All fields can successfully save information
  • Canceling unsaved information prompts warning dialog
  1. Edit an article
  • All fields can successfully be edited
  1. Link an existing article to an author page
  • Link that same article to a (different) co-author's page (admin only)
  1. Create a new author page (admin only)
  2. Invite/create a new user (admin only)
  3. Delete an article (admin only)

About

Transparent and credible evidence.

https://curatescience.org

License:MIT License


Languages

Language:HTML 53.6%Language:JavaScript 25.6%Language:CSS 15.5%Language:Python 5.1%Language:R 0.1%Language:Shell 0.0%