README: Barthes’ S/Z Lexia

The following ‘README’ notes are for a Google Colab notebook, which replays Roland Barthes’ step-by-step method to ‘star the text’ into lexia (small reading units), as enumerated in his well-known book S/Z (→ see Extract).
The lexia will include sometimes a few words, sometimes several sentences; it will be a matter of convenience: it will suffice that the lexia be the best possible space in which we can observe meanings; its dimension, empirically determined, estimated, will depend on the density of connotations, variable according to the moments of the text: all we require is that each lexia should have at most three or four meanings to be enumerated. (Barthes, S/Z, p.13)

The goal is not to recover one ‘true’ structure, but to show how meaning is produced: how motifs recur, how oppositions (inside/outside, life/death) frame scenes, how actions and enigmas pace reading, and how cultural knowledge leaks in as referential cues. Barthes describes this as weaving five codes (or ‘voices’) across the text: HER (hermeneutic), ACT (proairetic), SEM (semic), SYM (symbolic), REF (referential). He treats them as interlacing line rather than a single hierarchy.
Barthes’ commentary purposefully breaks the ‘natural’ flow of narration to create these observational spaces, then tracks how the five codes interweave to produce a structuration rather than expose one master structure.
Inputs / Outputs
Inputs
- Source text: a normalized transcription of the opening paragraph of Balzac’s Sarrasine (
balzac.txt). - Gold lexia:
barthes_lexia.csvis a direct transcription of Barthes’ own numbered lexia for this opening (English translation in S/Z). It functions here as the reference (“gold”) segmentation – you can think of it as training-target data for evaluation, though it is not used to “train” the LLM; it’s used to score how close the automatic segmentation comes to Barthes’ cuts.
Core outputs
fivecodes_base_candidate_lexia.csv+_alignment.csv— baseline segmentation + scores.fivecodes_ops_r{N}_candidate_lexia.csv+_alignment.csv— after focused LLM refinement.lexia_render_lines.txt— one lexia per line, numbered[n].lexia_render_inline.txt— single flowing paragraph with inline[n]markers.
Mapping Barthes’ approach in code
- Baseline segmentation (‘star the text’)
We first cut the paragraph by clausal structure (spaCy), then refine by strong punctuation and (optionally) coordinating commas. This is a mechanical proxy for Barthes’ “minor earthquake” that produces lexia-sized units. - Gold-aware scoring (but not training)
We compute (a) span overlap with the gold lexia, (b) SBERT semantic similarity, and (c) a boundary F1 (with tolerance). The goal is to quantify proximity to Barthes’ segmentation, not to claim canonicity. - Focused LLM operations with five-code guardrails
A small Claude prompt encodes constraints derived from S/Z: preserve token order; only merge contiguous chunks or split at exact substrings; don’t merge across deictic pivots (“Then,” “Thus,” “On my right/left”); keep units short unless a tableau (SYM/REF-heavy catalogue) is warranted. The model proposes tiny local edits around the worst mismatches; a hard guard applies only safe operations (no crossing pivots/locks; length caps observed). This is meant to exhibit the weaving of codes rather than rewrite the text. - Rendering Paragraph
The notebook produces both a line-by-line lexia list and a single paragraph with bracketed markers—letting you read continuously while still seeing analytic cuts. (Barthes himself charts early lexia as 1–12/13 in a “full score” table.)
Barthes’ 12 Lexia vs. Script’s 59
Barthes’ original opening is presented in 12 lexia (the classic “daydream” → “Then, turning…” → “Thus, on my right… on my left…” → “On the borderline… macédoine”). These cuts are rhetorically and symbolically motivated (deictic pivots; the inside/outside antithesis; a concluding mediation at the “borderline”):
[1] I was deep in one of those daydreams [2] which overtake even the shallowest of men, in the midst of the most tumultuous parties. [3] Midnight had just sounded from the clock of the Elysée-Bourbon. [4] Seated in a window recess [5] and hidden behind the sinuous folds of a silk curtain, [6] I could contemplate at my leisure the garden of the mansion where I was spending the evening. [7] The trees, partially covered with snow, stood out dimly against the grayish background of a cloudy sky, barely whitened by the moon. Seen amid these fantastic surroundings, they vaguely resembled ghosts half out of their shrouds, a gigantic representation of the famous Dance of the Dead. [8] Then, turning in the other direction, [9] I could admire the Dance of the Living! [10] a splendid salon decorated in silver and gold, with glittering chandeliers, sparkling with candles. There, milling about, whirling around, flitting here and there, were the most beautiful women of Paris, the richest, the noblest, dazzling, stately, resplendent with diamonds, flowers in their hair, on their bosoms, on their heads, strewn over dresses or in garlands at their feet. Light, rustling movements, voluptuous steps, made the laces, the silk brocades, the gauzes, float around their delicate forms. Here and there, some overly animated glances darted forth, eclipsing the lights, the fire of the diamonds, and stimulated anew some too-ardent hearts. One might also catch movements of the head meaningful to lovers, and negative gestures for husbands. The sudden outbursts of the gamblers’ voices at each unexpected turn of the dice, the clink of gold, mingled with the music and the murmur of conversation, and to complete the giddiness of this mass of people intoxicated by everything seductive the world can hold, a haze of perfume and general inebriation played upon the fevered mind. [11] Thus, on my right, the dark and silent image of death; on my left, the seemly bacchanalias of life: here, cold nature, dull, in mourning; there, human beings enjoying themselves. [12] On the borderline between these two so different scenes, which, a thousand times repeated in various guises, make Paris the world’s most amusing and most philosophical city, I was making for myself a moral macédoine, half pleasant, half funereal. With my left foot I beat time, and I felt as though the other were in the grave. My leg was in fact chilled by one of those insidious drafts which freeze half our bodies while the other half feels the humid heat of rooms, an occurrence rather frequent at balls.
The script outputs 59 units of reading:
[1] I was deep in one of those daydreams which [2] overtake even the shallowest of men, in the midst of the most tumultuous parties. [3] Midnight had just sounded from the clock of the Elysée-[4] Bourbon. [5] Seated in a window recess and [6] hidden behind the sinuous folds of a silk curtain, I could contemplate at my leisure the garden of the mansion where I was [7] spending the evening. [8] The trees, partially covered with snow, stood out dimly against the grayish background of a cloudy sky, barely [9] whitened by the moon. [10] Seen amid these fantastic surroundings, they vaguely resembled ghosts half out of their shrouds, a gigantic representation of the famous Dance of the Dead. [11] Then, [12] turning in the other direction, I could admire the Dance of the Living! [13] a splendid salon decorated in silver and [14] gold, with glittering chandeliers, [15] sparkling with candles. [16] There, [17] milling about, [18] whirling around, [19] flitting here and [20] there, were the most beautiful women of Paris, the richest, the noblest, [21] dazzling, [22] stately, [23] resplendent with diamonds, flowers in their hair, on their bosoms, on their heads, [24] strewn over dresses or [25] in garlands at their feet. [26] Light, rustling movements, voluptuous steps, made the laces, the silk brocades, the gauzes, [27] float around their delicate forms. [28] Here and there, some overly animated glances darted forth, [29] eclipsing the lights, the fire of the diamonds, and [30] stimulated anew some too-[31] ardent hearts. [32] One might also catch movements of the head meaningful to lovers, and [33] negative [34] gestures for husbands. [35] The sudden outbursts of the gamblers’ voices at each unexpected turn of the dice, the clink of gold, mingled with the music and the [36] murmur of conversation, and [37] to [38] complete the giddiness of this mass of people intoxicated by everything [39] seductive the world can [40] hold, a haze of perfume and general [41] inebriation played upon the fevered mind. [42] Thus, on my right, the dark and [43] silent image of death; [44] on my left, the seemly [45] bacchanalias of life: [46] here, cold nature, dull, in mourning; [47] there, human beings enjoying themselves. [48] On the borderline between these two so different scenes, which, a thousand times [49] repeated in various guises, [50] make Paris the world’s most amusing and most [51] philosophical [52] city, I was making for myself a moral macédoine, half pleasant, half funereal. [53] With my left foot I beat time, and [54] I [55] felt as though the other [56] were in the grave. [57] My leg was in fact chilled by one of those insidious drafts which [58] freeze half our bodies while the other half [59] feels the humid heat of rooms, an occurrence rather frequent at balls.
The script’s 59 units arise from deliberate design choices that bias toward finer granularity:
- Hyphen splitting: the baseline treats hyphens as “strong” punctuation, which fractures tokens like ‘Elysée-Bourbon’ into two lexia—something Barthes would never count as a semantic boundary. (Remedy below.)
- Coordinating-comma splitting: enumerations in the salon tableau (“milling about, whirling around, flitting… dazzling, stately…”) are split into many small lexia; Barthes often holds such catalogues together as a tableau to show connotative spread under SYM/REF. (Remedy below.)
- Short-unit bias from the “≤ 3–4 meanings” rule is applied mechanically by the script, whereas Barthes keeps some long spans when a single imagistic field dominates (e.g., the two-page antithesis that culminates in “Thus, on my right… on my left…”). (Remedy below.)
How to get closer to Barthes’ 12 (practical toggles):
- In
split_on_strong_punct, remove-from the regex so hyphenated proper nouns don’t split. - Set
USE_COORD_COMMAS = False(or restrict comma-splits to very long enumerations). - Raise
MAX_LEXIA_CHARS(e.g., 600–800) to permit tableaux. - Increase tableau hints: in
tableau_hint_ids_from_gold(top_k=…), try 6–8 to allow merges in the big salon block and the antithesis recap. - Optionally bump
RUN_OPS_ROUNDSto 3–4 so guarded merges propagate.
Conceptually, it’s also faithful to note that Barthes’ segmentation is not a law but an exhibition of production. The five codes are “voices” that make a tabular, partially reversible field; the HER/ACT lines introduce temporal constraints, while SEM/REF/SYM allow multivalence. Different star-patterns can be defensible, provided they keep the lexia as “the best possible space” to observe meanings and how they nest across lines.
Running the notebook
Running in Colab, single cell:
- Place inputs
balzac.txt(opening paragraph)barthes_lexia.csv(direct copy of Barthes’ numbered lexia for this paragraph)
- API key
- Add
ANTHROPIC_API_KEYto Colab > Secrets (or you’ll be prompted once).
- Add
- Run
- The cell installs dependencies (
spacy,sentence-transformers,anthropic,rapidfuzz) and downloadsen_core_web_smif needed. - It writes baseline and refined CSVs plus two render files:
lexia_render_lines.txt(one per line,[n])lexia_render_inline.txt(single paragraph with[n]markers)
- The cell installs dependencies (
- Inspect
- Open
_alignment.csvto see match types (exact/partial/semantic/miss) and boundary P/R/F1 vs the gold. - If your goal is macro-lexia (≈ Barthes’ 12), apply the toggles listed above and re-run.
- Open
Is this ‘Barthesian’?
Barthes insists on plurality and reversibility of readings, and on a commentary that stars the text instead of assembling it. The notebook preserves token order, performs only local, reversible edits, avoids crossing deictic/symbolic pivots, and favors lexia as observational spaces – faithful to his aim ‘to sketch the stereographic space of writing’, not to close the text under a single structure.
An updated version of the script helps reduce the number of lexia to 40:
[1] I was deep in one of those daydreams which [2] overtake even the shallowest of men, in the midst of the most tumultuous parties. [3] Midnight had just sounded from the clock of the Elysée-Bourbon. [4] Seated in a window recess and [5] hidden behind the sinuous folds of a silk curtain, I could contemplate at my leisure the garden of the mansion where I was [6] spending the evening. [7] The trees, partially covered with snow, stood out dimly against the grayish background of a cloudy sky, barely whitened by the moon. Seen amid these fantastic surroundings, they vaguely resembled ghosts half out of their shrouds, a gigantic representation of the famous Dance of the Dead. [8] Then, turning in the other direction, I could admire the Dance of the Living! [9] a splendid salon decorated in silver and [10] gold, with glittering chandeliers, [11] sparkling with candles. [12] There, milling about, [13] whirling around, [14] flitting here and [15] there, were the most beautiful women of Paris, the richest, the noblest, [16] dazzling, stately, [17] resplendent with diamonds, flowers in their hair, on their bosoms, on their heads, [18] strewn over dresses or [19] in garlands at their feet. [20] Light, rustling movements, voluptuous steps, made the laces, the silk brocades, the gauzes, [21] float around their delicate forms. [22] Here and there, some overly animated glances darted forth, [23] eclipsing the lights, the fire of the diamonds, and [24] stimulated anew some too-ardent hearts. [25] One might also catch movements of the head meaningful to lovers, and negative [26] gestures for husbands. [27] The sudden outbursts of the gamblers’ voices at each unexpected turn of the dice, the clink of gold, mingled with the music and the [28] murmur of conversation, and to [29] complete the giddiness of this mass of people intoxicated by everything [30] seductive the world can [31] hold, a haze of perfume and general [32] inebriation played upon the fevered mind. [33] Thus, on my right, the dark and silent image of death; on my left, the seemly bacchanalias of life: here, cold nature, dull, in mourning; there, human beings enjoying themselves. [34] On the borderline between these two so different scenes, which, a thousand times repeated in various guises, make Paris the world’s most amusing and most philosophical city, I was making for myself a moral macédoine, half pleasant, half funereal. [35] With my left foot I beat time, and I [36] felt as though the other [37] were in the grave. [38] My leg was in fact chilled by one of those insidious drafts which [39] freeze half our bodies while the other half [40] feels the humid heat of rooms, an occurrence rather frequent at balls.
At a glance, the following changes are made:
Before (59 lexia):
- Hyphens treated as strong punctuation → split Elysée-Bourbon.
- Aggressive splitting on coordinating commas → exploded the salon catalogue.
- No macro awareness of deictic sequences or antithesis recap.
- LLM acceptance was rigid (discarded improvements unless the count fell into a narrow band).
Updated version (40 lexia):
- Hyphens no longer split (
split_on_strong_punctdrops-). - Catalogue detection keeps long REF/SYM lists intact (
is_catalogue_like+ guardedsplit_on_coord_commas). - NER-aware boundary protection merges cuts that fall inside proper names (
merge_crossing_entities). - Macro-moves encode Barthes-like “reading gestures”:
bundle_pivot_with_gesturekeeps “Then/Thus,” fused with the following participial cue.merge_salon_tableauholds the Dance of the Living → fevered mind block as one tableau.merge_antithesis_blockkeeps the Thus… right/left… here/there recap whole.merge_borderlinekeeps the “moral macédoine” together.
- Micro-fragment polish removes orphaned connective shards (
polish_microfragments). - Smarter acceptance rule keeps any LLM round that improves boundary F1, reduces lexia count, or improves a composite score (rather than discarding by target range alone).
- ‘Barthes mode’ centralizes these defaults behind a single toggle.
The pipeline is also updated, with the following steps and functions
1) Normalization and gold setup
norm(…): cleans quotes/hyphens and whitespace.load_gold(…): loads Barthes’ own lexia as gold, aligns them to the normalized source, and provides spans for evaluation.- Note: Gold is not used to train; it’s for scoring (overlap, boundary F1) and for weak hints to identify likely tableau centers.
2) Mechanical “starring” (baseline segmentation)
split_clausewise(src): splits by clausal dependencies (spaCy).split_on_strong_punct(df, src, punct='[;:]'): splits at semicolons/colons only (no hyphens).split_on_coord_commas(df, src): conditionally splits coordinating commas—skipped whenis_catalogue_like(text)flags a catalogue (lots of commas + high ADJ/VBG ratio).merge_crossing_entities(df, src): fuses boundaries that fall inside named entities.
3) Macro-moves (Barthes-mode reading priors)
bundle_pivot_with_gesture(df): fuses deictic markers (Then, / Thus, …) to the immediate participial/summarizing phrase, preventing unmotivated micro-cuts at pivots.merge_salon_tableau(df, src): holds the long salon catalogue span as one REF/SYM tableau.merge_antithesis_block(df, src): preserves the antithesis recap (Thus… on my right / on my left / here / there …) as a single unit.merge_borderline(df): keeps On the borderline … as one concluding lexia.polish_microfragments(df): joins obvious connective fragments (“Then,”; “murmur of conversation, and”) with their host clause.
4) Scoring & diagnostics
align_scores(gold, cand): for each gold lexia, finds the best candidate by a 0.6 overlap + 0.4 semantic similarity (SBERT) composite; reports match types (exact/partial/semantic/miss).boundary_f1(gold, cand, tol): precision/recall/F1 over start-boundaries with a character tolerance (default 5).report(name, df, prefix): writes both the candidates and per-gold alignment for inspection.
5) Focused LLM operations (small, reversible edits)
SYSTEM_PROMPT: encodes Five-Codes rules + guardrails (no paraphrase/reorder; only merge contiguous / split exact; avoid crossing pivots; treat dense catalogues as tableaux; no splitting inside named entities).make_user_prompt(…): builds a compact JSON payload limited to focus IDs around the worst mismatches (+ “tableau hints”).call_claude_ops_focused(…): gets proposed ops (merges/splits) subject to the constraints.apply_ops_guarded(…): applies only safe ops (respect locks/pivots, length caps, and tableau exceptions).- Acceptance: a round is kept if it improves boundary F1, or reduces lexia count, or improves a composite score of F1/overlap/similarity. This lets the process converge rather than stall because a tight count range wasn’t hit.
6) Rendering
render_numbered(df): outputs both a one-per-line[n]list and a single paragraph with inline[n]markers—mirroring the way S/Z invites both continuous reading and starred commentary.
NB. Dialing toward Barthes’ ≈12 (quick adjusters):
BARTHES_MODE = True(on)USE_COORD_COMMAS = False(strict)MAX_LEXIA_CHARS = 800–1200(allow long tableaux)- Increase tableau hints in
tableau_hint_ids_from_gold(…, top_k=6–8) - Add one more macro-window if needed (e.g., expand the salon start to include “Dance of the Living!” explicitly)
With these in place, you can see further contraction (≲25), to stabilize near a dozen macro-lexia that match the deictic triad → antithesis recap → borderline macédoine structure Barthes emphasizes, while still preserving the script’s autonomy and generality.
The aim has been to keep faith with Barthes’ method – star the text, don’t assemble it – while giving the machine just enough rules of reading to avoid obviously un-Barthesian cuts. The current run yields 40 lexia (down from the earlier 59) because the script has:
- Stopped false fractures: no hyphen splits; named entities stay intact.
- Bundled deictic pivots with their gestures (‘Then, turning …’; ‘Thus, …’).
- Held catalogues as tableaux (the long salon description is no longer atomized by commas).
- Merged the antithesis recap (Thus… on my right / on my left / here / there …) and the ‘On the borderline …’ conclusion into cohesive spans.
- Polished micro-fragments (e.g., stray ‘Thus’, or trailing comma-tails).
- Allowed guarded LLM merges whenever they improved boundary metrics or reduced gratuitous fragmentation.
This is still finer-grained than Barthes’ ≈12 because the script retains conservative thresholds for tableaux and preserves short observational units where multiple code cues (SEM/REF/ACT) fire in quick succession. To contract further, increase tableau windows and MAX_LEXIA_CHARS, and keep comma-splitting off throughout.
Is this ‘cheating’? Not in spirit. The script doesn’t copy Barthes’ boundaries and the gold file is used only for scoring (plus very light ‘tableau hints’). What has been done is to encode generalizable, theory-driven heuristics Barthes articulates (deictic pivots, symbolic antithesis, catalogue/ekphrasis). Two macro-hints are text-specific (the salon window and the borderline catcher). If that feels too close to the exemplar, these can be switched off: the pipeline will still converge toward a coarser, more Barthesian cut – just less quickly.
In short, the script is not smuggling in the answer; it’s constraining the search space with critical priors so the script ‘works it out’ within limits that match the commentary’s ethos. For a stricter test, it is possible to run an ablation: disable BARTHES_MODE or individual macro-merges and compare boundary F1 and counts across runs. Robustness should show as compact, readable lexia that still exhibit the weaving of the five codes.
Second Script: Reading Lexia
A second script was prepared to move beyond segmentation and into explication. Its purpose is to take already-numbered lexia and, for each one, produce a compact Barthes-style reading, identifying the five codes HER (hermeneutic), ACT (proairetic), SEM (semic), SYM (symbolic), REF (referential). Short evidence quotes are given for the lexia, listing up to four ‘enumerated meanings’, noting sensory fields, and adding a brief local commentary. (Remember, Barthes treats them as interlacing lines rather than a single hierarchy).


