bio_reasoning.coordinator module#

class bio_reasoning.coordinator.Configuration(api_key: str, api_base_url: str, model_name: str, stream: bool = True)[source]#

Bases: object

api_key: str#
api_base_url: str#
model_name: str#
stream: bool = True#
to_dict() Dict[str, Any][source]#
__init__(api_key: str, api_base_url: str, model_name: str, stream: bool = True) None#
class bio_reasoning.coordinator.Coordinator(*, config: Configuration, system_prompt: str = 'You are a helpful assistant.')[source]#

Bases: object

This is the orchestrator of layers.

__init__(*, config: Configuration, system_prompt: str = 'You are a helpful assistant.') None[source]#
property reasoning_mode: ReasoningMode#
construct_system_prompt(messages=None, user_question_override=None) str[source]#

Construct system prompt combining default and reasoning mode prompts, filling in [USER_QUESTION].

query(messages: Sequence[ChatCompletionMessage | dict[str, str]], stream: bool = False, user_question_override: str | None = None) str[source]#
add_reasoning_mode(reasoning_mode: ReasoningMode) None[source]#

Add a reasoning mode to the active set.

set_reasoning_modes(reasoning_modes: List[ReasoningMode]) None[source]#

Set the complete set of reasoning modes.