Skip to content

[strategy]: Opening Range Breakout (trend/) #19

Description

@AetherAI3

Desired behavior

A session-anchored breakout: the host measures the high and low of a defined opening range — the first N minutes of the session — and the rule proposes a long when price breaks and holds above that range.

The library has trend/donchian_breakout, which breaks a rolling N-period channel. An opening range is a different object: it is anchored to a session boundary the host defines, it stops growing once the range window closes, and it is the same level for every participant that day. The NOT donchian_breakout: line in your header should say exactly that.

Expected inputs

Two host-provided series, both following the library's scale-free convention so the thresholds travel:

  • ORB_POS(close - range_low) / (range_high - range_low) against the session's opening range. At or above 1 means a break above the range high. Same shape as the existing DONCHIAN_POS.
  • something that distinguishes a break from a drift into the level — participation behind the move is the usual answer, and VOL_RATIO(20) already exists for that.

Baseline IR cannot carry a negative literal, so keep every series nonnegative.

What Nano is responsible for

Evaluating the thresholds and emitting the intent. Nothing else.

What remains host responsibility

All of the interesting parts, and your header should say so: where the session starts, how long the opening range window is, what happens on a holiday or a half day, and what "the session" means for a 24-hour instrument. This rule is meaningless without a session boundary, and Nano has no concept of one — it cannot read a clock.

Expected result

A buy intent with an asset and a confidence, on a schedule fast enough to catch the break but not faster than the host publishes the range.

Expected tests

None required. tests/test_library.py discovers the pair automatically and verifies compilation, IR agreement, and deterministic replay.

Boundary

No live execution, no network, no clock. The host supplies every number; Nano proposes and the host's DecisionGate disposes.

How to submit

Follow docs/first-contribution.md. The five-field comment header is required, the ORB_POS definition goes in your header since it is a new signal, and python scripts/check_contribution.py --write nano/library/trend/opening_range_breakout.nano generates the IR fixture and checks the whole entry.

If you are translating a publicly described version of this idea, add a SOURCE: line. Do not transcribe proprietary code.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions