Intelligent task scheduling method and system based on labels and cues
By adding tags and prompts to tasks, and utilizing natural language parsing and calculation formulas to optimize the allocation and execution order of tasks on the machine, the problems of resource waste and poor user experience in existing technologies are solved, achieving more efficient resource utilization and user control.
Patent Information
- Application Number
- CN202510673901.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-23
- Publication Date
- 2025-10-28
AI Technical Summary
Existing task scheduling systems struggle to accurately allocate tasks based on their actual resource requirements, time sensitivity, and user needs, leading to resource waste, task blockage, and poor user experience.
By adding initial tags and prompts to tasks, and using natural language parsing methods to convert the prompts into additional tags, combined with machine selection formulas and task execution order formulas, the allocation and execution order of tasks on the machine are dynamically adjusted.
It improves resource utilization, reduces task waiting time, enhances user experience, and can dynamically respond to user needs and system status changes, adapting to complex computing environments.
Smart Images

Figure CN120849029A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of computer task scheduling technology, and more specifically, to an intelligent task scheduling method and system based on tags and prompt words. Background Technology
[0002] In modern computing environments, task scheduling is a crucial element in ensuring efficient system operation. Existing task scheduling systems often struggle to accurately allocate tasks based on their actual resource requirements, time sensitivity, and user needs, leading to resource waste, task blocking, and poor user experience. Furthermore, users cannot visually view the execution order of tasks or directly intervene in it.
[0003] Most existing task scheduling systems are based on static rules or simple priority mechanisms, such as First-Come, First-Served (FCFS), Shortest Job First (SJF), and priority scheduling. While these methods are simple to implement, they suffer from resource waste, task blocking, and poor user experience in dynamic environments. For example, FCFS may cause short tasks to wait for long tasks to complete, while SJF may cause long tasks to starve, lacking the ability to dynamically respond to user needs. Users typically cannot express their task scheduling needs intuitively, nor can they intervene in the execution order of tasks in real time. Summary of the Invention
[0004] One objective of this invention is to provide an intelligent task scheduling method based on tags and prompts, which solves the technical problem that existing task scheduling systems often struggle to accurately allocate tasks based on their actual resource requirements, time sensitivity, and user needs, leading to resource waste, task blocking, and poor user experience. Another objective of this invention is to provide an intelligent task scheduling system based on tags and prompts.
[0005] To solve the above-mentioned technical problems, the technical solution of the present invention is as follows: The first aspect of this invention provides an intelligent task scheduling method based on tags and prompt words, comprising the following steps: Get the total and remaining resources of each machine currently used to execute the task; Add several initial tags and prompts to each task, and assign weights to each initial tag and prompt; The prompt words are converted into additional tags using natural language parsing methods; Based on the initial label, additional label, weight, total resources and remaining resources of each machine, the machine where each task is executed and the order of task execution when executed on the same machine are calculated using the preset machine selection formula and task execution order formula.
[0006] In the aforementioned technical approach, a natural language processing module converts user-input prompts into task resource requirement tags and execution order tags. This method not only enables precise allocation based on the actual resource requirements and time sensitivity of tasks, but also dynamically adjusts task priority and resource allocation. It solves the technical problem in existing task scheduling systems where precise allocation based on actual resource requirements, time sensitivity, and user needs often leads to resource waste, task blocking, and poor user experience.
[0007] Furthermore, the initial tags include a task resource requirement tag and a task execution order tag, wherein: The task resource requirement tags include CPU core count tags, memory size tags, hard disk capacity tags, and GPU availability tags; The task execution order labels include priority labels and real-time labels.
[0008] Furthermore, the prompts include resource requirement prompts, execution order prompts, and invalid prompts.
[0009] Furthermore, natural language processing methods are used to convert the prompt words into additional tags, including: For resource requirement prompts, perform keyword matching processing to convert the resource requirement prompts into resource constraint condition tags; For execution order prompts, perform keyword matching and convert the execution order prompts into priority or real-time tags; For invalid prompts, synonym suggestions are provided.
[0010] Furthermore, the machine selection formula includes: Score1 =
[0011] In the formula, Score1 represents the current machine score. Indicates the first The weight of the resource requirement tag for each task. Indicates the current machine's... The remaining amount of resources for each task. Indicates the current machine's... The total amount of resources for each task This indicates the first [word] after being transformed from the prompt word. The weight of resource constraint labels. This represents the constraint satisfaction coefficient, which is the coefficient required to satisfy resource constraints. The value is 1 when the resource constraint condition is met. =0; represents the number of task resource requirement tags, and m represents the number of resource constraint tags converted from prompt words.
[0012] Furthermore, the task execution order formula includes: Score2 =
[0013] In the formula, Score2 represents the score for the current task execution order. This indicates the weight of the priority label. The weight of the real-time label is indicated. This indicates the first [word] transformed from the prompt word. The weight of priority or real-time tags, This indicates the first [word] transformed from the prompt word. The directional coefficient of a priority or real-time tag, , These are the normalization coefficients for priority and real-time performance, respectively.
[0014] Furthermore, we obtain the machine on which each task is executed and the order in which tasks are executed on the same machine, including: The machine with the highest machine score calculated using the machine selection formula is selected as the machine where the task is executed. The tasks are then executed sequentially on the same machine according to the task execution order score calculated using the task execution order formula, from highest to lowest.
[0015] Furthermore, it also includes the following steps: Generate a sequence diagram showing the execution order of tasks on the same machine, and visualize it.
[0016] Furthermore, it also includes the following steps: Adjust the visualized sequence diagram as needed to change the execution order of tasks on the same machine.
[0017] A second aspect of the present invention provides an intelligent task scheduling system based on tags and prompt words, comprising: Get the total and remaining resources of each machine currently used to execute the task; Add several initial tags and prompts to each task, and assign weights to each initial tag and prompt; The prompt words are converted into additional tags using natural language parsing methods; Based on the initial label, additional label, weight, total resources and remaining resources of each machine, the machine where each task is executed and the order of task execution when executed on the same machine are calculated using the preset machine selection formula and task execution order formula.
[0018] Compared with the prior art, the beneficial effects of the technical solution of the present invention are: This invention proposes an intelligent task scheduling method based on tags and prompts, which can improve resource utilization, reduce task waiting time, and enhance user experience. Furthermore, by dynamically responding to user needs and system state changes, this invention can better adapt to complex computing environments. This method excels in multi-objective optimization, intelligence, and adaptive scheduling, overcoming the limitations of traditional task scheduling methods in resource allocation, dynamic adjustment, and system scalability. Attached Figure Description
[0019] Figure 1 A flowchart illustrating an intelligent task scheduling method based on tags and prompt words provided in an embodiment of the present invention; Figure 2 This is a schematic diagram of a module of an intelligent task scheduling system based on tags and prompt words, provided in an embodiment of the present invention. Detailed Implementation
[0020] The accompanying drawings are for illustrative purposes only and should not be construed as limiting the scope of this patent. To better illustrate this embodiment, some parts in the accompanying drawings may be omitted, enlarged, or reduced, and do not represent the actual product dimensions; It will be understood by those skilled in the art that certain well-known structures and their descriptions may be omitted in the accompanying drawings.
[0021] The technical solution of the present invention will be further described below with reference to the accompanying drawings and embodiments.
[0022] Example 1 This invention provides an intelligent task scheduling method based on tags and prompt words, such as... Figure 1 As shown, it includes the following steps: Get the total and remaining resources of each machine currently used to execute the task; Add several initial tags and prompts to each task, and assign weights to each initial tag and prompt; The prompt words are converted into additional tags using natural language parsing methods; Based on the initial label, additional label, weight, total resources and remaining resources of each machine, the machine where each task is executed and the order of task execution when executed on the same machine are calculated using the preset machine selection formula and task execution order formula.
[0023] In a specific embodiment, several initial labels and prompts are added to each task, and a weight is assigned to each initial label and prompt, specifically as follows: When a user submits a task, they are prompted to set task resource requirement tags and task execution order tags, and enter natural language prompts. A weight is assigned to each tag and prompt. Specifically: The user inputs a prompt and sets its weight. The prompt content is: "Requires at least 4 CPU cores" with a weight of 0.8; "Can be executed late" with a weight of 0.9. Users select task execution order tags: real-time tag, with a weight of 0.8; priority tag, with a weight of 0.6. User selects task resource requirement tags: CPU weight 0.9, memory weight 0.7.
[0024] In a specific embodiment, the prompt words are converted into additional tags using natural language parsing methods, specifically as follows: The prompts are converted into structured tags using natural language parsing, categorized into task resource requirement tags and task execution order tags, with directional tags (priority increase / decrease or real-time requirements). Prompts that cannot be parsed are marked on the user interface with suggested corrections. Specifically: User input suggestions and tags are parsed as follows: Task resource requirement tag: CPU ≥ 4 cores (weight 0.8); Task execution order label: can be delayed (weight 0.9, lk=-0.5).
[0025] In a further embodiment, the initial label includes a task resource requirement label and a task execution order label, wherein: The task resource requirement tags include CPU core count tags, memory size tags, hard disk capacity tags, and GPU availability tags, with weights specified by the user between 0 and 1; The task execution order labels include priority labels and real-time labels, with weights specified by the user between 0 and 1.
[0026] In a further embodiment, the prompt words include resource requirement prompt words, execution order prompt words, and invalid prompt words.
[0027] In a further embodiment, the prompt words are converted into additional tags using a natural language parsing method, including: For resource requirement prompts, keyword matching is performed to convert them into resource constraint labels. For example, "requires at least 500M memory" is parsed as "memory ≥ 500M". The weight is input by the user. For execution order prompts, keyword matching is performed to convert them into priority or real-time tags. For example, "execute immediately" is parsed as "real-time = high". The weight is input by the user. For invalid prompts, provide synonym suggestions, such as suggesting "execute quickly" to "execute first".
[0028] In a further embodiment, the machine selection formula includes: Score1 =
[0029] In the formula, Score1 represents the current machine score. Indicates the first The weight of the resource requirement tag for each task. Indicates the current machine's... The remaining amount of resources for each task. Indicates the current machine's... The total amount of resources for each task This indicates the first [word] after being transformed from the prompt word. The weight of resource constraint labels. This represents the constraint satisfaction coefficient, which is the coefficient required to satisfy resource constraints. The value is 1 when the resource constraint condition is met. =0; represents the number of task resource requirement tags, and m represents the number of resource constraint tags converted from prompt words.
[0030] In a specific embodiment, based on the weight of the task resource requirement tag and the machine resource matching degree, a weighted average formula is used to calculate the comprehensive score of each machine, and the machine with the highest score is selected to execute the task. Specifically: Assume machine A has the following resource status: 6 CPU cores remaining (out of 8), satisfying the prompt "CPU ≥ 4 cores"; and 1GB of memory remaining (out of 16GB). Assume machine B has the following resource status: 4 CPU cores remaining (out of 8), satisfying the message "CPU ≥ 4 cores"; and 14GB of memory remaining (out of 16GB). Based on the calculation formula selected by the machine: Score1 = get Machine A's score, Score1 = = 0.50625 Machine B's score: Score 1 = = 0.62083 Machine B scored higher than Machine A, so Machine B should be selected to perform the task.
[0031] In a further embodiment, the task execution order formula includes: Score2 =
[0032] In the formula, Score2 represents the score for the current task execution order. Indicates the weight (0~1) of the priority label. The weight (0~1) represents the real-time label. This indicates the first [word] transformed from the prompt word. The weight of priority or real-time label (0~1). This indicates the first [word] transformed from the prompt word. The directional coefficient (-1~1) of the priority or real-time tag. , These are the normalization coefficients for priority and real-time performance, respectively (default α=β=1).
[0033] In a specific embodiment, the direction coefficient of the prompt word is generated in the following way: for example, "execute immediately" is a positive instruction and can be parsed. =0.8 (Intensity coefficient can be quantified by adverbs, such as those requiring immediate execution, corresponding to...) =1); "Delayable processing" can be parsed as =-0.5 (the intensity coefficient can be calculated from the proportion of the delay time to the magnitude of the directional coefficient), specifically: According to the task execution order formula, Score2 = get Task execution order score: Score 2 = = 0.32759 Tasks with a lower execution order score will be executed later.
[0034] In a further embodiment, the user can adjust and The value of α is used to control the relative importance of priority and real-time performance; for example, α=2 indicates that the priority weight is doubled.
[0035] In a further embodiment, obtaining the machine where each task is executed and the order in which tasks are executed when they are executed on the same machine includes: The machine with the highest machine score calculated using the machine selection formula is selected as the machine where the task is executed. The tasks are then executed sequentially on the same machine according to the task execution order score calculated using the task execution order formula, from highest to lowest.
[0036] Example 2 Based on the intelligent task scheduling method based on tags and prompt words described in Example 1, this invention further provides the following steps: Generate a sequence diagram showing the execution order of tasks on the same machine, and visualize it.
[0037] In a further embodiment, the step of: Adjust the visualized sequence diagram as needed to change the execution order of tasks on the same machine.
[0038] In specific embodiments, users can intuitively view the task execution order through the interface and intervene in the task execution order in real time by adjusting labels, prompts, or dragging task nodes. Furthermore, this embodiment of the invention also provides a dynamic execution order diagram and a weight adjustment interface, enhancing user control over the scheduling process, specifically providing the following functions: Drag and drop adjustment: Users can directly drag and drop task nodes to different machines or adjust the execution order, and the system will recalculate the scheduling strategy in real time. Weight slider: Provides a visual slider for each tag and prompt word, allowing for dynamic modification of weight values; Conflict alert: When resources are insufficient or scheduling conflicts occur, the conflicting node is highlighted and a solution is recommended, such as "It is recommended to reduce the CPU weight of task A".
[0039] Example 3 This invention provides an intelligent task scheduling system based on tags and prompt words, applying the intelligent task scheduling method based on tags and prompt words described in Embodiments 1 and 2, such as... Figure 2 Shown, including: The acquisition module acquires the total and remaining resources of each machine currently used to execute the task; The tag weighting module adds several initial tags and prompt words to each task, and assigns a weight to each initial tag and prompt word; The parsing module uses natural language parsing methods to convert the prompt words into additional tags; The calculation execution module calculates the machine where each task is executed and the order of task execution when the tasks are executed on the same machine, based on the initial label, additional label, weight, total resources and remaining resources of each machine, using a preset machine selection formula and task execution order formula.
[0040] In a further embodiment, a visualization module is also included, which is used to visualize a sequence diagram of the task execution order on the machine and to provide the function of adjusting the visualized sequence diagram to change the task execution order on the same machine.
[0041] The same or similar labels correspond to the same or similar parts; The terms used to describe positional relationships in the accompanying drawings are for illustrative purposes only and should not be construed as limiting this patent. Obviously, the above embodiments of the present invention are merely examples for clearly illustrating the present invention, and are not intended to limit the implementation of the present invention. Those skilled in the art can make other variations or modifications based on the above description. It is neither necessary nor possible to exhaustively describe all embodiments here. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of the present invention should be included within the scope of protection of the claims of the present invention.
Claims
1. An intelligent task scheduling method based on tags and prompt words, characterized in that, Includes the following steps: Get the total and remaining resources of each machine currently used to execute the task; Add several initial tags and prompts to each task, and assign weights to each initial tag and prompt; The prompt words are converted into additional tags using natural language parsing methods; Based on the initial label, additional label, weight, total resources and remaining resources of each machine, the machine where each task is executed and the order of task execution when executed on the same machine are calculated using the preset machine selection formula and task execution order formula.
2. The intelligent task scheduling method based on tags and prompt words according to claim 1, characterized in that, The initial tags include task resource requirement tags and task execution order tags, wherein: The task resource requirement tags include CPU core count tags, memory size tags, hard disk capacity tags, and GPU availability tags; The task execution order labels include priority labels and real-time labels.
3. The intelligent task scheduling method based on tags and prompt words according to claim 2, characterized in that, The prompts include resource requirement prompts, execution order prompts, and invalid prompts.
4. The intelligent task scheduling method based on tags and prompt words according to claim 3, characterized in that, The prompt words are converted into additional tags using natural language parsing methods, including: For resource requirement prompts, perform keyword matching processing to convert the resource requirement prompts into resource constraint condition tags; For execution order prompts, perform keyword matching and convert the execution order prompts into priority or real-time tags; For invalid prompts, synonym suggestions are provided.
5. The intelligent task scheduling method based on tags and prompt words according to claim 4, characterized in that, The machine selection formula includes: Score1 = In the formula, Score1 represents the current machine score. Indicates the first The weight of the resource requirement tag for each task. Indicates the current machine's... The remaining amount of resources for each task. Indicates the current machine's... The total amount of resources for each task This indicates the first [word] after being transformed from the prompt word. The weight of resource constraint labels. This represents the constraint satisfaction coefficient, which is the coefficient required to satisfy resource constraints. The value is 1 when the resource constraint condition is met. =0; represents the number of task resource requirement tags, and m represents the number of resource constraint tags converted from prompt words.
6. The intelligent task scheduling method based on tags and prompt words according to claim 5, characterized in that, The task execution order formula includes: Score2 = In the formula, Score2 represents the score for the current task execution order. This indicates the weight of the priority label. The weight of the real-time label is indicated. This indicates the first [word] transformed from the prompt word. The weight of priority or real-time tags, This indicates the first [word] transformed from the prompt word. The directional coefficient of a priority or real-time tag, , These are the normalization coefficients for priority and real-time performance, respectively.
7. The intelligent task scheduling method based on tags and prompt words according to claim 6, characterized in that, Obtain the machine on which each task is executed and the execution order of tasks on the same machine, including: The machine with the highest machine score calculated using the machine selection formula is selected as the machine where the task is executed. The tasks are then executed sequentially on the same machine according to the task execution order score calculated using the task execution order formula, from highest to lowest.
8. The intelligent task scheduling method based on tags and prompt words according to any one of claims 1 to 7, characterized in that, It also includes the following steps: Generate a sequence diagram showing the execution order of tasks on the same machine, and visualize it.
9. The intelligent task scheduling method based on tags and prompt words according to claim 8, characterized in that, It also includes the following steps: Adjust the visualized sequence diagram as needed to change the execution order of tasks on the same machine.
10. An intelligent task scheduling system based on tags and prompt words, characterized in that, include: Get the total and remaining resources of each machine currently used to execute the task; Add several initial tags and prompts to each task, and assign weights to each initial tag and prompt; The prompt words are converted into additional tags using natural language parsing methods; Based on the initial label, additional label, weight, total resources and remaining resources of each machine, the machine where each task is executed and the order of task execution when executed on the same machine are calculated using the preset machine selection formula and task execution order formula.