Documentation
¶
Index ¶
- Constants
- func SaveLiveSmokeSnapshot(path string, snapshot ConnectorLiveSmokeSnapshot) error
- type CompiledQuestionPlan
- type ConnectorCapability
- type ConnectorCapabilityRegistry
- type ConnectorLiveSmokeAlert
- type ConnectorLiveSmokeResult
- type ConnectorLiveSmokeSnapshot
- type ExtractionField
- type ExtractionSchemaSeed
- type Framework
- type QueryExpansionInput
- type QueryExpansionProvenance
- type QueryExpansionSuggestion
- type QuestionInput
- type ReviewerPrompt
- type SourceAPIDriftDashboard
- type SourceAPIDriftDashboardEntry
- type SourcePlan
- type SourcePlanEntry
- type SourceQueryPlan
- type SourceTextLink
- type SuggestionAssistant
Constants ¶
View Source
const ( LiveSmokePass = "pass" LiveSmokeFail = "fail" LiveSmokeSkipped = "skipped" LiveSmokeMissing = "missing" )
Variables ¶
This section is empty.
Functions ¶
func SaveLiveSmokeSnapshot ¶
func SaveLiveSmokeSnapshot(path string, snapshot ConnectorLiveSmokeSnapshot) error
Types ¶
type CompiledQuestionPlan ¶
type CompiledQuestionPlan struct {
SchemaVersion string `json:"schemaVersion"`
Framework Framework `json:"framework"`
Question string `json:"question"`
Components map[string]string `json:"components"`
SourceQueries map[string]SourceQueryPlan `json:"sourceQueries"`
InclusionCriteria []string `json:"inclusionCriteria"`
ExclusionCriteria []string `json:"exclusionCriteria"`
ExtractionSchema ExtractionSchemaSeed `json:"extractionSchema"`
ReviewerPrompts []ReviewerPrompt `json:"reviewerPrompts"`
ReviewerApprovalRequired bool `json:"reviewerApprovalRequired"`
AutoAcceptedClaims bool `json:"autoAcceptedClaims"`
Warnings []string `json:"warnings,omitempty"`
}
func CompileQuestion ¶
func CompileQuestion(input QuestionInput) (CompiledQuestionPlan, error)
func (CompiledQuestionPlan) SortedSourceQueries ¶
func (p CompiledQuestionPlan) SortedSourceQueries() []SourceQueryPlan
type ConnectorCapability ¶
type ConnectorCapability struct {
ID string `json:"id"`
Label string `json:"label"`
Kind string `json:"kind"`
SupportedEntities []string `json:"supportedEntities"`
RateLimitPolicy string `json:"rateLimitPolicy"`
AuthNeeds string `json:"authNeeds"`
LiveSmokeStatus string `json:"liveSmokeStatus"`
Cacheability string `json:"cacheability"`
ProvenanceFields []string `json:"provenanceFields"`
}
type ConnectorCapabilityRegistry ¶
type ConnectorCapabilityRegistry struct {
SchemaVersion string `json:"schemaVersion"`
Connectors []ConnectorCapability `json:"connectors"`
}
ConnectorCapabilityRegistry describes source/tool adapter behavior needed for source planning, review gates, package manifests, and dashboard warnings.
func DefaultConnectorCapabilityRegistry ¶
func DefaultConnectorCapabilityRegistry() ConnectorCapabilityRegistry
func (ConnectorCapabilityRegistry) ByID ¶
func (r ConnectorCapabilityRegistry) ByID(id string) (ConnectorCapability, bool)
type ConnectorLiveSmokeAlert ¶
type ConnectorLiveSmokeAlert struct {
ConnectorID string `json:"connectorId"`
Label string `json:"label"`
Kind string `json:"kind"`
Severity string `json:"severity"`
Message string `json:"message"`
}
func ConnectorLiveSmokeAlerts ¶
func ConnectorLiveSmokeAlerts(registry ConnectorCapabilityRegistry, snapshot ConnectorLiveSmokeSnapshot, now time.Time) []ConnectorLiveSmokeAlert
type ConnectorLiveSmokeResult ¶
type ConnectorLiveSmokeResult struct {
ConnectorID string `json:"connectorId"`
Label string `json:"label,omitempty"`
Status string `json:"status"`
CheckedAt time.Time `json:"checkedAt"`
Message string `json:"message,omitempty"`
EndpointFingerprint string `json:"endpointFingerprint,omitempty"`
ObservedFields []string `json:"observedFields,omitempty"`
}
type ConnectorLiveSmokeSnapshot ¶
type ConnectorLiveSmokeSnapshot struct {
SchemaVersion string `json:"schemaVersion"`
CapturedAt time.Time `json:"capturedAt"`
Results []ConnectorLiveSmokeResult `json:"results"`
}
func LoadLiveSmokeSnapshot ¶
func LoadLiveSmokeSnapshot(path string) (ConnectorLiveSmokeSnapshot, error)
func NewLiveSmokeSnapshot ¶
func NewLiveSmokeSnapshot(registry ConnectorCapabilityRegistry, capturedAt time.Time) ConnectorLiveSmokeSnapshot
func (ConnectorLiveSmokeSnapshot) MustResult ¶
func (s ConnectorLiveSmokeSnapshot) MustResult(id string) ConnectorLiveSmokeResult
func (ConnectorLiveSmokeSnapshot) Result ¶
func (s ConnectorLiveSmokeSnapshot) Result(id string) (ConnectorLiveSmokeResult, bool)
func (*ConnectorLiveSmokeSnapshot) UpsertResult ¶
func (s *ConnectorLiveSmokeSnapshot) UpsertResult(result ConnectorLiveSmokeResult)
type ExtractionField ¶
type ExtractionSchemaSeed ¶
type ExtractionSchemaSeed struct {
Name string `json:"name"`
Fields []ExtractionField `json:"fields"`
}
type QueryExpansionInput ¶
type QueryExpansionInput struct {
Question string `json:"question"`
SourceTexts []SourceTextLink `json:"sourceTexts"`
}
type QueryExpansionSuggestion ¶
type QueryExpansionSuggestion struct {
ID string `json:"id"`
Assistant SuggestionAssistant `json:"assistant"`
SuggestedTerm string `json:"suggestedTerm"`
Rationale string `json:"rationale"`
SourceTextLinks []SourceTextLink `json:"sourceTextLinks"`
Score float64 `json:"score"`
DiversityScore float64 `json:"diversityScore"`
ExtractionMethod string `json:"extractionMethod"`
ProvenanceTag string `json:"provenanceTag"`
ReviewerApprovalRequired bool `json:"reviewerApprovalRequired"`
ReviewerApproved bool `json:"reviewerApproved"`
}
func DraftQueryExpansionSuggestions ¶
func DraftQueryExpansionSuggestions(input QueryExpansionInput) ([]QueryExpansionSuggestion, error)
type QuestionInput ¶
type ReviewerPrompt ¶
type SourceAPIDriftDashboard ¶
type SourceAPIDriftDashboard struct {
SchemaVersion string `json:"schemaVersion"`
CapturedAt time.Time `json:"capturedAt"`
Entries []SourceAPIDriftDashboardEntry `json:"entries"`
}
func BuildSourceAPIDriftDashboard ¶
func BuildSourceAPIDriftDashboard(registry ConnectorCapabilityRegistry, current ConnectorLiveSmokeSnapshot, previous *ConnectorLiveSmokeSnapshot, now time.Time, provenanceRefs map[string]string) SourceAPIDriftDashboard
func (SourceAPIDriftDashboard) Entry ¶
func (d SourceAPIDriftDashboard) Entry(connectorID string) (SourceAPIDriftDashboardEntry, bool)
type SourceAPIDriftDashboardEntry ¶
type SourceAPIDriftDashboardEntry struct {
ConnectorID string `json:"connectorId"`
Label string `json:"label"`
Status string `json:"status"`
CheckedAt time.Time `json:"checkedAt"`
EndpointFingerprint string `json:"endpointFingerprint,omitempty"`
ObservedFields []string `json:"observedFields,omitempty"`
PreviousFields []string `json:"previousFields,omitempty"`
AddedFields []string `json:"addedFields,omitempty"`
RemovedFields []string `json:"removedFields,omitempty"`
Alerts []ConnectorLiveSmokeAlert `json:"alerts,omitempty"`
ProvenanceRef string `json:"provenanceRef"`
}
type SourcePlan ¶
type SourcePlan struct {
SchemaVersion string `json:"schemaVersion"`
Question string `json:"question"`
Framework Framework `json:"framework"`
Sources []SourcePlanEntry `json:"sources"`
Warnings []string `json:"warnings"`
QueryExpansionProvenance []QueryExpansionProvenance `json:"queryExpansionProvenance,omitempty"`
}
func ApplyApprovedQueryExpansions ¶
func ApplyApprovedQueryExpansions(plan SourcePlan, suggestions []QueryExpansionSuggestion) (SourcePlan, error)
func CompileSourcePlan ¶
func CompileSourcePlan(plan CompiledQuestionPlan) SourcePlan
func CompileSourcePlanFromQuestion ¶
func CompileSourcePlanFromQuestion(input QuestionInput) (SourcePlan, error)
func (SourcePlan) BySource ¶
func (p SourcePlan) BySource(source string) (SourcePlanEntry, bool)
func (SourcePlan) MustSource ¶
func (p SourcePlan) MustSource(source string) SourcePlanEntry
type SourcePlanEntry ¶
type SourcePlanEntry struct {
Source string `json:"source"`
Label string `json:"label"`
SourceKind string `json:"sourceKind"`
SupportedEntities []string `json:"supportedEntities"`
Query string `json:"query"`
DryRunEstimate string `json:"dryRunEstimate"`
RateLimitPolicy string `json:"rateLimitPolicy"`
AuthRequirement string `json:"authRequirement"`
LiveSmokeStatus string `json:"liveSmokeStatus"`
Cacheability string `json:"cacheability"`
ProvenanceFields []string `json:"provenanceFields"`
PrivacyWarning string `json:"privacyWarning"`
ReviewerApprovalRequired bool `json:"reviewerApprovalRequired"`
CLICommand string `json:"cliCommand"`
}
type SourceQueryPlan ¶
type SourceTextLink ¶
type SuggestionAssistant ¶
type SuggestionAssistant string
const ( AssistantKeyBERT SuggestionAssistant = "keybert" AssistantSciSpaCy SuggestionAssistant = "scispacy" AssistantLLM SuggestionAssistant = "llm" )
Click to show internal directories.
Click to hide internal directories.