Skip to content

Shadow idea-generation sidecar (first milestone of #43) - #44

Merged
OnePunchMonk merged 1 commit into
mainfrom
feat/idea-sidecar-shadow-43
Oct 7, 2026
Merged

OnePunchMonk merged 1 commit into
mainfrom
feat/idea-sidecar-shadow-43

Conversation

@OnePunchMonk

Copy link
Copy Markdown
Owner

First milestone of #43: a non-learning shadow sidecar. No RL, no new dependency, off by default (AGENTQUANT_IDEA_SIDECAR=1 to enable). The zero-key demo never imports it.

It replays a fixed heuristic policy or a seeded random policy over the canonical momentum grid and logs a versioned observation / action / reward trajectory, including propensities and every rejected candidate.

What is in src/agent/idea_sidecar.py:

  • Typed, versioned schema: Observation, Action, Budget, RewardSpec, RewardComponents (components reported separately, composite is None when the holdout outcome is missing).
  • Observations use dev-window data only, and failure records are kept only if timestamped on or before the episode's dev_end. Unparseable timestamps are dropped.
  • Actions must be a canonical grid point from the step's candidate set, otherwise ActionOutOfSpace. The sidecar never emits code.
  • Winner is picked by dev Sharpe with the same 0.3 gate as the search arms, and the sealed holdout is graded once after the trajectory closes. final_holdout=True goes through FinalHoldoutGuard.
  • Every record carries an evidence tier (fixture, measured_historical, unverified; default unverified), a sidecar hash, and a replay check.

Tests (tests/test_idea_sidecar.py, 10 fixture tests) cover the five items from the issue: no future memory or holdout in observations, actions inside the canonical space, equal budget for random vs heuristic, replay reproducing logged decisions, and no bypass of the quality gate or holdout guard. Full suite passes locally (240).

Not in this PR, on purpose:

  • Any learned policy or offline bandit/RL.
  • The LLM-backed source (enum value is reserved, the candidate builder does not emit it).
  • Wiring into RunManifest / research memo. Records are standalone JSON for now.
  • The matched-budget baseline suite against grid, frozen agent and diagnosis mutation, and the paired uncertainty report.

All results here are fixture-tier on synthetic data. Nothing claims trading performance.

Non-learning sidecar that logs a typed, versioned observation/action/reward schema while replaying a heuristic or seeded random policy. Fixture tests cover chronological visibility, canonical action space, matched budgets, replay, the quality gate and the final-holdout guard.
@OnePunchMonk
OnePunchMonk marked this pull request as ready for review October 7, 2026 18:42
@OnePunchMonk
OnePunchMonk merged commit 1d23310 into main Oct 7, 2026
8 of 11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant