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
Copy file name to clipboardExpand all lines: autogen/agentchat/contrib/retrieve_user_proxy_agent.py
+8-7Lines changed: 8 additions & 7 deletions
Original file line number
Diff line number
Diff line change
@@ -77,17 +77,17 @@ def __init__(
77
77
retrieve_config: Optional[Dict] =None, # config for the retrieve agent
78
78
**kwargs,
79
79
):
80
-
"""
80
+
r"""
81
81
Args:
82
82
name (str): name of the agent.
83
83
human_input_mode (str): whether to ask for human inputs every time a message is received.
84
84
Possible values are "ALWAYS", "TERMINATE", "NEVER".
85
-
(1) When "ALWAYS", the agent prompts for human input every time a message is received.
85
+
1. When "ALWAYS", the agent prompts for human input every time a message is received.
86
86
Under this mode, the conversation stops when the human input is "exit",
87
87
or when is_termination_msg is True and there is no human input.
88
-
(2) When "TERMINATE", the agent only prompts for human input only when a termination message is received or
88
+
2. When "TERMINATE", the agent only prompts for human input only when a termination message is received or
89
89
the number of auto reply reaches the max_consecutive_auto_reply.
90
-
(3) When "NEVER", the agent will never prompt for human input. Under this mode, the conversation stops
90
+
3. When "NEVER", the agent will never prompt for human input. Under this mode, the conversation stops
91
91
when the number of auto reply reaches the max_consecutive_auto_reply or when is_termination_msg is True.
92
92
is_termination_msg (function): a function that takes a message in the form of a dictionary
93
93
and returns a boolean value indicating if this received message is a termination message.
@@ -136,10 +136,11 @@ def __init__(
136
136
- custom_text_types (Optional, List[str]): a list of file types to be processed. Default is `autogen.retrieve_utils.TEXT_FORMATS`.
137
137
This only applies to files under the directories in `docs_path`. Explicitly included files and urls will be chunked regardless of their types.
138
138
- recursive (Optional, bool): whether to search documents recursively in the docs_path. Default is True.
139
-
**kwargs (dict): other kwargs in [UserProxyAgent](../user_proxy_agent#__init__).
139
+
`**kwargs` (dict): other kwargs in [UserProxyAgent](../user_proxy_agent#__init__).
140
+
141
+
Example:
140
142
141
-
Example of overriding retrieve_docs:
142
-
If you have set up a customized vector db, and it's not compatible with chromadb, you can easily plug in it with below code.
143
+
Example of overriding retrieve_docs - If you have set up a customized vector db, and it's not compatible with chromadb, you can easily plug in it with below code.
143
144
```python
144
145
class MyRetrieveUserProxyAgent(RetrieveUserProxyAgent):
0 commit comments