Method, device and equipment for model configuration and storage medium
By obtaining and managing model configuration information, allowing users to use custom models in applications, it solves the problem that users find it difficult to introduce custom models in the existing technology, and improves application performance and flexibility.
Patent Information
- Application Number
- CN202311553610.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-11-20
- Publication Date
- 2024-11-22
- Estimated Expiration
- 2043-11-20
AI Technical Summary
In the prior art, when creating applications or customizing functions, it is difficult for users to introduce custom models, resulting in limited application performance and flexibility and cannot meet the model needs of different users.
By obtaining model configuration information related to model calls, it provides it to the application to define functions, allowing users to add and manage custom models, and calling models to perform tasks based on user configuration information.
It realizes the use of user-defined models, meets the model needs of different application scenarios, and improves application performance and flexibility.
Smart Images

Figure CN119002980A_ABST
Abstract
Description
Technical Field
[0001] Example embodiments of the present disclosure generally relate to the field of computers, and more particularly, to methods, devices, apparatuses, and computer-readable storage media for model configuration. Background Art
[0002] With the rapid development of Internet technology, the Internet has become an important platform for people to obtain and share content. Users can access the Internet through various applications to enjoy various services. Terminal devices present corresponding content through the user interface of the application and interact with users and provide services to users. With the development of machine learning technology, it is also expected to use various models to perform various functions or tasks required in the application. Summary of the invention
[0003] In a first aspect of the present disclosure, a method for model configuration is provided. The method includes: obtaining first model configuration information related to the call of a first model, the first model configuration information at least indicating parameter information for calling the first model; and providing the first model to a first application based on the first model configuration information for defining at least one type of function in the first application. When the first model is selected for defining a first function in the first application, the first model is called based on the model configuration information to perform at least part of the tasks of the first function.
[0004] In a second aspect of the present disclosure, a device for model configuration is provided. The device includes: a configuration acquisition module configured to acquire first model configuration information related to the call of a first model, the first model configuration information at least indicating parameter information for calling the first model; and a model providing module configured to provide the first model to a first application based on the first model configuration information for defining at least one type of function in the first application; wherein, when the first model is selected for defining a first function in the first application, the first model is called based on the model configuration information to perform at least part of the task of the first function.
[0005] In a third aspect of the present disclosure, an electronic device is provided. The device includes at least one processing unit; and at least one memory, the at least one memory is coupled to the at least one processing unit and stores instructions for execution by the at least one processing unit. When the instructions are executed by the at least one processing unit, the device executes the method of the first aspect.
[0006] In a fourth aspect of the present disclosure, a computer-readable storage medium is provided, wherein a computer program is stored on the computer-readable storage medium, and the computer program can be executed by a processor to implement the method of the first aspect.
[0007] It should be understood that the content described in this section is not intended to limit the key features or important features of the embodiments of the present disclosure, nor is it intended to limit the scope of the present disclosure. Other features of the present disclosure will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS
[0008] The above and other features, advantages and aspects of the embodiments of the present disclosure will become more apparent with reference to the following detailed description in conjunction with the accompanying drawings. In the accompanying drawings, the same or similar reference numerals represent the same or similar elements, wherein:
[0009] Figure 1 A schematic diagram showing an example environment in which embodiments of the present disclosure can be implemented;
[0010] Figure 2 A schematic diagram showing an example page for model configuration according to some embodiments of the present disclosure;
[0011] Figure 3 A schematic diagram showing an example model list page according to some embodiments of the present disclosure is shown;
[0012] Figure 4A A schematic diagram showing an example page for selecting a model in a plug-in definition according to some embodiments of the present disclosure;
[0013] Figure 4B A schematic diagram showing an example page for selecting a model in a scene definition according to some embodiments of the present disclosure;
[0014] Figure 5 A flowchart showing a process for model configuration according to some embodiments of the present disclosure is shown;
[0015] Figure 6 A block diagram showing an apparatus for model configuration according to some embodiments of the present disclosure; and
[0016] Figure 7 A block diagram of an electronic device in which one or more embodiments of the present disclosure may be implemented is shown. DETAILED DESCRIPTION
[0017] Embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. Although certain embodiments of the present disclosure are shown in the accompanying drawings, it should be understood that the present disclosure can be implemented in various forms and should not be construed as being limited to the embodiments set forth herein. On the contrary, these embodiments are provided to provide a more thorough and complete understanding of the present disclosure. It should be understood that the drawings and embodiments of the present disclosure are only for exemplary purposes and are not intended to limit the scope of protection of the present disclosure.
[0018] In the description of the embodiments of the present disclosure, the term "including" and similar terms should be understood as open inclusion, that is, "including but not limited to". The term "based on" should be understood as "based at least in part on". The term "one embodiment" or "the embodiment" should be understood as "at least one embodiment". The term "some embodiments" should be understood as "at least some embodiments". Other explicit and implicit definitions may also be included below.
[0019] Herein, unless explicitly stated, executing a step “in response to A” does not mean executing the step immediately after “A” but may include one or more intermediate steps.
[0020] It is understandable that the data involved in this technical solution (including but not limited to the data itself, the acquisition, use, storage or deletion of the data) shall comply with the requirements of relevant laws, regulations and relevant provisions.
[0021] It is understandable that before using the technical solutions disclosed in the various embodiments of the present disclosure, the types, scopes of use, usage scenarios, etc. of the information involved in the present disclosure should be informed to relevant users and their authorization should be obtained in an appropriate manner in accordance with relevant laws and regulations. The relevant users may include any type of right holders, such as individuals, enterprises, and groups.
[0022] For example, in response to receiving an active request from a user, a prompt message is sent to the relevant user to clearly prompt the relevant user that the operation requested to be performed will require obtaining and using the information of the relevant user, so that the relevant user can independently choose whether to provide information to software or hardware such as an electronic device, application, server or storage medium that executes the operation of the technical solution of the present disclosure based on the prompt message.
[0023] As an optional but non-limiting implementation, in response to receiving an active request from a relevant user, a prompt message is sent to the relevant user, for example, in the form of a pop-up window, in which the prompt message may be presented in text form. In addition, the pop-up window may also carry a selection control for the user to select "agree" or "disagree" to provide information to the electronic device.
[0024] It is understandable that the above notification and the process of obtaining user authorization are merely illustrative and do not constitute a limitation on the implementation of the present disclosure. Other methods that meet relevant laws and regulations may also be applied to the implementation of the present disclosure.
[0025] Figure 1A schematic diagram of an example environment 100 in which embodiments of the present disclosure can be implemented is shown. In the example environment 100, a digital assistant 120 and an application 125 are installed in a terminal device 110. A user 140 can interact with the digital assistant 120 and the application 125 via the terminal device 110 and / or an attached device of the terminal device 110.
[0026] In some embodiments, the digital assistant 120 and the application 125 can be downloaded and installed on the terminal device 110. In some embodiments, the digital assistant 120 and the application 125 can also be accessed through other means, such as through a web page. Figure 1 In the environment 100 , in response to the application 125 being started, the terminal device 110 can present the respective pages 150 of the digital assistant 120 and the application 125 .
[0027] Applications 125 include, but are not limited to, one or more of the following: chat applications (also known as instant messaging applications), document applications, audio and video conferencing applications, email applications, task applications, calendar applications, objectives and key results (OKR) applications, etc. Figure 1 A single application is shown in the figure, but in fact, multiple applications can be installed on the terminal device 110. In some embodiments, the application 125 may include a multi-functional collaboration platform, such as an office collaboration platform (also called an office suite) that can provide integration of multiple types of applications or components to facilitate people to carry out office work, communication and other activities. In the multi-functional collaboration platform, people can start different applications or components as needed to complete corresponding information processing, sharing, communication, etc.
[0028] The application 125 may provide a content entity 126. The content entity 126 may be a content instance created by the user 140 or other users on the application 125. For example, depending on the type of the application 125, the content entity 126 may be a document (e.g., a word document, a pdf document, a presentation, a spreadsheet document, etc.), an email, a message (e.g., a conversation message on an instant messaging application), a calendar, a schedule, a task, an audio, a video, an image, etc.
[0029] In some embodiments, the digital assistant 120 can be provided by a separate application, or can be integrated into an application 120 that can provide content entities. The application for providing the client interface of the digital assistant can correspond to a single-function application or a multi-function collaboration platform, such as an office suite or other collaboration platform that can integrate multiple components. In some embodiments, the digital assistant 120 supports the use of plug-ins. Each plug-in can provide one or more functions of the application. Such plug-ins include, but are not limited to, one or more of the following: search plug-ins, contact plug-ins, message plug-ins, document plug-ins, table plug-ins, mail plug-ins, calendar plug-ins, schedule plug-ins, task plug-ins, and the like.
[0030] The digital assistant 120 is an intelligent assistant of the user, which has intelligent dialogue and information processing capabilities. In an embodiment of the present disclosure, the digital assistant 120 is used to interact with the user 140 to assist the user 140 in using a terminal device or application. An interaction window with the digital assistant 120 may be presented in the client interface. In the interaction window, the user 140 can communicate with the digital assistant 120 by inputting natural language to instruct the digital assistant to assist in completing various tasks, including operations on the content entity 126.
[0031] In some embodiments, the digital assistant 120 can be included in the contact list of the current user 140 in the office suite as a contact of the user 140, or included in the information flow of the chat component. In some embodiments, the user 140 has a corresponding relationship with the digital assistant 120. For example, the first digital assistant corresponds to the first user, the second digital assistant corresponds to the second user, and so on. In some embodiments, the first digital assistant can correspond uniquely to the first user, the second digital assistant can correspond uniquely to the second user, and so on. That is, the first digital assistant of the first user can be specific to or exclusive to the first user. For example, in the process of the first digital assistant providing assistance or service to the first user, the first digital assistant can use its historical interaction information with the first user, the data authorized by the first user that it can access, and the current interaction context with the first user. If the first user is an individual or an individual, the first digital assistant can be regarded as a personal digital assistant. It can be understood that in the disclosed embodiments, the first digital assistant is based on the authorized access to the data to which the permission is granted by the first user. It should be understood that "uniquely corresponding" or similar expressions in the present disclosure are not intended to limit the first digital assistant to be updated accordingly based on the interaction process between the first user and the first digital assistant. Of course, depending on actual application needs, the digital assistant 120 does not have to be specific to the current user 140, but can be a general digital assistant.
[0032] In some embodiments, multiple interaction modes between the user 140 and the digital assistant 120 can be provided, and the multiple interaction modes can be flexibly switched. When a certain interaction mode is triggered, the corresponding interaction area is presented to facilitate the interaction between the user 140 and the digital assistant 120. The user 140 and the digital assistant 120 interact in different ways in different interaction modes, so that it can be flexibly adapted to the interaction needs in different application scenarios.
[0033] In some embodiments, information processing services specific to user 140 can be provided based on historical interaction information between user 140 and digital assistant 120 and / or a data range specific to user 140. In some embodiments, historical interaction information of user 140 interacting with digital assistant 120 in multiple interaction modes can be stored in association with user 140. In this way, in one interaction mode (any one or a designated one of the interaction modes) among the multiple interaction modes, digital assistant 120 can provide services to user 140 based on historical interaction information stored in association with user 140.
[0034] The digital assistant 120 can be called or awakened by an appropriate method (e.g., a shortcut key, button, or voice) to present an interaction window with the user 140. By selecting the digital assistant 120, the interaction window with the digital assistant 120 can be opened. The interaction window may include interface elements for model configuration, such as an input box, a message list, a message bubble, and the like. In other embodiments, the digital assistant 120 can be awakened through an entry control or menu provided in a page, or by inputting a preset instruction.
[0035] In some embodiments, the interaction window between the digital assistant 120 and the user 140 may include a conversation window, such as a conversation window in an instant messaging application or an instant messaging module of a target application. In some embodiments, the interaction window between the digital assistant 120 and the user 140 may include a floating window corresponding to the digital assistant.
[0036] In some embodiments, the digital assistant 120 may support an interactive mode of a conversation window, also referred to as a conversation mode. In this interactive mode, a conversation window between the user 140 and the digital assistant 120 is presented, in which the user 140 and the digital assistant 120 interact through conversation messages. In the conversation mode, the digital assistant 120 may perform tasks according to the conversation messages in the conversation window.
[0037] In some embodiments, the conversation mode between the user 140 and the digital assistant 120 can be called or awakened by an appropriate method (e.g., a shortcut key, a button, or voice) to present a conversation window. By selecting the digital assistant 120, a conversation window with the digital assistant 120 can be opened. The conversation window may include interface elements for model configuration, such as an input box, a message list, a message bubble, and the like.
[0038] In some embodiments, the digital assistant 120 may support an interactive mode of a floating window (or floating window), also referred to as a floating window mode. When the floating window mode is triggered, an operation panel (also referred to as a floating window) corresponding to the digital assistant 120 is presented, and the user 140 may issue instructions to the digital assistant 120 based on the operation panel. In some embodiments, the operation panel may include at least one candidate shortcut instruction. Alternatively or additionally, the operation panel may include an input control for receiving instructions. In floating window mode, the digital assistant 120 may perform tasks according to instructions issued by the user 140 through the operation panel.
[0039] In some embodiments, the floating window mode of the user 140 and the digital assistant 120 can also be called or awakened by an appropriate method (e.g., shortcut keys, buttons, or voice) to present the corresponding operation panel. In some embodiments, the awakening of the digital assistant 120 can be supported in a specific application, such as a document application, to provide interaction in the floating window mode. In some embodiments, in order to trigger the floating window mode to present the operation panel corresponding to the digital assistant 120, an entry control for the digital assistant 120 can be presented in the application interface. In response to detecting a triggering operation for the entry control, it can be determined that the floating window mode is triggered, and the operation panel corresponding to the digital assistant 120 is presented in the target interface area. In some embodiments described below, for ease of discussion, the interaction window between the user and the digital assistant is mainly taken as an example of a session window.
[0040] In some embodiments, the terminal device 110 communicates with the server 130 to provide services for the digital assistant 120 and the application 125. The terminal device 110 can be any type of mobile terminal, fixed terminal or portable terminal, including a mobile phone, a desktop computer, a laptop computer, a notebook computer, a netbook computer, a tablet computer, a media computer, a multimedia tablet, a personal communication system (PCS) device, a personal navigation device, a personal digital assistant (PDA), an audio / video player, a digital camera / camcorder, a television receiver, a radio broadcast receiver, an e-book device, a gaming device, or any combination of the foregoing, including accessories and peripherals of these devices or any combination thereof. In some embodiments, the terminal device 110 can also support any type of interface for the user (such as a "wearable" circuit, etc.). The server 130 can be various types of computing systems / servers that can provide computing power, including but not limited to mainframes, edge computing nodes, computing devices in cloud environments, and the like.
[0041] In some embodiments, some functions of the digital assistant 120 and / or application 125 may be configured to be performed with the aid of one or more models 162-1, 162-2, ... 162-N (collectively or individually referred to as model 162). For example, the digital assistant 120 determines the response to the user based on the output of model 162. The digital assistant 120 will use model 162 to understand the user input and provide a response to the user based on the output of model 162. Each model 162 can run on its own remote server. In some embodiments, model 162 can be a machine learning model, a deep learning model, a learning model, a neural network, etc. In some embodiments, one or more models 162 can be based on a language model (LM). The language model can have question-answering capabilities by learning from a large amount of corpus. The model can also be based on other appropriate types of models.
[0042] It should be understood that the structure and function of the various elements in the environment 100 are described for exemplary purposes only and do not imply any limitation on the scope of the present disclosure.
[0043] With the development of machine learning technology, configuring models to provide various functions in applications will help significantly improve application performance. When creating an application or defining various functions in an application, currently only some system default models can be provided for use. However, these models may not be sufficient to meet user needs. Sometimes users expect to use more powerful or different types of models. Various models are constantly emerging. In application creation or function customization scenarios, some users may expect to introduce more models to configure better applications or application functions.
[0044] According to some embodiments of the present disclosure, an improved scheme for model configuration is proposed. In an embodiment of the present disclosure, first model configuration information related to the call of a first model is obtained, and the first model configuration information at least indicates parameter information for calling the first model; and the first model is provided to a first application based on the first model configuration information to define at least one type of function in the first application. When the first model is selected to define a first function in the first application, the first model is called based on the model configuration information to perform at least part of the task of the first function.
[0045] In general solutions, users are usually only allowed to select the system's default available models to create applications or customize certain functions of applications, which cannot meet more user needs and limits application performance and flexibility. According to an embodiment of the present disclosure, users are allowed to add one or more custom models. Based on the model configuration information provided by the user, the user-specified custom model can be used in some applications or functions, thereby meeting the specific needs of different users for models in different application scenarios.
[0046] Some example embodiments of the present disclosure will be described in detail below with reference to examples of the accompanying drawings.
[0047] First reference Figures 2 to 4B An example page of is used to describe embodiments of the present disclosure.
[0048] The following will refer to Figure 1 describe Figure 2 And examples of other figures that follow. Figure 2 The client interfaces shown in the following other figures can all be implemented at the terminal device 110. It should be understood that Figures 2 to 4B The pages shown are only examples, and various interface designs may exist in practice. The various graphical elements in the interface may have different arrangements and different visual representations, one or more of which may be omitted or replaced, and one or more other elements may also exist. The embodiments of the present disclosure are not limited in this respect.
[0049] In an embodiment of the present disclosure, a scheme is provided for the user to configure the model to be used. The terminal device 110 is capable of acquiring first model configuration information related to the call of the first model. The first model configuration information at least indicates parameter information for calling the first model. Note that the term "first model" here is only for the convenience of discussion, and the user can configure each model according to the situation.
[0050] After acquiring the first model configuration information related to the call of the first model, the terminal device 110 provides the first model to the first application based on the first model configuration information for defining at least one type of function in the first application. In this way, when the first model is selected to define the first function in the first application, the first model is called based on the model configuration information to perform at least part of the task of the first function. In some embodiments, the model that can be configured can be a model that the user has the authority to call, or a model that is open for use by the user. In some embodiments, the first model can be provided to multiple different applications for defining the functions therein. The at least one type of function to be defined can be any appropriate function in the application that requires or can call a model to perform a task.
[0051] In some embodiments, a global model management service can be provided for users in need, allowing users to add one or more custom models. Models added by users can be selected for use when users define some applications or application functions. The model configuration information provided by the user, such as the parameter information of the model, will be integrated into the corresponding application or function to implement the call to the model. In this way, the specific needs of different users for models in different application scenarios can be met. In some embodiments, the model management service can be implemented as a functional component in a multi-functional collaboration platform, or as a separate application service. Users can use the model management service to manage the models they configure.
[0052] Figure 2 A schematic diagram of an example page 200 for model configuration according to some embodiments of the present disclosure is shown. Page 200 may be a first page for adding a model. Via the first page, the terminal device 110 may obtain first model configuration information input by a user. The provision of the first model is based on receiving a model addition confirmation for the first model configuration information. The first model configuration information at least indicates parameter information for calling the first model, so that the model can call the first model for processing based on the configured parameter information when it is selected to define a certain function.
[0053] In some embodiments, the parameter information in the first model configuration information may include a request link for requesting to call the first model. The request link may be, for example, Figure 2 By configuring the request link, when a function needs to call the first model, the model input provided by the function can be provided to the first model via the request link of the first model for processing. The request link of the first model can be as follows: Figure 2 The form of the URL shown, or any other form suitable for indicating the request address of the first model.
[0054] In some embodiments, the parameter information in the first model configuration information may include a request method for requesting to call the first model. The request method may be, for example, Figure 2 The request method 240 is provided in the input box corresponding to the request method 240 in the page 200 of the embodiment. The request method refers to a method for requesting a device (e.g., a server) running the first model to call the first model. In one example, the request method may include a POST method, which is used to submit data to a specific request chain for processing the request, and the submitted data may be defined as the input of the function to use the model. The data may be included in the request body.
[0055] In some embodiments, alternatively or additionally, the parameter information in the first model configuration information may include a request header for requesting to call the first model. The request header refers to the header in the message sent to the request link. The request header may be, for example, Figure 2 The key-value input boxes 270 and 272 corresponding to the request header in page 200 are provided. The user can define one or more types of information that need to be added to the request header when calling the first model. For example, depending on the specific requirements of the model call, the user can configure that the user's authentication information needs to be carried in the request header each time the first model is called to achieve a successful call. In addition to the authentication information, the request header can also define the application program interface (API) for the user to call the first model and other information that needs to be carried in the request header. In some embodiments, if the call of the model does not require user authentication or a specified API, then the request header may not be provided in the first model configuration information.
[0056] In some embodiments, alternatively or additionally, the parameter information in the first model configuration information may include at least one query parameter of the first model, and the at least one query parameter is included in the call request to the first model. The query parameter may be, for example, Figure 2 The query parameters are provided by key-value input boxes 260 and 262 corresponding to the query parameters in the page 200 of the example. The query parameters can specify specific query information of the first model in the call of the first model, for example, the version parameter of the first model to be called, one or some operating parameters of the first model, etc. For different model services, the query parameters configured by the user are supported when calling. After the query parameters are configured, the first model can run subsequent call requests according to the query parameters.
[0057] In some embodiments, alternatively or additionally, the parameter information in the first model configuration information may include parameters related to whether the first model supports function calling. The parameters related to whether function calling is supported may be, for example, Figure 2 The model supporting function calls has the ability to call external functions. Such a model can more flexibly select different atomic functional components (e.g., corresponding to different functions) to complete the provision of corresponding functional services when used. For example, if a certain function is associated with multiple plug-ins (i.e., atomic functional components), the model supporting function calls can help analyze and determine which plug-in among the multiple plug-ins needs to be called to complete the task each time the task is executed.
[0058] In some embodiments, the first model configuration information may also include the name and / or description of the first model, for example, Figure 2The first model configuration information may include a request body of the first model and / or a response body of the first model. The request body and the response body of the first model may be provided in the page 200 of the embodiment of the present invention. The model name and the description may be presented to the current user or other users for understanding the capabilities of the model or other related information. In some embodiments, the first model configuration information may also include a request body of the first model and / or a response body of the first model. The request body and the response body of the first model may be provided, for example, by Figure 2 The boxes 280 and 282 corresponding to the request body and the response body are provided respectively in page 200 of FIG. The request body is used to indicate the format of the entire request content when the request calls the first model, and the response body is used to indicate the format of the entire response content when the model returns a response. In some embodiments, the request body and the response body need to follow the corresponding protocol. In some embodiments, depending on the application capabilities, examples of the request body and the response body can be provided in page 200 to instruct the user to configure the back-end service of the model with reference to the format of these examples. In some embodiments, the user can also be allowed to adjust or define the request body and the response body.
[0059] After receiving the first model configuration information in page 200, a model addition confirmation for the first model configuration information may be received through the “Add” control 292. The added first model can be provided to one or more applications (including the first application) for defining at least one type of function in the first application.
[0060] In some embodiments, the user may be allowed to add multiple models in the above manner. In some embodiments, for the added models, a model list may be provided for the user to view and manage the models. Figure 3 FIG. 3 is a schematic diagram of an example model list page 300 according to some embodiments of the present disclosure. Figure 3 As shown, in the model list page 300 (sometimes also referred to as the "third page" in this document), the model list page 300 includes an added model list, which includes relevant information of one or more models added by the user, such as model name, model description, whether function call is supported, etc.
[0061] In some embodiments, a model adding control 313 may also be provided on the model list page 300. In response to detecting a trigger on the model adding control, the terminal device 110 receives a model adding request and provides a first page (eg, Figure 2 Of course, in addition to being able to trigger the presentation of the page 200 for adding models in the model list page 300, the trigger entry of the page 200 can also be configured in any other appropriate page. The embodiments of the present disclosure are not limited in this respect.
[0062] In some embodiments, for an added model, the user may also be allowed to set the enabled or disabled state of the model. Figure 3 In the model list page 300, for each added model, an enable setting control 350 can be provided for setting the enable or disable state of the corresponding model. If the terminal device 110 can receive a state setting for the first model, the state setting indicates the enable state or disable state of the first model. In some embodiments, after the model is successfully added, the default state is disabled, and the user can manually enable / disable it. In some embodiments, each added model including the first model can be provided for defining at least one type of function when in an enabled state.
[0063] In some embodiments, the added model may be determined as a default model. The default model refers to the model that is selected by default for use in the application or function associated with the user. Figure 3 In the model list page 300 of , a "default model" option 360 may be provided for each model that has been added. In some embodiments, only models that support function calls may select the "default model" option. Figure 3 In the example, "Working Model 1" is selected as the default model. For models that do not support function calls, this option is disabled. After the "Default Model" option 360 is selected, the user will additionally see system functions that declare the use of function call models on the client, and these functions will run on this model. Among all custom models that support function calls and are enabled, one, and usually only one, model is selected as the default model. In some embodiments, after the first model that supports function calls is successfully added, the model is automatically designated as the default model, and subsequent models that continue to support function calls are no longer designated by default, but are manually designated according to the user's wishes. If a model that supports function calls is designated as the default model and then disabled, the model that supports function calls and is enabled and ranks first in the added model list will be automatically designated as the default model.
[0064] In some embodiments, for the added model, the user may be allowed to continue editing the model configuration information. Figure 3 As shown, for each model that has been added, a corresponding editing control 330 is provided. In response to detecting that the editing control 330 is triggered, the terminal device 110 receives an editing request for the first model and provides a first page corresponding to the model configuration information (for example, Figure 2Page 200 of the example embodiment). Via the first page, the terminal device 110 may receive an update to the first model configuration information. In some embodiments, some or all of the information in the first model configuration information may be updated. After the editing is completed, the terminal device 110 may receive a model editing confirmation from the user. After the model editing is confirmed, if the first model is selected to define one or more functions in one or more applications, then the first model will be provided for defining the corresponding functions based on the updated model configuration information, and the functions that will be selected for definition will be selected later.
[0065] In some embodiments, the user may also be allowed to delete the added model. Figure 3 As shown, for each model that has been added, a corresponding delete control 340 is provided. In response to detecting that the delete control 340 is triggered, the terminal device 110 receives a delete request for the first model, deletes the first model configuration information of the first model, and the deleted first model is no longer provided for defining at least one type of function.
[0066] The above describes the process of adding a model to be customized. As described above, the added model can be selected to define one or more types of functions in the first application. The function here can be a function that supports user customization in the first application. In some embodiments, in response to receiving a function definition request, the terminal device 110 can provide a second page for defining the first function, and provide a model selection control in the second page. In response to receiving a trigger on the model selection control, the terminal device 110 can present an optional model list, and the optional model list includes at least the first model (and may also include other models added by the user). In response to the selection of the first model in the model list, the first model is indicated in the function definition information of the first function. Based on such function definition information, the first model is called based on the first model configuration information to perform the first function in the operation of the first function. For example, each time a task requiring a model is performed, the first function can pass the model input to the first model through a request link, and receive a response from the first model, including the model output. Depending on the specific requirements of the first model configuration information, the first function can also add information such as information required in the request header, query parameters, etc. in the request body when calling the model.
[0067] The digital assistant is used for interaction with the user. The interaction window between the user and the digital assistant can be presented in the client interface. The interaction window between the user and the digital assistant may include a conversation window, in which the interaction between the user and the digital assistant can be presented in the form of a conversation message. Alternatively or additionally, the interaction window between the user and the digital assistant may also include other types of windows, such as a window in a floating window mode, in which the user can trigger the digital assistant to perform corresponding operations by inputting instructions, selecting shortcut instructions, etc. As an intelligent assistant, the digital assistant has intelligent dialogue and information processing capabilities. In the interaction window, the user enters an interactive message, and the digital assistant provides a reply message in response to the user input. The client interface for providing a digital assistant may correspond to a single-function application or a multi-function collaboration platform, such as an office suite or other collaboration platform capable of integrating multiple components.
[0068] In some embodiments, the first application may include a digital assistant application, such as Figure 1 The digital assistant 120 shown. In some embodiments, for a digital assistant application, the functions that can be defined by the user selection model may include, but are not limited to: a plug-in function in the digital assistant application, and / or a scene function in the digital assistant application. A plug-in function is defined as performing a corresponding task. A scene function is defined as performing at least one task related to a scene, and each scene is associated with at least one plug-in function.
[0069] Some applications can provide integrated functions of different plug-ins. In addition to being able to have free conversations with the digital assistant, users can also use natural language instructions to enable the digital assistant to use different plug-ins to complete some more complex business-related operations of the application, such as creating documents, inviting schedules, creating tasks, etc. For example, the search plug-in is used to obtain messages and data that match the search keywords, and the document plug-in is used to perform document-related tasks such as creating documents. In the interaction between the user and the digital assistant, the plug-in to be used can be selected by the user or determined by the digital assistant independently. The selected plug-in will be used in the interaction between the user and the digital assistant.
[0070] In some embodiments, the digital assistant application may also allow users to customize plug-ins. The plug-ins created by users may be used by themselves or published to other users.
[0071] Figure 4AA schematic diagram of an example page 402 for selecting a model in a plug-in definition according to some embodiments of the present disclosure is shown. Via page 402, a user may be allowed to configure the plug-in creation information of the plug-in. The plug-in creation information may include basic information such as a plug-in icon, a plug-in name 412, a plug-in description 422, and may also include a model selection control 432 corresponding to the plug-in, and a data set selection control 442 (for defining a data set 442 to be used by the plug-in). Through the model selection control 432, the user may be allowed to select a model 432 to be used in the operation of the plug-in. After the model selection control 432 is triggered, one or more models added by the user may be provided for the user to use. In the case where the user does not specify, a default model may be selected to create the current plug-in. After the triggering of the "Create" control 452 is detected, the corresponding plug-in may be created based on the plug-in creation information received in page 402. The created plug-in may be selected during the interaction between the user and the digital assistant to support the interaction.
[0072] In some embodiments, the digital assistant also provides a scenario function. The scenario here refers to a collection of tasks of the same type, that is, one scenario corresponds to multiple tasks of the same type. One or more scenarios can be configured with corresponding configuration information to perform tasks of the corresponding type. For ease of understanding, the scenarios used in the interaction between the user and the digital assistant are briefly introduced.
[0073] The configuration information of the scene includes at least one of the following: scene setting information, plug-in information. The scene setting information is used to describe information related to the corresponding scene. The scene setting information of the scene can affect the digital assistant's reply to the user to a certain extent, or be used to determine the digital assistant's reply to the user. In some embodiments, the scene setting information is used to construct a prompt word (prompt) input to provide to the model used in the corresponding scene. The digital assistant's reply to the user is based on the output of the model. The scene setting information of the scene may, for example, include a description of the corresponding type of task, the digital assistant's reply style in the scene, the definition of the workflow to be executed in the corresponding scene, the definition of the digital assistant's reply format in the corresponding scene, and so on. In some embodiments, the digital assistant will use the model to understand the user input and provide a reply to the user based on the output of the model. The model used by the digital assistant can run locally on the terminal device 110 or on a remote server. By using the scene setting information to construct a part of the prompt word input of the model, the model can be guided to complete the task to be achieved in the corresponding scene.
[0074] The plug-in information indicates at least one plug-in for performing the task in the corresponding scenario. Through the plug-in information of the scenario, the plug-in to be used in the corresponding scenario can be configured. In some embodiments, in the corresponding scenario, during the operation of the plug-in, the plug-in can also call the model to complete the corresponding task. In some embodiments, a plug-in can also call the open interface provided by other applications (for example, documents, calendars, meetings, etc.) to complete the corresponding task, such as modifying documents, creating schedules, summarizing meetings, etc.
[0075] In some embodiments, the configuration information of the scene may also include a scene name, description information of the scene, and the like. In some embodiments, the terminal device 110 may provide a message card to the user in the conversation window, and at least part of a set of scenes may be presented in the message card. The terminal device 110 may present the scene name and / or description information of the scene of the corresponding scene in association with the scene in the message card. For example, the user may select a scene that meets his or her needs based on the scene name and / or description information of the scene presented in the message card.
[0076] In some embodiments, the configuration information of the scene may also include, but is not limited to: the selected model (the model here is called to determine the response to the user in the corresponding scene), scene guidance information (the scene guidance information is presented to the user after the corresponding scene is selected), at least one recommended question for the digital assistant (at least one recommended question is presented to the user for selection after the corresponding scene is selected), any combination of one or more of the foregoing, and the like. The scene guidance information may, for example, be descriptive information about a task instance that can be performed in the scene. In some embodiments, the scene setting information and configuration information of the scene may be configured, for example, in a natural language manner, so that the scene creator can easily constrain the output of the model and configure a variety of scenes.
[0077] In some embodiments, the digital assistant application may also allow users to customize scenes. Scenes created by users may be used by themselves or published to other users.
[0078] Figure 4BA schematic diagram of an example page 404 for selecting a model in a scene definition according to some embodiments of the present disclosure is shown. Through page 404, a user may be allowed to configure scene creation information of a scene. The scene creation information may include basic information such as a scene name 410, a scene setting 420, and may also include a model selection control 430 corresponding to the scene, a plug-in selection control 440, and the like. Through the model selection control 430, the user may be allowed to select a model 430 to be used in the scene operation. After the model selection control 430 is triggered, one or more models added by the user may be provided for the user to use. In the case where the user does not specify, a default model may be selected to create the current scene. Through the plug-in selection control 440, the user may be allowed to select one or more plug-ins to be used in the scene operation. After the plug-in selection control 440 is triggered, one or more plug-ins available to the user may be provided for selection. After the triggering of the "Create" control 434 is detected, the corresponding scene may be created based on the scene creation information received in page 404. The created scene may be selected during the interaction between the user and the digital assistant to support the interaction.
[0079] It should be understood that some embodiments of the present disclosure are described above in conjunction with the specific examples in the drawings, but these specific examples do not limit the scope of the embodiments of the present disclosure. The described embodiments can also be implemented in various other variations.
[0080] Figure 5 FIG. 5 is a flowchart of a process 500 for model configuration according to some embodiments of the present disclosure. The process 500 may be implemented at the terminal device 110. Figure 1 Process 500 is described.
[0081] In block 510 , the terminal device 110 obtains first model configuration information related to calling of the first model, where the first model configuration information at least indicates parameter information used to call the first model.
[0082] At block 520, the first model is provided to the first application based on the first model configuration information for defining at least one type of function in the first application. When the first model is selected to define the first function in the first application, the first model is called based on the model configuration information to perform at least part of the tasks of the first function.
[0083] In some embodiments, obtaining the first model configuration information includes: in response to receiving a model adding request, providing a first page for adding a model; and obtaining the first model configuration information via the first page. In some embodiments, providing the first model configuration information is based on receiving a model adding confirmation for the first model configuration information.
[0084] In some embodiments, process 500 also includes, in response to receiving a function definition request, providing a second page for defining a first function, providing a model selection control in the second page; in response to receiving a trigger on the model selection control, presenting a list of selectable models, the list of selectable models including at least a first model; and in response to selection of the first model in the model list, indicating the first model in the function definition information of the first function, wherein the first model is called based on the first model configuration information to execute the first function during the operation of the first function.
[0085] In some embodiments, the parameter information in the first model configuration information includes at least one of the following: a request link for requesting to call the first model, a request method for requesting to call the first model, a request header for requesting to call the first model, at least one query parameter of the first model, at least one query parameter included in the call request to the first model, or whether the first model supports function calls.
[0086] In some embodiments, the first model configuration information further indicates: a name of the first model, and a description of the first model.
[0087] In some embodiments, process 500 further includes: providing a third page, the third page including an added model list, the added model list including at least one of a name and a description of the first model.
[0088] In some embodiments, process 500 further includes receiving a state setting for the first model, the state setting indicating an enabled state or a disabled state of the first model, wherein the first model can be provided for defining at least one type of functionality when in the enabled state.
[0089] In some embodiments, the first application includes a digital assistant application.
[0090] In some embodiments, at least one type of function includes: a plug-in function in a digital assistant application, where the plug-in function is defined as performing a corresponding task, and a scene function in a digital assistant application, where the scene function is defined as performing at least one task related to a scene, and each scene is associated with at least one plug-in function.
[0091] In some embodiments, process 500 also includes: in response to receiving an edit request for the first model, providing a first page; receiving an update to the first model configuration information via the first page; and in response to receiving a model edit confirmation, providing the first model for defining at least one type of functionality based on the updated model configuration information.
[0092] In some embodiments, the process 500 further includes: in response to receiving a deletion request for the first model, deleting first model configuration information of the first model, whereby the deleted first model is no longer provided for defining at least one type of functionality.
[0093] Figure 6 A block diagram of an apparatus 600 for model configuration according to some embodiments of the present disclosure is shown. The apparatus 600 may be implemented in or included in the terminal device 110, for example. Each module / component in the apparatus 600 may be implemented by hardware, software, firmware, or any combination thereof.
[0094] As shown in the figure, the device 600 includes a configuration acquisition module 610, which is configured to acquire first model configuration information related to the call of the first model, and the first model configuration information at least indicates parameter information used to call the first model. The device 600 also includes a model providing module 620, which is configured to provide the first model to a first application based on the first model configuration information, so as to define at least one type of function in the first application. When the first model is selected to define a first function in the first application, the first model is called based on the model configuration information to perform at least part of the task of the first function.
[0095] In some embodiments, the configuration acquisition module 610 includes: a first page providing module configured to provide a first page for adding a model in response to receiving a model adding request; and an information acquisition module via a page configured to acquire first model configuration information via the first page. In some embodiments, the provision of the first model configuration information is based on receiving a model adding confirmation for the first model configuration information.
[0096] In some embodiments, the device 600 also includes: a second page providing module, configured to provide a second page for defining the first function in response to receiving a function definition request, and provide a model selection control in the second page; a model list providing module, configured to present an optional model list in response to receiving a trigger for the model selection control, the optional model list including at least the first model; and a model indication module, configured to indicate the first model in the function definition information of the first function in response to selection of the first model in the model list, and the first model is called based on the first model configuration information to execute the first function during the operation of the first function.
[0097] In some embodiments, the parameter information in the first model configuration information includes at least one of the following: a request link for requesting to call the first model, a request method for requesting to call the first model, a request header for requesting to call the first model, at least one query parameter of the first model, at least one query parameter included in the call request to the first model, or whether the first model supports function calls.
[0098] In some embodiments, the first model configuration information further indicates: a name of the first model, and a description of the first model.
[0099] In some embodiments, the apparatus 600 further includes: a third page providing module configured to provide a third page, the third page including a list of added models, the list of added models including at least one of the name and description of the first model.
[0100] In some embodiments, the device 600 also includes: a setting receiving module configured to receive a status setting for the first model, the status setting indicating an enabled state or a disabled state of the first model, wherein the first model can be provided for defining at least one type of function when in the enabled state.
[0101] In some embodiments, the first application includes a digital assistant application.
[0102] In some embodiments, at least one type of function includes: a plug-in function in a digital assistant application, where the plug-in function is defined as performing a corresponding task, and a scene function in a digital assistant application, where the scene function is defined as performing at least one task related to a scene, and each scene is associated with at least one plug-in function.
[0103] In some embodiments, the device 600 also includes: an editing provision module, configured to provide a first page in response to receiving an edit request for the first model; a model update module, configured to receive updates to the first model configuration information via the first page; and a function update module, configured to provide the first model for defining at least one type of function based on the updated model configuration information in response to receiving a model editing confirmation.
[0104] In some embodiments, the device 600 also includes: an information deletion module, configured to delete first model configuration information of the first model in response to receiving a deletion request for the first model, and the deleted first model is no longer provided for defining at least one type of function.
[0105] It should be understood that one or more steps in the above method can be performed by a suitable electronic device or a combination of electronic devices. Such an electronic device or a combination of electronic devices may include, for example, Figure 1The server 130, the terminal device 110 and / or the combination of the server 130 and the terminal device 110.
[0106] Figure 7 1 shows a block diagram of an electronic device 700 in which one or more embodiments of the present disclosure may be implemented. It should be understood that Figure 7 The electronic device 700 shown is merely exemplary and should not constitute any limitation on the functionality and scope of the embodiments described herein. Figure 7 The electronic device 700 shown can be used to implement Figure 1 The terminal device 110 and / or Figure 6 The device 600 is shown.
[0107] like Figure 7 As shown, the electronic device 700 is in the form of a general electronic device. The components of the electronic device 700 may include, but are not limited to, one or more processors or processing units 710, a memory 720, a storage device 730, one or more communication units 740, one or more input devices 750, and one or more output devices 760. The processing unit 710 may be an actual or virtual processor and is capable of performing various processes according to a program stored in the memory 720. In a multi-processor system, multiple processing units execute computer executable instructions in parallel to improve the parallel processing capability of the electronic device 700.
[0108] The electronic device 700 typically includes a plurality of computer storage media. Such media can be any available media accessible to the electronic device 700, including but not limited to volatile and non-volatile media, removable and non-removable media. The memory 720 can be a volatile memory (e.g., register, cache, random access memory (RAM)), a non-volatile memory (e.g., read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory) or some combination thereof. The storage device 730 can be a removable or non-removable medium, and can include a machine-readable medium, such as a flash drive, a disk, or any other medium, which can be used to store information and / or data and can be accessed within the electronic device 700.
[0109] The electronic device 700 may further include additional removable / non-removable, volatile / non-volatile storage media. Figure 7As shown in , a disk drive for reading or writing from a removable, non-volatile disk (e.g., a "floppy disk") and an optical drive for reading or writing from a removable, non-volatile optical disk may be provided. In these cases, each drive may be connected to the bus (not shown) by one or more data media interfaces. The memory 720 may include a computer program product 725 having one or more program modules that are configured to perform various methods or actions of various embodiments of the present disclosure.
[0110] The communication unit 740 implements communication with other electronic devices through a communication medium. Additionally, the functions of the components of the electronic device 700 can be implemented with a single computing cluster or multiple computing machines that can communicate through a communication connection. Therefore, the electronic device 700 can operate in a networked environment using a logical connection with one or more other servers, a network personal computer (PC), or another network node.
[0111] The input device 750 may be one or more input devices, such as a mouse, a keyboard, a tracking ball, etc. The output device 760 may be one or more output devices, such as a display, a speaker, a printer, etc. The electronic device 700 may also communicate with one or more external devices (not shown) through the communication unit 740 as needed, such as a storage device, a display device, etc., communicate with one or more devices that allow a user to interact with the electronic device 700, or communicate with any device that allows the electronic device 700 to communicate with one or more other electronic devices (e.g., a network card, a modem, etc.). Such communication may be performed via an input / output (I / O) interface (not shown).
[0112] According to an exemplary implementation of the present disclosure, a computer-readable storage medium is provided, on which computer-executable instructions are stored, wherein the computer-executable instructions are executed by a processor to implement the method described above. According to an exemplary implementation of the present disclosure, a computer program product is also provided, which is tangibly stored on a non-transitory computer-readable medium and includes computer-executable instructions, and the computer-executable instructions are executed by a processor to implement the method described above.
[0113] Various aspects of the present disclosure are described herein with reference to the flowcharts and / or block diagrams of the methods, devices, equipment, and computer program products implemented according to the present disclosure. It should be understood that each box in the flowchart and / or block diagram and the combination of each box in the flowchart and / or block diagram can be implemented by computer-readable program instructions.
[0114] These computer-readable program instructions can be provided to a processing unit of a general-purpose computer, a special-purpose computer, or other programmable data processing device, thereby producing a machine, so that when these instructions are executed by the processing unit of the computer or other programmable data processing device, a device that implements the functions / actions specified in one or more boxes in the flowchart and / or block diagram is generated. These computer-readable program instructions can also be stored in a computer-readable storage medium, and these instructions cause the computer, programmable data processing device, and / or other equipment to work in a specific manner, so that the computer-readable medium storing the instructions includes a manufactured product, which includes instructions for implementing various aspects of the functions / actions specified in one or more boxes in the flowchart and / or block diagram.
[0115] Computer-readable program instructions can be loaded onto a computer, other programmable data processing apparatus, or other device so that a series of operational steps are performed on the computer, other programmable data processing apparatus, or other device to produce a computer-implemented process, so that the instructions executed on the computer, other programmable data processing apparatus, or other device implement the functions / actions specified in one or more boxes in the flowchart and / or block diagram.
[0116] The flow chart and block diagram in the accompanying drawings show the possible architecture, function and operation of the system, method and computer program product according to multiple implementations of the present disclosure. In this regard, each square box in the flow chart or block diagram can represent a part of a module, program segment or instruction, and a part of a module, program segment or instruction includes one or more executable instructions for realizing the logical function of the specification. In some implementations as replacements, the function marked in the square box can also occur in a sequence different from that marked in the accompanying drawings. For example, two continuous square boxes can actually be executed substantially in parallel, and they can sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each square box in the block diagram and / or flow chart, and the combination of the square boxes in the block diagram and / or flow chart can be realized by a special hardware-based system that performs the function or action of the specification, or can be realized by a combination of special hardware and computer instructions.
[0117] The above descriptions of various implementations of the present disclosure are exemplary, non-exhaustive, and not limited to the disclosed implementations. Many modifications and variations will be apparent to those of ordinary skill in the art without departing from the scope and spirit of the described implementations. The selection of terms used herein is intended to best explain the principles of the implementations, practical applications, or improvements to the technology in the market, or to enable other persons of ordinary skill in the art to understand the various implementations disclosed herein.
Claims
1. A method for model configuration, comprising: Acquire first model configuration information related to calling of the first model, where the first model configuration information at least indicates parameter information used to call the first model; as well as Providing the first model to a first application based on the first model configuration information to define at least one type of function in the first application; When the first model is selected to define a first function in the first application, the first model is called based on the model configuration information to perform at least part of the tasks of the first function.
2. The method according to claim 1, wherein obtaining the first model configuration information comprises: In response to receiving a model adding request, providing a first page for adding a model; as well as Obtaining the first model configuration information via the first page, and Wherein the providing of the first model configuration information is based on receiving a model addition confirmation for the first model configuration information.
3. The method according to claim 1, further comprising In response to receiving the function definition request, providing a second page for defining the first function, and providing a model selection control in the second page; In response to receiving a trigger on the model selection control, presenting a selectable model list, the selectable model list including at least the first model; and In response to selection of the first model in the model list, the first model is indicated in function definition information of the first function, and during operation of the first function, the first model is called based on the first model configuration information to execute the first function.
4. The method according to claim 1, wherein the parameter information in the first model configuration information includes at least one of the following: A request link for requesting to call the first model, A request method for requesting to call the first model, A request header for requesting to call the first model, at least one query parameter of the first model, the at least one query parameter being included in a call request to the first model, or Whether the first model supports function calls.
5. The method according to claim 1, wherein the first model configuration information further indicates: The name of the first model, Description of the first model, The request body of the first model, The response body of the first model.
6. The method according to claim 5, further comprising: A third page is provided, the third page including an added model list, the added model list including at least one of the name and the description of the first model.
7. The method according to claim 1, further comprising: receiving a state setting for the first model, the state setting indicating an enabled state or a disabled state of the first model, The first model, when in the enabled state, can be provided for defining at least one type of functionality.
8. The method of claim 1, wherein the first application comprises a digital assistant application.
9. The method of claim 8, wherein the at least one type of functionality comprises: The plug-in function in the digital assistant application is defined as performing a corresponding task, The scene function in the digital assistant application is defined as performing at least one task related to the scene, and each scene is associated with at least one plug-in function.
10. The method according to claim 2, further comprising: In response to receiving an edit request for the first model, providing the first page; receiving, via the first page, an update to the first model configuration information; as well as In response to receiving the model edit confirmation, the first model is provided for defining the at least one type of functionality based on the updated model configuration information.
11. The method according to claim 1, further comprising: In response to receiving a deletion request for the first model, the first model configuration information of the first model is deleted, and the deleted first model is no longer provided for defining the at least one type of function.
12. An apparatus for model configuration, comprising: A configuration acquisition module, configured to acquire first model configuration information related to calling the first model, wherein the first model configuration information at least indicates parameter information used to call the first model; as well as a model providing module, configured to provide the first model to a first application based on the first model configuration information, so as to define at least one type of function in the first application; When the first model is selected to define a first function in the first application, the first model is called based on the model configuration information to perform at least part of the tasks of the first function.
13. An electronic device, comprising: at least one processing unit; as well as At least one memory, the at least one memory being coupled to the at least one processing unit and storing instructions for execution by the at least one processing unit, the instructions causing the electronic device to perform the method according to any one of claims 1 to 11 when executed by the at least one processing unit.
14. A computer-readable storage medium having a computer program stored thereon, wherein the computer program can be executed by a processor to implement the method according to any one of claims 1 to 11.
Citation Information
Patent Citations
Generating a customized machine-learning model to perform tasks using artificial intelligence
CN112088386A
Model deployment method and device, computer equipment and storage medium
CN112230911A
AI model deployment method and device and storage medium
CN112394950A
Configured artificial intelligence scene application research and development method and system
CN112529023A
Universal model effect display method and device, equipment and storage medium
CN116225424A
