Expand description
Health and well-being: prescriptions, when to fetch their medicines and when to renew them; medicines and when to take them; a pause to move during long focus; a daily limit on chats. Sent nowhere, except sealed to your other devices when you share with them (docs/database.md).
Nothing here counts what was missed. A dose not marked taken is simply not marked; the next one comes as planned. Two kinds of medicines: those taken at set times of the day keep their times (being ready for something); those taken every few hours keep the hours between two doses, which the body (the liver, the kidneys) needs to clear one before the next: each dose taken, early or late, sets the next one that many hours after it.
Structs§
- Chat
Limit - Chats, a limit a day: after
minutesof use they are covered, silent and muted, forlocked_minutes; then they come back. - Dose
- One dose to take.
- Errand
- Something to do for a prescription, from a day on.
- Health
- Everything the health page keeps:
$XDG_DATA_HOME/sioul/health.toml. - Health
State - What is marked of the doses and done of the errands, kept apart from the
health file:
$XDG_STATE_HOME/sioul/health-state.toml. - Medicine
- A medicine to take, and when.
- Movement
- The pause to move: while a focus session runs, after this many minutes.
- Named
- A device a doubt names: its id (for “This device is off”), its name, a phone or not.
- Peer
- Another device sharing with this one, as known here, for the doses
(docs/health.md, “Knowing”): what it last said of itself in the sharing
folder (its entry in the devices’ registry,
said), and, for an older Sioul that writes none, what its claims said (until when everything it wrote is read here, whether it said it closed, how late its news comes). - Prescription
- A prescription: what it is for, who wrote it, until when it is valid, and how often the pharmacy gives its medicines.
- Said
- What a device says of itself in the sharing folder: its entry in the
devices’ registry (
sioul_sync::devices), its times on its own clock (Unix seconds). - Take
- A take of a medicine at set times each day: its time (“08:00”) and its amount (“1 tablet”; “” when none is said).
Enums§
- Doubt
- Why a dose is not known here: whether it was taken, Sioul cannot tell.
- Errand
Kind - Problem
- A change to the doses’ record that could not be made.
- Schedule
- When a medicine is taken.
- Take
Problem - Why takes could not be set.
- Unsound
- Why the doses’ record cannot be trusted: what it held is not known.
Constants§
- BROKEN_
SPAN - How long before a dose’s time a line lost from another device’s records may have held its answer (a dose marked ahead of its time), in seconds.
- FRESH
- How long a device in use stays known after its last export, as of now: within it, an answer it captured is one you have just given. Beyond it, what it captured since may still be on its way.
- NEWS_IN
- The longest a closed computer’s news may take to come here for it to count as closed, for an older Sioul known by its claims only: had it opened again, it would be known by now.
- QUIET
- A device in use not seen changing for this long may have stopped without closing (a crash): said so. Only the words change.
- SILENT_
DAYS - A device silent this long stops counting for the doses, and Settings ▸ Your folder and sharing offers to forget it: a guess (a computer away for a long weekend comes back within it).
- SKEW
- How far apart two devices’ clocks are taken to be, beyond what is measured
here (
Peer::ahead): a guess; devices set their clocks from the network, to within seconds.
Functions§
- counts
- Whether
peercounts for the doses atnow: not said off by you, still sharing, and heard withinSILENT_DAYS, by this device’s clock (its entry seen changing) or its own (its last export). - doubts
- The same, as a dose’s reminder asks it, near its time: one rule, kept by its name for its callers.
- doubts_
now - Why a dose due at
due(Unix seconds), not answered here, may have been answered on another device, as ofnow; none when it is known not taken (docs/health.md, “Knowing”). This device’s record must read, and each other device that counts (counts) be one of: - doubts_
unread doubts_now, at a phone’s alarm whose own pull did not go through since it began (since, Unix seconds): failed, or too slow, the sync app asked instead. Of the devices inheard, an entry or a health claim saying more came since: what they say is as fresh as the sync app makes it. Any other known only by what it said before then, closed (or an older Sioul whose claims say so), may have opened since and answered: said in doubt, as it was last heard, never known (docs/health.md, “Knowing”). One in use stays asFRESHhas it: known only while its news is minutes old, which the alarm’s own wait already spends.- forty_
five 🔒 - hhmm
- “8:00” → “08:00”: a take’s time as
amountskeys it; none when it does not read. - keep_
private 🔒 - What the body’s files hold is yours alone: on Unix, readable by you only (0600), whatever the system’s default for new files.
- known_
from - The first moment from
fromon, beforeuntil, at which a dose due atdueis known not taken (doubts_now) while nothing new is read: a device closed before it becomes known so once the news of an opening had the time to come (Peer::wake), a device in use only goes stale. None when it is not known byuntil. For what is shown ahead of time (a phone’s home screen card): “check” until then. - known_
until - Until when a dose due at
due, known not taken atfrom(doubts_now), stays known while nothing new is read (a device in use goes stale afterFRESH): the first moment it is not, elseuntil; 0 when it is not known atfrom. For what is shown ahead of time (a phone’s home screen card). - time_of 🔒
- “18:00” → 18:00.
- witnessed
- Whether a record of the doses was written here before (
witnesses). - witnesses 🔒
- The witnesses of a record of the doses (the marks,
health-state.toml; each dose’s record,health-doses.toml), made the first time it is written: gone, or of no bytes, with a witness there, it was lost, not never written. One beside it; one apart, in the data folder with the medicines, for a record in its usual place, the state folder: a state folder wiped whole (a reset, a backup put back without it) takes the record and the witness beside it, never that one (review of 5 October 2026, F22). - write_
witnessed - A record of the doses written next to its place, its bytes on the disk before it takes its name (a phone’s file system may keep the name of a file whose bytes a crash lost: a record of no bytes), then its folder’s change made to last; its witnesses made when missing.
- yes 🔒