Method for software function decomposition and effort estimation based on large language model
Patent Information
- Application Number
- CN202611090982.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-07-22
- Publication Date
- 2026-10-09
AI Technical Summary
然而,现有技术存在一定程度的缺陷,在功能分解层面,现有方法高度依赖人工分析师的经验判断,分解结果的粒度和一致性因人而异,且需求文档与代码文件的分析相互分离,难以形成统一的功能视图;大语言模型虽然能辅助功能识别,但在处理敏感项目资产时,将明文需求文档和代码直接传输至模型存在严重的数据泄漏风险,现有保护手段均为静态被动防护,数据存储结构固定,一旦访问控制被突破或密钥泄露,存储的数据即完全暴露,不具备攻击发生时的主动响应能力和攻击消退后的自恢复能力,在工作量估算层面,传统计划评审技术仅考虑任务间的依赖关系,假设资源无限可用,忽略了软件开发中普遍存在的资源竞争与任务等待现象,导致估算结果系统性偏乐观;
1、本发明通过构建活性聚合体将需求文档与代码文件分割为微数据载荷并分散存储于多个可信聚合体中,利用可熔断链路连接可信基座核与微核存储点,形成结构化的安全存储架构;当非法访问发生时,访问检测点判定访问路径不匹配有效访问路径,触发可熔断链路自主熔断,物理层面断开数据访问通道,同时可信基座核对已熔断链路的逻辑地址进行伪修改,将原始逻辑地址替换为虚假逻辑地址,使攻击者即使获取到地址信息也无法触达真实微核存储点;基于该机制,攻击者在攻击过程中不仅无法获取完整数据,连数据的存储位置信息都被虚假地址覆盖,有效提升代码数据的安全性;
Smart Images

Figure CN122885875A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of software workload estimation technology, specifically to a method for software function decomposition and workload estimation based on a large language model. Background Technology
[0002] Existing software workload estimation methods mainly include function point analysis, the COCOMO model, and program review and approval techniques. Function point analysis derives workload by calculating the number of function points and combining historical data. Program review and approval techniques perform three-point estimation and critical path calculation based on task dependencies. However, existing technologies have certain shortcomings. At the functional decomposition level, current methods rely heavily on the experience and judgment of human analysts, and the granularity and consistency of the decomposition results vary from person to person. Furthermore, the analysis of requirement documents and code files is separate, making it difficult to form a unified functional view. Although large language models can assist in functional identification, when dealing with sensitive project assets, directly transmitting plaintext requirement documents and code to the model poses a serious risk of data leakage. Existing protection measures are all static and passive, with fixed data storage structures. Once access control is breached or keys are leaked, the stored data is completely exposed, lacking the ability to proactively respond to attacks and the ability to self-recover after attacks subside. At the workload estimation level, traditional project review techniques only consider the dependencies between tasks, assuming unlimited resource availability and ignoring the resource competition and task waiting phenomena that are common in software development, leading to systematically optimistic estimation results. Therefore, it is of great significance to develop a software function decomposition and workload estimation method based on a large language model. Summary of the Invention
[0003] The purpose of this invention is to provide a method for software function decomposition and workload estimation based on a large language model, so as to solve the problems in the background technology.
[0004] To achieve the above objectives, this invention provides the following technical solution: a software function decomposition and workload estimation method based on a large language model, comprising: Build an active aggregate on a local trusted computing node; Obtain the software requirements document and code files, and segment the requirements document and code files into micro data payloads based on the active aggregate; In response to a normal access request, the large language model acquires the micro data payload, performs functional decomposition on the micro data payload, and outputs the functional granular network. The functional granular network is input into the virtual resource scheduling engine, and the workload estimation results are generated based on the virtual resource scheduling engine.
[0005] In a preferred embodiment, the step of constructing the active aggregate on the local trusted computing node is as follows: Build a mapping space on the local trusted node; Multiple trusted aggregates are constructed in the mapping space. Each trusted aggregate consists of a trusted base core, a fuselable link, and a micro-core storage point. For a single trusted aggregate, multiple micro-core storage points and trusted base cores are connected via fusible links; The trusted base core sets up access detection points and a link logical address mapping table. The access detection points are used to detect whether the access path is compliant, and the link logical address mapping table is used to record the correspondence between the logical address of each fusible link and the microcore storage point.
[0006] In a preferred embodiment, the step of segmenting the requirements document and code file into micro-data payloads based on the active polymer is as follows: Obtain the required files and code files from the local storage space and transfer them to the mapped space; Based on a preset data volume, the requirement file and code file are divided into multiple raw data stream fragments; The mapping space adds an integrity check label and a payload sequence number to each original data stream segment to generate a micro data payload. Extract the payload vector for each micro-payload data. The payload vector is a locally sensitive hash value generated based on the content of the micro-payload data. Calculate the similarity of local sensitive hash values among the micro-load data, and adopt a distributed allocation strategy to distribute the micro-load data with high similarity to different load clusters; The number of payload clusters and the number of trusted aggregates are the same; The payload clusters are assigned to trusted aggregates to generate valid allocation paths, and valid access paths are generated based on the valid allocation paths.
[0007] In a preferred embodiment, the step of generating a valid access path based on a valid allocation path is as follows: Each micro-payload data in the payload cluster is allocated and stored in the micro-core storage point based on the fusible link. The micro-data payload interacts with the trusted base core through the fusible link. For a trusted aggregate that has completed its allocation, the trusted base core generates a load distribution mapping table based on the allocation order. The load distribution mapping table includes microcore storage point identifiers, load allocation paths, and fuselable link identifiers. The effective allocation path and load distribution mapping table are combined to generate an effective access path.
[0008] In a preferred embodiment, the steps of responding to a normal access request, the large language model acquiring the micro data payload, performing functional decomposition on the micro data payload, and outputting the functional granular network are as follows: The large language model accesses the mapping space based on the effective access path, obtains micro-load data in sequence according to the effective access path, and concatenates them into requirement files and code files; Based on a large language model, semantic analysis is performed on requirement files and code files to identify functional boundaries and generate a functional granular network. The functional granule network consists of multiple functional granules and the dependencies between them, and defines a complexity label and a resource consumption label for each functional granule. For unauthorized access via invalid access paths, a data circuit breaker operation is performed to reject the unauthorized access.
[0009] In a preferred embodiment, the step of performing a data circuit breaker operation to reject illegal access for invalid access paths is as follows: The trusted aggregate detects received access requests based on the access detection points of the trusted base core. If the access request does not match a valid access path, it is determined to be an illegal access. When an unauthorized access is received, the trusted base core sends a circuit breaker request to the circuit breakerable link; The circuit-breakable link receives a circuit-break request, performs autonomous circuit breaking, and disconnects from the trusted base core. At the same time, the trusted base core modifies the logical address of each fusible link and generates a pseudo link logical address mapping table; When an illegal access is detected and the access ends, the active polymer is reconstructed based on the recovery mechanism.
[0010] In a preferred embodiment, the step of reconstructing the active polymer based on the recovery mechanism when the access detection point detects an illegal access and the access ends is as follows: The access detection point continuously monitors access requests. When no new illegal access is detected within a preset time window, the illegal access is considered to have ended. The access detection point sends a recovery trigger signal to the trusted base core, and the trusted base core executes the recovery mechanism. The trusted base core calls the load distribution mapping table and the pseudo link logical address mapping table, and resets the contents of the pseudo link logical address mapping table to the link logical address mapping table based on the load distribution mapping table. Based on the call payload distribution mapping table and the reset link logical address mapping table, the connection between the micro-payload data and the trusted base core is re-established, and the reconstruction of the active aggregate is completed.
[0011] In a preferred embodiment, the step of inputting the functional granular network into the virtual resource scheduling engine and generating a workload estimation result based on the virtual resource scheduling engine is as follows: A virtual resource scheduling engine is built for functional granularity parsing, directed acyclic graph construction, resource pooling, and Monte Carlo simulation. Based on the complexity label and resource consumption label of the functional granule, the optimistic estimate, most likely estimate and pessimistic estimate of each functional granule are defined to generate three-point estimation parameters. Constructing a directed acyclic graph based on the dependency relationships of functional granular networks; Resource pools are used to define resource types and the maximum amount of available data for each resource type; The virtual resource scheduling engine performs Monte Carlo simulation of the integrated resource pool. In each round of simulation, it randomly samples an execution time value for each functional particle based on the three-point estimation parameters of each functional particle. When performing simulation based on a directed acyclic graph, the activation of a functional particle requires that all predecessor dependencies be completed and that there is sufficient available data for the required resources. If the available data is insufficient, the functional particle enters a waiting state until the available data is released. The total project duration distribution of multiple rounds of Monte Carlo simulation is statistically analyzed, the project duration confidence interval under a preset confidence level is extracted, and the functional granular waiting time statistics are output to generate workload estimation results. The workload estimation results include the total expected duration, duration confidence level, and the percentage of waiting time for each resource type.
[0012] The technical effects and advantages provided by the present invention in the above technical solution are as follows: 1. This invention constructs active aggregates to segment requirement documents and code files into micro-data payloads and distribute them across multiple trusted aggregates. A fuselable link connects the trusted base core and the micro-core storage points, forming a structured secure storage architecture. When unauthorized access occurs, the access detection point determines that the access path does not match a valid access path, triggering the fuselable link to automatically fuse, physically disconnecting the data access channel. Simultaneously, the trusted base core performs pseudo-modification on the logical address of the fused link, replacing the original logical address with a fake logical address. This prevents attackers from accessing the real micro-core storage point even if they obtain the address information. Based on this mechanism, attackers not only cannot obtain complete data during an attack, but even the data's storage location information is overwritten by the fake address, effectively improving the security of code data. 2. This invention integrates a Monte Carlo simulation method with resource pool constraints through a virtual resource scheduling engine. Based on the directed acyclic graph of functional granules, it introduces constraints on resource type and available quantity limits. This ensures that the activation of a functional granule depends not only on the completion of its predecessor but also on the availability of the required resource type. It improves upon the shortcomings of traditional program review and approval techniques, which only consider dependencies and ignore resource contention waiting. In each round of Monte Carlo simulation, the system randomly samples execution time values from the three estimated parameters of each functional granule, simulating the complete lifecycle of resource application, occupation, waiting, and release during execution. Based on this mechanism, the workload estimation results include both the waiting costs caused by resource contention and quantify the uncertainty range of the project duration. Compared to traditional methods, it more realistically reflects the project duration inflation effect caused by resource bottlenecks in software development, providing more reliable data support for project planning. Attached Figure Description
[0013] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments recorded in this invention. For those skilled in the art, other drawings can be obtained based on these drawings.
[0014] Figure 1 This is a flowchart of the method of the present invention. Detailed Implementation
[0015] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0016] Example 1, please refer to Figure 1 As shown in this embodiment, the software function decomposition and workload estimation method based on a large language model includes: S1. Construct an active aggregate on a local trusted computing node; S2. Obtain the software requirements document and code files, and segment the requirements document and code files into micro data payloads based on the active aggregate; S3. In response to a normal access request, the large language model obtains the micro data payload, performs functional decomposition on the micro data payload, and outputs the functional granular network. S4. Input the functional granular network into the virtual resource scheduling engine, and generate workload estimation results based on the virtual resource scheduling engine. As described in steps S1-S4 above, existing software workload estimation methods mainly include function point analysis, COCOMO model, and program review and approval techniques. Function point analysis derives workload by calculating the number of function points and combining historical data. Program review and approval techniques perform three-point estimation and critical path calculation based on task dependencies. However, existing technologies have certain shortcomings. At the functional decomposition level, current methods rely heavily on the experience and judgment of human analysts, and the granularity and consistency of the decomposition results vary from person to person. Furthermore, the analysis of requirement documents and code files is separate, making it difficult to form a unified functional view. Although large language models can assist in functional identification, when dealing with sensitive project assets, directly transmitting plaintext requirement documents and code to the model poses a serious risk of data leakage. Existing protection measures are all static and passive, with fixed data storage structures. Once access control is breached or keys are leaked, the stored data is completely exposed, lacking the ability to proactively respond to attacks and the ability to self-recover after attacks subside. At the workload estimation level, traditional project review techniques only consider the dependencies between tasks, assuming unlimited resource availability and ignoring the resource competition and task waiting phenomena that are common in software development, leading to systematically optimistic estimation results. This invention constructs active aggregates to segment requirement documents and code files into micro-data payloads and distribute them across multiple trusted aggregates. A fuselable link connects the trusted base core and the micro-core storage points, forming a structured secure storage architecture. When unauthorized access occurs, the access detection point determines that the access path does not match a valid access path, triggering the fuselable link to automatically break, physically disconnecting the data access channel. Simultaneously, the trusted base core performs a pseudo-modification on the logical address of the broken link, replacing the original logical address with a fake logical address. This prevents attackers from accessing the real micro-core storage point even if they obtain the address information. Based on this mechanism, attackers not only cannot obtain complete data during an attack, but even the data's storage location information is overwritten by the fake address, effectively improving the security of code data. The Monte Carlo simulation method, which integrates resource pool constraints through a virtual resource scheduling engine, introduces constraints on resource type and available quantity limits based on the directed acyclic graph of functional granules. This ensures that the initiation of a functional granule depends not only on the completion of its predecessor functional granule but also on the availability of the required resource type. It improves upon the shortcomings of traditional program review and approval techniques, which only consider dependencies and ignore resource contention and waiting. In each round of Monte Carlo simulation, the system randomly samples execution time values from three estimated parameters of each functional granule, simulating the complete lifecycle of resource request, occupation, waiting, and release during execution. Based on this mechanism, the workload estimation results include both the waiting costs caused by resource contention and quantify the uncertainty range of the project duration. Compared to traditional methods, it more realistically reflects the project duration inflation effect caused by resource bottlenecks in software development, providing more reliable data support for project planning.
[0017] In one embodiment, step S1 of constructing the active aggregate on the local trusted computing node includes: S11. Construct a mapping space on the local trusted node; S12. Construct multiple trusted aggregates in the mapping space. Each trusted aggregate consists of a trusted base core, a fuselable link, and a micro-core storage point. S13. For a single trusted aggregate, multiple micro-core storage points and trusted base cores are connected through a fuselable link. S14. Access detection points and link logical address mapping tables are set in the trusted base core. Access detection points are used to detect whether the access path is compliant. Link logical address mapping tables are used to record the correspondence between the logical address of each fuselable link and the microcore storage point. As described in steps S11-S14 above, a logically isolated storage area is deployed as a mapping space in the local trusted execution environment. Multiple trusted aggregates are created within this mapping space. Each trusted aggregate is assigned a unique aggregate identifier and instantiates a trusted base core, a set of tamper-proof links, and a set of micro-core storage points. The trusted base core is the control center of the trusted aggregate, running as a secure process within the trusted execution environment. It is responsible for managing the aggregate's metadata, determining access policies, and maintaining link status. Tamper-proof links are logical communication channels established between the trusted base core and the micro-core storage points. Each tamper-proof link is assigned a link identifier upon establishment and maintains a connection status flag at both ends, with the flag value being either connected or disconnected. Micro-core storage points are independent encrypted storage directories created in the file system for storing micro-data payloads. For a single trusted aggregate, each micro-core storage point within the aggregate is connected to the trusted base core via a dedicated tamper-proof link, forming a star topology. Retrieval of all micro-data payloads is completed based on the tamper-proof links. The broken link allows bidirectional data transmission in the connected state, but physically blocks the data path in the broken state. The trusted base core internally sets up access detection points and a link logical address mapping table. The access detection point is implemented as a lightweight request filtering module, which internally maintains a compliant access path verification benchmark. This benchmark is a valid access path generated after the micro-data payload is allocated. When an external access request arrives at the trusted base core, the access detection point extracts the access path from the request and compares it item by item with the compliant access path verification benchmark. If the access path is completely consistent with the benchmark, it is deemed compliant and allowed; otherwise, any inconsistency is deemed illegal access and an alarm is triggered. The link logical address mapping table is implemented as a key-value pair data structure in memory. The key is the identifier of the bridging link, and the value is the correspondence between the logical address currently used by the bridging link and the target micro-core storage point. The link logical address mapping table is written with an initial mapping when the bridging link is established and is updated synchronously when the link logical address changes, ensuring that the trusted base core can always accurately address the corresponding micro-core storage point through the logical address.
[0018] In one embodiment, step S2, which segments the requirements document and code file into micro-data payloads based on the active polymer, includes: S21. Obtain the required files and code files from the local storage space and transfer them to the mapped space; S22. Divide the requirement file and code file into multiple raw data stream segments based on a preset data size; S23. The mapping space adds an integrity check label and a payload number to each original data stream segment to generate a micro data payload. S24. Extract the payload vector for each micro-payload data. The payload vector is a locally sensitive hash value generated based on the content of the micro-payload data. S25. Calculate the similarity of local sensitive hash values among the micro-load data, and use a distributed allocation strategy to distribute the micro-load data with high similarity to different load clusters; S26. The number of payload clusters and the number of trusted aggregates are the same. S27. Assign payload clusters to trusted aggregates, generate valid assignment paths, and generate valid access paths based on the valid assignment paths. As described in steps S21-S27 above, the trusted base core reads the requirement file and code file stored on the local trusted computing node through the local storage interface, and transmits the requirement file and code file completely to the mapping space in the form of binary data streams. The mapping space allocates a temporary buffer in memory to temporarily store all the data of the requirement file and code file. The mapping space divides the data stream of the requirement file and code file into equal-length segments using a preset data size as the unit of division. During the division process, the semantics of the file content are not recognized, and the data is only extracted in a fixed byte order to obtain multiple original data stream segments. Each original data stream segment is a continuous binary data block. If the last original data stream segment is less than the preset size, the actual length is maintained. The mapping space calculates an integrity check label for each original data stream segment. This label is generated using a hash function on all bytes of the original data stream segment and is used to verify whether the segment has been tampered with. Simultaneously, the mapping space assigns an incrementing payload number to each original data stream segment according to their segmentation order. The integrity check label and payload number are then appended to the original data stream segment to form a micro-data payload. The micro-data payload consists of a payload number, an integrity check label, and the original data stream segment itself. The mapping space extracts a payload vector for each micro-data payload by inputting the original data stream segment content of the micro-data payload into a locality-sensitive hash function (LSH). A fixed-length hash value is output as the payload vector for the micro-data payload. Locality-sensitive hash functions (LSH) have the property that similar content results in similar hash values, while different content results in different hash values. This allows the payload vector to characterize the features of the micro-data payload content without revealing its specific content. The mapping space calculates the similarity between the payload vectors of any two micro-data payloads, using vector distance as a metric. Closer vector distances indicate higher content similarity, while greater distances indicate greater content differences. The mapping space employs a distributed allocation strategy, assigning highly similar micro-data payloads to different payload clusters. The execution logic of this distributed allocation strategy involves traversing all micro-data payloads and, for the currently unassigned micro-data payload, calculating its... The similarity between the payload and the representative vector of each existing payload cluster is used to select the payload cluster with the lowest similarity as the allocation target, so as to maximize the content difference of each micro data payload within the same payload cluster. The number of payload clusters is preset to be the same as the number of trusted aggregates in the mapping space. Each payload cluster ultimately contains a group of micro data payloads with large content differences and scattered payload numbers. The mapping space allocates each payload cluster to a corresponding trusted aggregate. After the allocation is completed, the mapping space records the correspondence between each payload cluster and the trusted aggregate identifier, and generates an effective allocation path according to the payload number order of the micro data payloads in the payload cluster. The effective allocation path defines a complete access link starting from the trusted base core and accessing each micro core storage point in sequence through the fusible link.The mapping space generates valid access paths based on valid allocation paths. These valid access paths serve as the sole compliant route for legitimate users and large language models to access micro data payloads.
[0019] In one embodiment, step S27, which generates a valid access path based on a valid allocation path, includes: S271. Allocate and store each micro-payload data in the payload cluster to the micro-core storage point based on the fusible link. The micro-data payload interacts with the trusted base core through the fusible link. S272. For a trusted aggregate that has completed allocation, the trusted base core generates a load distribution mapping table based on the allocation order. The load distribution mapping table includes microcore storage point identifiers, load allocation paths, and fuselable link identifiers. S273. Combine the effective allocation path and the load distribution mapping table to generate an effective access path; As described in steps S271-S273 above, the mapping space allocates the micro-data payloads within each payload cluster to the corresponding micro-core storage points of the trusted aggregate. The allocation process involves the mapping space issuing allocation instructions to the trusted base core. Upon receiving the allocation instructions, the trusted base core establishes a dedicated fusible link for each micro-data payload within the payload cluster. One end of the fusible link is bound to the trusted base core, and the other end is bound to a micro-core storage point. Each fusible link generates a unique fusible link identifier upon establishment, and this identifier is written into the link logical address mapping table of the trusted base core. The micro-core storage point then receives the data... Micro-data payloads are written to their own encrypted storage directory. Within the microcore storage point, micro-data payloads are stored using their payload sequence number as an index key. After storage, the microcore storage point returns a storage confirmation signal to the trusted base core. This confirmation signal includes the microcore storage point identifier and the payload sequence number of the stored micro-data payload. Data interaction between the micro-data payload and the trusted base core is accomplished through a fusible link. When connected, the fusible link allows the trusted base core to initiate read requests to the microcore storage point. The microcore storage point returns the corresponding micro-data payload based on the payload sequence number in the read request. When all micro-data payloads within the payload cluster corresponding to this trusted aggregate are distributed... After the storage is merged, the trusted base core generates a load distribution mapping table based on the allocation order of the micro-data payloads during the allocation process. The load distribution mapping table is a data table recording the distribution information of the micro-data payloads. Each row of the load distribution mapping table records the distribution information of a micro-data payload, including the payload sequence number, the micro-core storage point identifier corresponding to the micro-data payload, the payload allocation path of the micro-data payload, and the corresponding fusible link identifier. The payload allocation path records the complete route of the micro-data payload from the mapping space through the trusted base core and the fusible link to finally reach the micro-core storage point. The mapping space is present in all trusted aggregates. After generating the payload distribution mapping table, the effective allocation path of each trusted aggregate is combined with the payload distribution mapping table of the corresponding trusted aggregate. The combination method is to concatenate the access order of trusted aggregates defined in the effective allocation path with the micro data payload distribution information recorded in the payload distribution mapping table to form an effective access path. The effective access path is a complete access route, which includes the hierarchical path information from the mapping space entrance through the trusted base core, the fuselable link, and the micro core storage point of each trusted aggregate. The large language model or legitimate user can traverse all micro data payloads in sequence and complete the concatenation and restoration based on the effective access path.
[0020] In one embodiment, step S3, which involves the large language model acquiring the micro data payload in response to a normal access request, performing functional decomposition on the micro data payload, and outputting the functional granular network, includes: S31. The large language model accesses the mapping space based on the effective access path, obtains micro-load data in sequence according to the effective access path, and splices them into requirement files and code files. S32. Based on the large language model, perform semantic analysis on the requirements file and code file and identify functional boundaries to generate a functional granular network. S33. The functional granule network includes multiple functional granules and the dependencies between functional granules, and defines a complexity label and a resource consumption label for each functional granule. S34. For illegal access via invalid access paths, execute a data circuit breaker operation to reject the illegal access; As described in steps S31-S34 above, when a legitimate user or system initiates a normal access request, the large language model obtains the generated valid access path. Based on the access order defined by the valid access path, it sequentially sends micro-data payload read requests to the trusted base cores of each trusted aggregate. The access detection point of the trusted base core compares the access path in the read request with the compliance access path verification benchmark. After the comparison is successful, the trusted base core forwards the read request to the corresponding micro-core storage point through a fusible link. The micro-core storage point retrieves the corresponding micro-data payload from the encrypted storage directory according to the payload sequence number carried in the read request, and transmits it to the large language model through the fusible link and the trusted base core. The large language model then processes the data according to the valid access path. After traversing all microkernel storage points and acquiring all microdata payloads one by one, the payloads are sequentially concatenated according to their payload numbers. The concatenated payloads are then restored to obtain the complete requirements and code files. Semantic analysis is performed on the concatenated requirements and code files. This process includes natural language understanding of the requirements file to extract the functional intent, user operation scenarios, and business rules described within it. Simultaneously, static structure parsing is performed on the code file to identify function definitions, class structures, interface declarations, and call relationships. The functional intents extracted from the requirements file are semantically aligned with the program structure identified in the code file, establishing a correspondence between the requirement description and code implementation. Based on the semantic alignment results... The functional boundaries are identified, and the requirement file and code file are divided into multiple functional units. Each functional unit corresponds to a functional description in the requirement file and a set of code snippets in the code file that implement that functional description. Further analysis is conducted on the calling relationships and data transfer relationships between these functional units. Calling relationships include the call chain between functions and the dependency chain between interfaces in the code file. Data transfer relationships include the flow order of the business process defined in the requirement file across the functional units. Based on these calling and data transfer relationships, the dependencies between functional units are determined. Dependencies are categorized as strong or weak. A strong dependency means that the execution of one functional unit depends on the completion of another functional unit, while a weak dependency means that there is a data dependency between the two functional units. The execution order can be adjusted, and all functional particles and dependencies are combined to generate a functional particle network. During the generation of the functional particle network, a complexity label is defined for each functional particle. The complexity label is comprehensively evaluated based on the cyclomatic complexity of the corresponding code snippet, the number of lines of code, and the number of business logic branches in the requirement description. The complexity label value is high complexity, medium complexity, or low complexity. At the same time, a resource consumption label is defined for each functional particle. The resource consumption label is determined based on the technology stack type and development type involved in the functional particle. The resource consumption label indicates one or more resource types required by the functional particle. Resource types include backend development resources, frontend development resources, database development resources, testing resources, and security review resources.During the processing of normal access requests, if the access detection point of the trusted aggregate detects that the access path of a certain access request does not match the compliance access path verification benchmark, then the access request is determined to be an illegal access using an invalid access path. For illegal access using invalid access paths, a data circuit breaker operation is performed to reject the illegal access.
[0021] In one embodiment, step S34, which involves performing a data circuit breaker operation to reject illegal access for invalid access paths, includes: S341. The trusted aggregate detects the received access request based on the access detection point of the trusted base core. If the access request does not match a valid access path, it is determined to be an illegal access. S342. When an unauthorized access is received, the trusted base core sends a circuit breaker request to the circuit breakerable link. S343. The fuselable link receives a fuselage request, performs autonomous fuselage, and disconnects from the trusted base core. S344. At the same time, the trusted base core modifies the logical address corresponding to each fusible link and generates a pseudo link logical address mapping table. S345. When an illegal access is detected and the access is terminated at the access detection point, the active polymer is reconstructed based on the recovery mechanism. As described in steps S341-S345 above, the access detection point of the trusted base core continuously monitors all access requests arriving at the trusted aggregate. If the access path of the access request does not match any of the following valid access paths: trusted aggregate identifier, trusted base core identifier, fuselable link identifier, microcore storage point identifier, or payload sequence number, the access detection point determines the access request as an illegal access. The access detection point generates an illegal access event record, which includes the access path of the illegal access request, the determination timestamp, and the specific node information of the mismatch. After the access detection point determines that the access is illegal, the trusted base core immediately starts. The circuit breaker process involves sending a circuit breaker request to the circuit breakerable link. This request is a control message containing the circuit breakerable link identifier and a circuit breaker command. The request is sent through the control channel between the trusted base core and the circuit breakerable link. This control channel is independent of the data transmission channel, ensuring that the circuit breaker command can still be delivered even if the data transmission channel is occupied. Upon receiving the request, the circuit breakerable link performs an autonomous circuit breaker operation. This operation is controlled by the connection status flags maintained by both ends of the link. The link flips the connection status flag at the trusted base core end from connected to broken. In the broken state, the data transmission channel of the circuit breakerable link is physically closed, preventing any data transmission via... Data read and write requests for the fusible link are directly rejected. While the fusible link performs autonomous circuit breaking, the trusted base core modifies the logical address of each broken fusible link. The trusted base core accesses its own stored link logical address mapping table. This table records the correspondence between all fusible link identifiers within the trusted aggregate and their respective current logical addresses. The trusted base core then assigns each broken fusible link its corresponding... The logical address is replaced from the original logical address with a fake logical address. Each fake logical address of the fuselage link is independently and randomly generated by the trusted base core. Each fake logical address points to an empty location in the mapping space or a pre-created pseudo micro-core storage point. The pseudo micro-core storage point only stores meaningless padding data. After all logical addresses are replaced, the trusted base core generates a pseudo link logical address mapping table. The correspondence between the original logical address and the micro-core storage point is retained in the link logical address mapping table and is not deleted. It is only visible to the trusted base core. When the access detection point detects illegal access and ends, the active aggregate is reconstructed based on the recovery mechanism.
[0022] In one embodiment, step S345, which reconstructs the active polymer based on a recovery mechanism when an access detection point detects an illegal access and the access ends, includes: S3451. The access detection point continuously monitors access requests. When no new illegal access is detected within the preset time window, the illegal access is determined to have ended. S3452. The access detection point sends a recovery trigger signal to the trusted base core, and the trusted base core executes the recovery mechanism. S3453, the trusted base core calls the load distribution mapping table and the pseudo link logical address mapping table, and resets the contents of the pseudo link logical address mapping table to the link logical address mapping table based on the load distribution mapping table; S3454. Based on the call payload distribution mapping table and the reset link logical address mapping table, the connection between the micro-payload data and the trusted base core is re-established, and the reconstruction of the active aggregate is completed. As described in steps S3451-S3454 above, when the access detection point continuously monitors access requests within a preset time window and does not detect any new illegal access, the access detection point determines that the illegal access has ended. The access detection point sends a recovery trigger signal to the trusted base core. After receiving the recovery trigger signal, the trusted base core executes the recovery mechanism. The trusted base core calls the load distribution mapping table and the pseudo-link logical address mapping table. Based on the micro-data load allocation information recorded in the load distribution mapping table, it replaces the false logical addresses in the pseudo-link logical address mapping table back to the original logical addresses one by one, restoring each fuselage link and its corresponding... The logical address mapping relationship of the microcore storage point is established. The trusted base core sends a recovery command to each fusible link. After receiving the recovery command, the fusible link flips the connection status flags at both ends from fused to connected, and re-establishes the data transmission channel between the trusted base core and the microcore storage point. After the fusible link is reconnected, the micro data payload returns to normal through data interaction with the trusted base core via the fusible link. After receiving the connection recovery signals of all fusible links, the trusted base core restores the state of the trusted aggregate from the fused state to the aggregated state, and regenerates the valid access path based on the load distribution mapping table. The reconstruction of the active aggregate is completed.
[0023] In one embodiment, step S4, which involves inputting the functional granular network into a virtual resource scheduling engine and generating a workload estimation result based on the virtual resource scheduling engine, includes: S41. Construct a virtual resource scheduling engine for functional granularity parsing, directed acyclic graph construction, resource pooling, and Monte Carlo simulation; S42. Based on the complexity label and resource consumption label of the functional granule, define the optimistic estimate, most likely estimate and pessimistic estimate of each functional granule, and generate three-point estimation parameters. S43. Construct a directed acyclic graph based on the dependency relationships of functional granular networks; S44. Resource pools are used to define resource types and the maximum amount of available data for each resource type. S45. The virtual resource scheduling engine performs Monte Carlo simulation of the integrated resource pool. In each round of simulation, an execution time value is randomly sampled for each functional particle based on the three-point estimation parameters of each functional particle. S46. When performing simulation based on a directed acyclic graph, the activation of a functional particle requires that all predecessor dependencies be completed and that the available data of the required resources be sufficient. If the available data is insufficient, the functional particle enters a waiting state until the available data is released. S47. Statistically analyze the total project duration distribution in multiple rounds of Monte Carlo simulation, extract the duration confidence interval under the preset confidence level, output the functional granular waiting time statistics, and generate the workload estimation results. S48. The workload estimation results include the total expected duration, duration confidence level, and the percentage of waiting time for each resource type. As described in steps S41-S48 above, a virtual resource scheduling engine is constructed. This engine is used for functional granule parsing, directed acyclic graph construction, resource pool management, and Monte Carlo simulation. The virtual resource scheduling engine receives the functional granule network, extracts the complexity label and resource consumption label of each functional granule, and extracts the dependencies between functional granules. Based on the complexity label and resource consumption label of each functional granule, optimistic, most likely, and pessimistic estimates are defined for each functional granule, generating three-point estimation parameters. Specifically, a complexity resource parameter mapping table is pre-constructed within the virtual resource scheduling engine, using a combination of complexity labels and resource consumption labels as an index. Each index corresponds to a set of preset optimistic, most likely, and pessimistic estimates. The complexity label includes high, medium, and low complexity, and the resource consumption label indicates the type and quantity of resources required by the functional particle. Each functional particle in the functional particle network is traversed, and its complexity and resource consumption labels are obtained. Using these labels as query keys, a matching search is performed in the complexity-resource parameter mapping table. Upon successful matching, the optimistic, most likely, and pessimistic estimates corresponding to that index are extracted. After completing all table lookups, a three-point estimation parameter set for the functional particle is generated. The virtual resource scheduling engine constructs a directed acyclic loop (DAG) with functional particles as nodes and dependencies as directed edges. The graph, a directed acyclic graph (DAG), defines the execution order constraints between functional granules. A resource pool is constructed, defining resource types and the maximum available quantity for each type. Resource types include, but are not limited to, backend development resources, frontend development resources, database development resources, testing resources, and security review resources. The maximum available quantity is defined based on the resource usage of conventional equipment. The virtual resource scheduling engine performs Monte Carlo simulations of the integrated resource pool. In each simulation round, an execution time value is randomly sampled for each functional granule based on its three-point estimation parameters. The specific steps are as follows: the virtual resource scheduling engine uses a triangular distribution sampling method, with the optimistic estimate as the lower bound and the most likely estimate as the mode. Using a pessimistic estimate as the upper limit of the distribution, a value is sampled on the triangular distribution curve by a random number generator. This value is the execution time of the corresponding functional particle in this round of simulation. When the simulation is advanced based on the directed acyclic graph, the virtual resource scheduling engine maintains a virtual clock. The virtual clock starts from zero. The virtual resource scheduling engine traverses all functional particles that have not yet started and whose predecessor dependencies have all been completed. It checks whether the resource requirements of each functional particle are met. If all are met, the functional particle starts immediately. The virtual resource scheduling engine deducts the corresponding resource quantity from the resource pool and records the start execution time of the functional particle. The expected completion time of the functional particle is the current virtual clock plus the execution time value obtained by sampling the functional particle.If the current available quantity of any resource type is insufficient, the functional particle will not start and will enter a waiting state. The virtual resource scheduling engine will add the functional particle to the waiting queue and record the waiting start time. The virtual resource scheduling engine will advance the virtual clock to the earliest estimated completion time among all executing functional particles. At this time, the corresponding functional particle will be marked as completed, and the quantities of each resource type occupied by the functional particle will be returned to the resource pool. Subsequently, the virtual resource scheduling engine will traverse the waiting queue and re-check the resource availability conditions of the functional particles in the waiting queue. If the resource conditions are met at this time, the functional particle will be removed from the waiting queue and started. The remaining functional particles in the waiting queue will continue to wait for subsequent resource release. The virtual resource scheduling engine will repeat the above process, advancing the virtual clock to the next earliest estimated completion time each time, processing completion events and resource release events, and re-evaluating the waiting queue, until all functional particles in the directed acyclic graph are marked as completed. At this time, the current value of the virtual clock is the total project duration of this simulation. The total project duration of this simulation and the waiting time of each functional particle in this simulation are recorded. This completes all preset rounds. After Monte Carlo simulation, the total project duration values recorded in all simulation rounds are aggregated into a duration data set. This data set is then sorted by numerical value to form a total project duration distribution. The arithmetic mean of all total duration values in the data set is calculated; this arithmetic mean is the total expected project duration. A confidence interval for the project duration is then extracted from the total project duration distribution based on a pre-set confidence level. Specifically, the percentile corresponding to the pre-set confidence level is used to take values at both ends of the sorted duration data set. The duration value corresponding to the lower percentile is the lower limit of the confidence interval, and the duration value corresponding to the upper percentile is the lower limit of the confidence interval. The project duration is defined as the upper limit of the confidence interval, with the lower and upper limits together forming the project duration confidence interval. Simultaneously, the waiting time recorded for each functional unit across all simulation rounds is aggregated. The waiting times of all functional units are grouped and aggregated according to the resource types required by the functional units. For each resource type, the sum of all waiting times under that resource type is calculated, and this sum is compared to the sum of the total project durations corresponding to that resource type to obtain the percentage of waiting time for that resource type. The total expected project duration, the project duration confidence interval, and the percentage of waiting time for each resource type are encapsulated into a workload estimation result for output.
[0024] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.
Claims
1. A method for software function decomposition and workload estimation based on a large language model, characterized in that, include: Build an active aggregate on a local trusted computing node; Obtain the software requirements document and code files, and segment the requirements document and code files into micro data payloads based on the active aggregate; In response to a normal access request, the large language model acquires the micro data payload, performs functional decomposition on the micro data payload, and outputs the functional granular network. The functional granular network is input into the virtual resource scheduling engine, and the workload estimation results are generated based on the virtual resource scheduling engine.
2. The software function decomposition and workload estimation method based on a large language model according to claim 1, characterized in that, The steps for constructing the active aggregate on the local trusted computing node are as follows: Build a mapping space on the local trusted node; Multiple trusted aggregates are constructed in the mapping space. Each trusted aggregate consists of a trusted base core, a fuselable link, and a micro-core storage point. For a single trusted aggregate, multiple micro-core storage points and trusted base cores are connected via fusible links; The trusted base core is configured with access detection points and a link logical address mapping table. The access detection points are used to detect whether the access path is compliant, and the link logical address mapping table is used to record the correspondence between the logical address of each fuselable link and the microcore storage point.
3. The software function decomposition and workload estimation method based on a large language model according to claim 2, characterized in that, The step of segmenting the requirement document and code file into micro-data payloads based on the active aggregate is as follows: Obtain the required files and code files from the local storage space and transfer them to the mapped space; Based on a preset data volume, the requirement file and code file are divided into multiple raw data stream fragments; The mapping space adds an integrity check label and a payload sequence number to each original data stream segment to generate a micro data payload. Extract the payload vector for each micro-payload data. The payload vector is a locally sensitive hash value generated based on the content of the micro-payload data. Calculate the similarity of local sensitive hash values among the micro-load data, and adopt a distributed allocation strategy to distribute the micro-load data with high similarity to different load clusters; The number of payload clusters and the number of trusted aggregates are the same; The payload clusters are assigned to trusted aggregates to generate valid allocation paths, and valid access paths are generated based on the valid allocation paths.
4. The software function decomposition and workload estimation method based on a large language model according to claim 3, characterized in that, The steps for generating a valid access path based on a valid allocated path are as follows: Each micro-payload data in the payload cluster is allocated and stored in the micro-core storage point based on the fusible link. The micro-data payload interacts with the trusted base core through the fusible link. For a trusted aggregate that has completed its allocation, the trusted base core generates a load distribution mapping table based on the allocation order. The load distribution mapping table includes microcore storage point identifiers, load allocation paths, and fuselable link identifiers. The effective allocation path and load distribution mapping table are combined to generate an effective access path.
5. The software function decomposition and workload estimation method based on a large language model according to claim 4, characterized in that, The steps for responding to a normal access request, obtaining the micro-data payload from the large language model, performing functional decomposition on the micro-data payload, and outputting the functional granular network are as follows: The large language model accesses the mapping space based on the effective access path, obtains micro-load data in sequence according to the effective access path, and concatenates them into requirement files and code files; Based on a large language model, semantic analysis is performed on requirement files and code files to identify functional boundaries and generate a functional granular network. The functional granule network consists of multiple functional granules and the dependencies between them, and defines a complexity label and a resource consumption label for each functional granule. For unauthorized access via invalid access paths, a data circuit breaker operation is performed to reject the unauthorized access.
6. The software function decomposition and workload estimation method based on a large language model according to claim 5, characterized in that, The steps for performing a data circuit breaker operation to reject illegal access via invalid access paths are as follows: The trusted aggregate detects received access requests based on the access detection points of the trusted base core. If the access request does not match a valid access path, it is determined to be an illegal access. When an unauthorized access is received, the trusted base core sends a circuit breaker request to the circuit breakerable link; The circuit-breakable link receives a circuit-break request, performs autonomous circuit breaking, and disconnects from the trusted base core. At the same time, the trusted base core modifies the logical address of each fusible link and generates a pseudo link logical address mapping table; When an illegal access is detected and the access ends, the active polymer is reconstructed based on the recovery mechanism.
7. The software function decomposition and workload estimation method based on a large language model according to claim 6, characterized in that, The step of reconstructing the active polymer based on the recovery mechanism when the access detection point detects an illegal access and the process ends is as follows: The access detection point continuously monitors access requests. When no new illegal access is detected within a preset time window, the illegal access is considered to have ended. The access detection point sends a recovery trigger signal to the trusted base core, and the trusted base core executes the recovery mechanism. The trusted base core calls the load distribution mapping table and the pseudo link logical address mapping table, and resets the contents of the pseudo link logical address mapping table to the link logical address mapping table based on the load distribution mapping table. Based on the call payload distribution mapping table and the reset link logical address mapping table, the connection between the micro-payload data and the trusted base core is re-established, and the reconstruction of the active aggregate is completed.
8. The software function decomposition and workload estimation method based on a large language model according to claim 1, characterized in that, The step of inputting the functional granular network into the virtual resource scheduling engine and generating workload estimation results based on the virtual resource scheduling engine is as follows: A virtual resource scheduling engine is built for functional granularity parsing, directed acyclic graph construction, resource pooling, and Monte Carlo simulation. Based on the complexity label and resource consumption label of the functional granule, the optimistic estimate, most likely estimate and pessimistic estimate of each functional granule are defined to generate three-point estimation parameters. Constructing a directed acyclic graph based on the dependency relationships of functional granular networks; Resource pools are used to define resource types and the maximum amount of available data for each resource type; The virtual resource scheduling engine performs Monte Carlo simulation of the integrated resource pool. In each round of simulation, it randomly samples an execution time value for each functional particle based on the three-point estimation parameters of each functional particle. When performing simulation based on a directed acyclic graph, the activation of a functional particle requires that all predecessor dependencies be completed and that there is sufficient available data for the required resources. If the available data is insufficient, the functional particle enters a waiting state until the available data is released. The total project duration distribution of multiple rounds of Monte Carlo simulation is statistically analyzed, the project duration confidence interval under a preset confidence level is extracted, and the functional granular waiting time statistics are output to generate workload estimation results. The workload estimation results include the total expected duration, duration confidence level, and the percentage of waiting time for each resource type.