Documentation
¶
Overview ¶
Package selfcases samples label-free retrieval cases from an index: a documented symbol plus the query built from its own docstring. Shared by cmd/selfsweep (scores them) and cmd/confcal (uses them as positives whose answer definitely exists).
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func FirstSentence ¶
FirstSentence extracts the leading prose sentence and strips the comment syntax the indexer stored with it. Queries must not contain "//" — the stored docstring does, which would hand lexical search a literal substring of the answer.
func StripLeadingName ¶
StripLeadingName removes the Go-doc leading symbol name ("Foo returns..." -> "returns...").
Types ¶
type Case ¶
type Case struct {
Name string // bare symbol name
Qualified string // qualified name, the retrieval target
Sentence string // first docstring sentence, comment markers stripped
}
Case is one symbol and the queries derived from its docstring.
func Sample ¶
DECISION(2026-07): behavioral kinds only by default. Const/type docs in the Go convention restate the name ("DefaultAuthMode is the default authentication mode"), so a name-stripped query is a subject-less predicate no agent would type — those cases measure grammar, not retrieval.
func (Case) Paraphrase ¶
Paraphrase is Sentence with the leading symbol name removed, so lexical search cannot match the answer by name alone.