1111 - [ BaseChatAgent()._ init_run] ( #basechatagent()_init_run )
1212 - [ BaseChatAgent()._ post_run] ( #basechatagent()_post_run )
1313 - [ BaseChatAgent()._ pre_run] ( #basechatagent()_pre_run )
14+ - [ BaseChatAgent().get_context_provider] ( #basechatagent()get_context_provider )
1415 - [ BaseChatAgent().get_response] ( #basechatagent()get_response )
1516 - [ BaseChatAgent().get_system_prompt] ( #basechatagent()get_system_prompt )
17+ - [ BaseChatAgent().register_context_provider] ( #basechatagent()register_context_provider )
1618 - [ BaseChatAgent().reset_memory] ( #basechatagent()reset_memory )
1719 - [ BaseChatAgent().run] ( #basechatagent()run )
20+ - [ BaseChatAgent().unregister_context_provider] ( #basechatagent()unregister_context_provider )
1821 - [ BaseChatAgentConfig] ( #basechatagentconfig )
1922 - [ BaseChatAgentInputSchema] ( #basechatagentinputschema )
20- - [ BaseChatAgentResponseSchema] ( #basechatagentresponse )
23+ - [ BaseChatAgentResponseSchema] ( #basechatagentresponseschema )
2124
2225## BaseAgentIO
2326
@@ -35,7 +38,7 @@ class BaseAgentIO(BaseModel): ...
3538
3639## BaseChatAgent
3740
38- [ Show source in base_chat_agent.py:46 ] ( ../../../../atomic_agents/agents/base_chat_agent.py#L46 )
41+ [ Show source in base_chat_agent.py:62 ] ( ../../../../atomic_agents/agents/base_chat_agent.py#L62 )
3942
4043Base class for chat agents.
4144
@@ -70,7 +73,7 @@ class BaseChatAgent:
7073
7174### BaseChatAgent()._ get_and_handle_response
7275
73- [ Show source in base_chat_agent.py:132 ] ( ../../../../atomic_agents/agents/base_chat_agent.py#L132 )
76+ [ Show source in base_chat_agent.py:150 ] ( ../../../../atomic_agents/agents/base_chat_agent.py#L150 )
7477
7578Handles obtaining and processing the response.
7679
@@ -86,7 +89,7 @@ def _get_and_handle_response(self): ...
8689
8790### BaseChatAgent()._ init_run
8891
89- [ Show source in base_chat_agent.py:142 ] ( ../../../../atomic_agents/agents/base_chat_agent.py#L142 )
92+ [ Show source in base_chat_agent.py:159 ] ( ../../../../atomic_agents/agents/base_chat_agent.py#L159 )
9093
9194Initializes the run with the given user input.
9295
@@ -106,7 +109,7 @@ def _init_run(self, user_input: Type[BaseAgentIO]): ...
106109
107110### BaseChatAgent()._ post_run
108111
109- [ Show source in base_chat_agent.py:158 ] ( ../../../../atomic_agents/agents/base_chat_agent.py#L158 )
112+ [ Show source in base_chat_agent.py:175 ] ( ../../../../atomic_agents/agents/base_chat_agent.py#L175 )
110113
111114Finalizes the run with the given response.
112115
@@ -122,7 +125,7 @@ def _post_run(self, response): ...
122125
123126### BaseChatAgent()._ pre_run
124127
125- [ Show source in base_chat_agent.py:152 ] ( ../../../../atomic_agents/agents/base_chat_agent.py#L152 )
128+ [ Show source in base_chat_agent.py:169 ] ( ../../../../atomic_agents/agents/base_chat_agent.py#L169 )
126129
127130Prepares for the run. This method can be overridden by subclasses to add custom pre-run logic.
128131
@@ -132,9 +135,39 @@ Prepares for the run. This method can be overridden by subclasses to add custom
132135def _pre_run (self ): ...
133136```
134137
138+ ### BaseChatAgent().get_context_provider
139+
140+ [ Show source in base_chat_agent.py:184] ( ../../../../atomic_agents/agents/base_chat_agent.py#L184 )
141+
142+ Retrieves a context provider by name.
143+
144+ #### Arguments
145+
146+ - ` provider_name ` * str* - The name of the context provider.
147+
148+ #### Returns
149+
150+ - ` SystemPromptContextProviderBase ` - The context provider if found.
151+
152+ #### Raises
153+
154+ - ` KeyError ` - If the context provider is not found.
155+
156+ #### Signature
157+
158+ ``` python
159+ def get_context_provider (
160+ self , provider_name : str
161+ ) -> Type[SystemPromptContextProviderBase]: ...
162+ ```
163+
164+ #### See also
165+
166+ - [ SystemPromptContextProviderBase] ( ../lib/components/system_prompt_generator.md#systempromptcontextproviderbase )
167+
135168### BaseChatAgent().get_response
136169
137- [ Show source in base_chat_agent.py:94 ] ( ../../../../atomic_agents/agents/base_chat_agent.py#L94 )
170+ [ Show source in base_chat_agent.py:112 ] ( ../../../../atomic_agents/agents/base_chat_agent.py#L112 )
138171
139172Obtains a response from the language model.
140173
@@ -154,7 +187,7 @@ def get_response(self, response_model=None) -> Type[BaseModel]: ...
154187
155188### BaseChatAgent().get_system_prompt
156189
157- [ Show source in base_chat_agent.py:85 ] ( ../../../../atomic_agents/agents/base_chat_agent.py#L85 )
190+ [ Show source in base_chat_agent.py:103 ] ( ../../../../atomic_agents/agents/base_chat_agent.py#L103 )
158191
159192Generates the system prompt.
160193
@@ -168,9 +201,32 @@ Generates the system prompt.
168201def get_system_prompt (self ) -> str : ...
169202```
170203
204+ ### BaseChatAgent().register_context_provider
205+
206+ [ Show source in base_chat_agent.py:201] ( ../../../../atomic_agents/agents/base_chat_agent.py#L201 )
207+
208+ Registers a new context provider.
209+
210+ #### Arguments
211+
212+ - ` provider_name ` * str* - The name of the context provider.
213+ - ` provider ` * SystemPromptContextProviderBase* - The context provider instance.
214+
215+ #### Signature
216+
217+ ``` python
218+ def register_context_provider (
219+ self , provider_name : str , provider : SystemPromptContextProviderBase
220+ ): ...
221+ ```
222+
223+ #### See also
224+
225+ - [ SystemPromptContextProviderBase] ( ../lib/components/system_prompt_generator.md#systempromptcontextproviderbase )
226+
171227### BaseChatAgent().reset_memory
172228
173- [ Show source in base_chat_agent.py:79 ] ( ../../../../atomic_agents/agents/base_chat_agent.py#L79 )
229+ [ Show source in base_chat_agent.py:97 ] ( ../../../../atomic_agents/agents/base_chat_agent.py#L97 )
174230
175231Resets the memory to its initial state.
176232
@@ -182,7 +238,7 @@ def reset_memory(self): ...
182238
183239### BaseChatAgent().run
184240
185- [ Show source in base_chat_agent.py:115 ] ( ../../../../atomic_agents/agents/base_chat_agent.py#L115 )
241+ [ Show source in base_chat_agent.py:133 ] ( ../../../../atomic_agents/agents/base_chat_agent.py#L133 )
186242
187243Runs the chat agent with the given user input.
188244
@@ -204,11 +260,27 @@ def run(self, user_input: Optional[Type[BaseAgentIO]] = None) -> Type[BaseAgentI
204260
205261- [ BaseAgentIO] ( #baseagentio )
206262
263+ ### BaseChatAgent().unregister_context_provider
264+
265+ [ Show source in base_chat_agent.py:211] ( ../../../../atomic_agents/agents/base_chat_agent.py#L211 )
266+
267+ Unregisters an existing context provider.
268+
269+ #### Arguments
270+
271+ - ` provider_name ` * str* - The name of the context provider to remove.
272+
273+ #### Signature
274+
275+ ``` python
276+ def unregister_context_provider (self , provider_name : str ): ...
277+ ```
278+
207279
208280
209281## BaseChatAgentConfig
210282
211- [ Show source in base_chat_agent.py:36 ] ( ../../../../atomic_agents/agents/base_chat_agent.py#L36 )
283+ [ Show source in base_chat_agent.py:51 ] ( ../../../../atomic_agents/agents/base_chat_agent.py#L51 )
212284
213285#### Signature
214286
@@ -220,7 +292,7 @@ class BaseChatAgentConfig(BaseModel): ...
220292
221293## BaseChatAgentInputSchema
222294
223- [ Show source in base_chat_agent.py:22 ] ( ../../../../atomic_agents/agents/base_chat_agent.py#L22 )
295+ [ Show source in base_chat_agent.py:21 ] ( ../../../../atomic_agents/agents/base_chat_agent.py#L21 )
224296
225297#### Signature
226298
@@ -236,7 +308,7 @@ class BaseChatAgentInputSchema(BaseAgentIO): ...
236308
237309## BaseChatAgentResponseSchema
238310
239- [ Show source in base_chat_agent.py:25 ] ( ../../../../atomic_agents/agents/base_chat_agent.py#L25 )
311+ [ Show source in base_chat_agent.py:36 ] ( ../../../../atomic_agents/agents/base_chat_agent.py#L36 )
240312
241313#### Signature
242314
0 commit comments