An intelligent interactive command line terminal for an industry-oriented ubiquitous operating system

By designing intelligent interactive command line terminals in an industrial-oriented ubiquitous operating system, using large language models and context-aware modules, the problems of insufficient timeliness, low customization and security are solved, and more intuitive, natural and intelligent human-computer interaction is achieved.

CN119476503BActive Publication Date: 2025-04-04ADVANCED OPERATING SYST INNOVATION CENT (TIANJIN) CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510052710.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-01-14
Publication Date
2025-04-04
Estimated Expiration
2045-01-14

AI Technical Summary

Technical Problem

The prior art human-computer interactive command line terminals in industrial-oriented ubiquitous operating systems have problems of insufficient timeliness, low customization and security.

Method used

An industrial-oriented ubiquitous operating system intelligent interactive command line terminal is designed, using a combination of intelligent terminal interaction interface, context perception module, command line intelligent auxiliary module and continuous optimization module. It can interact intelligently through a large language model, support natural language input, provide multiple interaction modes, and customize and security check through continuous optimization module.

Benefits of technology

It realizes more intuitive, natural and intelligent human-computer interaction, improves the timeliness and customization of the interaction, and ensures the security of the output through security inspection strategies.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119476503B_ABST
    Figure CN119476503B_ABST
Patent Text Reader

Abstract

The present application relates to an industry-oriented ubiquitous operating system intelligent interactive command line terminal, which relates to the field of computer technology, including a context perception module that obtains user input through an intelligent terminal interactive interface, while continuously collecting context information, and converts the context information and user input into structured data as the input of an intelligent agent and passes it to a command line intelligent assistance module; the command line intelligent assistance module reads the context information and user input, is used to build an intelligent agent with a large language model as a decision-making base, and combines the context information and the operation mode in the user input to understand the instructions in the user input, execute tasks, and perform reasoning and output; the continuous optimization module collects user feedback data and user dialogue context information through the intelligent terminal interactive interface, and optimizes the command line intelligent assistance module based on the user feedback data and the user dialogue context information.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of computer technology, and in particular to an industry-oriented ubiquitous operating system intelligent interactive command line terminal. Background Art

[0002] The current development of information technology is entering an era of ubiquitous computing where everything is connected, and ubiquitous operating systems have emerged. Ubiquitous operating systems can integrate ubiquitous "end" resources such as "cloud, management, edge, end, things, and people", shield the heterogeneity and complexity of managed resources downward, and condense and precipitate application commonality upward; manage and dispatch massive heterogeneous resources downward, and provide programming interfaces to support application development upward. In the industrial world, some ubiquitous operating systems have been deployed and used. Industrial-oriented ubiquitous operating systems manage a wide variety of end resources, including processors, sensors, communicators, controllers, and other terminal devices of various architectures. Interacting with the above-mentioned devices through ubiquitous operating systems has become a necessary means for daily configuration, operation, and maintenance in industrial production.

[0003] Human-computer interaction is a key link in the operating system, which is directly related to the effect and efficiency of operators' use of equipment in industrial production. At present, the human-computer interaction of ubiquitous operating systems in the industrial sector is usually based on the traditional command line terminal (CLI). In recent years, the development of artificial intelligence and natural language processing technology, especially the rise of large language models (LLM), has brought new possibilities to the traditional human-computer interaction mode of operating systems, which is expected to make the interaction mode more intelligent and the interaction process more natural and intuitive. CLI relies on users to enter specific code commands. This interaction mode has remained relatively stable in the development of operating systems. The traditional command line requires users to memorize and enter complex command formats, which brings a high learning cost. This is very unfriendly for new users who are not familiar with commands. In addition, in the ubiquitous operating system for industry, the scenarios are complex and changeable, the supported industrial hardware and equipment types are diverse, and the instructions for interaction of each device are different, making the use of the command line more difficult. Large language models (such as GPT, Llama, GLM, etc.) have demonstrated excellent natural language understanding, code understanding capabilities, and excellent conversational interaction capabilities. These capabilities have made it possible to improve the intelligence of human-computer interaction in ubiquitous operating systems and reduce the difficulty of use.

[0004] In summary, although some command line tools have integrated artificial intelligence algorithms or tools and support intelligent interaction to a certain extent, the following problems still exist:

