You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
> If the appended content should only affect the current LLM request and should not be persisted into conversation history, call `.mark_as_temp()` to mark it as temporary:
299
+
>
300
+
>```python
301
+
> req.extra_user_content_parts.append(
302
+
> TextPart(text="<runtime_hint>This hint only applies to the current request.</runtime_hint>").mark_as_temp()
303
+
> )
304
+
>```
305
+
>
298
306
> For long-term memory, knowledge bases, or external system queries that may be large or unnecessary for every round, do not put everything directly into the prompt. Prefer registering them as`llm_tool` functions so the model can call them when needed, or retrieve only a small relevant summary in your plugin and append that summary through `extra_user_content_parts`.
299
307
300
308
> You cannot use yield to send messages here. If you need to send, please use the `event.send()` method directly.
0 commit comments