Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
42 commits
Select commit Hold shift + click to select a range
a5ab61b
Authenticate missing store refresh token
shincap8 Aug 22, 2025
9dbc60f
Update_apiService
shincap8 Aug 22, 2025
5cc0d5b
Merge branch 'main' of https://github.com/mlcommons/dynabench into Up…
shincap8 Oct 22, 2025
d9f201f
Include all the refresh token logic on this backend and fix up things…
shincap8 Nov 3, 2025
03a6467
include changes in the frontEnd
shincap8 Nov 3, 2025
7fb43ae
Run prettier in ApiService
shincap8 Nov 3, 2025
675316f
put back the name AUTH_JWT_SECRET_KEY for the environment variable
shincap8 Nov 3, 2025
dceadfe
put back the name AUTH_JWT_SECRET_KEY for the environment variable
shincap8 Nov 3, 2025
7994f11
Merge branch 'main' of https://github.com/mlcommons/dynabench into Up…
shincap8 Nov 4, 2025
bb0bf0f
move is admin_or_owner to backend and fix refresh in ProfilePage
shincap8 Nov 7, 2025
54be2f2
is_admin_or_owner touches
shincap8 Nov 7, 2025
575fbe4
move endpoint users from bottle to fastAPI
shincap8 Nov 11, 2025
acea9c5
Merge branch 'main' into Update/move-to-backend
shincap8 Nov 11, 2025
bcc0f13
run prettier
shincap8 Nov 11, 2025
2bdf559
Fix buttons when not needed in help-med and ps-on-ai
shincap8 Nov 12, 2025
5ba9f41
undo last commit
shincap8 Nov 12, 2025
8fc869e
Merge branch 'main' of https://github.com/mlcommons/dynabench into Up…
shincap8 Nov 13, 2025
4ab6f7f
create Tasks endpoint
shincap8 Nov 17, 2025
996c655
implement all_active tasks endpoint
shincap8 Nov 17, 2025
72f261c
Merge branch 'main' of https://github.com/mlcommons/dynabench into Up…
shincap8 Nov 17, 2025
76dcde4
Move get task metadata from Bottle to FastAPI
shincap8 Nov 19, 2025
5c33326
unburn cc_contact variable
shincap8 Nov 19, 2025
f976deb
Merge branch 'main' of https://github.com/mlcommons/dynabench into Up…
shincap8 Nov 19, 2025
41ffadd
Move Trends from Bottle to FastAPI
shincap8 Nov 20, 2025
ff9059c
run prettier
shincap8 Nov 20, 2025
fb58808
Move Task Owner endpoint to FastAPI
shincap8 Nov 21, 2025
14c2332
Update backend/app/domain/services/base/score.py
shincap8 Nov 21, 2025
be8520b
Delete unnecesary if and use hidden instead of active
shincap8 Nov 21, 2025
bfd166f
Merge branch 'Update/move-to-backend' of https://github.com/mlcommons…
shincap8 Nov 21, 2025
21c8a88
Update backend/app/domain/services/base/task.py
shincap8 Nov 21, 2025
03ade2f
move endpoints from Bottle to FastAPI
shincap8 Nov 22, 2025
cff5f0c
Merge branch 'Update/move-to-backend' of https://github.com/mlcommons…
shincap8 Nov 22, 2025
3efb292
merge with main
shincap8 Nov 22, 2025
311af4a
remove get_examples_by_task_id_and_round_id_with_validations_ids not …
shincap8 Nov 22, 2025
bc7670a
Merge branch 'main' of https://github.com/mlcommons/dynabench into Up…
shincap8 Nov 24, 2025
0a8b402
Move Forgot password pipeline to Backend
shincap8 Nov 24, 2025
d6ba66b
undo local config
shincap8 Nov 24, 2025
7cb00d8
Merge branch 'main' of https://github.com/mlcommons/dynabench into Up…
shincap8 Nov 24, 2025
8311fc5
move more Bottle Endpoints to FastAPI Backend
shincap8 Nov 25, 2025
0bb5dd1
delete hide for score
shincap8 Nov 26, 2025
66e8885
Merge branch 'main' of https://github.com/mlcommons/dynabench into Up…
shincap8 Nov 26, 2025
4c1af61
fix methods to implement new enum type
shincap8 Nov 29, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion backend/app/domain/services/base/task.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
from app.domain.services.builder_and_evaluation.eval_utils.metrics_dicts import (
meta_metrics_dict,
)
from app.infrastructure.models.models import AccessTypeEnum
from app.infrastructure.repositories.dataset import DatasetRepository
from app.infrastructure.repositories.example import ExampleRepository
from app.infrastructure.repositories.historical_data import HistoricalDataRepository
Expand Down Expand Up @@ -412,7 +413,7 @@ def get_task_with_round_and_metric_data(self, task_id_or_code: Union[int, str]):
scoring_dataset_list = []
for dataset in datasets:
dataset_list.append({"id": dataset.id, "name": dataset.name})
if dataset.access_type == "scoring":
if dataset.access_type == AccessTypeEnum.scoring:
scoring_dataset_list.append(
{
"id": dataset.id,
Expand Down
14 changes: 8 additions & 6 deletions backend/app/infrastructure/repositories/dataset.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
# LICENSE file in the root directory of this source tree.

from app.domain.schemas.base.dataset import UpdateDatasetInfo
from app.infrastructure.models.models import Dataset
from app.infrastructure.models.models import AccessTypeEnum, Dataset
from app.infrastructure.repositories.abstract import AbstractRepository


Expand All @@ -17,7 +17,8 @@ def __init__(self) -> None:

def get_scoring_datasets(self, task_id: int, dataset_name: str = None) -> dict:
scoring_datasets = self.session.query(self.model).filter(
(self.model.access_type == "scoring") & (self.model.tid == task_id)
(self.model.access_type == AccessTypeEnum.scoring)
& (self.model.tid == task_id)
)
if dataset_name:
scoring_datasets = scoring_datasets.filter(self.model.name == dataset_name)
Expand All @@ -33,7 +34,8 @@ def get_scoring_datasets(self, task_id: int, dataset_name: str = None) -> dict:

def get_not_scoring_datasets(self, task_id: int) -> dict:
no_scoring_datasets = self.session.query(self.model).filter(
(self.model.access_type != "scoring") & (self.model.tid == task_id)
(self.model.access_type != AccessTypeEnum.scoring)
& (self.model.tid == task_id)
)

jsonl_no_scoring_datasets = []
Expand Down Expand Up @@ -66,7 +68,7 @@ def get_order_scoring_datasets_by_task_id(self, task_id: int) -> dict:
self.session.query(self.model)
.order_by(self.model.id)
.filter(self.model.tid == task_id)
.filter(self.model.access_type == "scoring")
.filter(self.model.access_type == AccessTypeEnum.scoring)
.all()
)

Expand Down Expand Up @@ -95,7 +97,7 @@ def get_scoring_datasets_by_task_id(self, task_id: int) -> dict:
return (
self.session.query(self.model.id)
.filter(self.model.tid == task_id)
.filter(self.model.access_type == "scoring")
.filter(self.model.access_type == AccessTypeEnum.scoring)
.all()
)

Expand All @@ -114,7 +116,7 @@ def get_downstream_datasets(self, task_id: int) -> dict:
downstream_datasets = (
self.session.query(self.model)
.filter(self.model.tid == task_id)
.filter(self.model.access_type == "scoring")
.filter(self.model.access_type == AccessTypeEnum.scoring)
)
jsonl_downstream_datasets = []
for downstream_dataset in downstream_datasets:
Expand Down
Loading