This application relates to the field of
code generation technology, and discloses a
software code generation method and its apparatus, device, and medium. The method includes: responding to a
code generation driving event and determining the multimodal information corresponding to the event, wherein the multimodal information corresponds to the original
software development requirements; semantically aligning the different
modal information in the multimodal information and fusing them to generate
software function planning information; extracting each function planning unit as a code generation subtask of the corresponding code generation type according to the code generation type corresponding to the function planning unit described in the software function planning information; calling a large
language model to execute each code generation subtask and synchronously triggering the corresponding coding constraint instructions to generate target code. This application, through the
semantic alignment and fusion of multimodal information and the synchronous triggering mechanism of coding constraints in the code
generation process, highly restores the development requirements of the software code and reduces the subsequent security audit costs and
software maintenance risks of the software code.