Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BlockStartIndex ¶
BlockStartIndex builds a map from each block's Range.Start to its index. Useful for mapping segment blocks back to the global block list.
Types ¶
type Block ¶
type Block struct {
Kind BlockKind
Text string
HeadingLevel int
HeadingPath []string
Range SourceRange
TokensApprox int
LinesApprox int
IsPseudoHeading bool
}
Block represents a single markdown block element.
type Segment ¶
type Segment struct {
Blocks []Block
HeadingPath []string
Range SourceRange
TokenCount int
LineCount int
// Multi-agent support fields
ID string // Content-addressable segment ID (SHA256)
Coherence float64 // Intra-segment semantic coherence (0.0-1.0)
PrevSegmentID string // Previous segment ID (empty if first)
NextSegmentID string // Next segment ID (empty if last)
}
Segment represents a contiguous group of blocks forming a semantic unit.
type SourceRange ¶
SourceRange represents a byte range in the original source.
Click to show internal directories.
Click to hide internal directories.