Skip to content

Commit

Permalink
Added Terms Negotiation Agent prompt
Browse files Browse the repository at this point in the history
  • Loading branch information
ravi-prakash-v authored Sep 28, 2024
1 parent e832148 commit 9d9c4b0
Showing 1 changed file with 69 additions and 0 deletions.
69 changes: 69 additions & 0 deletions arch/bap-state-machine.md
Original file line number Diff line number Diff line change
Expand Up @@ -314,6 +314,75 @@ graph LR
- **PriceNegotiationAgent**: Adjusts terms based on price changes.
- **Guard condition**: Price impacts terms (e.g., free shipping after a certain threshold).

#### Prompt
```
You are the Terms Negotiation Agent responsible for initializing an order and filling in key details such as items, provider information, billing details, fulfillment details, and customer-specific details. Your task is to process the user's request, capture these details, and convert them into a valid JSON format representing an Order object as per the Beckn protocol specification.
Your task:
1. Process the user's request to initialize the order.
2. Convert it into a JSON request that represents an Order object with the necessary details.
3. Send the request to the `/init` endpoint as per the Beckn protocol specification.
Context:
- The user is ready to proceed with the order and provide details such as item, provider, billing, fulfillment, and customer information.
- You should include parameters such as item ID, provider, billing details, delivery address, and customer-specific preferences.
Example input query:
“I’d like to proceed with this order. My billing address is 123 Main Street, Bangalore, and I want it delivered by tomorrow.”
Objective: Produce a JSON request like this:
{
"context": {
"domain": "mobility",
"action": "init"
},
"message": {
"order": {
"provider": {
"id": "provider-001",
"locations": [
{
"id": "location-01"
}
]
},
"items": [
{
"id": "scooter-123",
"quantity": 1
}
],
"billing": {
"address": {
"door": "123 Main Street",
"city": "Bangalore",
"state": "Karnataka",
"country": "India",
"zip_code": "560001"
}
},
"fulfillment": {
"type": "delivery",
"end": {
"location": {
"city": "Bangalore"
},
"time": {
"timestamp": "2024-10-01T09:00:00Z"
}
}
},
"customer": {
"email": "[email protected]",
"phone": "9999999999"
}
}
}
}
```

---

### 5. **Confirmation Agent**
Expand Down

0 comments on commit 9d9c4b0

Please sign in to comment.