langchain/tests/unit_tests/tools
Prerit Das 2747ccbcf1
Allow custom base Zapier prompt (#4213)
Currently, all Zapier tools are built using the pre-written base Zapier
prompt. These small changes (that retain default behavior) will allow a
user to create a Zapier tool using the ZapierNLARunTool while providing
their own base prompt.

Their prompt must contain input fields for zapier_description and
params, checked and enforced in the tool's root validator.

An example of when this may be useful: user has several, say 10, Zapier
tools enabled. Currently, the long generic default Zapier base prompt is
attached to every single tool, using an extreme number of tokens for no
real added benefit (repeated). User prompts LLM on how to use Zapier
tools once, then overrides the base prompt.

Or: user has a few specific Zapier tools and wants to maximize their
success rate. So, user writes prompts/descriptions for those tools
specific to their use case, and provides those to the ZapierNLARunTool.

A consideration - this is the simplest way to implement this I could
think of... though ideally custom prompting would be possible at the
Toolkit level as well. For now, this should be sufficient in solving the
concerns outlined above.
2023-05-13 21:08:18 -07:00
..
file_management Add Other File Utilities (#3209) 2023-04-28 10:53:37 -07:00
openapi Add Request body (#2507) 2023-04-06 13:02:42 -07:00
python Fix Python RePL Tool (#4137) 2023-05-04 20:31:16 -07:00
requests tools refactor (#2961) 2023-04-17 21:35:29 -07:00
shell Accept str or list[str] for shell (#4060) 2023-05-03 21:11:06 -07:00
__init__.py Add a SQL agent for interacting with SQL Databases and JSON Agent for interacting with large JSON blobs (#1150) 2023-02-28 19:44:39 -08:00
test_base.py Pass parsed inputs through to tool _run (#4309) 2023-05-08 09:13:05 -07:00
test_exported.py Update some Tools Docs (#3913) 2023-05-01 19:07:26 -07:00
test_json.py Add a SQL agent for interacting with SQL Databases and JSON Agent for interacting with large JSON blobs (#1150) 2023-02-28 19:44:39 -08:00
test_public_api.py Add Steamship Image Generation Tool (#4580) 2023-05-12 10:35:01 -07:00
test_signatures.py Pass parsed inputs through to tool _run (#4309) 2023-05-08 09:13:05 -07:00
test_zapier.py Allow custom base Zapier prompt (#4213) 2023-05-13 21:08:18 -07:00