
```mermaid
sequenceDiagram
participant Client
participant MyService
participant PriceData
Client->>MyService: Send HTTP Request (platform, price)
MyService->>PriceData: Update Price(platform, price)
PriceData-->>MyService: Price Updated

MyService->>MyService: Adjust Decimal Points
MyService->>MyService: Check Deviation Compensation
alt Time Since Last Compensation > Interval
MyService->>MyService: Calculate Average Prices
MyService->>PriceData: Update Deviation Compensation
end

MyService->>MyService: Calculate Deviation Percentage
MyService->>MyService: Determine Position
alt Open Long
MyService->>PriceData: Open Long Position
else Close Long
MyService->>PriceData: Close Long Position
end
alt Open Short
MyService->>PriceData: Open Short Position
else Close Short
MyService->>PriceData: Close Short Position
end

MyService-->>Client: Response (Processed)

```
