NixLabConnectionconnecting
ProjectsProject
web /

dreamstop.openfp.net

publicguest

dreamstop.openfp.net, the website and user manual of dreamstop, a language for continuous disambiguation

git clone git@nixlab.openfp.net:web/dreamstop.openfp.net.git
c46d9ab01fba5e4e33328e3479a8600176055ce4manual/introduction.typ
#import "style.typ": a, entry, readings, rewrites, source

= Introduction

dreamstop is a language for marking up what each clause of a document means. It is for authors who write documentation, ChangeLogs, issues and websites, and for reviewers who check them. An annotator, a program, reads a sentence and writes down each meaning it can find, as a short string of codes. A sentence with one meaning gets one annotation. A sentence with several meanings gets one annotation for each, and the author rewrites it until one is left. Doing this at every review, rather than once, is what continuous disambiguation means.

No prior knowledge of linguistics is assumed. The codes are defined as they come up, and the reference at the end of this manual lists them all.

== Reading an annotation

An annotation is a list of clauses in brackets. Each clause holds its codes, joined by middle dots, always in the same order. For example, this ChangeLog entry is two clauses:

#entry[Added the review store, which keeps reviews in acid-state.]

#a("[ASR·PFV] {review: OBJ} [ASR·HAB]/rel1 {reviews: OBJ}")

The first clause, "Added the review store", is `ASR·PFV`: it states something (`ASR`, an assertion) about one event seen as a whole (`PFV`, perfective). That is how a ChangeLog reports what a release did. The second clause, "which keeps reviews in acid-state", is `ASR·HAB`: it states what the store regularly does (`HAB`, habitual). The `/rel1` after its brackets says that it is a relative clause of clause 1. The braces after a clause give the code of each noun that names an act, such as "review": `OBJ` means the thing the act produces, here a review someone wrote, and not the act of reviewing.

Codes are three letters. Each belongs to one layer, such as force, aspect or modality, and the manual prints each layer in its own colour, as the website does. The colours help to tell the layers apart, but the letters carry the information.

A clause is one finite verb with everything it governs: "keeps", "must now restore", "has been checked" and the imperative "Keep" each start a clause. Infinitives such as "to raise the fuel default", participles such as "measured on a copy of the live database" and phrases with no verb belong to the clause around them. Two verbs joined by "and" are two clauses, even when they share a subject.

== Why a grammatical sentence needs annotating

A grammatical English sentence can leave its meaning undecided. Consider this ChangeLog entry, which the OpenFP Quality Control Handbook uses to introduce its own annotations:

#entry[No longer silently ignores invalid signatures.]

It is grammatical, names a behaviour and reads like a security fix. It does not say what "no longer" denies. Invalid signatures may now be rejected, or they may still be accepted with a warning. One reading closes a hole and the other leaves it open, and a review that checks only English form passes the entry under either reading. Either of the following rewrites carries only one:

#rewrites(
  ("[ASR·HAB·CSS]", [Invalid signatures are no longer accepted.]),
  ("[ASR·HAB·CNT] [ASR·HAB·INC]", [Invalid signatures are still accepted, but now produce a warning.]),
)

`CSS`, read "no longer", says that something was true before the release and is false after it. It carries its own negation, so the first rewrite needs no `NEG`. In the second reading, acceptance continues, which is `CNT`, read "still", and the warning is new, which is `INC`, read "now". The rewrite gives each its own clause.

The entry itself is one clause, and under either reading an annotator writes `[ASR·HAB·CSS]`. What differs is which part of the clause stops being true, and the codes do not record that. The ambiguity becomes visible only once the rewrites put each part in its own clause. The chapter on what the codes cannot see returns to this.

A sentence can also leave open how an activity unfolds in time. Consider this entry:

#entry[Synchronisation now stops when a backup starts.]

It may describe a pause that ends when the backup finishes, or a stop that lasts until someone restarts synchronisation. Under the first reading nobody needs to act. Under the second, someone must restart synchronisation after every backup. Either of the following rewrites carries only one:

#rewrites(
  ("[ASR·HAB·INC] [ASR·HAB]/adv1", [Synchronisation now pauses while a backup runs.]),
  ("[ASR·HAB·INC] [ASR·HAB]/adv1 [ASR·HAB·INC] [ASR·HAB]/adv3", [Synchronisation now stops when a backup starts, and stays stopped until it is restarted.]),
)

The handbook gives the first rewrite a code of its own for a pause, which carries the expectation of resuming. dreamstop has no such code: "pauses" and "stops" are both new standing behaviour, `ASR·HAB·INC`. The second rewrite settles the meaning by adding a clause that says synchronisation stays stopped, and that clause shows in the codes. The first rewrite settles it only through the verb "pauses", which the codes cannot see.

An imperative can report what a release does or tell readers what to do. Consider this entry:

#entry[Configure backups to expire after 30 days.]

Read as a commit subject, it reports that the release now makes backups expire after 30 days. Read as an upgrade note, it tells operators to configure that expiry themselves. Under the first reading, backups older than 30 days expire after the upgrade, and operators who need them for longer must act. Under the second, no backup expires until operators configure it. The entry has two readings:

#readings(
  ("[ASR·PFV] {backups: OBJ}", [a report, in the mood of a commit subject, that the release made backups expire.]),
  ("[DIR·PFV] {backups: OBJ}", [an instruction (`DIR`, directive) to configure the expiry.]),
)

Either of the following rewrites carries only one:

#rewrites(
  ("[ASR·HAB·INC] {backups: OBJ}", [Backups now expire after 30 days.]),
  ("[ASR·HAB·INC·DEO·NEC] {backups: OBJ}", [Operators must now configure backups to expire after 30 days.]),
)

The first rewrite makes a claim about the software that is new in this release. The second states a new obligation: `DEO·NEC` is "must" grounded in a rule. A ChangeLog states obligations and does not command, so the obligation is an assertion, `ASR`, not a directive. "To expire after 30 days" is an infinitive and belongs to the clause around it.

A report can also leave open how the writer knows it. Consider this entry:

#entry[Fixes the memory leak on large imports.]

It reads as a confirmed fix. A checked-in test may show that the leak is gone, or the writer may only have reasoned from the change without testing it. Under the first reading, operators can rely on the fix. Under the second, they must still watch memory on large imports.

#readings(
  ("[ASR·PFV·PUP] {imports: BSC}", [the fix rests on a record anyone can check (`PUP`), such as a test.]),
  ("[ASR·PFV·INF] {imports: BSC}", [the fix is inferred (`INF`) from the change.]),
)

Either of the following rewrites carries only one:

#rewrites(
  ("[ASR·HAB·CSS·PUP] [ASR·HAB]/adv1 {imports: BSC}", [Large imports no longer leak memory, as the large-import regression test shows.]),
  ("[ASR·HAB·CSS·INF] [ASR·HAB]/adv1 [ASR·PRF·NEG] {imports: BSC}", [Large imports probably no longer leak memory, because the change removes a likely cause of the leak, but no test has checked this.]),
)

The first rewrite names a checked-in test as its basis, `PUP`. The second presents the end of the leak as reasoned, `INF`, and says that no test has checked it. The handbook also marks the second as uncertain with a mood of its own. dreamstop folds that uncertainty into `INF`: "probably" is an inference.

Both rewrites settle the meaning, but the ChangeLog kind, as released, accepts neither. It allows evidence only on a measured outcome, `OBS` or `PUP` with no phase, because a measurement states its own comparison. So it rejects "no longer" beside a basis, and it rejects `INF` and a main clause in the perfect outright. The chapter on document kinds explains these patterns.

== Reading a short annotation

A short sentence can state an obligation or report a result. Its annotation shows which, so that we can check whether the wording expresses it clearly.

#table(
  columns: (auto, 1fr),
  table.header([*Annotation*], [*Example*]),
  a("[ASR·HAB·DEO·NEC]"), [Authors must regenerate the package files after changing horizon.vx.],
  a("[ASR·HAB] [ASR·PFV·PUP]/comp1"), [The CI record reports that this revision passed the build.],
)

The first sentence states a standing obligation (`HAB` with `DEO·NEC`). "After changing horizon.vx" has no finite verb, so it belongs to the same clause. The second makes a claim about what a record says, and the clause after "that" (`/comp1`, a complement of clause 1) reports one past event, the build, on the basis of that record, `PUP`. It does not instruct anyone to run the build.

== Reading a longer passage

A longer passage can move between obligations and reported results. Each annotation applies to the clause it analyses, rather than assigning one meaning to the whole paragraph. Consider this passage from the handbook:

#entry[Authors must run the parser checks before requesting review. The linked CI record reports that those checks passed for this revision. Reviewers must assess the remaining requirements before approving changes.]

#table(
  columns: (auto, auto, 1fr),
  table.header([*Sentence*], [*Annotation*], [*Meaning*]),
  [1], a("[ASR·HAB·DEO·NEC] {checks: BSC, review: BSC}"), [An obligation on authors, with a condition saying when the checks are required.],
  [2], a("[ASR·HAB] [ASR·PFV·PUP]/comp1 {checks: BSC}"), [A particular result, attributed to the linked record.],
  [3], a("[ASR·HAB·DEO·NEC]"), [A separate obligation on reviewers, before approval.],
)

The first sentence assigns the checks to authors, the second reports a result from a record, and the third assigns the remaining assessment to reviewers. Reporting a passing check does not perform that assessment. The annotations make these changes of statement visible without asking the English to follow a template. "Checks" and "review" name acts, and `BSC` says that they mean the acts themselves, not something the acts produce.

== Where the codes come from

New Ithkuil is a constructed language invented by John Quijada. Its grammar uses a rich system of categories to express distinctions in meaning explicitly and reduce ambiguity. The OpenFP Quality Control Handbook borrowed those categories to annotate English, and dreamstop grew out of the handbook's annotations.

dreamstop keeps New Ithkuil's names for many of its codes. The forces `ASR`, `DIR`, `IRG`, `DEC` and `ADM` are New Ithkuil illocutions, the moods `FAC`, `HYP` and `COU` are New Ithkuil moods, the evidence codes are New Ithkuil validations, and `BSC` and `OBJ` come from New Ithkuil's specification. `PRG`, `HAB` and `CSS` are New Ithkuil aspects, although dreamstop's `CSS` means a truth that stops holding at a release, not an action that stops. dreamstop's phases, its two-axis modality and its bound are its own. An annotation is an analysis of English, not a translation into Ithkuil.

The examples in this manual come from the handbook's introduction and from the minimal pairs of the document kinds, `dreamstop/kinds/changelog`, `readme`, `manual`, `issue`, `labels` and `website`, at their 0.1.0.0 tags. Each pair names its source in the kind's repository.