That's determined in your Relationship settings when you create it, you can set aliases for parent and child.
However, I admit its not the smartest move, as you have no control over what happens if MORE than one post is there.
Let's debug your custom code then.
https://toolset.com/forums/topic/how-to-test-for-related-posts-to-post-of-current-view/#post-1521975
Please add a few lines of this to your code error_log(print_r($checked_data, true));
Insert this anywhere in the code you think there could be an issue and important data is getting asked by the program.
So, I'd start with global $post;
Just below that line - you insert error_log(print_r($post;, true));
We are telling the program to log to the error log of your system the variable $post.
You need to activate wp debug and error logging for this https://codex.wordpress.org/WP_DEBUG
Then load the page where that ShortCode is used on, or view, or CT. Important is that in some way or another this shortcode is executed on the place you later want it to work.
Then check your debug log file in the sytem and see what is output for $post
It should be a lot of data, including ID, postname etc
Or, it could be just empty. Then, it means you have no data in the $post global.
Similarly, you can proceed on each line of the code if the previous line is OK.
So let's assume you receive indeed the post object in the global $post as expected, you could check $relationship = toolset_get_relationship( $atts['relationship'] ); by adding just below that line the debug statement:
error_log(print_r($relationship, true));
Again, if everything is as expected move to the next line, etc.
You will find at some point either unexpected or empty data.
My tip is on the global $post
You might have more success by populating a posts object with $post = get_post();, if global post is an issue.
Please let me know if you can proceed with this, I am happy to give more advice on how to debug this together!