bugfix: patched csv agent (#1095)

This commit is contained in:
Gabriel Luiz Freitas Almeida 2023-11-01 11:16:20 -03:00 committed by GitHub
commit d85cd1a3c1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -106,9 +106,9 @@ class CSVAgent(CustomAgentExecutor):
tools,
prefix=PANDAS_PREFIX,
suffix=PANDAS_SUFFIX,
input_variables=["df", "input", "agent_scratchpad"],
input_variables=["df_head", "input", "agent_scratchpad"],
)
partial_prompt = prompt.partial(df=str(df.head()))
partial_prompt = prompt.partial(df_head=str(df.head()))
llm_chain = LLMChain(
llm=llm,
prompt=partial_prompt,