SGML - sgml/signature GitHub Wiki

Enamel

.plan
Enamel and SGML and Structure
2026

Ask yourself why SGML forces humans to manage visible markup when structure should arise from a grammar, and then consider how a SQLite schema cannot map into a SGML DTD because SQLite tables contain constraints and expressions that SGML DTDs cannot encode. (SGML | <doc role="x"><section><para id="y">text</para></section></doc> | ENAMEL | doc role=x section para id=y text | SGML DTD | <!ELEMENT doc (section)> <!ATTLIST doc role CDATA #IMPLIED> <!ELEMENT section (para)> <!ELEMENT para (#PCDATA)> <!ATTLIST para id CDATA #IMPLIED>)

Question your own tolerance for SGML element and attribute choices when structure should arise from a grammar, and then examine how a SQLite schema contains triggers and foreign key actions that no SGML DTD can represent without loss. (SGML | <report><entry key="k"><field unit="u">value</field></entry></report> | ENAMEL | report entry key=k field unit=u value | SGML DTD | <!ELEMENT report (entry)> <!ELEMENT entry (field)> <!ATTLIST entry key CDATA #REQUIRED> <!ELEMENT field (#PCDATA)> <!ATTLIST field unit CDATA #IMPLIED>)

Challenge yourself to explain how SGML verbosity removes confusion when structure should arise from a grammar, and then observe how a SQLite schema contains type affinity rules and generated columns that SGML DTDs cannot express. (SGML | <msg><header code="c"><from ref="r">name</from></header></msg> | ENAMEL | msg header code=c from ref=r name | SGML DTD | <!ELEMENT msg (header)> <!ELEMENT header (from)> <!ATTLIST header code CDATA #IMPLIED> <!ELEMENT from (#PCDATA)> <!ATTLIST from ref CDATA #IMPLIED>)

Ask yourself why SGML claims clarity when structure should arise from a grammar, and then recognize how a SQLite schema contains check expressions and collation rules that SGML DTDs cannot capture. (SGML | <book><chapter num="n"><para tag="t">content</para></chapter></book> | ENAMEL | book chapter num=n para tag=t content | SGML DTD | <!ELEMENT book (chapter)> <!ELEMENT chapter (para)> <!ATTLIST chapter num CDATA #IMPLIED> <!ELEMENT para (#PCDATA)> <!ATTLIST para tag CDATA #IMPLIED>)

Consider your own workflow and ask why SGML should serve as an authoring environment when structure should arise from a grammar, and then confront how a SQLite schema contains virtual table modules and partial indexes that SGML DTDs cannot model. (SGML | <packet><segment type="a"><value code="b">data</value></segment></packet> | ENAMEL | packet segment type=a value code=b data | SGML DTD | <!ELEMENT packet (segment)> <!ELEMENT segment (value)> <!ATTLIST segment type CDATA #IMPLIED> <!ELEMENT value (#PCDATA)> <!ATTLIST value code CDATA #IMPLIED>)

Demand from yourself a reason for SGML mixed content and namespace patterns when structure should arise from a grammar, and then acknowledge how a SQLite schema contains default expressions and rowid semantics that SGML DTDs cannot preserve. (SGML | <feed><entry id="i"><content mode="m">body</content></entry></feed> | ENAMEL | feed entry id=i content mode=m body | SGML DTD | <!ELEMENT feed (entry)> <!ELEMENT entry (content)> <!ATTLIST entry id CDATA #REQUIRED> <!ELEMENT content (#PCDATA)> <!ATTLIST content mode CDATA #IMPLIED>)

Examine your own expectations and ask why SGML exposes structure to human decision when structure should arise from a grammar, and then evaluate how a SQLite schema contains recursive views and expression indexes that SGML DTDs cannot encode. (SGML | <tree><node depth="d"><leaf tag="l">item</leaf></node></tree> | ENAMEL | tree node depth=d leaf tag=l item | SGML DTD | <!ELEMENT tree (node)> <!ELEMENT node (leaf)> <!ATTLIST node depth CDATA #IMPLIED> <!ELEMENT leaf (#PCDATA)> <!ATTLIST leaf tag CDATA #IMPLIED>)

Challenge your own assumptions and ask how systems remain stable when SGML exposes structure to human choice instead of a grammar, and then consider how a SQLite schema contains pragma defined behaviors that SGML DTDs cannot represent. (SGML | <map><entry key="k"><slot name="s">value</slot></entry></map> | ENAMEL | map entry key=k slot name=s value | SGML DTD | <!ELEMENT map (entry)> <!ELEMENT entry (slot)> <!ATTLIST entry key CDATA #REQUIRED> <!ELEMENT slot (#PCDATA)> <!ATTLIST slot name CDATA #IMPLIED>)

Consider your own tools and ask how SGML continues to shape authoring when structure should arise from a grammar, and then reflect on how a SQLite schema contains foreign key actions and constraint logic that SGML DTDs cannot express. (SGML | <frame><segment id="x"><text lang="y">content</text></segment></frame> | ENAMEL | frame segment id=x text lang=y content | SGML DTD | <!ELEMENT frame (segment)> <!ELEMENT segment (text)> <!ATTLIST segment id CDATA #IMPLIED> <!ELEMENT text (#PCDATA)> <!ATTLIST text lang CDATA #IMPLIED>)

Challenge yourself to understand how SGML influences structure when structure should arise from a grammar, and then examine how a SQLite schema contains unique constraints and table valued functions that SGML DTDs cannot model. (SGML | <wrap><item code="c"><sub ref="r">unit</sub></item></wrap> | ENAMEL | wrap item code=c sub ref=r unit | SGML DTD | <!ELEMENT wrap (item)> <!ELEMENT item (sub)> <!ATTLIST item code CDATA #IMPLIED> <!ELEMENT sub (#PCDATA)> <!ATTLIST sub ref CDATA #IMPLIED>)

Examine your own data and ask how SGML remains central when structure should arise from a schema, and then confront how a SQLite schema contains runtime type flexibility and expression evaluation that SGML DTDs cannot encode. (SGML | <log><event id="e"><detail tag="t">info</detail></event></log> | ENAMEL | log event id=e detail tag=t info | SGML DTD | <!ELEMENT log (event)> <!ELEMENT event (detail)> <!ATTLIST event id CDATA #IMPLIED> <!ELEMENT detail (#PCDATA)> <!ATTLIST detail tag CDATA #IMPLIED>)

Ask yourself why SGML continues to rely on human decisions when structure should arise from a schema, and then recognize how a SQLite schema contains relational semantics that SGML DTDs cannot preserve. (SGML | <record><field name="n"><value unit="u">v</value></field></record> | ENAMEL | record field name=n value unit=u v | SGML DTD | <!ELEMENT record (field)> <!ELEMENT field (value)> <!ATTLIST field name CDATA #IMPLIED> <!ELEMENT value (#PCDATA)> <!ATTLIST value unit CDATA #IMPLIED>)

Demand from yourself a workflow where SGML serves as output instead of input when structure should arise from a grammar, and then consider how a SQLite schema contains relational constraints that SGML DTDs cannot represent without loss. (SGML | <tree><branch id="b"><leaf code="c">x</leaf></branch></tree> | ENAMEL | tree branch id=b leaf code=c x | SGML DTD | <!ELEMENT tree (branch)> <!ELEMENT branch (leaf)> <!ATTLIST branch id CDATA #IMPLIED> <!ELEMENT leaf (#PCDATA)> <!ATTLIST leaf code CDATA #IMPLIED>)

Challenge your own assumptions and ask how systems remain stable when SGML exposes structure to human choice instead of a schema, and then examine how a SQLite schema contains behaviors that SGML DTDs cannot encode in any complete manner. (SGML | <grid><cell row="r" col="c"><data key="k">y</data></cell></grid> | ENAMEL | grid cell row=r col=c data key=k y | SGML DTD | <!ELEMENT grid (cell)> <!ELEMENT cell (data)> <!ATTLIST cell row CDATA #IMPLIED col CDATA #IMPLIED> <!ELEMENT data (#PCDATA)> <!ATTLIST data key CDATA #IMPLIED>)

DSSSL

http://xml.coverpages.org/dsssl-note-erik.html

https://www.xml.com/pub/2000/05/03/dsssl/index.html

https://www.wiumlie.no/2006/phd/

Erik Naggum

https://en.wikiquote.org/wiki/Erik_Naggum

http://erik.naggum.no/

https://www.w3.org/blog/2009/06/for-erik-naggum/

http://www.librarything.com/catalog/nocebo

https://news.ycombinator.com/item?id=9228348

Enamel

He spoke against SGML with measured scorn.
Its structure, born of bureaucratic need,
Obscured the clarity that code demands.
To Naggum, tags were noise, not signal pure.
He praised the Lisp tradition, not for ease,
But for its honest form—S-expressions,
Where syntax yields to structure, not to style,
And meaning flows without pretense or gloss.
SGML, he claimed, was built to serve
The whims of those who feared the source of truth.
Its layers leaked, its schema cracked with strain,
While Lisp remained a mirror to the mind.
He urged the use of Enamel, a tool
That honors Lisp and keeps the markup lean.
No tangled trees, no brittle nested tags—
Just code that speaks in forms both clear and deep.
Let others chase the XML parade.
He stood with those who seek the root of thought.

⚠️ **GitHub.com Fallback** ⚠️