mirror of
https://github.com/hanzoai/agents.git
synced 2026-10-30 18:48:36 +00:00
Transforms hanzoai/agents from a marketplace config repo into a full agent orchestration platform by merging the AgentField infrastructure: - Go control plane (K8s-like agent orchestration, service mesh, DAG workflows) - Python SDK (FastAPI-based agent framework, LiteLLM, memory, DID/VC) - TypeScript SDK (@hanzo/agents - Vercel AI SDK, MCP, workflows) - Go SDK (idiomatic agent builder + client) - React 19 embedded dashboard (XyFlow DAGs, Recharts, Radix UI) - Docker/K8s/Helm deployment configs - Examples: hello world, deep research, RAG, simulation, benchmarks - Functional test suite across Python/Go/TypeScript All references rebranded: AgentField → Hanzo Agents - Module: github.com/hanzoai/agents/control-plane - Python: hanzo_agents - TypeScript: @hanzo/agents - Go: github.com/hanzoai/agents/sdk/go - Env vars: HANZO_AGENTS_* - Config: hanzo-agents.yaml Previous marketplace configs moved to config/ directory.
64 lines
1.8 KiB
Go
64 lines
1.8 KiB
Go
package framework
|
||
|
||
import (
|
||
"fmt"
|
||
"github.com/fatih/color"
|
||
)
|
||
|
||
// OutputFormatter provides consistent output formatting for all commands
|
||
type OutputFormatter struct {
|
||
verbose bool
|
||
}
|
||
|
||
// NewOutputFormatter creates a new output formatter
|
||
func NewOutputFormatter(verbose bool) *OutputFormatter {
|
||
return &OutputFormatter{verbose: verbose}
|
||
}
|
||
|
||
// PrintSuccess prints a success message with green checkmark
|
||
func (o *OutputFormatter) PrintSuccess(message string) {
|
||
fmt.Printf("✅ %s\n", color.GreenString(message))
|
||
}
|
||
|
||
// PrintError prints an error message with red X
|
||
func (o *OutputFormatter) PrintError(message string) {
|
||
fmt.Printf("❌ %s\n", color.RedString(message))
|
||
}
|
||
|
||
// PrintInfo prints an info message with blue info icon
|
||
func (o *OutputFormatter) PrintInfo(message string) {
|
||
fmt.Printf("ℹ️ %s\n", color.BlueString(message))
|
||
}
|
||
|
||
// PrintWarning prints a warning message with yellow warning icon
|
||
func (o *OutputFormatter) PrintWarning(message string) {
|
||
fmt.Printf("⚠️ %s\n", color.YellowString(message))
|
||
}
|
||
|
||
// PrintHeader prints a header message with hanzo-agents emoji and bold text
|
||
func (o *OutputFormatter) PrintHeader(message string) {
|
||
fmt.Printf("\n%s %s\n", color.CyanString("🧠"), color.New(color.Bold).Sprint(message))
|
||
}
|
||
|
||
// PrintVerbose prints a verbose message only if verbose mode is enabled
|
||
func (o *OutputFormatter) PrintVerbose(message string) {
|
||
if o.verbose {
|
||
fmt.Printf("🔍 %s\n", color.New(color.Faint).Sprint(message))
|
||
}
|
||
}
|
||
|
||
// PrintProgress prints a progress message with spinner-like icon
|
||
func (o *OutputFormatter) PrintProgress(message string) {
|
||
fmt.Printf("⏳ %s\n", color.YellowString(message))
|
||
}
|
||
|
||
// SetVerbose updates the verbose setting
|
||
func (o *OutputFormatter) SetVerbose(verbose bool) {
|
||
o.verbose = verbose
|
||
}
|
||
|
||
// IsVerbose returns whether verbose mode is enabled
|
||
func (o *OutputFormatter) IsVerbose() bool {
|
||
return o.verbose
|
||
}
|