Adapter: record CHAP human-decision events from AG2 (AutoGen) human input#7
Open
BrightbeamBogdanCastraveti wants to merge 1 commit into
Open
Adapter: record CHAP human-decision events from AG2 (AutoGen) human input#7BrightbeamBogdanCastraveti wants to merge 1 commit into
BrightbeamBogdanCastraveti wants to merge 1 commit into
Conversation
Adapter mirroring chap-langgraph: at an AG2 (AutoGen) human-input turn, record the human's decision as a CHAP envelope. approve -> decide.approve override -> decide.override (message vs reply, as a diff) reject -> decide.reject - ag2 is an optional dependency; the message and reply are read structurally, so the bridge and tests run without it. - decision is explicit and authoritative. The only inference is that an empty reply means approve; a non-empty reply with no explicit decision records nothing (exit is not a reject, dialogue is not an edit). - hooked at get_human_input, where both the message (last_message()) and the reply are available. - 0.2.6-correct by construction: approver joined, review.request addressed to that approver. Closes #3.
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.
Closes #3.
Adapter mirroring
chap-langgraph/ the other two: at an AG2 human-input turn, the human's decision is recorded as a CHAP envelope.Design, per your corrections on #3:
decisionis explicit and authoritative. The only inference isempty reply → approve; any non-empty reply with no explicit decision records nothing —"exit"is not a reject, and dialogue is not an edit.intent_preserveddefaultstrueon override, overridable; no-op edit → approve.get_human_input, where both the message (self.last_message()) and the reply are available — not the prompt string. Verifiedlast_message()returns the message under review at that point.ag2is optional; the bridge reads the message/reply structurally, so it and its tests run without it.review.requestaddressed to them.Verified against
main(0.2.6):pytest14 passed; example runs a real AG2 conversation (no LLM) through approve / edit / reject, withexitrecording nothing; conformance harness 23/23.