What is DREAM (not) good for?

Continuing the discussion from D1.2 – UPSYCLE Architecture Overview:

Ok let me try something. I got to thinking, in the context of using DREAM in a hospital:

A patient goes to a hospital and is examined by two doctors simultaneously.

The doctors’ phones are connected through a local edge network.

Doctor 1 carries out the examination while doctor 2 makes a report as a series of notes to his own DMC.

At 12:00 the examination is done and the doctors sync their DMC containers and then go home.

Doctor 1 has no internet at home but doctor 2 does.

Doctor 1 reads the report, and writes at 6:00pm: “I certify that everything written up to this point is true”, but doctor 2 writes an obvious lie at 3:00pm and syncs it to core: “The patient spread his wings and flew away.”

Doctor 1 goes to her local coffee-shop, syncs to core (the phone does that automatically), and submits the report, and then does a massive facepalm. So what went wrong? Is this even a valid usage of DREAM to begin with? If so, was it user error and what could doctor 1 have done differently?

Other questions: can doctor 1 edit doctor 2’s notes? Can doctor 2 even edit his own notes? Or does editing a note consist of removing, altering, and resaving?

Also, does it make sense to put a timestamp on the notes and have the application order them (since they’re just undifferentiated elements of a DMC set?) Or will that quickly get expensive?


Since we mentioned a shared document: could one implement a shared pad using DREAM? And if so how would it differ from the existing ones?

How about a drawing program or shared whiteboard?

2 Likes

Nice example.

Allen Haim via DREAM noreply@dream.public.cat writes:

[…]

Doctor 1 carries out the examination while doctor 2 makes a
report as a series of notes to his own DMC.

The patients file is a set of notes (and possibly other documents
such as an X-Ray image, etc) and is a DMC.

At 12:00 the examination is done and the doctors sync their DMC
containers and then go home.

Doctor 1 has no internet at home but doctor 2 does.

Doctor 1 reads the report, and writes at 6:00pm: “I certify that
everything written up to this point is true”, but doctor 2
writes an obvious lie at 3:00pm and syncs it to core: “The
patient spread his wings and flew away.”

The time-stamp of notes is not reliable (and is not necessary for
DMC sets). The same situation could arise when doctor 2 really
writes his report about the patient spreading his wings at 7pm but
his devices clock has stopped and thinks it is 3pm.

Doctor 1 goes to her local coffee-shop, syncs to core (the phone
does that automatically), and submits the report, and then does
a massive facepalm. So what went wrong? Is this even a valid
usage of DREAM to begin with? If so, was it user error and what
could doctor 1 have done differently?

It might be not the best usage of DMC. Maybe for a patient file an
append-only log would be better. Consider the situation where
doctor 1 has already done the X-Ray scan but it is not yet synced
yet. Doctor 2 arrives and sees that the X-Ray scan is not there
and places the patient back in the tube - exposing the patient to
unnecessary dangerous X-Rays (replace X-ray with crazy medication
for a more extreme effect). For a patient file, the file should
maybe physically be with the patient to prevent such things from
happening.

Other questions: can doctor 1 edit doctor 2’s notes? Can doctor
2 even edit his own notes? Or does editing a note consist of
removing, altering, and resaving?

Yes. But there might be multiple ways of editing:

  1. As you say removing, altering and resaving.
  2. Creating an “Edit note” (a diff) that references the original
    note. The “edit note” is a member of the DMC as everything else
    but is displayed in the UI as a change to the original note. Users
    can see what changes were made by the edit.

Also, does it make sense to put a timestamp on the notes and
have the application order them (since they’re just
undifferentiated elements of a DMC set?) Or will that quickly
get expensive?

Absolutely! The display order is completely left up to the
application. In some cases it might make sense to sort by creation
date (as for notes in this example) or by event date (for cultural
events or planned actions) or by geographical coordinates.

When the amount of data increases it might make sense for
clients/applications to maintain their own indices where things
are sorted in whatever way they want. This solves the performance
issues.

Since we mentioned a shared document: could one implement a
shared pad using DREAM? And if so how would it differ from the
existing ones?

In general yes. However, DMC only provides the Set and Register
containers. Maybe for text editing a CRDT of a
Rope would
be better. Still many things can be done with a Set (with RDF
magic). See for example dokielie or csarven’s
thesis as a complete example:
Linked Research on the Decentralised Web.

How about a drawing program or shared whiteboard?

If you can come up with a RDF vocabulary that can encapsulate
drawings, sure.

2 Likes

Thank you both much for this conversation @misterfish and @pukkamustard

When I mentionned the idea that DREAM could be used in the health sector, it was mainly because there has been so many data leaks from hospitals recently, they obviously need to change systme, and I still think it could be a valid usecase especially when information needs to be shared within and outside the hospital (other practitioners for example). However at DREAM we do not have the capacity to undertake such projects (at least not as of now)

When it comes to envisioning effective user scenarios I think it is impossible to do it without being in relation with the profession. I mean health professionals have dedicated processes for decision making that certainly does not involve one person, As for examination, my experience of a hospital is that they exactly know where the patient is at every moment because each staff does their administrative duty on time (even if it takes them an excessive amount of time).

It would be very interesting to go discuss the case with health professionals, maybe I will do it.

Dokielie looks amazing