Spekulative Multi-Aktions-Ausführung
UFO² führt ein neues Feature namens Spekulative Multi-Action-Ausführung ein. Dieses Feature ermöglicht es dem Agenten, mehrere vorhergesagte Schritte zu einem einzigen LLM-Aufruf zu bündeln, die dann live validiert werden. Dieser Ansatz kann zu bis zu 51 % weniger Abfragen führen, im Vergleich zur separaten Inferenz jedes Schritts. Der Agent wird zunächst einen Stapel wahrscheinlicher Aktionen vorhersagen und diese dann in einem einzigen Durchgang gegen den Live-UIA-Status validieren. Wir illustrieren die spekulative Multi-Action-Ausführung in der Abbildung unten.
Konfiguration
Um die spekulative Multi-Action-Ausführung zu aktivieren, müssen Sie ACTION_SEQUENCE in der Datei config_dev.yaml auf True setzen.
ACTION_SEQUENCE: True
Referenzen
Die Implementierung der spekulativen Multi-Action-Ausführung befindet sich in der Datei ufo/agents/processors/actions.py. Die folgenden Klassen werden für die spekulative Multi-Action-Ausführung verwendet.
Quellcode in agents/processors/actions.py
56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 | |
after_status property
Ruft den Status ab.
| Rückgabe |
|
|---|
args property
Ruft die Argumente ab.
| Rückgabe |
|
|---|
command_string property
Generiert eine Funktionsaufrufzeichenfolge.
| Rückgabe |
|
|---|
control_label property
Ruft das Steuerelementetikett ab.
| Rückgabe |
|
|---|
control_log property writable
Ruft das Steuerelementprotokoll ab.
| Rückgabe |
|
|---|
control_text property
Ruft den Steuerelementtext ab.
| Rückgabe |
|
|---|
function property
Ruft den Funktionsnamen ab.
| Rückgabe |
|
|---|
results property writable
Ruft die Ergebnisse ab.
| Rückgabe |
|
|---|
action_flow(puppeteer, control_dict, application_window)
Führt den Aktionsfluss aus.
| Parameter |
|
|---|
| Rückgabe |
|
|---|
Quellcode in agents/processors/actions.py
241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 | |
count_repeat_times(previous_actions)
Ruft die Anzahl der gleichen Aktionen in den vorherigen Aktionen ab.
| Parameter |
|
|---|
| Rückgabe |
|
|---|
Quellcode in agents/processors/actions.py
172 173 174 175 176 177 178 179 180 181 182 183 184 185 | |
execute(puppeteer)
Führt die Aktion aus.
| Parameter |
|
|---|
Quellcode in agents/processors/actions.py
234 235 236 237 238 239 | |
get_operation_point_list()
Ruft die Operationspunkte der Aktion ab.
| Rückgabe |
|
|---|
Quellcode in agents/processors/actions.py
364 365 366 367 368 369 370 371 372 373 374 375 | |
is_same_action(action_to_compare)
Prüft, ob die beiden Aktionen gleich sind.
| Parameter |
|
|---|
| Rückgabe |
|
|---|
Quellcode in agents/processors/actions.py
159 160 161 162 163 164 165 166 167 168 169 170 | |
print_result()
Gibt das Ergebnis der Aktionsausführung aus.
Quellcode in agents/processors/actions.py
342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 | |
to_dict(previous_actions)
Konvertiert die Aktion in ein Dictionary.
| Parameter |
|
|---|
| Rückgabe |
|
|---|
Quellcode in agents/processors/actions.py
187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 | |
to_string(previous_actions)
Konvertiert die Aktion in eine Zeichenfolge.
| Parameter |
|
|---|
| Rückgabe |
|
|---|
Quellcode in agents/processors/actions.py
211 212 213 214 215 216 217 | |