MCPcopy Create free account
hub / github.com/wavetermdev/waveterm / getMaxFileSize

Function getMaxFileSize

pkg/aiusechat/google/google-summarize.go:150–161  ·  view source on GitHub ↗
(mimeType, mode string)

Source from the content-addressed store, hash-verified

148}
149
150func getMaxFileSize(mimeType, mode string) (int, string) {
151 if mimeType == "application/pdf" {
152 return 5 * 1024 * 1024, "5MB"
153 }
154 if strings.HasPrefix(mimeType, "image/") {
155 return 7 * 1024 * 1024, "7MB"
156 }
157 if mode == ModeHTMLContent || mode == ModeHTMLFull {
158 return 500 * 1024, "500KB"
159 }
160 return 200 * 1024, "200KB"
161}
162
163// SummarizeFile reads a file and generates a summary using Google's Generative AI.
164// It supports images, PDFs, and text files based on the limits defined in wshcmd-ai.go.

Callers 1

SummarizeFileFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected