ultravioletrs / cocos

Cocos AI - Confidential Computing System for AI
https://ultraviolet.rs/cocos.html
Apache License 2.0
25 stars 9 forks source link

COCOS-168 - Allow Computations With No Datasets To Run #175

Closed rodneyosodo closed 4 months ago

rodneyosodo commented 4 months ago

What type of PR is this?

This is a feature because it adds running computation when dataset is empty

What does this do?

The updates enable state-machine transitions from the receivingAlgorithm state to the running state if no dataset is provided.

Which issue(s) does this PR fix/relate to?

Have you included tests for your changes?

Yes, I have included tests for my changes.

Did you document any new/modified feature?

No need for documentation since this is an expected scenario

Notes

sequenceDiagram
    participant User
    participant Agent
    participant StateMachine
    User->>Agent: Provide Algorithm
    Note right of Agent: Checking dataset length
    alt Dataset length is 0
        Agent->>StateMachine: Send algoReceivedNoData event
        StateMachine->>StateMachine: Transition to running state
    else Dataset length > 0
        Agent->>StateMachine: Send algorithmReceived event
        StateMachine->>StateMachine: Transition to receivingAlgorithm state
    end
    StateMachine->>User: Acknowledge state transition