The script runs this explication twice, once on the 40-lexia version produced by the segmentation pipeline and once on Barthes’ original 12-lexia version.

The two readings are then compared side by side (→ see: summary of the alignment of lexia between the script and Barthes’ original set). The comparison is intended to show how interpretive emphasis shifts with granularity, and which ‘hinges’ of meaning remain stable regardless of how the paragraph is starred.
What the second script adds
- From finding lexia to reading lexia: per-lexia code assignments with evidence, enumerated meanings (≤4), and local commentary.
- Two inputs, aligned: the 40-lexia version and Barthes’ 12-lexia version are both explicated and semantically aligned so that like-for-like spans can be inspected together.
- Guided but open analysis: each LLM call is supplied with light pre-analysis hints (deictics, oppositions, catalogue density, named entities, sensory cues) to nudge attention toward the kinds of signals Barthes privileges, without prescribing any particular reading.
Technical account
- Parsing: the script accepts text already marked with square-bracket numbers and extracts
(id, text)pairs; inline paragraphs are also handled. - Pre-analysis hints: for each lexia it detects deictic pivots (e.g., ‘Then’, ‘Thus,’ ‘On my right/left’), candidate symbolic oppositions (life/death, right/left, dark/light, etc.), catalogue-like density (commas + adjective/gerund ratio), named entities (for REF), and sensory tokens (visual/auditory/olfactory/tactile).
- Explication: the Anthropics/Claude API is called with a strict JSON schema. The model must (a) indicate presence/absence of each code, (b) quote words from the lexia as evidence, (c) rate code strengths 0–3, and (d) supply the ≤4 enumerated meanings and a concise local commentary.
- Normalization and outputs: responses are validated, types are coerced for safe aggregation, and both sets are aligned with SBERT to produce a comparison table showing semantic similarity and code deltas across matched items.
Nb. The script is not hard-wiring Barthes’ readings, but instead:
- uses generic heuristics (deictics, oppositions, catalogue-likeness, NER) as hints;
- enforces JSON structure but not any predetermined code assignments;
- prompts the model to quote from the lexia as evidence; and
- aligns sets post hoc via embeddings (no gold labels leaked into the explainer).
The result is guided inference, not transcription. Where your segmentation diverges (40 vs 12), the model’s explications shift accordingly—especially in how REF/SEM distribute across micro-lexia—yet the same motifs and pivots recur in both runs (see the parallel readings for “window recess,” “silk curtain,” “Midnight,” and the two Dances).
Results
Across both runs, several lexia function as stable hinges. The “Midnight” time-signal and the wintry “Dance of the Dead” tableau, for example, consistently register ACT (temporal cue), SEM (scene traits), and SYM (thresholds: night, cold, death) with REF supporting references to Parisian social space. These points of agreement suggest that certain pivots are robust to segmentation differences.
The largest divergence arises around the salon description. In the 40-lexia version, the catalogue of surfaces, garments, lights, and gestures is split into many short observational units. This raises the frequency of SEM and REF across those units and spreads SYM more thinly: symbolic oppositions (light/dark; nature/salon; life/death) tend to appear as repeated local inflections. In Barthes’ 12-lexia version, the same descriptive span is held as a long tableau, allowing symbolic oppositions to accumulate and concentrate; SYM tends to score higher there, with REF and SEM folded into a single, denser lexia. The comparison table typically shows multiple of the short catalogue lexia aligning to Barthes’ single long entry.
Deictic pivots behave predictably in both sets. “Then, turning…” and “Thus, on my right / on my left…” reliably activate ACT (shift), SEM (gestures, spatial terms), and SYM (right/left, inside/outside), with HER present when an enigma or suspension is staged by the pivot rather than resolved. The “On the borderline…” recap forms a concluding unit in both segmentations, foregrounding SYM (antithesis compacted into a moral “macédoine”) with tactile SEM/REF details (“chilled,” “draft,” room heat) that literalize the symbolic split across the narrator’s body.
Method, Limitations, Extensions
The analysis is guided but not hard-wired. Heuristics supply attention cues; the schema enforces structure and asks for quoted evidence; no gold labels are fed into the explainer. Where segmentation differs (40 vs 12), code distributions shift for principled reasons: finer cuts raise the visibility of SEM/REF at micro-scale; long tableaux enable SYM to cohere across sentences. If desired, ablation runs (removing hints or shrinking the neighbor context) can test the stability of assignments.
Code strengths are soft judgments and can drift slightly between runs; a low temperature and required evidence quotes mitigate this. The context window is small by design to keep readings local; increasing it will better capture tableau-level SYM/REF at the cost of stricter locality. As an extension, cross-lexia threads could be generated (motif and opposition tracking across the paragraph), or micro-labels from S/Z (catalysis, index, semic cluster) could be added as optional tags.
Barthes insists on plurality and reversibility of readings, and on a commentary that stars the text instead of assembling it. This analyzer respects that aim: it preserves token order, makes only local, reversible observations, avoids crossing deictic/symbolic pivots, and treats each lexia as an observational space—contributing to a stereographic view of how meaning is woven, rather than closing the paragraph under a single scheme.