From 60b7c009196905c278cb7680663acae18f43c757 Mon Sep 17 00:00:00 2001 From: Reinier van der Leer Date: Wed, 25 Sep 2024 21:53:09 +0200 Subject: [PATCH] fix output titles --- .../backend/backend/blocks/github/issues.py | 4 +++- .../backend/backend/blocks/github/pull_requests.py | 7 +++++-- autogpt_platform/backend/backend/blocks/github/repo.py | 10 ++++++---- 3 files changed, 14 insertions(+), 7 deletions(-) diff --git a/autogpt_platform/backend/backend/blocks/github/issues.py b/autogpt_platform/backend/backend/blocks/github/issues.py index 92bf278c137e..97a4694340e4 100644 --- a/autogpt_platform/backend/backend/blocks/github/issues.py +++ b/autogpt_platform/backend/backend/blocks/github/issues.py @@ -283,7 +283,9 @@ class IssueItem(TypedDict): title: str url: str - issue: IssueItem = SchemaField(description="Issues with their title and URL") + issue: IssueItem = SchemaField( + title="Issue", description="Issues with their title and URL" + ) error: str = SchemaField(description="Error message if listing issues failed") def __init__(self): diff --git a/autogpt_platform/backend/backend/blocks/github/pull_requests.py b/autogpt_platform/backend/backend/blocks/github/pull_requests.py index 9938587c7e32..87540b66df59 100644 --- a/autogpt_platform/backend/backend/blocks/github/pull_requests.py +++ b/autogpt_platform/backend/backend/blocks/github/pull_requests.py @@ -26,7 +26,9 @@ class PRItem(TypedDict): title: str url: str - pull_request: PRItem = SchemaField(description="PRs with their title and URL") + pull_request: PRItem = SchemaField( + title="Pull Request", description="PRs with their title and URL" + ) error: str = SchemaField(description="Error message if listing issues failed") def __init__(self): @@ -513,7 +515,8 @@ class ReviewerItem(TypedDict): url: str reviewer: ReviewerItem = SchemaField( - description="Reviewers with their username and profile URL" + title="Reviewer", + description="Reviewers with their username and profile URL", ) error: str = SchemaField( description="Error message if listing reviewers failed" diff --git a/autogpt_platform/backend/backend/blocks/github/repo.py b/autogpt_platform/backend/backend/blocks/github/repo.py index 8c3fbc294c8f..63dcc7e1a143 100644 --- a/autogpt_platform/backend/backend/blocks/github/repo.py +++ b/autogpt_platform/backend/backend/blocks/github/repo.py @@ -29,7 +29,7 @@ class TagItem(TypedDict): url: str tag: TagItem = SchemaField( - description="Tags with their name and file tree browser URL" + title="Tag", description="Tags with their name and file tree browser URL" ) error: str = SchemaField(description="Error message if listing tags failed") @@ -120,7 +120,8 @@ class BranchItem(TypedDict): url: str branch: BranchItem = SchemaField( - description="Branches with their name and file tree browser URL" + title="Branch", + description="Branches with their name and file tree browser URL", ) error: str = SchemaField(description="Error message if listing branches failed") @@ -209,7 +210,7 @@ class DiscussionItem(TypedDict): url: str discussion: DiscussionItem = SchemaField( - description="Discussions with their title and URL" + title="Discussion", description="Discussions with their title and URL" ) error: str = SchemaField( description="Error message if listing discussions failed" @@ -316,7 +317,8 @@ class ReleaseItem(TypedDict): url: str release: ReleaseItem = SchemaField( - description="Releases with their name and file tree browser URL" + title="Release", + description="Releases with their name and file tree browser URL", ) error: str = SchemaField(description="Error message if listing releases failed")