Design
Structure
Conceptually, all you really need to get the core of the tool working are stages and transitions. Here's how:
-
Start by breaking your use case into stages (or coherent conversational tasks), rather than turns as in the old way
-
Then define the desired end result for each stage (and possible other results you want to handle) that should allow the agent to leave each given stage and move to a different one
For example, the stages of an interaction with an agent at a restaurant might be:
- Greet the user
- Ask them whether they want to reserve them a table, check an existing reservation, or make an enquiry (three branches)
- (For reserving a table) collect the data needed to reserve a table: day and time, number of guests, any dietary requirements the guests have
- etc.
Exploiting real-world domains
Existing real world domain examples can often provide usable conversational structures.
For example, for a sales agent, the conversation structure might be broken down into stages using classical sales process steps:
- Qualification Stage
- Needs Analysis Stage
- Presentation Stage
- Handling Objections Stage
- Closing Stage
Or, as an example of a component of a conversation structure designed to help the user prioritize objectives you might, for example, wish to exploit the the Eisenhower Matrix and build an iterative stage structure implementing that process.
The inherent strength with adopting the approach and language of these real-world domains is that the LLM will already have in-depth knowledge of the domain you are attempting to model. So, assuming you use the language inherent to that domain, it will also implicitly understand the task at hand.
This is one of the strengths of using iostack - it is extremely easy to model well-known processes using one or more stages without having to attend to the extreme minutiae that those processes would require if you were forced to model them from scratch.