The community member is building a tool to help people with complex application processes, such as visa applications. The tool should be able to guide users through the process, asking questions to understand their needs and then providing appropriate advice. The community member is using LlamaIndex and is stuck on the interactive Q&A part of the tool. The comments suggest that customizing the system prompt and tool descriptions may be key to creating a good-performing agent. There is discussion around the length of the tool descriptions and how they impact the context window of the language model.
Hi all. LlamaIndex newbie here! Hope I can get some guidance from you guys here on a particular use case. I have been working on this with LlamaIndex, but stuck on a specific aspect of it. Details below:
I'm building a tool that helps people enquire about and submit applications. The kind that requires a lot of paperwork, e.g. resident or work visa applications.
When using the tool, we assume that the applicant could either be starting from zero, or they have a specific issue they need clarification on.
If starting from zero, they would be in advice-seeking mode, where they just need to find out what they need to do, what forms to fill in, who they need to talk to, and what the process looks like.
If they're asking about a specific issue, they just need answers and advice on how to complete a particular form or task, for example.
In both cases, the tool should be able to act as an advisor, asking the applicant questions, until it fully understand what the applicant needs. Only then will it provide appropriate advice, including which forms to fill in, what documents they need to provide, where to submit them to, etc.
The RAG part is fine. I've managed to ingest various documentation and use Sub Query Question Engine to answer complex questions.
But, I'm not stuck on the interactive Q&A part. How do I get the tool (agent?) to figure out what level of information the user needs and guide them appropriately via Q&A. It won't work if it's just the user asking questions and the agent answering that question because the agent should also be able to surface categories of information that the user is not aware of.
Is the Sub Query Question Engine still the appropriate tool for this. Is there another feature of LlamaIndex I should be looking at (eg. Chat engine with agent mode?). Or is it just a case of writing the right prompts?
Hi Farez, not an expert here, but I think you can get a good mileage out of playing with the prompt for an agent or tool - make sure you are using it in chat mode, rather than query