[0005] 1) Lack of timeliness: The knowledge of large language models is often based on data before a certain time point, lacking the latest information, and it is difficult to update the knowledge base as the system is updated.

[0006] 2) Low customization: The supported hardware devices are limited. Most products only support interaction with hardware of a certain architecture, which cannot meet the ubiquitous computing scenarios of ubiquitous operating systems. Customized adjustments cannot be made based on specific types of hardware.

[0007] 3) Security: Ensure the security of the output commands to avoid incorrectly generated instructions that may lead to accidental deletion of files and other erroneous operations, which may cause serious or irreversible consequences. Summary of the invention

[0008] To solve the above problems, the present application provides an industry-oriented ubiquitous operating system intelligent interactive command line terminal, which adopts the following technical solutions:

[0009] An industry-oriented ubiquitous operating system intelligent interactive command line terminal, comprising: an intelligent terminal interactive interface provided by a terminal tool, a context perception module and a continuous optimization module connected to a command line intelligent auxiliary module respectively, and the command line intelligent auxiliary module, the context perception module and the continuous optimization module are all connected to the intelligent terminal interactive interface, wherein:

[0010] The context-aware module is used to obtain user input (including instructions and operation modes) through the intelligent terminal interactive interface, while continuously collecting context information, and converting the context information and user input into structured data as the input of the intelligent agent and passing it to the command line intelligent assistance module for the command line intelligent assistance module to construct the intelligent agent;

[0011] The command line intelligent assistance module is used to read context information and user input, build an intelligent agent based on a large language model, and combine context information and operation modes in user input to understand the instructions in user input, execute tasks, and perform reasoning and output;

[0012] The continuous optimization module is used to collect user feedback data and user dialogue context information through the intelligent terminal interaction interface, and optimize the command line intelligent assistance module based on the user feedback data and user dialogue context information.

[0013] In a possible implementation, the context information includes: interactive object hardware context information, operating system related context information, command line working environment context information, and user dialogue context information.

[0014] In a possible implementation, the interactive object hardware context information is collected by the context awareness module from the interactive object, including the interactive object type, hardware device architecture, and interactive object status;

[0015] The operating system related context information is collected by the context awareness module from the operating system, including system configuration, system type, system version, environment variables, user permission level and system time;

[0016] The command line working environment context information is collected by the context-aware module from the running environment, including the current working directory, executed historical commands, configuration files, functions and scripts, command line mode, and input and output redirection;

[0017] The user dialogue context information is collected by the context awareness module from the intelligent terminal interaction interface, including current input, command parameters, error messages, expected input and interactive prompts.

[0018] In one possible implementation, the command line intelligent assistance module includes four parts: intelligent agent, knowledge base (the knowledge base includes two parts: WEB knowledge base and local knowledge base), retrieval enhancement generation and output security check, so as to provide intelligent agent construction function, knowledge retrieval function, retrieval enhancement function and security check function respectively.

[0019] In a possible implementation, the command line intelligent assistance module implements the following process when making decisions on user commands based on operation mode and context information based on the intelligent agent building function, knowledge retrieval function, retrieval enhancement function and security check function:

[0020] Step Sa, the command line intelligent assistance module loads the prompt word template corresponding to the understanding mode by default;

[0021] Step Sb, initializing the agent to enter the understanding mode;

[0022] Step Sc, reading the instruction input by the user from the terminal tool, and determining whether the instruction currently input by the user is in a scripting language;

[0023] Step Sc1: If yes, continue to determine whether the script language is an interactive mode switching instruction: if it is a mode switching instruction, dynamically adjust the prompt word template according to the mode switching instruction, reconstruct the agent corresponding to the target operation mode based on the large language model and the prompt word template corresponding to the specified operation mode, and enter the corresponding specified operation mode, and continue to execute step Sc; if it is not a mode switching instruction, directly execute the instruction input by the user, and continue to execute step Sd;

[0024] Step Sc2: if not, it is determined that the instruction currently input by the user is a natural language, and the intelligent agent continues to perform search enhancement based on the knowledge base to generate preliminary output results, and the knowledge base includes a WEB knowledge base and a local knowledge base;

[0025] Step Sd: Based on the security check strategy, the preliminary output result is subjected to an output security check, and it is determined whether risk warning information needs to be generated. If necessary, the corresponding risk warning information is generated and output. Specifically, the security check strategy includes a preset risk level, and the risk level of the preliminary output result is determined by the preset risk level. If it is a high risk level, risk warning information is given while outputting, and the consequences of the preliminary output result after running are pointed out;

[0026] Step Se, determining whether a closing operation needs to be performed, if so, the process ends, if not, continuing to step Sc, reading the next instruction input by the user.

[0027] In a possible implementation, when it is a mode switching instruction, dynamically adjusting the prompt word template according to the mode switching instruction, reconstructing the agent corresponding to the target operation mode and entering the corresponding target operation mode, including:

[0028] When the target operation mode switched by the mode switching instruction is the dialogue mode, the prompt word template is dynamically adjusted to the prompt word template corresponding to the dialogue mode, and the intelligent agent corresponding to the dialogue mode is rebuilt to enter the dialogue mode;

[0029] When the target operation mode switched by the mode switching instruction is the generation mode, the prompt word template is dynamically adjusted to the prompt word template corresponding to the generation mode, and the intelligent agent corresponding to the generation mode is reconstructed to enter the generation mode.

[0030] In a possible implementation, the reconstructing an agent corresponding to the target operation mode includes:

[0031] Based on the large language model and the prompt word template corresponding to the target operation mode, an intelligent agent corresponding to the target operation mode is constructed. The large language model includes a base model with GLM as the decision base and a customized low-rank model with user personalized settings.

[0032] In a possible implementation, the command line intelligent assistance module provides a RAG functional interface, and the intelligent agent accesses the knowledge base through the RAG functional interface.

[0033] In summary, this application includes the following beneficial technical effects:

[0034] This application can process natural language input, supports more hardware devices than traditional command line tools, has richer interaction methods, and has more intuitive, natural, and intelligent interaction effects. The terminal can refer to the WEB knowledge base for retrieval enhancement. Compared with the traditional large offline model, the output results generated by this application take into account both timeliness and accuracy, and can be customized for user habits and preferences; at the same time, the use of low-rank matrices to store customized models for multiple devices is more lightweight and easy to deploy. BRIEF DESCRIPTION OF THE DRAWINGS

[0035] Figure 1 It is a structural diagram of an industry-oriented ubiquitous operating system intelligent interactive command line terminal in an embodiment of the present application.

[0036] Figure 2 It is a flowchart of the implementation process of an industry-oriented ubiquitous operating system intelligent interactive command line terminal in an embodiment of the present application. DETAILED DESCRIPTION

[0037] The present application is further described in detail below in conjunction with the accompanying drawings.

[0038] After reading this specification, those skilled in the art may make non-creative modifications to this embodiment as needed, but such modifications are protected by patent law as long as they are within the scope of the claims of this application.

[0039] In order to make the purpose, technical solution and advantages of the embodiments of the present application clearer, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.

[0040] In addition, the term "and / or" in this article is only a description of the association relationship of associated objects, indicating that there can be three relationships. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. In addition, the character " / " in this article, unless otherwise specified, generally means that the associated objects before and after are in an "or" relationship.

[0041] The embodiments of the present application are further described in detail below in conjunction with the drawings in the specification.

[0042] The present application embodiment provides an industry-oriented ubiquitous operating system intelligent interactive command line terminal, such as Figure 1 As shown, the industry-oriented ubiquitous operating system intelligent interactive command line terminal includes: an intelligent terminal interactive interface, a context perception module, a command line intelligent auxiliary module and a continuous optimization module, wherein the intelligent terminal interactive interface is provided by a terminal tool, the context perception module and the continuous optimization module are respectively connected to the command line intelligent auxiliary module, and the command line intelligent auxiliary module, the context perception module and the continuous optimization module are all connected to the intelligent terminal interactive interface. Specifically, the functions of each module are as follows:

[0043] 1. Context-aware module

[0044] The context-aware module is used to obtain user input (including instructions and operation modes) through the intelligent terminal interactive interface, while continuously collecting context information, and converting the context information and user input into structured data as the input of the intelligent agent and passing it to the command line intelligent assistance module for the command line intelligent assistance module to build the intelligent agent. Context information is the system environment and status of the user when using the command line terminal, which is of great significance for understanding the user's intention. Based on the context information, the command line intelligent assistance module can better understand the user's intention, and then can more accurately and efficiently assist the user in using the command line terminal.

[0045] (1) Context information includes: interactive object hardware context information, operating system related context information, command line working environment context information and user dialogue context information. Specifically, the detailed introduction of each type of context information is as follows:

[0046] 1.1 Interaction Object Hardware Context Information

[0047] The interactive object hardware context information is collected by the context awareness module from the interactive object. Specifically, the interactive object hardware context information includes:

[0048] Interaction object type: hardware objects operated by users, such as processors, sensors, communicators, controllers and other industrial hardware devices;

[0049] Hardware device architecture: The architecture of the interactive object and the instruction set it supports.

[0050] Interaction object status: status information of industrial hardware equipment, such as the task being executed.

[0051] 1.2 Operating system related context information

[0052] The operating system related context information is collected by the context awareness module from the operating system. The specific operating system related context information includes:

[0053] System configuration: including hardware information such as CPU architecture, memory size, and disk space.

[0054] Basic system information: system type and version information.

[0055] System status: current system load and network connection status, etc.

[0056] Environment variables: Environment variables that affect command line behavior, such as PATH, HOME, and USER.

[0057] Permission level: The permission level of the user when executing commands (such as ordinary user, administrator).

[0058] System Time: Current system date and time and time zone information.

[0059] Language and regional settings: The user's preferred language and regional settings affect the display of the smart terminal interactive interface.

[0060] 1.3 Command line working environment context information

[0061] The command line working environment context information is collected by the context awareness module from the running environment. The specific command line working environment context information includes:

[0062] Current working directory: The directory the user is currently in on the command line.

[0063] Executed command history: The command sequence previously executed by the user, used for historical search and repeated execution.

[0064] Alias: Command alias set by the user to simplify command input.

[0065] Configuration files: such as .bashrc, .bash_profile, .profile, etc., containing personalized configurations.

[0066] Functions and scripts: Functions and scripts defined by the user in the command line environment.

[0067] Command line mode: Whether the current command line is in a special mode, such as Vi editing mode.

[0068] Input and output redirection: Whether the input and output of the current command line are redirected to files or other devices.

[0069] 1.4 User Conversation Context Information

[0070] The user conversation context information is collected by the context awareness module from the intelligent terminal interaction interface. Specifically, the user conversation context information includes:

[0071] Current input: The command or text that the user is currently entering.

[0072] Command parameters: Parameters and options that come with a command entered by the user.

[0073] Error message: Any error or warning message generated after the user enters a command.

[0074] Anticipate input: Based on the logic of the current command or script, predict the information that the user may need to enter next.

[0075] Interactive prompt: The prompt information displayed by the intelligent interactive terminal in the industrial ubiquitous operating system when waiting for user input.

[0076] (2) The operation modes include understanding mode, dialogue mode and generation mode. The processing method of the intelligent interactive command line terminal of the ubiquitous operating system for industry in each mode is as follows:

[0077] Understanding mode: Users can enter understanding mode through the aiassist-default command. In understanding mode, the terminal is used in a similar way to traditional terminal tools. Users are required to enter scripts or instructions that the operating system can understand (such as Bash in Linux and Batch Script in Windows). At the same time, the terminal takes into account contextual information such as the device attributes and status of the user's operation. When the user types a command, the terminal can automatically complete it. At the same time, when the user selects text such as instructions on the intelligent terminal interactive interface, command line prompts (such as warnings and errors), the terminal can automatically generate and display corresponding command syntax semantics interpretation, instruction execution effect interpretation, error analysis and other information.

[0078] In addition to supporting users to input script languages, the conversation mode and generation mode can also support users to input natural languages. Specifically, users can enter the conversation mode through the aiassist-chat command. In the conversation mode, when users input natural language questions, the terminal can answer the questions raised by users through multiple rounds of natural language dialogue. Users can enter the generation mode through the aiassist-gen command. In the generation mode, the terminal directly displays a list of script instructions that the operating system can understand based on the user's natural language input, and executes it after the user selects and confirms it.

