Skip to content

Commit

Permalink
add kwargs to from_tools (#6971)
Browse files Browse the repository at this point in the history
  • Loading branch information
logan-markewich committed Jul 19, 2023
1 parent d19b82b commit 576eba7
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
### Bug Fixes / Nits
- Added `model_name` to LLMMetadata (#6911)
- Fallback to retriever service context in query engines (#6911)
- Fixed `as_chat_engine()` ValueError with extra kwargs (#6971

## [v0.7.10.post1] - 2023-07-18

Expand Down
3 changes: 2 additions & 1 deletion llama_index/agent/openai_agent.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import time
from abc import abstractmethod
from threading import Thread
from typing import Callable, List, Optional, Tuple, Type
from typing import Any, Callable, List, Optional, Tuple, Type

from llama_index.agent.types import BaseAgent
from llama_index.callbacks.base import CallbackManager
Expand Down Expand Up @@ -367,6 +367,7 @@ def from_tools(
callback_manager: Optional[CallbackManager] = None,
system_prompt: Optional[str] = None,
prefix_messages: Optional[List[ChatMessage]] = None,
**kwargs: Any,
) -> "OpenAIAgent":
tools = tools or []
chat_history = chat_history or []
Expand Down
3 changes: 2 additions & 1 deletion llama_index/agent/react/base.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# ReAct agent

from typing import List, Optional, Sequence, Tuple, cast
from typing import Any, List, Optional, Sequence, Tuple, cast

from llama_index.agent.react.formatter import ReActChatFormatter
from llama_index.agent.react.output_parser import ReActOutputParser
Expand Down Expand Up @@ -66,6 +66,7 @@ def from_tools(
output_parser: Optional[ReActOutputParser] = None,
callback_manager: Optional[CallbackManager] = None,
verbose: bool = False,
**kwargs: Any,
) -> "ReActAgent":
tools = tools or []
chat_history = chat_history or []
Expand Down

0 comments on commit 576eba7

Please sign in to comment.