-
Notifications
You must be signed in to change notification settings - Fork 15
Ehancement: Add names to AgentSetDF
and AgentSetsAccessor
for name/type/index lookup and container-aware keying
#172
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
Draft
adamamer20
wants to merge
90
commits into
main
Choose a base branch
from
146-enhancement-consider-using-a-key-based-structure-for-agentsets-instead-of-list-in-agentsdf
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…ed agent set management
…oved performance and clarity
…roved clarity and performance
…od for AgentSetsAccessor
…ement and enhance rename method for better delegation to AgentsDF.
…messages for key lookups
…ames in ValueError for better debugging
…gent sets as a list for multiple matches and improve error messaging for better clarity.
…ct functionality and error handling
…o 146-enhancement-consider-using-a-key-based-structure-for-agentsets-instead-of-list-in-agentsdf
…ency and clarity in the abstract class naming.
…proved consistency and clarity; enhance error messaging in __getitem__ and rename methods for better readability.
for more information, see https://pre-commit.ci
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #172 +/- ##
==========================================
- Coverage 92.44% 91.17% -1.28%
==========================================
Files 13 15 +2
Lines 1695 1904 +209
==========================================
+ Hits 1567 1736 +169
- Misses 128 168 +40 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
…nt set types, improving performance and clarity in KeyError messages.
…arity in AGENTS.md, agents.py, agentset.py, and test_sets_accessor.py; improve formatting in test cases.
…r-agentsets-instead-of-list-in-agentsdf' of https://github.com/projectmesa/mesa-frames into 146-enhancement-consider-using-a-key-based-structure-for-agentsets-instead-of-list-in-agentsdf
…cessor; update parameter descriptions for improved understanding.
…update conflict resolution and mode descriptions for improved understanding.
…type annotations for parameters.
…cessor and AgentSetsAccessor; update default values and descriptions for parameters.
for more information, see https://pre-commit.ci
…-and-agentsetpolars-to-agentsetdf-for-clarity' of https://github.com/projectmesa/mesa-frames into 146-enhancement-consider-using-a-key-based-structure-for-agentsets-instead-of-list-in-agentsdf
…codebase for consistency and clarity
…-and-agentsetpolars-to-agentsetdf-for-clarity' of https://github.com/projectmesa/mesa-frames into 146-enhancement-consider-using-a-key-based-structure-for-agentsets-instead-of-list-in-agentsdf
…e to MoneyAgentNative for clarity; update MoneyModelDF to MoneyModel and adjust related references.
…egistry instead of AgentsDF
…DF; remove unused abstract properties for cleaner interface.
…Model for consistency across the codebase
…-and-agentsetpolars-to-agentsetdf-for-clarity' of https://github.com/projectmesa/mesa-frames into 146-enhancement-consider-using-a-key-based-structure-for-agentsets-instead-of-list-in-agentsdf
for more information, see https://pre-commit.ci
…r-agentsets-instead-of-list-in-agentsdf' of https://github.com/projectmesa/mesa-frames into 146-enhancement-consider-using-a-key-based-structure-for-agentsets-instead-of-list-in-agentsdf
for more information, see https://pre-commit.ci
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
breaking
Changes that break backwards compatibility or require major updates.
enhancement
Improvements to existing features or performance.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR implements the new
.sets
accessor onAgentsDF
, addressing #146, #124 . The goal is to make agent set management more predictable and user-friendly by exposing a dict-like API for lookup and iteration, while keeping_agentsets
internal. This also sets the stage for #162 (column accessor) and container-level name canonicalization.Notes:
AgentsDF
level for separation of concernsAgentSetsAccessor
is not copied in copy operation but created from scratch to avoid keeping the_parent
reference to the original `AgentsDF