MCPcopy Create free account
hub / github.com/LumaAI-API/Luma-API / checkChatConfig

Function checkChatConfig

chat.go:193–205  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

191}
192
193func checkChatConfig() error {
194 if common.ChatOpenaiApiBASE == "" {
195 return fmt.Errorf("CHAT_OPENAI_BASE is empty")
196 }
197 if common.ChatOpenaiApiKey == "" {
198 return fmt.Errorf("CHAT_OPENAI_KEY is empty")
199 }
200 _, ok := common.Templates["chat_resp"]
201 if !ok {
202 return fmt.Errorf("chat_resp template not found")
203 }
204 return nil
205}
206
207func setSSEHeaders(c *gin.Context) {
208 c.Writer.Header().Set("Content-Type", "text/event-stream")

Callers 1

ChatCompletionsFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected