Skip to content

Add teiHeader and standOff inclusion to get_passage()#33

Open
PonteIneptique wants to merge 1 commit into
mainfrom
feature/context
Open

Add teiHeader and standOff inclusion to get_passage()#33
PonteIneptique wants to merge 1 commit into
mainfrom
feature/context

Conversation

@PonteIneptique
Copy link
Copy Markdown
Member

Introduces two opt-in parameters on Document.get_passage():

  • include_header: prepends the full teiHeader to the reconstructed passage.
  • include_standoff: appends a filtered standOff, resolving three reference directions — passage → standOff (corresp/ref), standOff → passage (target/from/to), and transitive standOff → standOff (ana and similar attributes) via fixed-point expansion until the reference set stabilises.

Both flags are exposed on create_app() in the Flask layer so a deployment can opt in server-wide without changing per-request logic.

Adds a dedicated TEI test fixture (tei_with_standoff.xml) and tests covering all three linking cases, header/standOff ordering, and the document HTTP endpoint for each flag combination.

Introduces two opt-in parameters on Document.get_passage():

- include_header: prepends the full teiHeader to the reconstructed passage.
- include_standoff: appends a filtered standOff, resolving three reference
  directions — passage → standOff (corresp/ref), standOff → passage
  (target/from/to), and transitive standOff → standOff (ana and similar
  attributes) via fixed-point expansion until the reference set stabilises.

Both flags are exposed on create_app() in the Flask layer so a deployment
can opt in server-wide without changing per-request logic.

Adds a dedicated TEI test fixture (tei_with_standoff.xml) and tests
covering all three linking cases, header/standOff ordering, and the
document HTTP endpoint for each flag combination.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant