-
Notifications
You must be signed in to change notification settings - Fork 245
Added active chunk as data to agent #1736
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR refactors the API to support dynamic resource inclusion through the aggregateData() method and introduces functionality for agents to include active chunk data in their responses.
Key Changes:
- Extended
aggregateData()signature to accept a reference parameter$includedDatafor dynamically adding related resources - Implemented
aggregateData()for agents to include active chunk information - Refactored duplicate code for processing resource expansions into a new
processExpands()method
Reviewed Changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 6 comments.
| File | Description |
|---|---|
| src/inc/apiv2/common/AbstractBaseAPI.class.php | Updated aggregateData() and obj2Resource() signatures to support dynamic includes; moved addToRelatedResources() from AbstractModelAPI; added new processExpands() method to consolidate expansion logic |
| src/inc/apiv2/common/AbstractModelAPI.class.php | Removed duplicate addToRelatedResources() method and refactored to use new processExpands() method |
| src/inc/apiv2/model/tasks.routes.php | Updated aggregateData() signature to match base class changes |
| src/inc/apiv2/model/agents.routes.php | Added aggregateData() implementation to fetch and include active chunk data for agents |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
No description provided.