Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: DIA-1415: LabelStudio skill #227

Merged
merged 15 commits into from
Oct 21, 2024
Merged

feat: DIA-1415: LabelStudio skill #227

merged 15 commits into from
Oct 21, 2024

Conversation

niklub
Copy link
Contributor

@niklub niklub commented Oct 11, 2024

• Introduced a new "LabelStudioSkill" to process labeling configurations in XML format and generate structured LLM outputs:

  • Added LabelStudioSkill class in adala/skills/collection/label_studio.py
  • Implemented functionality to convert Label Studio XML configs to JSON schema
  • Added support for dynamic response model creation based on the labeling config

• Updated skill imports in adala/skills/__init__.py to include the new LabelStudioSkill

• Added test case test_label_studio_skill in tests/test_label_studio_skill.py:

  • Demonstrates usage of LabelStudioSkill for classifying GitHub issues
  • Verifies correct output structure and content based on the provided labeling config

• Included VCR cassettes for the new test case to support reproducible testing

• Enhanced Agent serialization capabilities, as evidenced by the new test case test_agent_is_serializable_to_json

@robot-ci-heartex robot-ci-heartex marked this pull request as draft October 12, 2024 01:32
@niklub niklub marked this pull request as ready for review October 15, 2024 14:16
@niklub
Copy link
Contributor Author

niklub commented Oct 15, 2024

/git merge master

Workflow run
Successfully merged: 2 files changed, 316 insertions(+), 89 deletions(-)

@codecov-commenter
Copy link

codecov-commenter commented Oct 15, 2024

Codecov Report

Attention: Patch coverage is 90.62500% with 3 lines in your changes missing coverage. Please review.

Project coverage is 66.84%. Comparing base (cd98c73) to head (989461e).
Report is 5 commits behind head on master.

Files with missing lines Patch % Lines
adala/skills/collection/label_studio.py 90.32% 3 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master     #227      +/-   ##
==========================================
+ Coverage   66.41%   66.84%   +0.43%     
==========================================
  Files          46       47       +1     
  Lines        2230     2262      +32     
==========================================
+ Hits         1481     1512      +31     
- Misses        749      750       +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@robot-ci-heartex robot-ci-heartex marked this pull request as draft October 16, 2024 08:07
@niklub
Copy link
Contributor Author

niklub commented Oct 16, 2024

/git merge master

Workflow run
Successfully merged: 3 files changed, 48 insertions(+), 81 deletions(-)

@niklub niklub marked this pull request as ready for review October 16, 2024 11:02
@niklub
Copy link
Contributor Author

niklub commented Oct 16, 2024

/git merge master

Workflow run
Successfully merged: create mode 100644 .github/workflows/follow-merge-upstream-repo-sync.yml

pyproject.toml Outdated Show resolved Hide resolved

assert predictions.classification.tolist() == ["Bug report", "Feature request"]
assert predictions.evaluation.tolist() == [5, 5]
assert predictions.rationale.tolist() == [
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Im curious how we are able to know and ensure this exact output from the LLM?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

pretty sure the answer is we're not, we only ensure that the output is valid, this is just for demonstration

@niklub niklub enabled auto-merge (squash) October 16, 2024 18:20
@robot-ci-heartex robot-ci-heartex marked this pull request as draft October 17, 2024 04:06
auto-merge was automatically disabled October 17, 2024 04:06

Pull request was converted to draft


assert predictions.classification.tolist() == ["Bug report", "Feature request"]
assert predictions.evaluation.tolist() == [5, 5]
assert predictions.rationale.tolist() == [
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

pretty sure the answer is we're not, we only ensure that the output is valid, this is just for demonstration

@robot-ci-heartex robot-ci-heartex marked this pull request as ready for review October 21, 2024 13:30
@robot-ci-heartex robot-ci-heartex enabled auto-merge (squash) October 21, 2024 13:30
@robot-ci-heartex robot-ci-heartex merged commit db34d51 into master Oct 21, 2024
2 of 3 checks passed
@robot-ci-heartex robot-ci-heartex deleted the fb-dia-1415-2 branch October 21, 2024 13:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants