Refactor Benchmarking Workflow and Introduce New Data Models (#5264)

* New benchmark data models

* Update _benchmarkBaseUrl

* Remove ReportRequestBody

* Update benchmark service methods for proxy approach

* Add eval id to SkillNodeData

* Refactor runBenchmark Method for proxy approach
This commit is contained in:
hunteraraujo
2023-09-19 17:01:15 -07:00
committed by GitHub
parent 2098e192da
commit 5afab461ee
8 changed files with 113 additions and 70 deletions

View File

@@ -1,4 +1,4 @@
import 'package:auto_gpt_flutter_client/models/benchmark_service/report_request_body.dart';
import 'package:auto_gpt_flutter_client/viewmodels/chat_viewmodel.dart';
import 'package:flutter/material.dart';
import 'package:auto_gpt_flutter_client/viewmodels/skill_tree_viewmodel.dart';
import 'package:provider/provider.dart';
@@ -56,8 +56,12 @@ class TaskQueueView extends StatelessWidget {
onPressed: viewModel.isBenchmarkRunning
? null
: () {
// TODO: Handle this better
final chatViewModel =
Provider.of<ChatViewModel>(context, listen: false);
chatViewModel.clearCurrentTaskAndChats();
// Call runBenchmark method from SkillTreeViewModel
viewModel.runBenchmark();
viewModel.runBenchmark(chatViewModel);
},
child: Row(
mainAxisAlignment: