Version 7.8.0¶
Minor release headlined by agent reasoning state support and
multi-LLM configuration in the BAF (BESSER Agent Framework) code
generator. It adds new agent metamodel classes (ReasoningState,
Tool, Skill, Workspace) and multi-LLM factory methods on
Agent (new_llm, set_default_llm, new_tool, new_skill,
new_workspace, new_reasoning_state), surfaced through the BAF
generator template, the agent-model code builder, and the JSON↔B-UML
converters.
Agent Reasoning State and Multi-LLM Support¶
BAF Generator — multi-LLM handling¶
Introduced a unified
default_llmvariable in generated agent code, replacing the previousreply_llmapproach. The variable is set dynamically from the agent configuration or the first available LLM; if no LLM is configured it is set toNoneso that a clearAttributeErroris raised at runtime rather than producing a silent no-op.All LLM invocations (
DBReply,LLMReply, intent-classifier, and fallback actions) now resolve the LLM by name at runtime, falling back todefault_llmwhen no explicit override is provided. This makes it straightforward to run different actions against different models in the same agent.The intent-classifier LLM selection uses a prioritised search across the per-classifier config and the agent-level defaults, ensuring consistent fallback behaviour when the classifier does not declare its own model.
RAG improvements¶
RAG (Retrieval-Augmented Generation) configurations now resolve their LLM at runtime via
llm_name, falling back todefault_llmwhen not explicitly set. The separaterag_llmvariable that previously appeared in generated code is no longer emitted, reducing boilerplate and potential inconsistencies.
Tools, Skills, and Workspaces¶
Generated agent initialisation code now registers agent tools, skills, and workspaces with the agent instance, completing the round-trip from B-UML agent model to runnable BAF code for these component types.
Reasoning State support¶
Added code generation for
ReasoningStateobjects: the generator detects reasoning states in the agent model and emits anew_reasoning_state(...)call with the appropriate LLM reference (falling back todefault_llm) and configuration (max_steps,enable_task_planning,stream_steps,system_prompt,fallback_message).
Internal refactoring¶
Updated imports in
besser/utilities/buml_code_builder/agent_model_builder.pyto includeReasoningState,Tool,Skill, andWorkspaceas well as the helper functions required by the new generation logic.The BAF generator template (
besser/generators/agents/templates/) has been refactored for improved modularity, readability, and extensibility.