Help us shape the future of Go! Take the 2026 Go Developer Survey

combine

package
v0.14.0 Latest Latest
Warning

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

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

Documentation

Overview

Package combine provides functionality for combining multiple evaluations into a single report, with DAG-based ordering.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AggregateResults

func AggregateResults(results []AgentResult, project, version, phase string) *summary.SummaryReport

AggregateResults combines multiple agent results into a summary report.

func AggregateWithDAG

func AggregateWithDAG(results []AgentResult, dag []TeamDependency, project, version, phase string) *summary.SummaryReport

AggregateWithDAG combines results and sorts by DAG order.

func SortByDAG

func SortByDAG(teams []summary.TeamSection) []summary.TeamSection

SortByDAG sorts teams in topological order based on their dependencies. Uses Kahn's algorithm. Teams at the same level are sorted alphabetically for deterministic output.

func SortReportByDAG

func SortReportByDAG(report *summary.SummaryReport)

SortReportByDAG sorts the teams in a summary report by DAG order.

Types

type AgentResult

type AgentResult struct {
	// Schema is the JSON Schema URL.
	Schema string `json:"$schema,omitempty"`

	// AgentID identifies the agent.
	AgentID string `json:"agent_id"`

	// StepID is the workflow step this agent executed.
	StepID string `json:"step_id"`

	// Inputs provided to the agent.
	Inputs map[string]any `json:"inputs,omitempty"`

	// Outputs produced by the agent.
	Outputs map[string]any `json:"outputs,omitempty"`

	// Tasks are the individual task results.
	Tasks []summary.TaskResult `json:"tasks"`

	// Status is the overall status.
	Status summary.Status `json:"status"`

	// ExecutedAt is when the agent ran.
	ExecutedAt time.Time `json:"executed_at"`

	// AgentModel is the LLM model used.
	AgentModel string `json:"agent_model,omitempty"`

	// Duration is the execution time.
	Duration string `json:"duration,omitempty"`

	// Error contains any error message.
	Error string `json:"error,omitempty"`
}

AgentResult represents the output from a single agent execution. This is the intermediate format agents produce before aggregation.

func (*AgentResult) ComputeStatus

func (a *AgentResult) ComputeStatus() summary.Status

ComputeStatus calculates the status from tasks.

func (*AgentResult) ToTeamSection

func (a *AgentResult) ToTeamSection() summary.TeamSection

ToTeamSection converts an AgentResult to a TeamSection.

type TeamDependency

type TeamDependency struct {
	ID        string   `json:"id"`
	DependsOn []string `json:"depends_on"`
}

TeamDependency defines dependencies for a team in the DAG.

Jump to

Keyboard shortcuts

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