docgraph

package
v0.7.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 3, 2026 License: MIT Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DefaultProfile

func DefaultProfile() model.DocsReadProfile

func DetectLayerForPath added in v0.3.0

func DetectLayerForPath(profile model.DocsReadProfile, path string) string

func GovernanceDocPath added in v0.3.0

func GovernanceDocPath(root string) string

func GovernanceReadinessSummary added in v0.3.0

func GovernanceReadinessSummary(status model.GovernanceStatus) string

func IndexWorkspaceDocs

func IndexWorkspaceDocs(ctx context.Context, root string, matcher *workspace.IgnoreMatcher) ([]model.DocRecord, []model.DocEdge, []model.DocMention, []string, error)

func IndexWorkspaceDocsWithProgress added in v0.3.0

func IndexWorkspaceDocsWithProgress(ctx context.Context, root string, matcher *workspace.IgnoreMatcher, progress ProgressFunc) ([]model.DocRecord, []model.DocEdge, []model.DocMention, []string, error)

func IndexWorkspaceDocsWithSourcesWithProgress added in v0.3.0

func IndexWorkspaceDocsWithSourcesWithProgress(ctx context.Context, root string, matcher *workspace.IgnoreMatcher, progress ProgressFunc) ([]model.DocRecord, []model.DocEdge, []model.DocMention, []model.DocSourceBlock, []model.DocSourceRecord, []string, error)

func IndexWorkspaceDocsWithSourcesWithProgressPrior added in v0.5.16

func IndexWorkspaceDocsWithSourcesWithProgressPrior(ctx context.Context, root string, matcher *workspace.IgnoreMatcher, progress ProgressFunc, prior *PriorDocSnapshot) ([]model.DocRecord, []model.DocEdge, []model.DocMention, []model.DocSourceBlock, []model.DocSourceRecord, []string, error)

IndexWorkspaceDocsWithSourcesWithProgressPrior indexes docs and skips markdown/wiki-source reparse when prior content_hash still matches the on-disk file bytes.

func InspectGovernance added in v0.3.0

func InspectGovernance(root string, autoSync bool) model.GovernanceStatus

func LoadProfile

func LoadProfile(root string) (model.DocsReadProfile, string, []string)

func MatchFamily

func MatchFamily(question string, profile model.DocsReadProfile) string

func ProfilePath

func ProfilePath(root string) string

func QuestionTokens

func QuestionTokens(question string) []string

func Tier1CanonicalRoute added in v0.3.0

func Tier1CanonicalRoute(question string, profile model.DocsReadProfile, root string) (model.RouteCanonicalLane, []string)

Tier1CanonicalRoute builds a canonical route from governance/profile alone. It does not require a full docs index — it derives the route skeleton from the read-model and the root docs that exist on the filesystem. This implements the fail-closed canonical semantics for RF-QRY-014.

Types

type PriorDocSnapshot added in v0.5.16

type PriorDocSnapshot struct {
	Docs     map[string]model.DocRecord
	Edges    map[string][]model.DocEdge
	Mentions map[string][]model.DocMention
	Blocks   map[string][]model.DocSourceBlock
	Records  map[string][]model.DocSourceRecord
}

PriorDocSnapshot holds a previous docs index keyed by relative path so IndexWorkspaceDocs can skip markdown/wiki-source reparse when content_hash matches.

func BuildPriorDocSnapshot added in v0.5.16

func BuildPriorDocSnapshot(
	docs []model.DocRecord,
	edges []model.DocEdge,
	mentions []model.DocMention,
	blocks []model.DocSourceBlock,
	records []model.DocSourceRecord,
) *PriorDocSnapshot

BuildPriorDocSnapshot indexes prior docs facts by path for skip-reparse reuse.

type Progress added in v0.3.0

type Progress struct {
	Stage      string
	Path       string
	Docs       int
	FilesTotal int
	// Parsed/Skipped report docs.read path-level skip-reparse stats when available.
	Parsed  int
	Skipped int
	Force   bool
}

type ProgressFunc added in v0.3.0

type ProgressFunc func(context.Context, Progress) error

type RFFrontMatter

type RFFrontMatter struct {
	ID         string   `yaml:"id"`
	Title      string   `yaml:"title"`
	Implements []string `yaml:"implements"`
	Tests      []string `yaml:"tests"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL