docssearch

package
v0.0.1-alpha.17 Latest Latest
Warning

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

Go to latest
Published: Jul 22, 2026 License: MIT Imports: 3 Imported by: 0

Documentation

Overview

Package docssearch serves search over the published docs/ tree.

index.gen.go (the postings table searched below) is a generated build artifact, not checked into git — run `go generate` here, or `make docs-index` / `task docs-index`, to produce it locally.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Document

type Document struct {
	ID          int
	Path        string
	Href        string
	Title       string
	Description string
	Section     string
	Tags        []string
}

Document is the metadata returned for a searchable documentation page.

type Posting

type Posting struct {
	Doc   int
	Score int
}

Posting records a precomputed relevance score for a term in a document.

type Result

type Result struct {
	Document
	Score int
}

Result is one ranked documentation search result.

func Search(query string, limit int) []Result

Search returns ranked documentation matches from the generated inverted index.

Jump to

Keyboard shortcuts

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