[0079] 2. Command Line Intelligent Assistance Module

[0080] The command line intelligent assistance module is used to read context information and user input, to build an intelligent agent based on a large language model as a decision-making base, and to understand the instructions in the user input by combining context information and the operation mode in the user input, to perform tasks (such as command generation, code interpretation), and to perform reasoning and output.

[0081] The command line intelligent assistance module consists of four parts: intelligent agent, knowledge base (the knowledge base includes WEB knowledge base and local knowledge base), retrieval enhancement generation and output security check, which respectively provide intelligent agent construction function, knowledge retrieval function, retrieval enhancement function and security check function.

[0082] 1. Agent

[0083] The intelligent agent consists of two parts: a large language model (the large language model includes a base model with GLM as the decision-making base and a customized low-rank model with user personalized settings) and a dynamic prompt word template.

[0084] After the user selects the corresponding operation mode in the command line, the intelligent agent immediately loads the corresponding dynamic prompt word template. At the same time, according to the context information perceived by the context perception module, the dynamic prompt word template is dynamically set and adjusted (based on the prompt word function, the intelligent agent provides customized prompt word templates for calling according to different operation modes and industrial equipment), the role of the intelligent agent is set, and the construction of the intelligent agent is completed, so that the intelligent agent can complete specific tasks according to user needs (such as completing interaction tasks with specific types of hardware in industrial scenarios).

[0085] 2. Knowledge Base

[0086] Since the knowledge of the large language model is limited to a certain point in time, there is a certain lag. Therefore, the present invention is based on the RAG technology that combines online and offline, and the server provides a WEB knowledge base and a local knowledge base to improve timeliness: the command line intelligent assistance module of the present invention provides a RAG interface, so that the intelligent agent can access the knowledge base through the interface, perform offline and online knowledge retrieval, and extract knowledge that is highly relevant to the user input as the output basis for reasoning, obtain output results, and provide more comprehensive answers.

[0087] 3. Retrieval Enhancement Generation

[0088] When the intelligent agent retrieves knowledge from the WEB knowledge base and local knowledge base based on processing user input and considering contextual information, it can also collect highly timely and relevant information based on retrieval enhancement generation technology.

[0089] 4. Output safety check

[0090] The present invention sets up a security check list in the command line intelligent assistance module. Before the intelligent agent outputs the answer, it first checks whether the command in the answer belongs to a high-risk level. For high-risk level commands, a warning prompt message is given at the same time when the command is output, and the consequences after the command is run are explained.

[0091] Please combine Figure 2 As shown, based on the above functions, the command line intelligent assistance module implements the following process when making decisions on user commands based on the operation mode and context information:

[0092] Step Sa, the command line intelligent assistance module loads the prompt word template corresponding to the understanding mode by default;

[0093] Step Sb, initializing the agent to enter the understanding mode;

[0094] Step Sc, reading the instruction input by the user from the terminal tool, and determining whether the instruction currently input by the user is in a scripting language;

[0095] Step Sc1: If yes, continue to determine whether the script language is an interactive mode switching instruction: if it is a mode switching instruction, dynamically adjust the prompt word template (corresponding to Figure 2 ), based on the large language model and the prompt word template corresponding to the specified operation mode, rebuild the agent corresponding to the target operation mode and enter the corresponding specified operation mode (corresponding to Figure 2 When the command is not a mode switching command, the command input by the user is directly executed and the step Sd is continued.

[0096] Step Sc2: if not, it is determined that the instruction currently input by the user is a natural language, and the intelligent agent continues to perform search enhancement based on the knowledge base to generate preliminary output results, and the knowledge base includes a WEB knowledge base and a local knowledge base;

[0097] Step Sd: Based on the security check strategy, the preliminary output result is subjected to an output security check, and it is determined whether risk warning information needs to be generated. If necessary, the corresponding risk warning information is generated and output. Specifically, the security check strategy includes a preset risk level, and the risk level of the preliminary output result is determined by the preset risk level. If it is a high risk level, risk warning information is given while outputting, and the consequences of the preliminary output result after running are pointed out;

[0098] Step Se, determining whether a closing operation needs to be performed, if so, the process ends, if not, continuing to step Sc, reading the next instruction input by the user.

[0099] 3. Continuous Optimization Module

[0100] The continuous optimization module includes user feedback data collection function and continuous optimization training function (including reinforcement learning and low-rank fine-tuning). The user feedback data collection function is realized by collecting user feedback data and user conversation context information through the intelligent terminal interaction interface. The continuous optimization training function is realized by optimizing the command line intelligent assistance module based on user feedback data and user conversation context information.

[0101] Specifically, the user data collection function is implemented as follows:

[0102] The application provides an interactive feedback user interface in the intelligent interactive command line terminal of the ubiquitous operating system for industry, which supports feedback modes such as questionnaire surveys, scoring and direct feedback, so as to support users to feedback their satisfaction and experience. Users can answer questionnaires, score and provide feedback through the intelligent terminal interactive interface. Each time a user provides feedback, the continuous optimization module will record the user's feedback data and the user dialogue context information corresponding to the user as training data for subsequent reinforcement learning.

[0103] The specific implementation of continuous optimization training function is as follows:

[0104] The continuous optimization model uses Q-learning reinforcement learning technology to fine-tune the base model of the large language model based on the recorded user feedback data and user conversation context information. The customized low-rank model is obtained, and the customized low-rank model is classified and saved according to the device type of the interactive object. It is used in combination with the base model as a customized large language model for industrial equipment. Since the large language model has a large number of parameters, if a base model is stored for each type of industrial equipment, it will bring huge storage pressure. The model weight matrix is ​​low-rank approximated, so that the model can be fine-tuned to adapt to specific tasks while greatly reducing the number of parameters. Therefore, after the LoRA is fine-tuned based on the user interaction record data, the present application only needs to store one base model and multiple LoRA parameter matrices for specific industrial equipment, which reflects the lightweight and highly customized characteristics of the present application.

[0105] The beneficial effects of the present invention are as follows:

[0106] 1. Intuitive, natural and accurate interaction: With the help of the language understanding and generation capabilities of the large language model, the present invention can process the user's natural language input, parse the natural language and convert it into commands that the corresponding operating system can understand. This not only reduces the user's memory burden, but also makes the command line more intuitive and friendly;

[0107] 2. Accurate and efficient: The present invention takes context information into full consideration and recommends commands to users based on online and offline combined retrieval enhancement technology, and the output has the advantages of accuracy and efficiency;

[0108] 3. Customization: The present invention is targeted at various industrial devices targeted by the ubiquitous operating system, supports hardware devices such as processors, controllers, communicators, and sensing terminals of various architectures in industrial environments, and provides multiple interaction modes such as dialogue mode, generation mode, and understanding mode. On this basis, it collects user usage records and feedback results, and regularly updates based on reinforcement learning technology to achieve customized interaction support for multiple devices in industrial ubiquitous computing scenarios, while achieving continuous evolution and optimization;

[0109] 4. Lightweight: The present invention uses LoRA technology to fine-tune the model, making the model parameters lighter and the deployment simpler.

[0110] The above are only some implementation methods of the present application. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present application. These improvements and modifications should also be regarded as the scope of protection of the present application.

Claims

1. An industry-oriented ubiquitous operating system intelligent interactive command line terminal, characterized in that: include: The intelligent terminal interaction interface is provided by the terminal tool. The context awareness module and the continuous optimization module are respectively connected to the command line intelligent assistance module. The command line intelligent assistance module, the context awareness module and the continuous optimization module are all connected to the intelligent terminal interaction interface. The context perception module is used to obtain user input through the intelligent terminal interactive interface, while continuously collecting context information, and converting the context information and user input into structured data as the input of the intelligent agent and passing it to the command line intelligent assistance module for the command line intelligent assistance module to construct the intelligent agent. The user input includes instructions and operation modes; The command line intelligent assistance module is used to read context information and user input, build an intelligent agent based on a large language model, and combine context information and operation modes in user input to understand the instructions in user input, execute tasks, and perform reasoning and output; The continuous optimization module is used to collect user feedback data and user dialogue context information through the intelligent terminal interaction interface, and optimize the command line intelligent assistance module based on the user feedback data and user dialogue context information; the context information includes: interactive object hardware context information, operating system related context information, command line working environment context information and user dialogue context information; The interactive object hardware context information is collected by the context awareness module from the interactive object, including the interactive object type, hardware device architecture, and interactive object status; The operating system related context information is collected by the context awareness module from the operating system, including system configuration, system type, system version, environment variables, user permission level and system time; The command line working environment context information is collected by the context-aware module from the running environment, including the current working directory, executed historical commands, configuration files, functions and scripts, command line mode, and input and output redirection; The user dialogue context information is collected by the context awareness module from the intelligent terminal interaction interface, including current input, command parameters, error messages, expected input and interactive prompts.

2. The industry-oriented ubiquitous operating system intelligent interactive command line terminal according to claim 1, characterized in that: The command line intelligent assistance module includes four parts: intelligent agent, knowledge base, retrieval enhancement generation and output security check, which respectively provide intelligent agent construction function, knowledge retrieval function, retrieval enhancement function and security check function. The knowledge base includes two parts: WEB knowledge base and local knowledge base.

3. The industry-oriented ubiquitous operating system intelligent interactive command line terminal according to claim 2, characterized in that: The command line intelligent assistance module implements the following process when making decisions on user commands based on operation mode and context information based on the agent building function, knowledge retrieval function, retrieval enhancement function and security check function: Step Sa, the command line intelligent assistance module loads the prompt word template corresponding to the understanding mode by default; Step Sb, initializing the agent to enter the understanding mode; Step Sc, reading the instruction input by the user from the terminal tool, and determining whether the instruction currently input by the user is in a scripting language; Step Sc1: If yes, continue to determine whether the script language is an interactive mode switching instruction: if it is a mode switching instruction, dynamically adjust the prompt word template according to the mode switching instruction, reconstruct the agent corresponding to the target operation mode based on the large language model and the prompt word template corresponding to the specified operation mode, and enter the corresponding specified operation mode, and continue to execute step Sc; if it is not a mode switching instruction, directly execute the instruction input by the user, and continue to execute step Sd; Step Sc2: if not, it is determined that the instruction currently input by the user is a natural language, and the intelligent agent continues to perform search enhancement based on the knowledge base to generate preliminary output results, and the knowledge base includes a WEB knowledge base and a local knowledge base; Step Sd: Based on the security check strategy, the preliminary output result is subjected to an output security check, and it is determined whether risk warning information needs to be generated. If necessary, the corresponding risk warning information is generated and output. Specifically, the security check strategy includes a preset risk level, and the risk level of the preliminary output result is determined by the preset risk level. If it is a high risk level, risk warning information is given while outputting, and the consequences of the preliminary output result after running are pointed out; Step Se, determining whether a closing operation needs to be performed, if so, the process ends, if not, continuing to step Sc, reading the next instruction input by the user.

4. The industry-oriented ubiquitous operating system intelligent interactive command line terminal according to claim 3, characterized in that: When it is a mode switching instruction, dynamically adjust the prompt word template according to the mode switching instruction, reconstruct the intelligent agent corresponding to the target operation mode and enter the corresponding target operation mode, including: When the target operation mode switched by the mode switching instruction is the dialogue mode, the prompt word template is dynamically adjusted to the prompt word template corresponding to the dialogue mode, and the intelligent agent corresponding to the dialogue mode is rebuilt to enter the dialogue mode; When the target operation mode switched by the mode switching instruction is the generation mode, the prompt word template is dynamically adjusted to the prompt word template corresponding to the generation mode, and the intelligent agent corresponding to the generation mode is reconstructed to enter the generation mode.

5. The industry-oriented ubiquitous operating system intelligent interactive command line terminal according to claim 3, characterized in that: The reconstructing of the intelligent agent corresponding to the target operation mode comprises: Based on the large language model and the prompt word template corresponding to the target operation mode, an intelligent agent corresponding to the target operation mode is constructed. The large language model includes a base model with GLM as the decision base and a customized low-rank model with user personalized settings.

6. The industry-oriented ubiquitous operating system intelligent interactive command line terminal according to claim 3, characterized in that: The command line intelligent assistance module provides the RAG functional interface, through which the intelligent agent accesses the knowledge base.

Citation Information

Patent Citations

  • Intelligent agent intention understanding interaction system, method and device

    CN118607535A

  • Contextual knowledge summarization with large language models

    US20240346255A1