[Hackathon] chainaim-sathya: feasible-frontier audit + generic-N multi-attribute negotiation with a heuristic/Bayesian opponent-model seam (price + deadline + quantity-3 axis active)#47
Open
chainaim-sathya wants to merge 1 commit into
Conversation
…) + feasible-frontier audit + heuristic/Bayesian opponent-model seam
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
[Hackathon] chainaim-sathya: feasible-frontier audit + generic-N multi-attribute negotiation with a heuristic/Bayesian opponent-model seam (price + deadline + quantity)
Short summary
Problem #7 — multi-attribute negotiation. A plugin that bargains over several attributes and converges on Pareto-efficient deals, plus an adversarial validator that catches inefficiency a price-only check structurally misses.
What this does. Adds a multi-attribute negotiation plugin at
("negotiation", "chainaim_neg_multi_pareto")that bargains over an ordered attribute list (price + deadline, extended to price + deadline + quantity ), inferring the opponent's weights from observed offers only behind a swappable heuristic/Bayesian seam. Adds a feasible-frontier validator that reconstructs the outcome space from disclosed profiles and flags dominated settlements. Backward-compatible — ships alongsidealternating_offers(untouched).Registration / key surface
("negotiation","chainaim_neg_multi_pareto")plugins.py_BUILTINSandpyproject.tomlentry pointopen()/offer()/respond()/close()opponent_model="heuristic" | "bayesian"attributes=(...)Negotiation validators
validate_negotiation_pareto— exchanged-offers Pareto check (spec-literal gate, unchanged).validate_negotiation_frontier— feasible-frontier reconstruction; flags a settlement when a feasible point dominates it. The mandated adversarial check: FAILs the price-only baseline, PASSes the multi-attribute plugin.validate_negotiation_disclosure+validate_negotiation_individual_rationality— defense-in-depth.Files (negotiation layer only)
packages/nest-plugins-reference/nest_plugins_reference/negotiation/chainaim_neg_multi_pareto.py— the plugin (~1,217 lines; heuristic + Bayesian opponent models, generic-N decision)packages/nest-core/nest_core/validators.py— the negotiation validators (frontier reconstruction + helpers)packages/nest-core/nest_core/plugins.py—_BUILTINSregistry entrypackages/nest-plugins-reference/pyproject.toml—nest.plugins.negotiationentry pointpackages/nest-core/tests/—test_negotiation_golden.py,test_negotiation_price_deadline_quantity.py,test_negotiation_asymmetric.py,test_negotiation_direction.py,test_negotiation_ir.py,test_negotiation_metrics.py,test_negotiation_nattr.py,test_negotiation_nattr_equivalence.py,test_negotiation_ab_property.py, plus negotiation cases intest_validators.pypackages/nest-plugins-reference/tests/—test_negotiation_opponent_model.py,test_negotiation_strategy_seam.py, plus the plugin case intest_plugins.pyscenarios/—chainaim_multi_attribute_market.yaml,multi_attribute_baseline.yaml,multi_attribute_asymmetric.yaml,multi_attribute_market_3attr_price_deadline_quantity.yaml,…_bayes.yamlCI. All green:
uv sync·ruff check·ruff format --check·pyright·pytest(833 passed, 2 skipped).Verify
The agent — a configurable, attribute-generic negotiation plugin that bargains over an ordered attribute list (here price + deadline + quantity) but configurable for n-attr , price + deadline + quantity, price + deadline + quality , and further extension of attributes, inferring the opponent's per-attribute weights from observed offers only (never the disclosed profile), behind two clean construction-time seams., with hueristic and bayesian modes.
Adds a Non-obvious variant from peers:
The feasible-frontier validator enforces an invariant the rig didn't have: it catches a Pareto-dominated multi-attribute settlement that an observed-bids check structurally cannot (the price-only antichain).
The Heuristic-vs-Bayesian A/B: on the 3-attribute market the heuristic leaves 4 deals inside the frontier, Bayesian only 2 — a benchmark that surfaces a measurable efficiency property that would otherwise stay hidden.
Fully compliant with hackathon rules, configurable and extensible to n attributes ( 3 axis active bargaining in reference implementation )
Detailed and Visual Explanation