Source-linked AI summary
KARMA: Training-Free Knowledge-Atomic Harness Evolution for Industrial Advertising Agents
Xinhua Miao, Yuanzhen Rong, Weiru Zhang, Xiaoyi Zeng
TL;DR
Industrial advertising agents need decision knowledge that keeps pace with changing marketplace conditions, but updating it can entangle changes or broaden validation requirements. KARMA evolves typed external knowledge while keeping model weights and executable harness code fixed. Across the reported settings, it improves average hold-out score, and the paper also reports cross-domain transfer gains.
Problem
Advertising agents’ decision rules can become incomplete or outdated as marketplace conditions change, while updating them risks entangling knowledge changes or broadening what must be validated.
Source: §1 · p. 1Method
KARMA evolves typed external knowledge through evidence-guided atomic edits and validation-gated rollback while keeping model weights and executable harness code fixed.
Source: §1 · p. 2Results
Takeaways & Limitations
KARMA links retained knowledge updates to diagnostic evidence and measured outcomes, supporting inspectable, reversible adaptation with weights and executable harness code fixed.
Source: §7 · p. 9Generalization beyond the sampled cases, period, and platform remains open, and the framework cannot repair faulty tools or orchestration code.
Source: §6 · p. 9
Abstract
from arXiv · showhide
Industrial advertising agents must continually adapt their decision knowledge to changing product offerings, traffic patterns, and operating policies. We present KARMA (Knowledge-Atomic, Regression-Gated Modular Adaptation), a training-free framework that evolves six typed knowledge modules while keeping model weights and executable harness code frozen. During our evolution, a deterministic Trace Verifier maps observed errors to candidate modules, and a Critic compares successful and failed trajectories to guide a tool-constrained Evolver. The Evolver applies atomic knowledge edits, which a fixed validation gate retains only when their measured gain reaches a threshold; otherwise, the previous knowledge state is restored. We evaluate KARMA with three LLM families on cases sampled from a corpus of approximately half a million real-world operation logs across six e-commerce domains. Across 18 domain--model settings, KARMA raises the average hold-out score from 30.19 to 39.15 (+8.96 points, +29.7%). Ablations show that removing either successful or failed trajectories more than halves the average hold-out gain. Evolved knowledge also transfers across domains without further adaptation, yielding an average hold-out gain of 8.54 points across all source--target pairs. By linking retained patches to their diagnostic evidence and validation outcomes, KARMA supports inspectable, reversible knowledge adaptation for agents in Web marketplaces.
1 Introduction
KARMA addresses how advertising agents can update decision knowledge as marketplace rules change, without changing model weights or executable harness code. It uses evidence-guided, atomic knowledge edits and validation-gated retention to make adaptation inspectable and regression-aware.
1 Introduction
- Marketplace advertising agents must choose products, budgets, and bids under changing demand and competition, while their decision rules may become incomplete or outdated.Updating rules can change both the selected control and the direction of intervention.Source: §1 · p. 1
- Fine-tuning is costly, and prompt rewriting or harness-code editing can entangle changes or broaden what must be validated, motivating external knowledge updates with the executable process fixed.The paper asks whether evaluated trajectories can improve this decision knowledge without changing model weights or executable harness code.Source: §1 · p. 1
- Advertising adaptation must distinguish wrong action types from wrong directions, account for rules that may disrupt correct decisions, and separate tool or protocol failures from semantic errors.These considerations motivate structured diagnosis, evidence from both successes and failures, and an outcome-based acceptance gate.Source: §1 · p. 1
- KARMA externalizes knowledge into six typed modules and uses schema-checked, journaled atomic edits while keeping weights, business tools, and executable code fixed.A deterministic verifier maps failures to candidate modules; a Critic compares failures with successful trajectories, and a fixed validation gate retains or rolls back each patch.Source: §1 · p. 2
- Across six domains and three LLM families, KARMA improves average hold-out score by 8.96 points (+29.7%).The reported result covers 18 domain–model settings.Source: §1 · p. 2
2 Related Work
Prior work adapts agents through prompts, memories, workflows, and harnesses, but the cited work leaves open challenges in component-level diagnosis, preserving effective behavior, and reusable knowledge across advertising decisions and product domains.
2.1 Training-Free Agent Adaptation
- Training-free agent adaptation includes feedback-driven prompt optimization and persistent memories or skills, while linking feedback to specific knowledge components and preserving effective behavior remain challenging.The approaches described include iterative prompt revision, reusable experience-based insights, and structured context playbooks.Source: §2.1 · p. 2
2.2 Harness Evolution and Repair
- Harness-evolution methods search or revise modular pipelines, executable designs, workflows, and harness components, but broader code edits expand validation dependencies and accepted changes may generalize unevenly.Other approaches use scoped repairs, component-wise optimization, or gated verification.Source: §2.2 · pp. 2–3
2.3 Commerce and Advertising Agents
- Commerce-agent studies cover grounded shopping, advertising bids, and live-commerce avatars, but reusable knowledge updates across budget, bid, and item decisions remain limited.The cited advertising and avatar approaches use, respectively, bidding strategies with memory and reflection, and changing harness configurations with training-based methods.Source: §2.3 · p. 3
3 Problem Formulation
The formulation treats the agent’s external knowledge as the evolving state while model parameters and reference actions remain outside inference. It defines a type-and-direction score and separates training batches, validation, and untouched hold-out evaluation.
3 Problem Formulation
- The inner agent uses decision context and mutable external knowledge with frozen model parameters, queries read-only business tools, and emits a structured decision.Logged reference actions are excluded from inference inputs and tool observations and are used only for scoring and outer-loop feedback.Source: §3 · p. 3
- The structured output includes an action type and direction, and the strict score measures agreement with the logged reference action on those two dimensions.The metric does not assess item-identifier accuracy, adjustment magnitude, rationale quality, or downstream business utility.Source: §3 · pp. 3–4
- Training batches are processed across evolution cycles, validation measures observed average score for knowledge states, and the untouched hold-out set is never used for diagnosis, mutation, or selection.Final effectiveness is the paired hold-out score gain of evolved knowledge over initial knowledge.Source: §3 · p. 4
4 Method
KARMA separates frozen decision execution from an outer knowledge-evolution loop that diagnoses trajectories, proposes atomic edits, and gates their retention. Its typed knowledge representation and rollback mechanism keep changes inspectable and reversible.
4.1 System Overview
- The outer loop verifies trajectories, proposes and applies atomic knowledge edits, and retains them only after validation, while accepted knowledge serves the next training batch.Diagnosis, editing, and acceptance are assigned to the Trace Verifier, Evolver, and deterministic outer loop, respectively.Source: §4.1 · p. 4
4.2 Frozen Decision Agent
- The frozen agent renders current knowledge into a fixed prompt and response schema, gathers evidence through read-only tools, then emits a structured decision under a bounded protocol.Traces record the knowledge fingerprint, tool observations, decision, termination reason, and protocol errors; advertising actions are not executed.Source: §4.2 · p. 4
4.3 Typed Modular Knowledge
- Knowledge is organized as six typed modules, and mutations target a module or rule; schema checks, journals, and snapshots support auditability and rollback.A cycle allows at most three mutations, evaluated together as one candidate patch.Source: §4.3 · p. 4
4.4 Verification and Full Ingestion
- The verifier separates semantic failures from infrastructure errors, maps failures and protocol codes to candidate modules, and presents clustered failures alongside successes for diagnosis.Successes expose conditions where current knowledge works, helping the Critic consider whether a proposed general rule would also affect correct cases.Source: §4.4 · pp. 4–5
4.5 Critic and Evolver
- The Critic compares verifier reports with trajectories to propose edits, while the Evolver checks proposals against current modules and produces a short patch within a three-mutation budget.The Evolver must avoid sample-specific identifiers and may choose no edit under uncertainty; business tools, shell access, and gate control are prohibited.Source: §4.5 · p. 5
4.6 Validation and Rollback
- A candidate patch is retained only when an eligible cycle’s validation gain reaches θ=0.01; otherwise, the six-module directory is restored to its pre-edit snapshot.The fixed validation set gates changes, while the untouched hold-out set separately assesses whether retained changes generalize.Source: §4.6 · p. 5
5 Experiments
Across six e-commerce domains and three LLM families, the experiments test whether knowledge evolution improves held-out decisions, how evidence channels and proposal engines contribute, and whether evolved knowledge transfers. KARMA improves average hold-out performance, while results vary across domains and transfer sources.
5.2 Main Results
- The average hold-out score rises from 30.19 to 39.15 (+8.96 points, +29.7%), improving 16 of 18 domain–model settings.Improvements span all three model families and multiple domains under a fixed executable harness.Source: Table 3 · p. 6, §5.2 · pp. 6–7
5.1.1 Dataset.
- For each domain, researchers sampled 800 cases from approximately half a million July 2026 operation logs, assigning 480 to training, 160 to validation, and 160 untouched cases to hold-out.Scores and absolute gains are scaled by 100.Source: §5.1.1 · p. 6, §5.1.3 · p. 6
5.4 Evolution Engine Comparison
- KARMA achieves the largest hold-out gain in both tested domains: +15.94 on H and +18.13 on B, at comparable token cost to other engines.The alternatives are GEPA and AHE on H, and AHE is the strongest alternative on B.Source: Table 5 · p. 7, §5.4 · p. 7
5.2 Main Results
- All three model families gain on average, but domain-level improvements vary, and Kimi-K3 regresses on A and E.Five-seed Qwen3.8-Max runs on E remain positive, with gains ranging from +0.94 to +11.25.Source: §5.2 · p. 7
5.3 Evidence Ablations
- Removing either evidence channel more than halves the average hold-out gain: +16.67 for KARMA, +8.23 without successes, and +6.56 without failures.Full ingestion scores highest in every tested domain on both validation and hold-out sets; neither single channel dominates across domains.Source: Table 4 · p. 6, §5.3 · p. 7
5.7 Gate Dynamics
- Retained validation scores rise in steps separated by plateaus, while rejected patches leave the active knowledge and cached score unchanged.Validation and hold-out improvements are broadly consistent but less so on A; the gate does not guarantee hold-out improvement.Source: Figure 4 · p. 8, §5.7 · p. 8
5.5 Cross-Domain Transfer
- Across 30 source–target pairs, transferred knowledge averages +8.54 points, about 71% of the average in-domain gain; 23 pairs are positive.Transfer effectiveness varies by source: all seven negative entries involve A, while excluding A as source or target leaves 20 positive entries averaging +12.73.Source: Table 6 · p. 7, §5.5 · p. 8
5.6 Automotive Anomaly
- On A, operation-level changes differ by model, and sample-level gains and losses can offset one another, leaving little net gain despite altered decisions.Mutation records and rationales show new priorities alongside existing heuristics; stable rule identifiers help inspect potential interactions.Source: Figure 3 · p. 7, §5.6 · p. 8
6 Limitations and Future Work
KARMA is evaluated offline against historical actions, which may encode policy biases and do not establish business outcomes. Its generalization remains bounded by the evaluation design and sampled platform, period, and cases.
6 Limitations and Future Work
- Offline evaluation does not execute actions, and agreement with historical actions does not establish gains in revenue, welfare, or fairness.Future work will consider deployment with business guardrails, monitoring, human oversight, and prospective evaluation.Source: §6 · p. 8
- Direct merchant and campaign identifiers are not released; reporting uses access controls and anonymization.Source: §6 · p. 9
- Repeated selection on a fixed validation set may favor changes that fail to carry over to hold-out or transfer evaluation.Deterministic attribution may also miss complex interactions.Source: §6 · p. 9
- Generalization beyond the sampled cases, period, and platform remains open, and the framework cannot repair faulty tools or orchestration code.Each main configuration is run once; additional seed, threshold, and comparison studies cover selected settings.Source: §6 · p. 9
7 Conclusion
KARMA evolves typed, rule-addressable knowledge while keeping model weights and executable harness code fixed. Across six domains and three model families, it improves average hold-out performance, and the paper also reports gains from cross-domain transfer.
7 Conclusion
- The average hold-out score rises from 30.19 to 39.15 (+29.7%) across six domains and three model families.Ablations support using both success and failure evidence, while cross-domain transfer yields an average gain of 8.54 points.Source: §7 · p. 9
- KARMA combines deterministic verification, success/failure reflection, constrained mutation, and validation-gated rollback.Retained updates are linked to diagnostic evidence and measured outcomes.Source: §7 · p. 9
- The framework supports inspectable, reversible knowledge adaptation while keeping model weights and executable harness code fixed.Source: §7 · p. 9
A.1 Data and Runtime Setup
The appendices specify KARMA’s data and runtime setup, evidence handling, proposal and editing constraints, comparison engines, and gated state management. They document how knowledge edits and their validation outcomes are recorded and controlled.
A.1 Data and Runtime Setup
- Each domain contributes 800 cases, split into 480 training, 160 validation, and 160 untouched hold-out cases.Initial knowledge comes from existing advertising instructions; the setup also specifies inference and evolution turn limits, proposal counts, and read-only business tools.Source: §A.1 · pp. 9–10
A.2 Diagnostic Evidence
- The verifier groups failures by frequency while retaining decision records, and routes semantic errors to candidate modules that protocol codes can supplement.Successful cases are grouped separately, and long traces are compacted so the Critic can compare decisions with execution context.Source: §A.2 · p. 10, Table 7 · p. 10
A.3 Critic and Evolver Guidance
- The Critic proposes evidence-backed reusable changes from four perspectives, while the Evolver inspects modules and may adopt, adapt, or reject proposals.Evolution is bounded by a mutation budget and tool whitelist; the outer loop, not the Evolver, decides whether a patch is retained.Source: §A.3 · p. 10
A.4 Engine Implementations
- GEPA, AHE, and Self-Harness use different proposal and screening procedures under the same knowledge interface and outer gate.Their comparison accounts for engine calls and inference over training and validation cases, with runtime including final hold-out evaluation.Source: §A.4 · p. 10
A.5 Interfaces and Artifacts
- The interface edits all six knowledge modules, while the outer loop controls permissions, mutation limits, snapshots, and restoration.Run artifacts record splits, traces, scores, knowledge states, mutation journals, fingerprints, and gate decisions.Source: §A.5 · p. 10
B Evolution Procedure
- The evolution procedure uses fixed validation records and makes candidates ineligible when they fail the stated eligibility rule or encounter an evolution error.The algorithm uses a validation cache and identifies semantic failures through the verifier.Source: B Evolution Procedure · p. 11
B.1 State Management
- Snapshots enable restoration, validation records support comparisons, and mutation journals preserve edits—including rejected patches—for inspection.Fingerprints identify knowledge-state changes, and the cycle record connects verifier evidence, proposals, actual mutations, and gate outcomes.Source: §B.1 · p. 11
C.1 Data Seed
The sensitivity studies report positive hold-out gains across five data seeds for one setting and mostly retained gains across tested threshold alternatives. The threshold study also reports a reduced gain on L when the threshold is raised.
C.1 Data Seed
- All five Qwen3.8-Max runs on E had positive hold-out gains (+0.94 to +11.25; mean +6.06).Variation combines case-selection and batch-order changes with LLM sampling; seed 42 was toward the upper end.Source: §C.1 · p. 11, Table 9 · p. 11
C.2 Gate Threshold
- Five of six alternative domain–threshold combinations retain the default gains for Qwen3.8-Max on H, B, and L.Raising the threshold reduces the gain on L, but every gain remains positive; the shared default θ=0.01 was not selected using hold-out results.Source: §C.2 · p. 11
D Case Studies
The case studies contrast a retained patch that improves validation and hold-out performance with a rejected patch restored after validation loss. They also show that validation gains need not predict hold-out gains.
Case comparison
- Both the largest accepted gain and largest rejected loss among 108 gated cycles occur at cycle 2 on E.The accepted example groups 50 failures into ten modes; the rejected example finds 56 failures, including 40 wrong action types.Source: D Case Studies · p. 11
Accepted cycle
- 33.13 to 43.44 (+10.31) on hold-out, Qwen3.8-Max’s retained patch also raises validation from 36.88 to 48.75 (+11.88).The Evolver adopts two of six proposals and generalizes them into rules E17–E19; a corrected rationale cites E17/E18.Source: D Case Studies · p. 11
Rejected cycle
- 41.25 to 34.38 (−6.88) on validation, Kimi-K3’s patch is rejected and the previous knowledge state restored.The rejected patch is not evaluated on hold-out, so its hold-out effect is unknown.Source: D Case Studies · p. 11
- Kimi-K3’s accepted patch on A improves validation but regresses on hold-out, illustrating that validation improvement does not guarantee hold-out improvement.The rejected patch on E has no measured hold-out effect.Source: D Case Studies · p. 11
E Discussion
The discussion connects trajectory-informed updates and proposal generation with observed effectiveness, then considers transfer across product domains. It frames KARMA as a way to revise advertising knowledge while keeping executable systems intact, with offline evaluation and target-setting evaluation as boundaries.
E Discussion
- Full ingestion performs best among evaluated evidence variants, proposal engines yield different outcomes under a common acceptance rule, and transfer evaluation tests retained knowledge in other domains.The A results underscore that reuse still requires evaluation in the target setting.Source: E Discussion · p. 11
- On E, Figure 5 contrasts Qwen3.8-Max’s largest accepted validation gain (+11.88) with Kimi-K3’s largest rejected loss (−6.88), with validation measured against the cached baseline.Source: Figure 5 · p. 12
- Evaluation is offline and measures agreement with logged actions; deployment with monitoring and human oversight remains future work.The discussion points to broader limitations and governance considerations in Section 6.Source: E Discussion · p. 12
F Industry Relevance
- KARMA’s industry evaluation uses historical AliExpress merchant logs across six e-commerce domains for budget, bid, and advertised-item decisions.The records ground the task and evaluation in actual marketplace operations.Source: F Industry Relevance · p. 12
- The experiments provide offline evidence of improved action agreement and cross-domain knowledge reuse while leaving model retraining and executable-code changes out of the update process.Traceable edits, validation, and rollback support inspection and controlled updates.Source: F Industry Relevance · p. 12