Files
Travis Cline db2a947ba4 agents: fix ChainCallOption silent failure (#1420)
* llms/openai: sanitize HTTP errors to prevent API key exposure (#1393)

Fix security issue where context deadline errors could expose API keys and
sensitive request details in error messages. Added sanitizeHTTPError function
to detect context timeouts and network errors, then return generic error
messages without exposing sensitive information.

Changes:
- Added sanitizeHTTPError() function to sanitize HTTP client errors
- Updated chat.go to use sanitizeHTTPError() for http.Do() errors
- Updated embeddings.go to use sanitizeHTTPError() for http.Do() errors
- Added comprehensive test cases to prevent regression

* agents: fix ChainCallOption silent failure (#1416)

Fix issue where ChainCallOption parameters were silently ignored by Executor.Call() and Agent implementations.

Changes:
- Updated Agent.Plan() interface signature to accept variadic ChainCallOption parameters
- Updated Executor.Call() to accept and propagate options to Agent.Plan()
- Updated Executor.doIteration() to propagate options through the chain
- Updated OneShotZeroAgent.Plan() to accept and pass options to chains.Predict()
- Updated ConversationalAgent.Plan() to accept and pass options to chains.Predict()
- Updated OpenAIFunctionsAgent.Plan() to accept and pass options to LLM.GenerateContent()
- Exported GetLLMCallOptions() function for option conversion (was getLLMCallOptions)
- Updated test mock to match new Agent interface signature

Now users can pass LLM configuration options (temperature, max tokens, etc.) through executors to agents.
2025-10-19 17:03:11 -07:00
..
2025-06-16 18:14:02 +02:00
2024-01-17 14:09:45 -08:00
2024-01-17 14:09:45 -08:00
2023-12-20 19:57:37 +00:00
2025-06-16 18:14:02 +02:00
2024-01-17 14:09:45 -08:00
2024-01-17 14:09:45 -08:00
2024-01-17 14:09:45 -08:00
2023-12-20 19:57:37 +00:00