Documentation
¶
Index ¶
- type Action
- type AnalyticsBatch
- type AnalyticsConcept
- type AnalyticsPeriod
- type AnalyticsView
- type BacklinksView
- type CheckBundle
- type CheckStats
- type CheckView
- type Concept
- type ContextResult
- type ContextView
- type Directory
- type Format
- type GraphNode
- type GraphView
- type Issue
- type Link
- type LinksView
- type ListEntry
- type ListView
- type Renderer
- type SearchResult
- type SearchView
- type ShowCollectionView
- type ShowResult
- type ShowView
- type SourceInfo
- type View
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AnalyticsBatch ¶ added in v1.4.0
type AnalyticsBatch struct {
BatchID string `json:"batch_id"`
OccurredAt time.Time `json:"occurred_at"`
EntryPoint string `json:"entry_point"`
ConceptCount int `json:"concept_count"`
ConceptIDs []string `json:"concept_ids"`
}
AnalyticsBatch contains one recent retrieval group.
type AnalyticsConcept ¶ added in v1.4.0
type AnalyticsConcept struct {
ConceptID string `json:"concept_id"`
LoadCount int `json:"load_count"`
}
AnalyticsConcept contains one concept's usage count.
type AnalyticsPeriod ¶ added in v1.4.0
AnalyticsPeriod identifies the lower bound used for a report.
type AnalyticsView ¶ added in v1.4.0
type AnalyticsView struct {
Enabled bool `json:"enabled"`
Provider string `json:"provider,omitempty"`
Period AnalyticsPeriod `json:"period"`
ConceptLoads int `json:"concept_loads"`
RetrievalBatches int `json:"retrieval_batches"`
AverageConceptsPerBatch float64 `json:"average_concepts_per_batch"`
EntryPoints map[string]int `json:"entry_points"`
TopConcepts []AnalyticsConcept `json:"top_concepts"`
RecentBatches []AnalyticsBatch `json:"recent_batches"`
}
AnalyticsView contains local concept-usage analytics.
type BacklinksView ¶
BacklinksView contains incoming links for one concept.
type CheckBundle ¶
type CheckBundle struct {
Name string `json:"name"`
Root string `json:"root"`
MarkdownFiles int `json:"markdown_files"`
ReservedFiles int `json:"reserved_files"`
ConceptFiles int `json:"concept_files"`
LoadedConcepts int `json:"loaded_concepts"`
InvalidConceptFiles int `json:"invalid_concept_files"`
LinksChecked int `json:"links_checked"`
BrokenLinks int `json:"broken_links"`
StaleGeneratedIndexes int `json:"stale_generated_indexes"`
}
CheckBundle contains per-bundle validation statistics.
type CheckStats ¶
type CheckStats struct {
Bundles int `json:"bundles"`
MarkdownFiles int `json:"markdown_files"`
ReservedFiles int `json:"reserved_files"`
ConceptFiles int `json:"concept_files"`
LoadedConcepts int `json:"loaded_concepts"`
InvalidConceptFiles int `json:"invalid_concept_files"`
LinksChecked int `json:"links_checked"`
BrokenLinks int `json:"broken_links"`
StaleGeneratedIndexes int `json:"stale_generated_indexes"`
Errors int `json:"errors"`
Warnings int `json:"warnings"`
}
CheckStats contains aggregate validation and scan statistics.
type CheckView ¶
type CheckView struct {
Root string `json:"root"`
Mode string `json:"mode"`
Stats CheckStats `json:"stats"`
Bundles []CheckBundle `json:"bundles,omitempty"`
Errors []Issue `json:"Errors"`
Warnings []Issue `json:"Warnings"`
Valid bool `json:"valid"`
}
CheckView contains bundle validation results.
type Concept ¶
type Concept struct {
ID string `json:"id"`
Path string `json:"path"`
Type string `json:"type,omitempty"`
Title string `json:"title"`
Description string `json:"description,omitempty"`
Tags []string `json:"tags,omitempty"`
Content string `json:"content,omitempty"`
}
Concept contains presentation-ready concept metadata and content.
type ContextResult ¶
type ContextResult struct {
Concept Concept `json:"concept"`
Score float64 `json:"score"`
MatchedFields []string `json:"matched_fields,omitempty"`
MatchedTerms []string `json:"matched_terms,omitempty"`
MatchedRank string `json:"matched_rank,omitempty"`
Confidence string `json:"confidence,omitempty"`
Bundle string `json:"bundle,omitempty"`
Links []Link `json:"links"`
Actions []Action `json:"actions"`
}
ContextResult contains one context concept and its links.
type ContextView ¶
type ContextView struct {
Query string `json:"query"`
Source SourceInfo `json:"source"`
Confident bool `json:"confident"`
Results []ContextResult `json:"results"`
}
ContextView contains bounded context results for a query.
type Format ¶
type Format string
Format identifies an output representation.
func ParseFormat ¶
ParseFormat validates a user-provided output format.
type GraphNode ¶
type GraphNode struct {
ID string `json:"id"`
Title string `json:"title"`
Depth int `json:"depth"`
}
GraphNode contains one concept and its traversal depth.
type GraphView ¶
type GraphView struct {
Nodes []GraphNode `json:"nodes"`
}
GraphView contains graph traversal nodes.
type Link ¶
type Link struct {
Label string `json:"label"`
Title string `json:"-"`
Target string `json:"target,omitempty"`
TargetPath string `json:"target_path,omitempty"`
URL string `json:"url,omitempty"`
Broken bool `json:"broken,omitempty"`
External bool `json:"external,omitempty"`
}
Link contains presentation-ready link information.
type ListEntry ¶
type ListEntry struct {
Concept Concept `json:"concept"`
Actions []Action `json:"actions,omitempty"`
}
ListEntry contains one concept and its available actions.
type ListView ¶
type ListView struct {
Root string `json:"root"`
Path string `json:"path"`
Heading string `json:"heading,omitempty"`
Recursive bool `json:"recursive"`
Directories []Directory `json:"directories"`
Entries []ListEntry `json:"entries"`
Count int `json:"count,omitempty"`
HideActions bool `json:"-"`
HideUsage bool `json:"-"`
}
ListView contains directory listing data.
type SearchResult ¶
type SearchResult struct {
Concept Concept `json:"concept"`
Score float64 `json:"score"`
MatchedFields []string `json:"matched_fields,omitempty"`
MatchedTerms []string `json:"matched_terms,omitempty"`
MatchedRank string `json:"matched_rank,omitempty"`
Confidence string `json:"confidence,omitempty"`
Bundle string `json:"bundle,omitempty"`
Actions []Action `json:"actions"`
}
SearchResult contains one scored search result.
type SearchView ¶
type SearchView struct {
Query string `json:"query"`
Source SourceInfo `json:"source"`
Confident bool `json:"confident"`
Results []SearchResult `json:"results"`
}
SearchView contains search results for a query.
type ShowCollectionView ¶
type ShowCollectionView struct {
Results []ShowResult `json:"results"`
}
ShowCollectionView contains multiple complete concepts and their relationships.
type ShowResult ¶
type ShowResult struct {
Concept Concept `json:"concept"`
Links []Link `json:"links"`
Backlinks []Link `json:"backlinks"`
Actions []Action `json:"actions,omitempty"`
HideUsage bool `json:"-"`
}
ShowResult contains one concept and its relationships in a collection.
type ShowView ¶
type ShowView struct {
Concept Concept `json:"concept"`
Links []Link `json:"links"`
Backlinks []Link `json:"backlinks"`
Actions []Action `json:"actions,omitempty"`
HideActions bool `json:"-"`
HideUsage bool `json:"-"`
}
ShowView contains one complete concept and its relationships.
type SourceInfo ¶ added in v1.3.0
SourceInfo identifies where results came from.