Skip to main content

Class: InterlinearWord

Defined in: Data/Models/Bible/BibleVerse.ts:362

Interlinear word entity (for original language texts).

Word offsets are 0-based and inclusive (WS-5): wordPositionStart is the index of the first word covered and wordPositionEnd the last, so a single word has start === end. v1 declared these 1-based (CHECK (word_position_start > 0)); the shipped modules all store 0-based values matching this declaration, so there is no legacy data to rebase.

They index the verse's whitespace-separated English word sequence — the same index space user_text_markup.text_start / text_end (highlights, underlines) and formatting.spans (words-of-christ, supplied) use. That is verified against every shipped module by scripts/verify-interlinear-alignment.js, and is what lets the desktop interlinear view render each English word as an individually highlightable span (packages/desktop/src/ui/components/study/interlinearCells.ts).

Eight shipped bible modules populate interlinear_word (abp, asv, bsb, darby, kjv, kjva, rlt, rwebster) — roughly 2.9M rows in total. An earlier revision of this comment claimed none did; that was wrong.

Constructors

Constructor

new InterlinearWord(data): InterlinearWord

Defined in: Data/Models/Bible/BibleVerse.ts:382

Parameters

data
gloss?

string

interlinearId?

number

lemma?

string

metadata?

Metadata

morphology?

string

originalWord?

string

strongsNumber?

string

transliteration?

string

verseId

number

wordPositionEnd

number

wordPositionStart

number

Returns

InterlinearWord

Properties

gloss?

optional gloss?: string

Defined in: Data/Models/Bible/BibleVerse.ts:379


interlinearId?

optional interlinearId?: number

Defined in: Data/Models/Bible/BibleVerse.ts:363


lemma?

optional lemma?: string

Defined in: Data/Models/Bible/BibleVerse.ts:378


metadata?

optional metadata?: Metadata

Defined in: Data/Models/Bible/BibleVerse.ts:380


morphology?

optional morphology?: string

Defined in: Data/Models/Bible/BibleVerse.ts:377


originalWord?

optional originalWord?: string

Defined in: Data/Models/Bible/BibleVerse.ts:374

The original-language surface form. Optional: original_word is a nullable column and the shipped modules leave it NULL for the entire OT (Hebrew), carrying only strongsNumber/lemma/gloss there.


strongsNumber?

optional strongsNumber?: string

Defined in: Data/Models/Bible/BibleVerse.ts:376


transliteration?

optional transliteration?: string

Defined in: Data/Models/Bible/BibleVerse.ts:375


verseId

verseId: number

Defined in: Data/Models/Bible/BibleVerse.ts:364


wordPositionEnd

wordPositionEnd: number

Defined in: Data/Models/Bible/BibleVerse.ts:368

Last word covered. 0-based, inclusive; equal to start for a single word.


wordPositionStart

wordPositionStart: number

Defined in: Data/Models/Bible/BibleVerse.ts:366

First word covered. 0-based, inclusive.

Methods

getLanguage()

getLanguage(): "Greek" | "Hebrew" | "Unknown"

Defined in: Data/Models/Bible/BibleVerse.ts:430

Get the language (Hebrew or Greek) based on Strong's number prefix

Returns

"Greek" | "Hebrew" | "Unknown"


hasStrongsNumber()

hasStrongsNumber(): boolean

Defined in: Data/Models/Bible/BibleVerse.ts:423

Check if this word has Strong's number

Returns

boolean


isSingleWord()

isSingleWord(): boolean

Defined in: Data/Models/Bible/BibleVerse.ts:416

Check if this is a single word (not a phrase)

Returns

boolean


wordRange()

wordRange(): WordRange

Defined in: Data/Models/Bible/BibleVerse.ts:409

The covered word range, 0-based and inclusive.

Returns

WordRange