I think that the ability to write a creative piece in response to an unseen stimulus or question and under timed conditions relies heavily on your imagination and your ability to quickly come up with an idea that would be appropriate to implement in writing your short story. This in turn requires substantial practice, which would enable you to improve your imagination and consequently not only be able to have a more diverse set of general and stimulus/question-specific ideas, but also develop patterns that can assist you in thinking of an idea and subsequently adapting it to match the needs of the stimulus or question. You will find that this becomes increasingly relevant in Stage 6, particularly as part of Module C in year 12.
In applying this approach, you may wish to have a look at a number of stimuli and questions, which can be from different sources, such as from books, exam papers or Google. Depending on the type of stimulus that you are required to target (for instance, whether it is in visual or written form), such sources can provide you with a range of examples, allowing you to first try to come up with ideas as if you were to respond to those stimuli (similar to how you are required to write a short story), which supports the notion of expanding your imagination. You can then practise writing creative pieces in response to such stimuli, thereby applying such ideas. You could start by practising under untimed conditions so that you are comfortable as you would still be trying to familiarise yourself with this process, although it would be a good idea to eventually practise under timed conditions, so as to not only mirror the conditions of your short story, but also ensure that you have maximised your ability to quickly think of a good idea(s) to use as the foundation of your short story (and any other creative piece that you may be required to write).
I hope this helps!