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-- | What the page says that is data: its links, a clear ChangeLog entry, the
-- examples for each codepoint layer and the minimal pair. Every example is
-- quoted word for word from the OpenFP Quality Control Handbook 0.18.0.0 or
-- from a real document named in its source.
--
-- @since 0.1.0.0
module Site.Content
( repository
, package
, manual
, Reading (MkReading, readingCodes, readingGloss)
, Example (MkExample, exampleLabel, exampleSentence, exampleReadings)
, Entry (MkEntry, entryHeading, entrySentences, entrySource)
, entry
, Layer (Force, Mood, Aspect, Phase, Modality, Negation, Bound, Evidence, Nominalisation)
, layers
, layerName
, Verdict (Clear, Ambiguous, Nonsense)
, verdictName
, LayerExample (MkLayerExample, layerVerdict, layerExample, layerDecides, layerSource)
, layerExamples
, pair
, pairSlot
) where
import Data.Kind (Type)
import Miso.String (MisoString)
-- | This page's repository on the forge.
--
-- @since 0.1.0.0
repository :: MisoString
repository = "https://nixlab.openfp.net/web/dreamstop.openfp.net"
-- | The dreamstop package's repository on the forge.
--
-- @since 0.1.0.0
package :: MisoString
package = "https://nixlab.openfp.net/dreamstop/dreamstop"
-- | The user manual, a PDF published with the page.
--
-- @since 0.1.0.0
manual :: MisoString
manual = "manual/dreamstop.pdf"
-- | One reading of a sentence: its codes and a plain gloss.
--
-- @since 0.2.0.0
type Reading :: Type
data Reading = MkReading
{ readingCodes :: MisoString
, readingGloss :: MisoString
}
-- | An example sentence under a label, with every reading annotators find.
-- No reading means the sentence is nonsense.
--
-- @since 0.2.0.0
type Example :: Type
data Example = MkExample
{ exampleLabel :: MisoString
, exampleSentence :: MisoString
, exampleReadings :: [Reading]
}
-- | A whole ChangeLog entry: its release heading, each bullet with its one
-- reading, and where it was published.
--
-- @since 0.3.0.0
type Entry :: Type
data Entry = MkEntry
{ entryHeading :: MisoString
, entrySentences :: [Example]
, entrySource :: MisoString
}
-- | The 0.21.0 entry of the horizon-flake-parts ChangeLog, as tag 0.46.1
-- publishes it. Every bullet is clear under the ChangeLog kind: each clause
-- is a release action.
--
-- @since 0.3.0.0
entry :: Entry
entry =
MkEntry
"## 0.21.0 — 2026-04-14"
[ MkExample
"1"
"Added horizon-end-user-assurances 0.1.0 and its named required-package lists."
[MkReading "[ASR·PFV]" "the release added the package and its lists"]
, MkExample
"2"
"Added the required-package presence check to `horizon.packageSet`."
[MkReading "[ASR·PFV] {check: BSC}" "the release added the check, the procedure itself"]
, MkExample
"3"
"Added `cabal update` before the horizon-gen-nix CI job and made its cabal-install package configurable through `horizon-gen-nix.cabal`."
[MkReading "[ASR·PFV] [ASR·PFV]" "two things the release did: it added the update step and it made the package configurable"]
]
"From the ChangeLog of horizon-flake-parts, release 0.21.0, as published in tag 0.46.1."
-- | A codepoint layer, in the order the manual's reference table lists them.
--
-- @since 0.3.0.0
type Layer :: Type
data Layer
= Force
| Mood
| Aspect
| Phase
| Modality
| Negation
| Bound
| Evidence
| Nominalisation
deriving stock (Eq, Enum, Bounded)
-- | Every layer, first to last.
--
-- @since 0.3.0.0
layers :: [Layer]
layers = [minBound .. maxBound]
-- | A layer's name, which is also the class codepoints.css colours it by.
--
-- @since 0.3.0.0
layerName :: Layer -> MisoString
layerName = \case
Force -> "Force"
Mood -> "Mood"
Aspect -> "Aspect"
Phase -> "Phase"
Modality -> "Modality"
Negation -> "Negation"
Bound -> "Bound"
Evidence -> "Evidence"
Nominalisation -> "Nominalisation"
-- | The verdict an example shows.
--
-- @since 0.3.0.0
type Verdict :: Type
data Verdict = Clear | Ambiguous | Nonsense
-- | A verdict's label.
--
-- @since 0.3.0.0
verdictName :: Verdict -> MisoString
verdictName = \case
Clear -> "Clear"
Ambiguous -> "Ambiguous"
Nonsense -> "Nonsense"
-- | One example under a layer: its verdict, the sentence with its readings,
-- what the layer's codes decide in it, and where it is quoted from.
--
-- @since 0.3.0.0
type LayerExample :: Type
data LayerExample = MkLayerExample
{ layerVerdict :: Verdict
, layerExample :: Example
, layerDecides :: MisoString
, layerSource :: MisoString
}
-- | A layer's clear, ambiguous and nonsense examples, each turning on that
-- layer. A verdict with no real sentence for the layer is left out.
--
-- @since 0.3.0.0
layerExamples :: Layer -> [LayerExample]
layerExamples = \case
Force ->
[ example Clear "This edition retires QC.DescribeCheckCoverage."
[MkReading "[DEC·PFV]" "saying it makes it so: the edition retires the rule"]
"DEC: the sentence retires the rule by being said, rather than reporting that it was retired."
"From the ChangeLog of quality-control, release 0.7.0.0."
, example Ambiguous "Split vortex-shell from the vortex repository into its own repository."
[ MkReading "[ASR·PFV]" "reports that the release moved vortex-shell into its own repository"
, MkReading "[DIR·PFV]" "tells the reader to move it"
]
"ASR or DIR: the codes decide whether the sentence reports a change or gives an instruction."
"From the ChangeLog of vortex-shell, release 0.1.0."
, example Nonsense "Our open source" []
"No finite verb means no clause and no force, so the button neither states anything nor asks the visitor to do anything."
"A button on the openfp.net front page."
]
Mood ->
[ example Clear "This would have caught the dead buttons."
[MkReading "[ASR·COU·PFV]" "it did not catch them, and it would have if it had been in place"]
"COU: the event is known not to have happened."
"From the unsafePerformApocalypse estate plan."
, example Ambiguous "A local definition could replace one part of a shipped loop."
[ MkReading "[ASR·HAB·ABL·POS]" "a fact: a local definition is able to do this today"
, MkReading "[ASR·HYP·HAB·ABL·POS]" "a proposal: a local definition might do this, if it is adopted"
]
"FAC or HYP: the codes decide whether the claim is put forward as fact or only considered."
"From the introduction of the Vortex manual."
]
Aspect ->
[ example Clear "Added a console that preserves bindings between commands."
[MkReading "[ASR·PFV] [ASR·HAB]/rel1" "the release added the console, and preserving bindings is what the console does"]
"PFV against HAB: the adding is one event, and the preserving is standing behaviour."
"From the Quality Control Handbook, CLG.ChooseEntryForms."
, example Ambiguous "Keep branch"
[ MkReading "[DIR·PFV]" "one act: choose not to delete the branch"
, MkReading "[DIR·PRG]" "a state kept up: hold the branch in place"
]
"PFV or PRG: the codes decide whether the button is one act or a state to maintain."
"A button in the NixLab web interface."
]
Phase ->
[ example Clear "A project or group called `sw.js` is not yet refused."
[MkReading "[ASR·HAB·EXP]" "not refused before the release or in it, and refusal is expected later"]
"EXP: false before the release, false after it, and expected to change."
"From the ChangeLog of nixlab-shell, release 0.98.0.0."
, example Ambiguous "The forge keeps this picture now."
[ MkReading "[ASR·HAB·INC]" "the forge did not keep it before, and keeps it from now on"
, MkReading "[ASR·HAB]" "the forge keeps the picture, with nothing said about before"
]
"INC or no phase: the codes decide whether keeping the picture is new."
"A message in the NixLab web interface."
, example Nonsense "Removed the legacy importer, which reads the old export format." []
"Under the release action, the relative clause says the importer reads the format from this release on, but the same release removed it."
"From the Quality Control Handbook, CLG.DescribeAddedThingsInPresent."
]
Modality ->
[ example Clear "Callers of `runScript` must now pass a `Charge` record."
[MkReading "[ASR·HAB·INC·DEO·NEC]" "a rule now requires callers to pass one"]
"DEO·NEC: a rule requires it."
"From the Quality Control Handbook, CLG.StateReaderObligations."
, example Ambiguous "A site's `root` may now be a package or an absolute path."
[ MkReading "[ASR·HAB·INC·DEO·POS]" "a rule now allows either"
, MkReading "[ASR·HAB·INC·ABL·POS]" "the program can now take either"
]
"DEO or ABL: the codes decide whether a rule allows it or the program is able to do it."
"From the ChangeLog of skettis, release 0.2.60."
]
Negation ->
[ example Clear "Maintainers must not edit the generated file by hand."
[MkReading "[ASR·HAB·DEO·NEC·NEG]" "a rule requires that they do not edit it"]
"NEG after DEO·NEC negates the edit, not the rule, so the sentence prohibits editing."
"From the Quality Control Handbook, QC.ClarifyExceptionsAndNegation."
]
Bound ->
[ example Clear "The store now imports the SQLite review and sign-off tables once, at its first use."
[MkReading "[ASR·PFV·INC·ONE] {review: OBJ}" "a one-off import, new in this release, at the store's first use"]
"ONE: the import happens one time in the program's life."
"From the ChangeLog of nixlab-shell, release 0.122.0.0."
, example Ambiguous "`MovesNotFollowed` or `CheckpointFailed` after the import is reported once and tried again with the next to-do call."
[ MkReading "[ASR·PFV·ONE] [ASR·HAB] {import: BSC}" "the error is reported one time only"
, MkReading "[ASR·HAB] [ASR·HAB] {import: BSC}" "the error is reported once for each failure"
]
"ONE or none: the codes decide whether the report happens one time ever or each time."
"From the deployment guide of systems/shattrath."
]
Evidence ->
[ example Clear "Median startup time fell from 800 ms to 200 ms with a warm library cache in the recorded benchmark."
[MkReading "[ASR·PFV·PUP]" "a measured fall, which the recorded benchmark lets anyone check"]
"PUP: a record someone else can check backs the figure."
"From the Quality Control Handbook, CLG.ChooseEntryForms."
]
Nominalisation ->
[ example Clear "On first start the forge now imports every review from the SQLite database once."
[MkReading "[ASR·PFV·INC·ONE] {start: BSC} {review: OBJ}" "a review here is a record, what reviewing produced"]
"OBJ: review names the record, not the act of reviewing."
"From the Quality Control Handbook, CLG.DescribeAddedThingsInPresent."
]
where
example :: Verdict -> MisoString -> [Reading] -> MisoString -> MisoString -> LayerExample
example v s rs = MkLayerExample v (MkExample (verdictName v) s rs)
-- | The handbook's contrast for CLG.DescribeAddedThingsInPresent as a
-- minimal pair.
--
-- @since 0.1.0.0
pair :: [Example]
pair =
[ MkExample "Bad" "Added the review store, which moved reviews and sign-offs out of SQLite." [storeMoves, storeMoved]
, MkExample "Good" "Added the review store, which moves reviews and sign-offs out of SQLite." [storeMoves]
]
-- | The pair's question and its edit.
--
-- @since 0.1.0.0
pairSlot :: MisoString
pairSlot = "Question: what does the store do? Edit: moved becomes moves, which leaves clause 2 only its HAB reading"
-- | The review-store relative clause read as what the store does.
storeMoves :: Reading
storeMoves = MkReading "[ASR·PFV] {review: OBJ} [ASR·HAB]/rel1 {reviews: OBJ}" "the store moves reviews and sign-offs out of SQLite, which is what it does from now on"
-- | The review-store relative clause read as a migration that already happened.
storeMoved :: Reading
storeMoved = MkReading "[ASR·PFV] {review: OBJ} [ASR·PFV·ONE]/rel1 {reviews: OBJ}" "reviews and sign-offs were moved out of SQLite once, a migration that already happened"