Data for Fine tuning for a context aware chatbot

I wan to finetune davinci for context aware chat bot. Will the below format work?. Here context is going to be common for all prompts. Context contains policies and guidelines.

{
    "context": "The context information that provides background for the conversation",
    "prompt": "The prompt for the main question",
    "answer": "The answer to the main question",
    "follow_up_prompt": "The prompt for the follow-up question",
    "follow_up_answer": "The answer to the follow-up question"
}

Below is also another sample which has high level context and subsequently sub contexts

{
    "context": [
        "Supply Chain",
        "Inventory"
    ],
    "prompt": "What are the best practices for inventory management?",
    "answer": "Some best practices for inventory management include regularly reviewing and adjusting inventory levels, implementing just-in-time (JIT) principles, utilizing technology to improve visibility and accuracy, and establishing clear processes for managing stock."
}

{
    "context": [
        "Supply Chain",
        "Orders"
    ],
    "prompt": "What is the on-time in-full (OTIF) metric in the context of orders?",
    "answer": "The on-time in-full (OTIF) metric is a key performance indicator (KPI) that measures the percentage of orders that are delivered on time and in full. This metric is important for ensuring customer satisfaction and maintaining a healthy supply chain."
}

{
    "context": [
        "Supply Chain",
        "Transportation"
    ],
    "prompt": "What are the common causes of transportation disruptions?",
    "answer": "Common causes of transportation disruptions include extreme weather conditions, road closures, equipment breakdowns, and logistical problems such as delayed shipments or misrouted cargo."
}

Please let me know if any one of the format is going to work for fine tuning.

2 Likes

Did you read the API docs on how to create fine-tuning JSONL files and the format and requirements for each line @lalituor ?

1 Like

yes, i have read documentation but I am not able to find anything that will suit my requirement.