generalbots/src/llm
Rodrigo Rodriguez (Pragmatismo) 52b9f1e152 feat(llm): add message parsing for OpenAI client
Added parse_messages method to handle structured prompt input for OpenAI API. The method converts human/bot/compact prefixes to appropriate OpenAI roles (user/assistant/system) and properly formats multi-line messages. This enables more complex conversation structures in prompts while maintaining compatibility with the OpenAI API format.

Removed the direct prompt-to-message conversion in generate and generate_stream methods, replacing it with the new parse_messages utility. Also reorganized the impl blocks for better code organization.
2025-11-11 21:13:12 -03:00
..
local.rs feat: refactor prompt compaction and clean up test files 2025-11-11 18:32:52 -03:00
mod.rs feat(llm): add message parsing for OpenAI client 2025-11-11 21:13:12 -03:00