diff --git a/protos/athena/athena.proto b/protos/athena/athena.proto index 04cdb19..b4fdc40 100644 --- a/protos/athena/athena.proto +++ b/protos/athena/athena.proto @@ -5,7 +5,7 @@ package athena.v1; import "athena/athena_struct.proto"; import "candlestick_struct.proto"; -// GetBacktestRequest +// [message] GetBacktestRequest message GetBacktestRequest { // Backtest configurations. Configuration config = 1; @@ -13,7 +13,7 @@ message GetBacktestRequest { repeated Candlestick candlesticks = 2; } -// GetBacktestResponse +// [message] GetBacktestResponse message GetBacktestResponse { // Backtest statistics. Statistics statistics = 1; diff --git a/protos/candlestick_struct.proto b/protos/candlestick_struct.proto index 1f3b1cb..0c31140 100644 --- a/protos/candlestick_struct.proto +++ b/protos/candlestick_struct.proto @@ -1,20 +1,47 @@ syntax = "proto3"; +import "enums_struct.proto"; import "google/protobuf/timestamp.proto"; -// Candlestick -// Represents a single candlestick bar with timestamp and other properties. -message Candlestick { - // Candlestick's Timestamp. - google.protobuf.Timestamp timestamp = 1; +// [message] Ohlcv +// Represents open, high, low, close, and volume. +message Ohlcv { // Candlestick's opening price. - float open = 2; + float open = 1; // Candlestick's high price. - float high = 3; + float high = 2; // Candlestick's low price. - float low = 4; + float low = 3; // Candlestick's closing price. - float close = 5; + float close = 4; // Traded volume. - float volume = 6; + float volume = 5; +} + +// [message] Candlestick +// Represents a single candlestick. +message Candlestick { + // Candlestick's Timestamp. + google.protobuf.Timestamp timestamp = 1; + // Candlestick's open, high, low, close and volume data. + Ohlcv ohlcv = 2; + // Signal + Signal signal = 3; +} + +// [message] Signal +// Represents signal for a single. +message Signal { + // Timestamp for when the signal is generated + google.protobuf.Timestamp timestamp = 1; + // Position: Long or short + Position position = 3; + // Side: Buy or sell + Side side = 4; + // Take-profit price + float take_profit = 6; + // Stop-loss price + float stop_loss = 7; + // Confidence percentage [0-1] + float confidence = 5; }