From c84de0507c42395836e2b9798bd4b04288ff9f9b Mon Sep 17 00:00:00 2001 From: Christian Rocha Date: Sun, 2 Nov 2025 09:26:36 -0500 Subject: [PATCH] docs: add some package-level GoDoc comments Co-authored-by: Justin Johnson --- CRUSH.md | 2 +- internal/agent/agent.go | 9 ++++++++- internal/app/app.go | 2 ++ 3 files changed, 11 insertions(+), 2 deletions(-) diff --git a/CRUSH.md b/CRUSH.md index 226214bb9bafddac4b3f674059adaa48aef0d434..b98b8813fde6109bd5fdbbc21b1c2f92dee602af 100644 --- a/CRUSH.md +++ b/CRUSH.md @@ -62,7 +62,7 @@ func TestYourFunction(t *testing.T) { ## Comments -- Comments that live one their own lines should start with capital letters and +- Comments that live on their own lines should start with capital letters and end with periods. Wrap comments at 78 columns. ## Committing diff --git a/internal/agent/agent.go b/internal/agent/agent.go index 6a817e96d93aa5554897952052703b6e3291e8e8..7e682460fffd0a781886fe29691558dd6da48049 100644 --- a/internal/agent/agent.go +++ b/internal/agent/agent.go @@ -1,3 +1,10 @@ +// Package agent is the core orchestration layer for Crush AI agents. +// +// It provides session-based AI agent functionality for managing +// conversations, tool execution, and message handling. It coordinates +// interactions between language models, messages, sessions, and tools while +// handling features like automatic summarization, queuing, and token +// management. package agent import ( @@ -131,7 +138,7 @@ func (a *sessionAgent) Run(ctx context.Context, call SessionAgentCall) (*fantasy } if len(a.tools) > 0 { - // Add anthropic caching to the last tool. + // Add Anthropic caching to the last tool. a.tools[len(a.tools)-1].SetProviderOptions(a.getCacheControlOptions()) } diff --git a/internal/app/app.go b/internal/app/app.go index 6668b8d31c90c41118a09cd729cf61bf71edf245..0957de2422b1f25dd08780c06ed73f2543b64c98 100644 --- a/internal/app/app.go +++ b/internal/app/app.go @@ -1,3 +1,5 @@ +// Package app wires together services, coordinates agents, and manages +// application lifecycle. package app import (