Documentation
¶
Overview ¶
Package tryview renders the `forge try` agent's audit stream as inline, human-readable "loop" lines — tool calls, egress checks, guardrail blocks — so the first-run experience shows the agent working, not just its reply.
The renderer implements the coreruntime audit Sink contract, so it attaches alongside (or instead of) the NDJSON sink. It reads existing audit events only; it never derives fields that aren't on the event. Styling degrades to plain text when color is unavailable.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Renderer ¶
type Renderer struct {
// contains filtered or unexported fields
}
Renderer maps audit events to inline loop lines. Zero value is not usable; construct with New.
func New ¶
New builds a Renderer writing to out. quiet hides the loop; audit echoes the full NDJSON stream; color enables the orange/grey styling (pass false for a non-TTY or NO_COLOR).
func (*Renderer) FlushSummary ¶
func (r *Renderer) FlushSummary()
FlushSummary prints the one-line compact audit summary for the turn (dim), then resets it. Call it after printing the agent reply. No-op under --quiet / --audit or when the turn touched no tools or egress.