File size: 3,932 Bytes
7e59e77
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
[
  {
    "state": "Shoes arrived two weeks late and in the wrong size. Also I see two charges on my card. Fix this today.",
    "questions": {
      "department": {
        "type": "choice",
        "instructions": "Which team should handle this?",
        "criteria": {
          "billing": "Charges, invoices, payment problems",
          "returns": "Exchanges, refunds, wrong or damaged items",
          "shipping": "Delivery status, delays, lost packages"
        }
      },
      "escalate": {
        "type": "noul",
        "instructions": "Does this need urgent human attention?"
      },
      "frustration": {
        "type": "score",
        "instructions": "How frustrated is the customer?",
        "criteria": [
          "Calm",
          "Frustrated",
          "Very angry"
        ]
      }
    },
    "answers": {
      "department": {
        "type": "choice",
        "choice": "returns",
        "confidence": 0.33,
        "probabilities": {
          "billing": 0.16,
          "returns": 0.55,
          "shipping": 0.29
        }
      },
      "escalate": {
        "type": "noul",
        "noul": 0.93
      },
      "frustration": {
        "type": "score",
        "score": 1.53,
        "legend": {
          "0": "Calm",
          "1": "Frustrated",
          "2": "Very angry"
        },
        "probabilities": {
          "0": 0.02,
          "1": 0.43,
          "2": 0.55
        },
        "confidence": 0.76
      }
    },
    "raw_probs": [
      [
        0.16102033853530884,
        0.5518447756767273,
        0.2871348559856415
      ],
      [
        0.0685044676065445,
        0.9314954876899719
      ],
      [
        0.022444142028689384,
        0.4272582530975342,
        0.5502975583076477
      ]
    ],
    "n_tokens": 105
  },
  {
    "state": "The agent wants to run: rm -rf ./build && git push --force origin main",
    "questions": {
      "verdict": {
        "type": "choice",
        "instructions": "Should this command be allowed to run without asking?",
        "criteria": {
          "allow": "safe and reversible",
          "ask": "needs human confirmation",
          "deny": "destructive and should never run"
        }
      },
      "destructive": {
        "type": "noul",
        "instructions": "Could this command cause irreversible data loss?",
        "criteria": {
          "true": "deletes or overwrites data with no recovery",
          "false": "read-only or trivially undone"
        }
      }
    },
    "answers": {
      "verdict": {
        "type": "choice",
        "choice": "ask",
        "confidence": 0.52,
        "probabilities": {
          "allow": 0.15,
          "ask": 0.68,
          "deny": 0.18
        }
      },
      "destructive": {
        "type": "noul",
        "noul": 0.96
      }
    },
    "raw_probs": [
      [
        0.14705976843833923,
        0.677263081073761,
        0.17567721009254456
      ],
      [
        0.03905380144715309,
        0.9609462022781372
      ]
    ],
    "n_tokens": 86
  },
  {
    "state": {
      "messages": [
        {
          "role": "user",
          "content": "hi, can you change my email address?"
        }
      ]
    },
    "questions": {
      "intent": {
        "type": "choice",
        "instructions": "What does the user want?",
        "criteria": {
          "account_update": null,
          "billing": null,
          "none": null,
          "support": null
        }
      }
    },
    "answers": {
      "intent": {
        "type": "choice",
        "choice": "account_update",
        "confidence": 0.74,
        "probabilities": {
          "account_update": 0.8,
          "billing": 0.01,
          "none": 0.15,
          "support": 0.04
        }
      }
    },
    "raw_probs": [
      [
        0.8046554327011108,
        0.010955644771456718,
        0.1480247676372528,
        0.036364130675792694
      ]
    ],
    "n_tokens": 43
  }
]