Name: [IMP] viin_ai_base, viin_ai_agent: bidirectional data-driven message adapter (close #64 #62 #63)

State: Failed finished in 15m

PR State: merged

PR Author: David Tran

PR Author Email:

PR: #65

Committer: David Tran

Committer Email: davidtran.hp@gmail.com

Commit: ac14577744bc3fc698166e57c1f1ffdfa43d0330

Description:

                                            [IMP] viin_ai_base, viin_ai_agent: bidirectional data-driven message adapter (close #64 #62 #63)

Symmetric follow-up to the outgoing adapter (#59): make the INCOMING response
normalizer data-driven via viin.ai.message.adapter, add a per-vendor empty-content
knob, and route the streaming path through the adapter with a contract guard.

- #64: viin.ai.message.adapter gains a `direction` discriminator (outgoing|incoming)
  + incoming response-map knobs; viin.ai.provider._normalize_completion_response is
  rewired to dispatch data-driven incoming primitives (output byte-stable for the 3
  seeded protocols). An admin can hotfix a vendor response-key rename with no release.
- #62: per-vendor `empty_content_repr` knob (empty_string|null|omit), default
  empty_string (byte-identical to prior behaviour) for strict gateways (Azure OpenAI).
- #63: viin_ai_agent._do_llm_stream redacts-then-adapts before transport + a contract
  guard test that fails if a future streaming multi-turn path bypasses the adapter
  (also patches a latent streaming PII-redaction gap).
- ADR-018 (bidirectional data-driven message adapter); docs/roadmap/module-map
  reconcile (32 modules, PR #57/#59/#60 history, ADR ledger, adr-015/016 status sync).

Tests: Odoo native, no-API-key; 74-class net green (normalize/wire byte-stable
non-regression + incoming data-driven proof + #62 matrix + #63 guard + multiturn loop).

Claude-Session: https://claude.ai/code/session_01MpghN1mdjfEzHd1yuSqdut
                                            

Branch: 17.0

Instance ID: 0

Age:

Up-time: