Skip to article frontmatterSkip to article content
Site not loading correctly?

This may be due to an incorrect BASE_URL configuration. See the MyST Documentation for reference.

Working as a team

By default a project is single-user: all your data sits in one file on your own laptop. To let several people review the same project at once (splitting the screening queue, reconciling each other’s conflicts, sharing one set of extractions), you switch that file for a shared database that everyone connects to. This page explains how that works and walks through the setup step by step. You do not need any database experience to follow it.

How it works

The app keeps two kinds of things completely separate, and team mode shares them in two different ways:

   Reviewer A's laptop            Reviewer B's laptop
   ┌──────────────┐               ┌──────────────┐
   │  ailr app    │               │  ailr app    │
   └──────┬───────┘               └──────┬───────┘
          │  reads / writes data         │
          └───────────────┬──────────────┘
                          ▼
              ┌───────────────────────┐
              │  shared PostgreSQL DB  │  ← the data: decisions,
              │  (lives on the web)    │     extractions, audit trail
              └───────────────────────┘

      project folder (config + PDFs)  ← shared separately,
      via a synced drive or git          through a synced drive

1. The data: decisions, extractions, the audit trail. The app writes everything it produces into a database. On a solo project that database is a single SQLite file (data/review.sqlite) inside your project folder. That is handy, but only one person can use one file. For a team you swap it for a PostgreSQL database: the same kind of storage, but running as a server on the internet that many people can connect to at the same time. Each teammate still runs their own copy of the app on their own laptop; those copies are just windows onto the same shared database, so the moment reviewer A records a decision, it is in the database, and reviewer B sees it the next time their page loads. The app behaves identically on SQLite or PostgreSQL; it just needs to be told which one to use.

2. The config and PDFs: your criteria, prompts, schema, and the PDF files. These are not in the database; they are plain files in the project folder. So they are shared a different way: by putting the folder somewhere everyone can reach (a synced drive or a git repository). Everyone must use the same folder contents and the same project name, because the database is namespaced by project name and your results are only comparable if everyone screened against the same criteria and prompt.

What you need

Step 1: Create the shared database (once)

One person sets this up; everyone else just receives the URL.

  1. Create a PostgreSQL database with any managed host. Several offer a free tier that is plenty for a review project; you do not need to install or run anything yourself. After signing up you create a database and the host gives you a connection URL that looks roughly like this:

    postgresql://user:password@host.example.com/dbname?sslmode=require
  2. Use the URL as-is. Paste it exactly as the host gave it. ailr automatically selects the right driver, so postgresql://, postgres://, and postgresql+psycopg:// all work. (Older docs told you to change the prefix to postgresql+psycopg://; that still works but is no longer required.)

  3. In Step 2 below you put this URL into the project’s lit_review.yaml. Because it contains the password, share the project folder privately (a synced drive like Box, or a private git repo), never a public git repo. The generated .gitignore excludes lit_review.yaml so it isn’t committed by accident.

There are three ways to get that database, from easiest to most involved, all giving you the same kind of PostgreSQL connection URL:

Step 2: Point the project at it

This is done once, in the project’s lit_review.yaml. Add the URL under storage:

storage:
  database_url: "postgresql+psycopg://user:password@host.example.com/dbname?sslmode=require"

Because the project folder is shared (Step 3), everyone who opens it connects to the same database automatically, with no per-machine setup. Each project’s yaml can point to its own database, so different reviews stay in different databases.

Step 3: Share the project folder

The data is now shared, but the config and PDFs are still files. Put the project folder on a team drive (Box / OneDrive / Google Drive) so everyone has identical copies. The files init created (lit_review.yaml, prompts/, your criteria, and the schema) are plain text, so they sync cleanly. When one person refines the criteria or the prompt, the synced drive carries that change to everyone, and lit_review.yaml carries the database URL too, so a teammate just opens the folder and is connected.

Entering your reviewer ID and dividing the work

Each person enters their own reviewer ID at the top of the app (e.g. their initials). It is stamped onto every decision and extraction, which is how the app tells teammates apart and how it builds inter-rater reliability and the audit trail. Use a stable handle and reuse it every session.

How the work splits depends on the workflow mode:

ModeHow work is split
assisted screeningeach paper is screened by one human: whoever opens a paper first claims it, and the app rejects a second human vote on an already-screened paper, so two people working at once never collide or double-count
independent screeningboth humans review every paper (Cochrane dual screening), each blinded to the other, then you reconcile the disagreements in Conflicts

So in assisted mode the queue naturally divides itself as people work through it; in independent mode everyone covers the whole set on purpose.

The two screening stages carry their own mode, so a team can split the abstract queue and still have both people read every full text.

Sharing PDFs

init creates a data/pdfs/ folder inside the project. Export your Zotero library (RIS + Export Files) into that folder, and ailr links the PDFs automatically when anyone opens the full-text pages (see Link PDFs from Zotero).

Because each link is stored relative to the project root, it resolves on every teammate’s machine with nothing to configure. Once the project folder is on the shared drive (Box / OneDrive / Drive), the PDFs travel with it and the whole team shares one copy, with no per-person path setting.

Moving a solo project to a team database

If you started solo and already have data in the local SQLite file, copy it into the shared database (the target must be empty):

ailr db-migrate <project-folder> --to "postgresql+psycopg://user:password@host.example.com/dbname?sslmode=require"

This copies all of the project’s data into PostgreSQL. Afterwards, set storage.database_url in lit_review.yaml to that same URL, exactly as in Step 2 above.

Troubleshooting

SymptomLikely causeFix
Settings shows a local SQLite file, not the shared DBdatabase_url is missing/misspelled in lit_review.yaml, or that teammate’s copy of the file didn’t syncadd storage.database_url to the yaml; make sure everyone has the same lit_review.yaml
Teammates can’t see each other’s decisionsdifferent project names, or one person isn’t on the shared DBuse the identical project name everywhere; check Settings shows the same database for everyone
App can’t connect to the databasea copy/paste error in the URL, or the host/network is unreachablecheck the URL is exactly what the host gave (including ?sslmode=require if present); the prefix can be postgresql:// or postgresql+psycopg://, either works
Pages wait about 10 seconds, then show a database errorthe network dropped, or the host is slow to wake a suspended databasecheck the connection; if the host routinely needs longer to wake, add connect_timeout=30 to the URL (...?sslmode=require&connect_timeout=30)
PDFs won’t open for a teammatethe project folder (with data/pdfs/) hasn’t finished syncing on their machinelet the shared drive finish syncing, then click Re-scan data/pdfs on the full-text Workflow page
A second screening vote was rejectedassisted mode allows one human per paperthis is expected: that paper was already screened by someone; use Conflicts if you disagree with the recorded decision