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

Structure/Task Context Improvements #1259

Merged
merged 2 commits into from
Oct 15, 2024
Merged

Conversation

collindutter
Copy link
Member

@collindutter collindutter commented Oct 14, 2024

Describe your changes

Added

  • BaseTask.task_outputs to get a dictionary of all task outputs. This has been added to Workflow.context and Pipeline.context.

Changed

  • BaseTask.parent_outputs type has changed from dict[str, str | None] to dict[str, BaseArtifact].
  • Workflow.context["parent_outputs"] type has changed from dict[str, str | None] to dict[str, BaseArtifact].
  • Pipeline.context["parent_output"] has changed type from str | None to BaseArtifact | None.

These may seem like breaking changes but in practice they are not since Artifacts are automatically stringified when rendered in jinja.

Issue ticket number and link

Closes #204
Road to 1.0


📚 Documentation preview 📚: https://griptape--1259.org.readthedocs.build//1259/

@collindutter collindutter changed the title Structure Task Context Improvements Structure/Task Context Improvements Oct 14, 2024
Copy link

codecov bot commented Oct 14, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

📢 Thoughts on this report? Let us know!

@collindutter collindutter force-pushed the feature/context-updates branch from 5f8e02a to 7c52ed1 Compare October 14, 2024 20:45
Copy link

@shhlife shhlife left a comment

Choose a reason for hiding this comment

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

looks good to me!

@collindutter collindutter merged commit 4fc3aed into dev Oct 15, 2024
15 checks passed
@collindutter collindutter deleted the feature/context-updates branch October 15, 2024 16:23
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.

Add ability to quickly access output from a previous task in pipelines and workflows
3 participants