feat(pptx): expose slide boundaries as per-slide anchors" - #126
Open
odn775 wants to merge 1 commit into
Open
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Every slide now carries a `slide-N` start anchor in the document model, so downstream consumers (RAG / document-indexing pipelines) can tell where one slide ends and the next begins. The anchor id was already computed, but the node was only emitted for slides some internal slide-to-slide link happened to target.
Change
Remove the `targeted` gate in `src/formats/pptx/mod.rs` and emit the per-slide anchor unconditionally. Anchors nothing links to already render as nothing in Markdown, so `to_markdown` output is unchanged; the boundary is visible via `to_document`.
Test
Added `pptx_slide_boundaries_are_exposed` (asserts `slide-1`/`slide-2` from `handmade-links.pptx`). Full snapshot suite passes with zero output regression.
Closes #94
Fixes #31
Note: the binary `.ppt` reader has no anchor machinery yet; left as a follow-up."
Summary by cubic
Expose PPTX slide boundaries by always emitting a
slide-Nstart anchor per slide. Previously we emitted anchors only when another slide linked to them; now all slides have an anchor so downstream chunkers/RAG can segment reliably.to_documentnow includes these anchors;to_markdownoutput is unchanged.targetedgate and theSLIDE_RELusage; unconditionally push a singleInline::Anchorbefore each slide’s content.pptx_slide_boundaries_are_exposedtest assertingslide-1/slide-2anchors; snapshot outputs remain unchanged..pptreader is unchanged and still has no anchor support.Written for commit ab04090. Summary will update on new commits.