WO2023087721A1 - Service processing model generation method and apparatus, and electronic device and storage medium - Google Patents

Service processing model generation method and apparatus, and electronic device and storage medium Download PDF

Info

Publication number
WO2023087721A1
WO2023087721A1 PCT/CN2022/102183 CN2022102183W WO2023087721A1 WO 2023087721 A1 WO2023087721 A1 WO 2023087721A1 CN 2022102183 W CN2022102183 W CN 2022102183W WO 2023087721 A1 WO2023087721 A1 WO 2023087721A1
Authority
WO
WIPO (PCT)
Prior art keywords
model
business
file
configuration parameters
information
Prior art date
Application number
PCT/CN2022/102183
Other languages
French (fr)
Chinese (zh)
Inventor
孟宪奎
程强
冯宇波
Original Assignee
北京锐安科技有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 北京锐安科技有限公司 filed Critical 北京锐安科技有限公司
Publication of WO2023087721A1 publication Critical patent/WO2023087721A1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/30Creation or generation of source code
    • G06F8/35Creation or generation of source code model driven
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/10Requirements analysis; Specification techniques
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/70Software maintenance or management
    • G06F8/71Version control; Configuration management

Definitions

  • the embodiments of the present application relate to the technical field of computer applications, for example, to a method, device, electronic device and storage medium for generating a service processing model.
  • This application provides a business processing model generation method, device, electronic equipment, and storage medium to realize the automatic generation of business processing models, reduce the code redundancy of business models, reduce the time cost of model development, and improve business processing efficiency .
  • the embodiment of the present application provides a method for generating a business processing model, the method including:
  • a model processing file is selected according to the model configuration parameters and business basic system information to form a business processing model.
  • the embodiment of the present application also provides an apparatus for generating a business processing model, which includes:
  • the requirement collection module is configured to generate a model description file according to the collected business requirement information
  • the parameter identification module is configured to extract the model configuration parameters in the model description file according to the preset tags
  • the model generation module is configured to select a model processing file to form a business processing model according to the model configuration parameters and business basic system information.
  • the embodiment of the present application further provides an electronic device, the electronic device comprising:
  • a memory configured to store at least one program
  • the at least one processor When the at least one program is executed by the at least one processor, the at least one processor is made to implement the service processing model generation method as described in the first aspect.
  • the embodiment of the present application further provides a computer-readable storage medium, on which a computer program is stored, and when the computer program is executed by a processor, the method for generating a service processing model as described in the first aspect is implemented.
  • Fig. 1 shows the flow chart of the implementation of the business processing model generation method in the related art
  • FIG. 2 is a flow chart of a method for generating a business processing model provided in Embodiment 1 of the present application;
  • FIG. 3 is a flow chart of a method for generating a business processing model provided in Embodiment 2 of the present application;
  • FIG. 4 is a flow chart of a method for generating a business processing model provided in Embodiment 3 of the present application;
  • FIG. 5 is a flow chart of another business processing model generation method provided in Embodiment 3 of the present application.
  • FIG. 6 is a flow chart of another method for generating a business processing model provided in Embodiment 3 of the present application.
  • FIG. 7 is a flow chart of another business processing model generation method provided in Embodiment 3 of the present application.
  • FIG. 8 is a schematic structural diagram of a business processing model generation device provided in Embodiment 4 of the present application.
  • FIG. 9 is a schematic structural diagram of an electronic device provided in Embodiment 5 of the present application.
  • FIG. 1 shows the flow chart of the realization of the business processing model generation method in the related technology.
  • the realization of the business processing model generation method in related technologies is as follows: first, the real-time streaming data uses flink or spark streaming to write hard code logic, and then uses spark and flink to write hard code in the offline link, and machine learning calculation, Graph computing is written and implemented in a hard-coded manner.
  • the differences in the needs of different users are difficult to maintain through offline code development. With the continuous iteration of product version functions, versions are duplicated and codes are confused, which cannot be effectively merged.
  • This application proposes a method for generating a business processing model, which realizes the automatic generation of the business processing model, effectively reduces the code redundancy of the business model, reduces the time cost of model development to a certain extent, and improves the efficiency of business processing.
  • Fig. 2 is a flow chart of a method for generating a business processing model provided in Embodiment 1 of the present application.
  • This embodiment is applicable to the automatic generation of a business processing model, and the method can be executed by a device for generating a business processing model , the device can be implemented in hardware and/or software, and can generally be configured in electronic equipment. Including the following steps:
  • the business requirement information can be understood as the business information needed to generate the business processing model, which may include the storage location of the business data, the processing flow of the business, and the like.
  • the business demand information can be the calculation of the price of a commodity input by the user on the front page; it can also be the realization of the optimal planning path of the input information; it can also be the realization of the input video transmission method, etc. , which is not limited in this embodiment.
  • the model description file can be understood as a file describing and defining the composition of the business model, and the model description file can include parameters used in the composition of the business processing model, such as input parameters, output parameters, and operators.
  • the generated model description file may be an extensible markup language (EXtensible Markup Language, XML) file.
  • the collected business requirements can be stored in a fixed format by receiving the business requirements input by the user on the front-end page, or by identifying the business requirements based on artificial intelligence for documents, video resources and other materials
  • the file is used as a model description file, and the file format of the model description file is not limited here, and may include an XML file or a custom format file.
  • business requirement information can be collected and stored as a model description file, and the way of collecting business requirement information in this process can include collecting business requirement information by manually inputting or dragging options on the page .
  • the preset tags can be text or special characters with characteristic meanings, and the preset tags can be used to mark different types of parameters in the description file, such as ⁇ model> tags, ⁇ inputs> tags, ⁇ outputs> tags, etc., this implementation Examples are not limited here.
  • Model configuration parameters can be understood as parameters used to generate business processing models. Model configuration parameters can be generated according to the aforementioned business requirement information, and different model configuration parameters can be stored in association with different preset tags.
  • the model configuration parameters may be information such as the computing framework type, model type, and model name in the ⁇ model> tag.
  • the calculation framework type can be spark; the model type can be batch, which is divided into two types: streaming and off-line; the model name can be testabsd.
  • model description file after the model description file is generated according to the collected business requirement information, the model description file must be loaded first, and the model description file can be parsed using preset tags to obtain model configuration parameters.
  • the method of extracting the model configuration parameters in the model description file according to the preset tags may include: by matching the keywords of the preset tags in the model description file, the parameter information after the keywords are extracted as the model configuration of the type corresponding to the keywords Parameters; it can also include the method of using language description information parameters according to the language description model, and then using simulation software to extract; it can also include selecting M computing nodes that store data sets from the blockchain system, and then selecting K Each computing node performs model training, obtains the training results, and finally obtains the model parameters according to the training results of the data set.
  • the business basic system information can be understood as the relevant file information in the business operating system.
  • the business basic system information may be file information in the windows system; it may also be file information in the Linux system, or it may be file information in the ios system, which is not limited in this embodiment. It can be understood that the types of file information executed by different business basic system information are different, and model processing files can be selected according to model configuration parameters and business basic system information to form a business processing model.
  • the model processing file can be understood as source codes generated based on different computing frameworks through parsing and controlling model configuration parameters.
  • the model processing files corresponding to different software development languages are different.
  • different software development languages may have different implementation methods, but their business processing capabilities are the same or similar.
  • different software development languages may be Java language; Python language; C language, etc., which are not limited in this embodiment.
  • the code files implemented by the two languages are different, but their business processing capabilities are the same or similar.
  • the business processing model can be understood as code information finally generated by selecting a model processing file according to model configuration parameters and business basic system information.
  • the service processing model may be a Java archive (Java Archive, jar) package. After the business processing model is formed, the user can use the business processing model to realize the operation of the jar package on different computers and different systems.
  • the method of selecting model processing files to form a business processing model according to the model configuration parameters and business basic system information can be to first generate basic engineering files according to the model information of the model configuration parameters, and then detect the running operating system of the business processing model And determine the business basic system information corresponding to the running operating system, select the matching model processing file according to the business basic system information, and fill the model configuration parameters into the model processing file according to the type to generate the business processing model; you can also obtain multiple parameter combinations , and then combine the sample set and multiple parameters to form corresponding business models, so as to obtain matching processing files according to the business models.
  • the model description file is generated according to the collected business requirement information
  • the model configuration parameters in the model description file are extracted according to the preset tags
  • the model processing file is selected using the model configuration parameters and business basic system information Constitutes a business processing model.
  • the model configuration parameters used in the generation of the business processing model can be accurately obtained, so that the automatic generation of the business processing model can be realized, and the business processing model can be constructed using the model processing file, reducing the number of business processing models
  • the degree of repeated development in the generation process solves the problem of writing hard code offline through online model configuration, which can effectively reduce the code redundancy of the business model and reduce the time cost of model development to a certain extent, thereby improving business processing efficiency.
  • the business processing model generation method adopted effectively solves the problems of duplication of versions, chaotic codes and inability to effectively merge caused by offline writing of hard codes and continuous updating of product version functions.
  • FIG. 3 is a flow chart of a method for generating a service processing model provided in Embodiment 2 of the present application. This embodiment is refined on the basis of the above-mentioned embodiments. Can include the following steps:
  • a model description file may be generated according to collected business requirement information.
  • the steps may be: S310 to S320.
  • the business requirement information input by the user may be the business requirement information input by the user by handwriting, or may be the business requirement information input by the user in the form of dragging or dragging, or may be entered by the user in the form of touch.
  • the input service requirement information does not make a limitation here.
  • the service requirement information input by the user may be monitored on the service requirement collection page.
  • the business requirement collection page can be understood as a page for collecting user service requirement information.
  • the belonging type can be understood as the attribute information of the service requirement information input by the user.
  • the belonging information may be computing framework type information or model type information, which is not limited in this embodiment. Exemplarily, when the belonging information is computing framework type information, it may be flink, spark, etc.; when the belonging information is model type information, it may be framework, type, name, input type, tablename, connection, etc.
  • the business requirement information input by the user needs to be filled into the description file template according to its type. It can be understood that each parameter information in the description file template has a certain binding relationship with the controls in the business requirement information input by the user.
  • the model configuration parameters in the model description file may be extracted according to preset tags.
  • the steps may be: S330 to S340.
  • the keywords of the preset tags can be understood as the keywords in the preset tags.
  • the model tag in the model description file; the inputs tag can also be input in the model description file; the outputs tag can also be output for the model description file. This embodiment is not limited here.
  • keywords of preset tags can be matched in the model description file to extract parameter information after keywords.
  • the parameter information after the keyword is extracted is used as a model configuration parameter of a type corresponding to the keyword.
  • the parameter information can be understood as the parameter information correspondingly filled into the description file template according to the type to generate the model description file.
  • the parameter information after the keyword can be extracted as the model configuration parameter of the corresponding type of keyword.
  • the type corresponding to the keyword may include a model, may also include an input, and may also include an operator, etc., which are not limited in this embodiment.
  • the keywords in the preset tags can be matched in the model description file, and then the parameter information after matching the keywords in the preset tags in the model description file can be extracted and generated as the model configuration of the type corresponding to the keywords parameter.
  • the corresponding types of keywords include at least: model, input, output, and operator.
  • the model can be understood as the processing model of the program code, and the processing logic when processing different business requirement information.
  • the model can contain spark, flag, transformer and other model frameworks.
  • Operators can be understood as pre-set business processing logic.
  • the operator can be related code processing logic for calculating the matching content of related graphics; it can also be related code processing logic for optimal path planning and implementation; it can also be related code processing logic for device detection. The embodiments are not limited here.
  • a service processing model may be formed by selecting a model processing file according to model configuration parameters and basic service system information. The steps may be: S350 to S380.
  • the basic project file can be understood as a file set showing the directory structure, used to store various project files, and the basic project file can be composed of multiple files.
  • Each basic project file corresponds to a piece of disk space, and an address pointing to the corresponding space is provided.
  • a folder of basic project files can include multiple subfolders, and the bottom layer is the file itself.
  • the types of basic project files can be document files, pictures, photo albums, music, video, voice, code files, etc. It should be noted that the bottom layer of the subfolder in the basic project file can realize a complete business processing capability.
  • the basic project file can be generated according to the model information of the model configuration parameters, and the template name of the basic project file can be revised according to the model definition name.
  • the running operating system may be understood as an operating system for compiling and running codes.
  • the running operating system may be a windows operating system, a Linux operating system, or an ios operating system, which is not limited in this embodiment.
  • different running operating systems have different compiling and running commands.
  • the cmd command can be applied to the windows running operating system, and the sh command can be used to run the linux operating system.
  • the service basic system information corresponding to the running operating system can be determined by detecting the running operating system of the service processing model, and the compiling and executing instructions can be dynamically selected according to the detection of the running operating system. After the selection, execute the compiling operation to execute the instruction and compile the code.
  • a matching model processing file can be selected according to the business basic system information for the next step of operation.
  • the matching model processing file is selected according to the basic business system information, and model configuration parameters can be filled into the model processing file according to type to generate a business processing model for reliable and convenient use by users.
  • the service basic system information may be understood as the corresponding service basic system information of different running operating systems.
  • the business processing model can be compiled according to the basic business system information.
  • the commands when compiling the business processing model are also different.
  • the corresponding business basic system information in the windows operating system can use cmd to execute commands to compile related business processing models; and the corresponding business basic system information in the linux operating system can use sh to execute commands to compile related business processing models.
  • the obtained business processing model can be released using model configuration parameters, so that it can run in different business basic systems and realize corresponding execution functions.
  • the method of publishing the business processing model by using the model configuration parameters may be as follows: firstly submit the public dependency package generated by compiling the business processing model to the distributed file system, then identify the computing framework in the model configuration parameters, and follow the calculation framework instance Submit the task manager, and use the task submission manager to process the public dependency package to realize the release of the business processing model; it can also be: firstly use the module to be compiled in the target project as the target module, and determine the operating mode of the target module, and then Obtain the configuration file of the target module in the independent operation mode, and then obtain the target configuration file of the target module in the integrated operation mode, and use the target configuration file to compile and publish the target module, which is not limited in this embodiment.
  • the business demand information is filled into the description file template according to its type to generate a model description file, and the pre-matched model description file is matched in the model description file.
  • Set the keyword of the label and extract the parameter information after the keyword as the model configuration parameter corresponding to the keyword, generate the basic project file according to the model information of the model configuration parameter, detect the operating system of the business processing model and determine the corresponding operating system According to the business basic system information, select the matching model processing file according to the business basic system information, and fill the model configuration parameters into the model processing file according to the type to generate a business processing model.
  • the automatic generation of the business processing model is realized, the matching model processing file is selected according to the business basic system information, and the model configuration parameters are classified according to the Fill in the model processing file to generate a business processing model, reduce the time cost of model development, reduce the code redundancy of the business model, and improve business processing efficiency to a certain extent.
  • model configuration parameters to publish the business processing model, including: submitting the public dependency package generated by compiling the business processing model to the distributed file system; identifying the computing framework in the model configuration parameters, and instantiating the task submission manager according to the computing framework ; Use the task submission manager to process the public dependency package to realize the release of the business processing model.
  • the public dependency package can be understood as a shared package file generated by compiling the business processing model.
  • Common dependencies can represent a package file format.
  • the public dependency package may be a jar package.
  • a distributed file system can be understood as a highly fault-tolerant system. The characteristic of the distributed file system is that it can provide high-throughput data access, which is very suitable for applications on large-scale data sets.
  • the calculation framework may be a calculation framework such as spark or flink, which is not limited in this embodiment.
  • the public dependency package generated by compiling the business processing model is submitted to the distributed file system. It is necessary to detect and identify the computing framework in the model configuration parameters.
  • computing frameworks such as spark and flink
  • the submission task can be divided into two types, one is to submit the public dependency package when the task is submitted, and the other is to submit the public dependency package to the distributed file system first, and then each time the task is submitted, only Submit the incremental content, because the public dependency packages are generally large, and if the task is submitted every time the task is executed, the task startup speed will be very low.
  • the computing framework in the model configuration parameters is detected and identified, and on the premise that the computing framework is determined, the task is submitted and managed according to the instantiation of the computing framework
  • the task submission manager uses the task submission manager to process the public dependency package to realize the release of the business processing model, and publish the business processing model to the system for users to download and use.
  • FIG. 4 is a flow chart of a method for generating a service processing model provided in Embodiment 3 of the present application.
  • the business process model generation method in this embodiment mainly includes a model file analysis engine and code generation technology, model compilation control technology, and task submission control technology.
  • the first is to design the model, then define parameter information according to the model, configure parsing parameter rules, configure platform as a service (Platform as a Service, Paas) component connection operator, configure operation operator, configure output Paas connection component operator, and form a preview model, and compile the model, publish the compiled model, configure model operating parameters, and form an operating model.
  • a service Platinum as a Service, Paas
  • model file parsing engine and code generation technology model compilation control technology and task submission control technology in more detail.
  • Model file analysis and code generation technology in the model file, is composed of three parts: input, operation, and output.
  • model framework represents the model framework
  • spark represents the specific parameters of the framework
  • type represents the type
  • batch represents the specific parameters of the type
  • name represents the name
  • testabsd represents the specific parameters of the name.
  • the model file parsing engine implements model configuration file parsing, extracts the content of the model file and transforms it into a structural object, extracts the content of the operator, and transfers it to the operator for parsing and generating code.
  • FIG. 5 is a flow chart of another method for generating a service processing model provided in Embodiment 3 of the present application. Both the ⁇ model> tag and the ⁇ inputs> tag represent default tags. As shown in Figure 5, the business processing model generation method in this embodiment includes the following steps:
  • model description file Generate a model description file according to the collected business requirement information.
  • the generated model description file is Model Document in XML format, and the structural information is extracted.
  • model engine After the model engine receives the model file, it first parses and loads the model engine file, extracts the attribute information in the ⁇ model> tag, and extracts information such as computing framework type, model type (both streaming and offline), and model name.
  • the model engine transfers the current part of the operator configuration content to the operator object to parse the file content to generate a configuration object, and the model engine realizes code generation through the configuration object.
  • the same control implementation mechanism is adopted for the operation operator and the output operator.
  • FIG. 6 is a flow chart of another method for generating a service processing model provided in Embodiment 3 of the present application. Among them, maven represents the basic project file. As shown in Figure 6, the business processing model generation method in this embodiment includes the following steps:
  • the compilation commands are also different.
  • the cmd command is used in the windows system
  • the sh command is used in the linux operating system.
  • the compilation and execution instructions are dynamically selected.
  • FIG. 7 is a flow chart of another method for generating a service processing model provided in Embodiment 3 of the present application.
  • the public jar package represents a public dependency package.
  • the business processing model generation method in this embodiment includes the following steps:
  • Detect the computing framework mainly to identify whether the computing framework is flink or spark, and select the task submission manager of the specific framework under the premise of determining the computing framework.
  • FIG. 8 is a schematic structural diagram of an apparatus for generating a service processing model provided in Embodiment 4 of the present application.
  • the device for generating a business processing model provided in this embodiment may be realized by software and/or hardware, and may be configured in a server to implement a method for generating a business processing model in the embodiment of the present application. As shown in FIG. 8 , the device may include: a requirement collection module 810 , a parameter identification module 820 and a model generation module 830 .
  • the requirement collection module 810 is configured to generate a model description file according to the collected business requirement information.
  • the parameter identification module 820 is configured to extract the model configuration parameters in the model description file according to preset tags.
  • the model generation module 830 is configured to select a model processing file to form a business processing model according to the model configuration parameters and business basic system information.
  • the requirement collection module generates a model description file according to the collected business requirement information
  • uses the parameter identification module to extract the model configuration parameters in the model description file according to the preset label
  • uses the model generation module according to Model configuration parameters and business basic system information selection model processing files constitute a business processing model.
  • the model configuration parameters used in the generation of the business processing model can be accurately obtained, so that the automatic generation of the business processing model can be realized, and the business processing model can be constructed using the model processing file, reducing the number of business processing models
  • the degree of repeated development in the generation process can reduce the degree of code redundancy and reduce the time cost of model development to a certain extent, thereby improving the efficiency of business processing.
  • the requirement collection module 810 may include:
  • the information input unit is configured to monitor the business demand information input by the user on the business demand collection page.
  • the file generation unit is configured to fill the description file template with the business requirement information according to its type to generate a model description file.
  • the parameter identification module 820 may include:
  • a keyword matching unit is configured to match keywords of the preset tags in the model description file.
  • the parameter extraction unit is configured to extract the parameter information after the keyword as a model configuration parameter of the type corresponding to the keyword.
  • the types corresponding to the keywords at least include: model, input, output, and operator.
  • the model generation module 830 may include: a project file generation unit configured to generate a basic project file according to the model information of the model configuration parameters.
  • the information determining unit is configured to detect the running operating system of the business processing model and determine the business basic system information corresponding to the running operating system.
  • the processing file matching unit is configured to select a matching model processing file according to the business basic system information.
  • a model generation unit configured to fill the model configuration parameters into the model processing file according to type to generate the business processing model.
  • the device for generating a business processing model further includes:
  • the model compiling module is configured to compile the business processing model according to the business basic system information.
  • a model publishing module configured to use the model configuration parameters to publish the business processing model.
  • model publishing module also includes:
  • the system submission unit is configured to submit the public dependency package generated by compiling the business processing model to the distributed file system.
  • the computing framework identifying unit is configured to identify the computing framework in the model configuration parameters, and instantiate the task submission manager according to the computing framework.
  • the release implementation unit is configured to use the task submission manager to process the public dependency package to implement the release of the business processing model.
  • a service processing model generating device provided in an embodiment of the present application can execute a service processing model generating method provided in any embodiment of the present application, and has corresponding functional modules for executing the method.
  • FIG. 9 is a schematic structural diagram of an electronic device provided in Embodiment 5 of the present application.
  • the device includes a processor 910, a memory 920, an input device 930, and an output device 940; the number of processors 910 in the device can be It is at least one.
  • a processor 910 is taken as an example; the processor 910, memory 920, input device 930, and output device 940 in the device can be connected through a bus or in other ways.
  • a bus connection is used as an example.
  • the memory 920 is configured to store software programs, computer-executable programs and modules, such as program instructions/modules corresponding to a business processing model generation method in the embodiment of the present application (for example, a business Process the requirement acquisition module 810, the parameter identification module 820 and the model generation module 830 in the model generation device.).
  • the processor 910 executes various functional applications and data processing of the device by running software programs, instructions and modules stored in the memory 920, that is, implements the above-mentioned method for generating a service processing model.
  • the memory 920 may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system and an application program required by at least one function; the data storage area may store data created according to the use of the terminal, and the like.
  • the memory 920 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other non-volatile solid-state storage devices.
  • memory 920 may include memory located remotely from processor 910, which remote memory may be connected to the device via a network. Examples of the aforementioned networks include, but are not limited to, the Internet, intranets, local area networks, mobile communication networks, and combinations thereof.
  • the input device 930 is configured to receive input numbers or character information, and generate key signal input related to user settings and function control of the device.
  • the output device 940 may include a display device such as a display screen.
  • Embodiment 6 of the present application also provides a storage medium containing computer-executable instructions, the computer-executable instructions are used to execute a method for generating a business processing model when executed by a computer processor, and the method includes:
  • a model processing file is selected according to the model configuration parameters and business basic system information to form a business processing model.
  • the storage medium containing computer-executable instructions provided in the embodiments of the present application the computer-executable instructions are not limited to the method operations described above, and can also execute a business processing model provided in any embodiment of the present application Generate related operations in the method.
  • the included units and modules are only divided according to functional logic, but are not limited to the above division, as long as the corresponding functions can be realized; in addition , the specific names of the functional units are only for the convenience of distinguishing each other, and are not used to limit the protection scope of the present application.

Landscapes

  • Engineering & Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Software Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Security & Cryptography (AREA)
  • Stored Programmes (AREA)

Abstract

A service processing model generation method and apparatus, and an electronic device and a storage medium. The method comprises: generating a model description file according to collected service demand information; extracting model configuration parameters in the model description file according to a preset label; and selecting a model processing file according to the model configuration parameters and service basic system information to form a service processing model.

Description

一种业务处理模型生成方法、装置、电子设备和存储介质A business processing model generation method, device, electronic equipment and storage medium
本申请要求在2021年11月22日提交中国专利局、申请号为202111383654.3的中国专利申请的优先权,该申请的全部内容通过引用结合在本申请中。This application claims priority to a Chinese patent application with application number 202111383654.3 filed with the China Patent Office on November 22, 2021, the entire contents of which are incorporated herein by reference.
技术领域technical field
本申请实施例涉及计算机应用技术领域,例如涉及一种业务处理模型生成方法、装置、电子设备和存储介质。The embodiments of the present application relate to the technical field of computer applications, for example, to a method, device, electronic device and storage medium for generating a service processing model.
背景技术Background technique
随着大数据技术的发展,技术迭代更新十分频繁,开发者需要丰富且复杂的工具完成相应的技术更新,因此在使用大数据技术处理业务问题时,实现方式往往十分复杂。往往不同的业务需求将会导致使用的大数据技术不同,例如,用于进行批处理的MapReduce、用于实时流处理的Flink、用于多媒体处理的Tensorflow以及结构化查询语句的Spark或Flink SQL等,大数据平台将上述技术框架、工具和类库整合在一起。With the development of big data technology, technology iterative updates are very frequent, and developers need rich and complex tools to complete the corresponding technology updates. Therefore, when using big data technology to deal with business problems, the implementation method is often very complicated. Often different business requirements will lead to different big data technologies used, for example, MapReduce for batch processing, Flink for real-time stream processing, Tensorflow for multimedia processing, Spark or Flink SQL for structured query statements, etc. , the big data platform integrates the above-mentioned technical frameworks, tools and class libraries.
由于不同的领域的业务需求差别较大,不同的业务处理模型在随着需求变动不断更新产品版本,导致线下代码开发难以维护,存在版本重复、代码混乱、无法有效合并的问题。目前亟需一种业务处理模型的线上生成方法,屏蔽不同技术细节,降低业务处理模型的生成难度。Due to the large differences in business requirements in different fields, different business processing models are constantly updating product versions as requirements change, making offline code development difficult to maintain, and there are problems such as repeated versions, chaotic codes, and inability to effectively merge. At present, there is an urgent need for an online generation method of business processing models, which can shield different technical details and reduce the difficulty of generating business processing models.
发明内容Contents of the invention
本申请提供一种业务处理模型生成方法、装置、电子设备和存储介质,以实现业务处理模型的自动化生成,降低业务模型的代码冗余程度,可减少模型开发的时间成本,以提高业务处理效率。This application provides a business processing model generation method, device, electronic equipment, and storage medium to realize the automatic generation of business processing models, reduce the code redundancy of business models, reduce the time cost of model development, and improve business processing efficiency .
第一方面,本申请实施例提供了一种业务处理模型生成方法,该方法包括:In the first aspect, the embodiment of the present application provides a method for generating a business processing model, the method including:
根据采集到的业务需求信息生成模型描述文件;Generate a model description file based on the collected business requirement information;
按照预设标签提取所述模型描述文件中的模型配置参数;Extracting the model configuration parameters in the model description file according to the preset tags;
按照所述模型配置参数和业务基础系统信息选择模型处理文件构成业务处理模型。A model processing file is selected according to the model configuration parameters and business basic system information to form a business processing model.
第二方面,本申请实施例还提供了一种业务处理模型生成装置,该装置包括:In the second aspect, the embodiment of the present application also provides an apparatus for generating a business processing model, which includes:
需求采集模块,设置为根据采集到的业务需求信息生成模型描述文件;The requirement collection module is configured to generate a model description file according to the collected business requirement information;
参数识别模块,设置为按照预设标签提取所述模型描述文件中的模型配置参数;The parameter identification module is configured to extract the model configuration parameters in the model description file according to the preset tags;
模型生成模块,设置为按照所述模型配置参数和业务基础系统信息选择模型处理文件构成业务处理模型。The model generation module is configured to select a model processing file to form a business processing model according to the model configuration parameters and business basic system information.
第三方面,本申请实施例还提供了一种电子设备,所述电子设备包括:In a third aspect, the embodiment of the present application further provides an electronic device, the electronic device comprising:
至少一个处理器;at least one processor;
存储器,设置为存储至少一个程序,a memory configured to store at least one program,
当所述至少一个程序被所述至少一个处理器执行,使得所述至少一个处理器实现如第一方面所述的业务处理模型生成方法。When the at least one program is executed by the at least one processor, the at least one processor is made to implement the service processing model generation method as described in the first aspect.
第四方面,本申请实施例还提供了一种计算机可读存储介质,其上存储有计算机程序,所述计算机程序被处理器执行时实现如第一方面所述的业务处理模型生成方法。In a fourth aspect, the embodiment of the present application further provides a computer-readable storage medium, on which a computer program is stored, and when the computer program is executed by a processor, the method for generating a service processing model as described in the first aspect is implemented.
附图说明Description of drawings
图1给出了相关技术中业务处理模型生成方法的实现的流程图;Fig. 1 shows the flow chart of the implementation of the business processing model generation method in the related art;
图2为本申请实施例一提供的一种业务处理模型生成方法的流程图;FIG. 2 is a flow chart of a method for generating a business processing model provided in Embodiment 1 of the present application;
图3为本申请实施例二提供的一种业务处理模型生成方法的流程图;FIG. 3 is a flow chart of a method for generating a business processing model provided in Embodiment 2 of the present application;
图4为本申请实施例三提供的一种业务处理模型生成方法的流程图;FIG. 4 is a flow chart of a method for generating a business processing model provided in Embodiment 3 of the present application;
图5为本申请实施例三提供的另一种业务处理模型生成方法的流程图;FIG. 5 is a flow chart of another business processing model generation method provided in Embodiment 3 of the present application;
图6为本申请实施例三提供的又一种业务处理模型生成方法的流程图;FIG. 6 is a flow chart of another method for generating a business processing model provided in Embodiment 3 of the present application;
图7为本申请实施例三提供的又一种业务处理模型生成方法的流程图;FIG. 7 is a flow chart of another business processing model generation method provided in Embodiment 3 of the present application;
图8为本申请实施例四提供的一种业务处理模型生成装置的结构示意图;FIG. 8 is a schematic structural diagram of a business processing model generation device provided in Embodiment 4 of the present application;
图9为本申请实施例五提供的一种电子设备的结构示意图。FIG. 9 is a schematic structural diagram of an electronic device provided in Embodiment 5 of the present application.
具体实施方式Detailed ways
下面结合附图和实施例对本申请作详细说明。在不冲突的情况下,本申请中的实施例及实施例中的特征可以相互组合。The application will be described in detail below in conjunction with the accompanying drawings and embodiments. In the case of no conflict, the embodiments in the present application and the features in the embodiments can be combined with each other.
为了便于验证相关技术中业务处理模型生成方法的应用,图1给出了相关技术中业务处理模型生成方法的实现的流程图。如图1所示,相关技术中业务处理模型生成方法的实现为:首先实时流数据采用flink或者spark streaming进行硬代码编写逻辑,然后离线环节用spark、flink进行硬代码编写,且机器学习计算、图计算均采用硬代码方式编写实现。然而,不同用户需求的差异,通过线下代码开发很难维护,随着产品版本功能的不断迭代,造成版本重复、代码混乱,无法有效合并。In order to facilitate the verification of the application of the business processing model generation method in the related technology, FIG. 1 shows the flow chart of the realization of the business processing model generation method in the related technology. As shown in Figure 1, the realization of the business processing model generation method in related technologies is as follows: first, the real-time streaming data uses flink or spark streaming to write hard code logic, and then uses spark and flink to write hard code in the offline link, and machine learning calculation, Graph computing is written and implemented in a hard-coded manner. However, the differences in the needs of different users are difficult to maintain through offline code development. With the continuous iteration of product version functions, versions are duplicated and codes are confused, which cannot be effectively merged.
本申请提出了一种业务处理模型生成方法,实现了业务处理模型的自动化生成,有效降低了业务模型的代码冗余程度,在一定程度上减少模型开发的时间成本,提升了业务处理效率。This application proposes a method for generating a business processing model, which realizes the automatic generation of the business processing model, effectively reduces the code redundancy of the business model, reduces the time cost of model development to a certain extent, and improves the efficiency of business processing.
实施例一Embodiment one
图2为本申请实施例一提供的一种业务处理模型生成方法的流程图,本实施例可适用于对业务处理模型的自动化生成的情况,该方法可以由一种业务处理模型生成装置来执行,该装置可以采用硬件和/或软件的方式来实现,通常可配置于电子设备中。包括如下步骤:Fig. 2 is a flow chart of a method for generating a business processing model provided in Embodiment 1 of the present application. This embodiment is applicable to the automatic generation of a business processing model, and the method can be executed by a device for generating a business processing model , the device can be implemented in hardware and/or software, and can generally be configured in electronic equipment. Including the following steps:
S210、根据采集到的业务需求信息生成模型描述文件。S210. Generate a model description file according to the collected business requirement information.
其中,业务需求信息可以理解为生成业务处理模型需要的业务信息,可以包括业务数据的存储位置、业务的处理流程等。示例性的,业务需求信息可以 为用户在前台页面中所输入的某件商品的价格计算;也可以为所输入的信息最优规划路径的实现;还可以为所输入的视频传输方法的实现等,本实施例在此不做限制。Wherein, the business requirement information can be understood as the business information needed to generate the business processing model, which may include the storage location of the business data, the processing flow of the business, and the like. Exemplarily, the business demand information can be the calculation of the price of a commodity input by the user on the front page; it can also be the realization of the optimal planning path of the input information; it can also be the realization of the input video transmission method, etc. , which is not limited in this embodiment.
在本实施例中,模型描述文件可以理解为对业务模型构成进行描述和定义的文件,模型描述文件中可以包括业务处理模型构成使用的参数,例如,输入参数、输出参数、操作算子等。例如,所生成模型描述文件可以是可扩展标记语言(EXtensible Markup Language,XML)文件。In this embodiment, the model description file can be understood as a file describing and defining the composition of the business model, and the model description file can include parameters used in the composition of the business processing model, such as input parameters, output parameters, and operators. For example, the generated model description file may be an extensible markup language (EXtensible Markup Language, XML) file.
在本实施例中,可以通过在前端页面中接收用户输入的业务需求,或者可以通过对文档资料、视频资源等资料基于人工智能识别其中的业务需求,可以将采集到的业务需求按照固定格式存储为文件作为模型描述文件,该模型描述文件的文件格式在此不进行限制,可以包括XML文件或者自定义格式文件。In this embodiment, the collected business requirements can be stored in a fixed format by receiving the business requirements input by the user on the front-end page, or by identifying the business requirements based on artificial intelligence for documents, video resources and other materials The file is used as a model description file, and the file format of the model description file is not limited here, and may include an XML file or a custom format file.
在本实施例中,可以采集业务需求信息,并将业务需求信息存储为模型描述文件,该过程中采集业务需求信息的方式可以包括在页面中通过手动输入或拖动选项的方式采集业务需求信息。In this embodiment, business requirement information can be collected and stored as a model description file, and the way of collecting business requirement information in this process can include collecting business requirement information by manually inputting or dragging options on the page .
S220、按照预设标签提取模型描述文件中的模型配置参数。S220. Extract the model configuration parameters in the model description file according to the preset tags.
其中,预设标签可以是具有特点含义的文字或者特殊字符,预设标签可以用于标记描述文件中不同类型的参数,如<model>标签、<inputs>标签、<outputs>标签等,本实施例在此不做限制。模型配置参数可以理解为是用于生成业务处理模型的参数,模型配置参数可以根据前述的业务需求信息生成,不同的模型配置参数可以与不同的预设标签关联存储。示例性的,模型配置参数可以为<model>标签中的计算框架类型、模型类型以及模型名称等信息。其中,计算框架类型可以为spark;模型类型可以为batch,分为流式和离式两种类型;模型名称可以为testabsd。Among them, the preset tags can be text or special characters with characteristic meanings, and the preset tags can be used to mark different types of parameters in the description file, such as <model> tags, <inputs> tags, <outputs> tags, etc., this implementation Examples are not limited here. Model configuration parameters can be understood as parameters used to generate business processing models. Model configuration parameters can be generated according to the aforementioned business requirement information, and different model configuration parameters can be stored in association with different preset tags. Exemplarily, the model configuration parameters may be information such as the computing framework type, model type, and model name in the <model> tag. Among them, the calculation framework type can be spark; the model type can be batch, which is divided into two types: streaming and off-line; the model name can be testabsd.
在本实施例中,在根据采集到的业务需求信息生成模型描述文件之后,首先要加载出模型描述文件,可以使用预设标签对模型描述文件进行解析以获取到模型配置参数。In this embodiment, after the model description file is generated according to the collected business requirement information, the model description file must be loaded first, and the model description file can be parsed using preset tags to obtain model configuration parameters.
例如,按照预设标签提取模型描述文件中的模型配置参数的方式可以包括:通过在模型描述文件内匹配预设标签的关键字,以提取关键字后的参数信息作为关键字对应类型的模型配置参数;也可以包括根据语言描述模型,采用语言描述信息的参数,然后采用模拟软件进行提取的方式;还可以包括从区块链系统中选择存储有数据集合的M个计算节点,然后从中选择K个计算节点进行模型训练,并获取其训练结果,最后根据数据集合的训练结果,得到模型参数。For example, the method of extracting the model configuration parameters in the model description file according to the preset tags may include: by matching the keywords of the preset tags in the model description file, the parameter information after the keywords are extracted as the model configuration of the type corresponding to the keywords Parameters; it can also include the method of using language description information parameters according to the language description model, and then using simulation software to extract; it can also include selecting M computing nodes that store data sets from the blockchain system, and then selecting K Each computing node performs model training, obtains the training results, and finally obtains the model parameters according to the training results of the data set.
S230、按照模型配置参数和业务基础系统信息选择模型处理文件构成业务处理模型。S230. Select a model processing file according to the model configuration parameters and business basic system information to form a business processing model.
其中,业务基础系统信息可以理解为业务操作系统中的相关文件信息。示例性的,业务基础系统信息可以是windows系统中的文件信息;也可以是Linux系统中的文件信息,还可以为ios系统中的文件信息,本实施例在此不做限制。可以理解的是,不同的业务基础系统信息所执行的文件信息的类型是不一样的,可以按照模型配置参数和业务基础系统信息进行选择模型处理文件以构成业务处理模型。Among them, the business basic system information can be understood as the relevant file information in the business operating system. Exemplarily, the business basic system information may be file information in the windows system; it may also be file information in the Linux system, or it may be file information in the ios system, which is not limited in this embodiment. It can be understood that the types of file information executed by different business basic system information are different, and model processing files can be selected according to model configuration parameters and business basic system information to form a business processing model.
在本实施例中,模型处理文件可以理解为通过对模型配置参数的解析以及控制,所生成基于不同计算框架实现的源代码。需要知道的是,不同的软件开发语言所对应的模型处理文件是不同的。对相同的业务需求信息,不同的软件开发语言的实现方式也可能是不相同的,但是其业务处理能力相同或相似。示例性的,不同的软件开发语言可以为Java语言;也可以为Python语言;还可以为c语言等等,本实施例在此不做限制。例如,Java语言,Python语言对相同的业务需求信息,两种语言实现的代码文件是不一样,但是其业务处理能力相同或相似。In this embodiment, the model processing file can be understood as source codes generated based on different computing frameworks through parsing and controlling model configuration parameters. What needs to be known is that the model processing files corresponding to different software development languages are different. For the same business requirement information, different software development languages may have different implementation methods, but their business processing capabilities are the same or similar. Exemplarily, different software development languages may be Java language; Python language; C language, etc., which are not limited in this embodiment. For example, for the same business requirement information in Java language and Python language, the code files implemented by the two languages are different, but their business processing capabilities are the same or similar.
在本实施例中,业务处理模型可以理解为按照模型配置参数和业务基础系统信息选择模型处理文件所最后生成的代码信息。示例性的,业务处理模型可以为Java归档(Java Archive,jar)包。业务处理模型形成以后,可以供用户使用业务处理模型实现jar包在不同电脑,不同系统下的运行。In this embodiment, the business processing model can be understood as code information finally generated by selecting a model processing file according to model configuration parameters and business basic system information. Exemplarily, the service processing model may be a Java archive (Java Archive, jar) package. After the business processing model is formed, the user can use the business processing model to realize the operation of the jar package on different computers and different systems.
在本实施例中,按照模型配置参数和业务基础系统信息选择模型处理文件构成业务处理模型的方式,可以为首先按照模型配置参数的模型信息生成基础工程文件,然后检测业务处理模型的运行操作系统并确定运行操作系统对应的业务基础系统信息,根据业务基础系统信息选择匹配的模型处理文件,将模型配置参数按照类型填充到模型处理文件以生成业务处理模型;也可以为通过获取多个参数组合,然后使样本集与多个参数组合构成分别对应的业务模型,以根据业务模型获取匹配的处理文件。In this embodiment, the method of selecting model processing files to form a business processing model according to the model configuration parameters and business basic system information can be to first generate basic engineering files according to the model information of the model configuration parameters, and then detect the running operating system of the business processing model And determine the business basic system information corresponding to the running operating system, select the matching model processing file according to the business basic system information, and fill the model configuration parameters into the model processing file according to the type to generate the business processing model; you can also obtain multiple parameter combinations , and then combine the sample set and multiple parameters to form corresponding business models, so as to obtain matching processing files according to the business models.
本申请实施例所提供的技术方案中,根据采集到的业务需求信息生成模型描述文件,按照预设标签提取模型描述文件中的模型配置参数,使用模型配置参数和业务基础系统信息选择模型处理文件构成业务处理模型。本申请实施例,通过使用预设标签解析模型描述文件,准确获取业务处理模型的生成使用的模型配置参数,可实现业务处理模型的自动化生成,使用模型处理文件构建业务处理模型,减少业务处理模型生成过程中的重复开发程度,解决了通过线上的模型配置解决线下编写硬代码的问题,可有效降低业务模型的代码冗余程度,在一定程度上减少了模型开发的时间成本,从而提高业务处理效率。与相关技术相比,所采用的业务处理模型生成方法,有效解决了线下编写硬代码以及产品版本功能不断更新过程中所造成的版本重复、代码混乱、无法有效合并的问题。In the technical solution provided by the embodiment of this application, the model description file is generated according to the collected business requirement information, the model configuration parameters in the model description file are extracted according to the preset tags, and the model processing file is selected using the model configuration parameters and business basic system information Constitutes a business processing model. In the embodiment of this application, by using the preset tags to parse the model description file, the model configuration parameters used in the generation of the business processing model can be accurately obtained, so that the automatic generation of the business processing model can be realized, and the business processing model can be constructed using the model processing file, reducing the number of business processing models The degree of repeated development in the generation process solves the problem of writing hard code offline through online model configuration, which can effectively reduce the code redundancy of the business model and reduce the time cost of model development to a certain extent, thereby improving business processing efficiency. Compared with related technologies, the business processing model generation method adopted effectively solves the problems of duplication of versions, chaotic codes and inability to effectively merge caused by offline writing of hard codes and continuous updating of product version functions.
实施例二Embodiment two
图3为本申请实施例二提供的一种业务处理模型生成方法的流程图。本实施例在上述各实施例地基础上,进行了细化。可以包含如下步骤:FIG. 3 is a flow chart of a method for generating a service processing model provided in Embodiment 2 of the present application. This embodiment is refined on the basis of the above-mentioned embodiments. Can include the following steps:
可选的,本实施例可以通过根据采集到的业务需求信息生成模型描述文件。步骤可以为:S310至S320。Optionally, in this embodiment, a model description file may be generated according to collected business requirement information. The steps may be: S310 to S320.
S310、在业务需求采集页面监测用户输入的业务需求信息。S310. Monitor the service requirement information input by the user on the service requirement collection page.
在本实施例中,用户输入的业务需求信息可以是用户手写输入的业务需求 信息,也可以是用户采用拖动、拖拽的形式输入的业务需求信息,还可以是用户采用点触的方式进行输入的业务需求信息;本实施例在此不做限制。In this embodiment, the business requirement information input by the user may be the business requirement information input by the user by handwriting, or may be the business requirement information input by the user in the form of dragging or dragging, or may be entered by the user in the form of touch. The input service requirement information; this embodiment does not make a limitation here.
在本实施例中,可以在业务需求采集页面监测用户输入的业务需求信息。其中,业务需求采集页面可以理解为用于采集用户业务需求信息的页面。In this embodiment, the service requirement information input by the user may be monitored on the service requirement collection page. Wherein, the business requirement collection page can be understood as a page for collecting user service requirement information.
S320、将业务需求信息按照所属类型填充到描述文件模板以生成模型描述文件。S320. Fill the business requirement information into the description file template according to its type to generate a model description file.
其中,所属类型可以理解为用户输入的业务需求信息的属性信息。所属信息可以为计算框架类型信息,也可以为模型类型信息,本实施例在此不做限制。示例性的,所属信息为计算框架类型信息时,可以为flink、spark等等;所属信息为模型类型信息时,可以为framework、type、name、input type、tablename、connection等等。Wherein, the belonging type can be understood as the attribute information of the service requirement information input by the user. The belonging information may be computing framework type information or model type information, which is not limited in this embodiment. Exemplarily, when the belonging information is computing framework type information, it may be flink, spark, etc.; when the belonging information is model type information, it may be framework, type, name, input type, tablename, connection, etc.
在本实施例中,需要将用户输入的业务需求信息按照其所属类型对应的填充到描述文件模板中。可以理解的是,描述文件模板中的每一个参数信息均与用户输入时的业务需求信息中的控件存在一定的绑定关系。In this embodiment, the business requirement information input by the user needs to be filled into the description file template according to its type. It can be understood that each parameter information in the description file template has a certain binding relationship with the controls in the business requirement information input by the user.
可选的,本实施例可以通过按照预设标签提取模型描述文件中的模型配置参数。步骤可以为:S330至S340。Optionally, in this embodiment, the model configuration parameters in the model description file may be extracted according to preset tags. The steps may be: S330 to S340.
S330、在模型描述文件内匹配预设标签的关键字。S330. Match keywords of preset tags in the model description file.
其中,预设标签的关键字可以理解为预先设置的标签中的关键字。示例性的,模型描述文件中的model标签;也可以模型描述文件中输入inputs标签;还可以为模型描述文件输出outputs标签。本实施例在此不做限制。Wherein, the keywords of the preset tags can be understood as the keywords in the preset tags. Exemplarily, the model tag in the model description file; the inputs tag can also be input in the model description file; the outputs tag can also be output for the model description file. This embodiment is not limited here.
在本实施例中,将至少一个业务需求信息按照所属类型填充到描述文件模板以生成模型描述文件之后,可以在模型描述文件内匹配预设标签的关键字,以提取关键字后的参数信息。In this embodiment, after at least one piece of business requirement information is filled into the description file template according to its type to generate a model description file, keywords of preset tags can be matched in the model description file to extract parameter information after keywords.
S340、提取关键字后的参数信息作为关键字对应类型的模型配置参数。S340. The parameter information after the keyword is extracted is used as a model configuration parameter of a type corresponding to the keyword.
其中,参数信息可以理解为按照所属类型对应填充到描述文件模板以生成模型描述文件的参数信息。在模型描述文件内匹配预设标签的关键字之后,可 以提取关键字后的参数信息作为关键字对应类型的模型配置参数。其中,关键字对应类型可以包括模型,也可以包括输入,还可以包括算子等等,本实施例在此不做限制。Wherein, the parameter information can be understood as the parameter information correspondingly filled into the description file template according to the type to generate the model description file. After matching the keyword of the preset tag in the model description file, the parameter information after the keyword can be extracted as the model configuration parameter of the corresponding type of keyword. Wherein, the type corresponding to the keyword may include a model, may also include an input, and may also include an operator, etc., which are not limited in this embodiment.
在本实施例中,可以在模型描述文件内匹配预先设置的标签中的关键字,然后提取生成模型描述文件内匹配预先设置的标签中的关键字后的参数信息作为关键字对应类型的模型配置参数。In this embodiment, the keywords in the preset tags can be matched in the model description file, and then the parameter information after matching the keywords in the preset tags in the model description file can be extracted and generated as the model configuration of the type corresponding to the keywords parameter.
可选的,关键字对应类型至少包括:模型、输入、输出、算子。Optionally, the corresponding types of keywords include at least: model, input, output, and operator.
其中,模型可以理解为程序代码的处理模型,在处理不同业务需求信息时的处理逻辑。模型可以包含spark、flag、transformer等等模型框架。算子可以理解为预先设置好的业务处理逻辑。示例性的,算子可以为计算相关图形的匹配内容的相关代码处理逻辑;也可以为最优路径的规划以及实现的相关代码处理逻辑;还可以为设备进行检测时的相关代码处理逻辑,本实施例在此不做限制。Among them, the model can be understood as the processing model of the program code, and the processing logic when processing different business requirement information. The model can contain spark, flag, transformer and other model frameworks. Operators can be understood as pre-set business processing logic. Exemplarily, the operator can be related code processing logic for calculating the matching content of related graphics; it can also be related code processing logic for optimal path planning and implementation; it can also be related code processing logic for device detection. The embodiments are not limited here.
在本实施例中,提取关键字后的参数信息可以作为关键字对应类型的模型配置参数之后,可以获取所有输入算子配置信息,依次循环输入算子并依据算子名称,获取算子实例对象。In this embodiment, after extracting the parameter information of keywords can be used as the model configuration parameters of the corresponding type of keywords, all input operator configuration information can be obtained, the input operators are cyclically input in sequence, and operator instance objects are obtained according to the operator names .
可选的,本实施例可以通过按照模型配置参数和业务基础系统信息选择模型处理文件构成业务处理模型。步骤可以为:S350至S380。Optionally, in this embodiment, a service processing model may be formed by selecting a model processing file according to model configuration parameters and basic service system information. The steps may be: S350 to S380.
S350、按照模型配置参数的模型信息生成基础工程文件。S350. Generate a basic engineering file according to the model information of the model configuration parameters.
其中,基础工程文件可以理解为显示目录结构的一个文件集,用于存放各种工程文件,基础工程文件可以由多个文件组成。每一个基础工程文件均对应一块磁盘空间,提供了指向对应空间的地址。基础工程文件的一个文件夹中可以包括多个子文件夹,最底层就是文件本身,基础工程文件的类型可以为文档文件、图片、相册、音乐、视频、语音、代码文件等等。需要说明的是,基础工程文件中子文件夹的最底层可以实现一个完整的业务处理能力。Among them, the basic project file can be understood as a file set showing the directory structure, used to store various project files, and the basic project file can be composed of multiple files. Each basic project file corresponds to a piece of disk space, and an address pointing to the corresponding space is provided. A folder of basic project files can include multiple subfolders, and the bottom layer is the file itself. The types of basic project files can be document files, pictures, photo albums, music, video, voice, code files, etc. It should be noted that the bottom layer of the subfolder in the basic project file can realize a complete business processing capability.
在本实施例中,可以按照模型配置参数的模型信息以生成基础工程文件,基础工程文件可以依据模型定义名称修订模板名称。In this embodiment, the basic project file can be generated according to the model information of the model configuration parameters, and the template name of the basic project file can be revised according to the model definition name.
S360、检测业务处理模型的运行操作系统并确定运行操作系统对应的业务基础系统信息。S360. Detect the running operating system of the service processing model and determine the service basic system information corresponding to the running operating system.
其中,运行操作系统可以理解为进行代码编译与运行的操作系统。运行操作系统可以为windows操作系统,也可以为Linux操作系统,还可以为ios操作系统,本实施例在此不做限制。Wherein, the running operating system may be understood as an operating system for compiling and running codes. The running operating system may be a windows operating system, a Linux operating system, or an ios operating system, which is not limited in this embodiment.
在本实施例中,不同的运行操作系统,其编译与运行命令也有不同。示例性的,windows运行操作系统可以应用cmd命令,而linux运行操作系统可以应用sh命令。In this embodiment, different running operating systems have different compiling and running commands. Exemplarily, the cmd command can be applied to the windows running operating system, and the sh command can be used to run the linux operating system.
在本实施例中,通过检测业务处理模型的运行操作系统可以确定运行操作系统对应的业务基础系统信息,根据运行操作系统的检测,可以动态选择编译执行指令。在选择之后,执行编译操作执行指令,对编码进行编译。In this embodiment, the service basic system information corresponding to the running operating system can be determined by detecting the running operating system of the service processing model, and the compiling and executing instructions can be dynamically selected according to the detection of the running operating system. After the selection, execute the compiling operation to execute the instruction and compile the code.
S370、按照业务基础系统信息选择匹配的模型处理文件。S370. Select a matching model according to the business basic system information and process the file.
在本实施例中,在检测业务处理模型的运行操作系统并确定运行操作系统对应的业务基础系统信息之后,可以按照业务基础系统信息选择匹配的模型处理文件,以进行下一步的操作。In this embodiment, after detecting the running operating system of the business processing model and determining the business basic system information corresponding to the running operating system, a matching model processing file can be selected according to the business basic system information for the next step of operation.
S380、将模型配置参数按照类型填充到模型处理文件以生成业务处理模型。S380. Fill the model configuration parameters according to types into the model processing file to generate a service processing model.
在本实施例中,按照业务基础系统信息选择匹配的模型处理文件,可以将模型配置参数按照类型填充到模型处理文件中以生成业务处理模型,供用户可靠、方便的使用。In this embodiment, the matching model processing file is selected according to the basic business system information, and model configuration parameters can be filled into the model processing file according to type to generate a business processing model for reliable and convenient use by users.
S390、按照业务基础系统信息编译业务处理模型。S390. Compile the service processing model according to the service basic system information.
其中,业务基础系统信息可以理解为不同运行操作系统的对应的业务基础系统信息。Wherein, the service basic system information may be understood as the corresponding service basic system information of different running operating systems.
在本实施例中,可以按照业务基础系统信息对业务处理模型进行编译。不同的业务基础系统信息,在编译业务处理模型时的命令也不相同。示例性的,windows操作系统中对应的业务基础系统信息可以应用cmd进行命令编译相关业务处理模型;而linux操作系统中对应的业务基础系统信息可以应用sh进行 命令编译相关业务处理模型,本实施例在此不做限制。In this embodiment, the business processing model can be compiled according to the basic business system information. For different business basic system information, the commands when compiling the business processing model are also different. Exemplarily, the corresponding business basic system information in the windows operating system can use cmd to execute commands to compile related business processing models; and the corresponding business basic system information in the linux operating system can use sh to execute commands to compile related business processing models. There is no limitation here.
S3100、使用模型配置参数发布业务处理模型。S3100. Publish the service processing model by using the model configuration parameters.
在本实施例中,按照业务基础系统信息编译业务处理模型之后,可以使用模型配置参数将得到的业务处理模型进行发布,使其在不同的业务基础系统都可以运行并实现相应的执行功能。In this embodiment, after the business processing model is compiled according to the information of the business basic system, the obtained business processing model can be released using model configuration parameters, so that it can run in different business basic systems and realize corresponding execution functions.
在本实施例中,使用模型配置参数发布业务处理模型方式可以为:首先将业务处理模型编译生成的公共依赖包提交到分布式文件系统,然后识别模型配置参数中计算框架,并按照计算框架实例化任务提交管理器,使用任务提交管理器处理公共依赖包以实现业务处理模型的发布;还可以为:首先将目标工程中当前待编译的模块作为目标模块,并确定目标模块的运行模式,然后获取目标模块在独立运行模式下的配置文件,之后得到目标模块在集成运行模式下的目标配置文件,并利用目标配置文件对目标模块进行编译并发布,本实施例在此不做限制。In this embodiment, the method of publishing the business processing model by using the model configuration parameters may be as follows: firstly submit the public dependency package generated by compiling the business processing model to the distributed file system, then identify the computing framework in the model configuration parameters, and follow the calculation framework instance Submit the task manager, and use the task submission manager to process the public dependency package to realize the release of the business processing model; it can also be: firstly use the module to be compiled in the target project as the target module, and determine the operating mode of the target module, and then Obtain the configuration file of the target module in the independent operation mode, and then obtain the target configuration file of the target module in the integrated operation mode, and use the target configuration file to compile and publish the target module, which is not limited in this embodiment.
本申请实施例所提供的技术方案中,通过在业务需求采集页面监测用户输入的业务需求信息,将业务需求信息按照所属类型填充到描述文件模板以生成模型描述文件,在模型描述文件内匹配预设标签的关键字,并提取关键字后的参数信息作为关键字对应类型的模型配置参数,按照模型配置参数的模型信息生成基础工程文件,检测业务处理模型的运行操作系统并确定运行操作系统对应的业务基础系统信息,按照业务基础系统信息选择匹配的模型处理文件,并将模型配置参数按照类型填充到模型处理文件以生成业务处理模型。本申请实施例,通过将业务需求信息按照所属类型填充到描述文件模板以生成模型描述文件,实现业务处理模型的自动化生成,按照业务基础系统信息选择匹配的模型处理文件,将模型配置参数按照类型填充到模型处理文件以生成业务处理模型,减少模型开发的时间成本,可降低业务模型的代码冗余程度,在一定程度上提高业务处理效率。In the technical solution provided by the embodiment of this application, by monitoring the business demand information input by the user on the business demand collection page, the business demand information is filled into the description file template according to its type to generate a model description file, and the pre-matched model description file is matched in the model description file. Set the keyword of the label, and extract the parameter information after the keyword as the model configuration parameter corresponding to the keyword, generate the basic project file according to the model information of the model configuration parameter, detect the operating system of the business processing model and determine the corresponding operating system According to the business basic system information, select the matching model processing file according to the business basic system information, and fill the model configuration parameters into the model processing file according to the type to generate a business processing model. In the embodiment of the present application, by filling the business requirement information into the description file template according to the type to generate the model description file, the automatic generation of the business processing model is realized, the matching model processing file is selected according to the business basic system information, and the model configuration parameters are classified according to the Fill in the model processing file to generate a business processing model, reduce the time cost of model development, reduce the code redundancy of the business model, and improve business processing efficiency to a certain extent.
可选的,使用模型配置参数发布业务处理模型,包括:将业务处理模型编 译生成的公共依赖包提交到分布式文件系统;识别模型配置参数中计算框架,并按照计算框架实例化任务提交管理器;使用任务提交管理器处理公共依赖包以实现业务处理模型的发布。Optionally, use the model configuration parameters to publish the business processing model, including: submitting the public dependency package generated by compiling the business processing model to the distributed file system; identifying the computing framework in the model configuration parameters, and instantiating the task submission manager according to the computing framework ; Use the task submission manager to process the public dependency package to realize the release of the business processing model.
其中,公共依赖包可以理解为业务处理模型编译生成的可以共用的包文件。公共依赖包可以表示一种软件包文件的格式。示例性的,公共依赖包可以为jar包。分布式文件系统可以理解为一个高度容错性的系统。分布式文件系统的特点是可以提供高吞吐量的数据访问,非常适合大规模数据集上的应用。计算框架可以为spark、flink等计算框架,本实施例在此不做限制。Among them, the public dependency package can be understood as a shared package file generated by compiling the business processing model. Common dependencies can represent a package file format. Exemplarily, the public dependency package may be a jar package. A distributed file system can be understood as a highly fault-tolerant system. The characteristic of the distributed file system is that it can provide high-throughput data access, which is very suitable for applications on large-scale data sets. The calculation framework may be a calculation framework such as spark or flink, which is not limited in this embodiment.
在本实施例中,将编译后业务处理模型编译生成的公共依赖包提交到分布式文件系统上,需要检测并识别模型配置参数中计算框架,在spark、flink等计算框架中,按照计算框架实例化任务提交管理器。其中,提交任务可以分为两种类型,一种是将公共依赖包在任务提交时提交,另一种是先将公共依赖包提交到分布式文件系统上,然后在每次任务提交时,只提交增量部分内容,这是因为公共依赖包一般都很大,如果每次执行任务再提交,任务启动速度会非常低。In this embodiment, the public dependency package generated by compiling the business processing model is submitted to the distributed file system. It is necessary to detect and identify the computing framework in the model configuration parameters. In computing frameworks such as spark and flink, follow the example of the computing framework Customized task submission manager. Among them, the submission task can be divided into two types, one is to submit the public dependency package when the task is submitted, and the other is to submit the public dependency package to the distributed file system first, and then each time the task is submitted, only Submit the incremental content, because the public dependency packages are generally large, and if the task is submitted every time the task is executed, the task startup speed will be very low.
在本实施例中,通过将业务处理模型编译生成的公共依赖包提交到分布式文件系统,检测并识别模型配置参数中计算框架,在确定计算框架的前提下,按照计算框架实例化任务提交管理器,在实例化任务提交管理器之后,使用任务提交管理器处理公共依赖包以实现业务处理模型的发布,将业务处理模型发布到系统中,供用户下载及使用。In this embodiment, by submitting the public dependency package generated by compiling the business processing model to the distributed file system, the computing framework in the model configuration parameters is detected and identified, and on the premise that the computing framework is determined, the task is submitted and managed according to the instantiation of the computing framework After instantiating the task submission manager, use the task submission manager to process the public dependency package to realize the release of the business processing model, and publish the business processing model to the system for users to download and use.
实施例三Embodiment Three
图4为本申请实施例三提供的一种业务处理模型生成方法的流程图。如图4所示,本实施例中的业务处理模型生成方法主要包含模型文件解析引擎与代码生成技术、模型编译控制技术以及任务提交控制技术。FIG. 4 is a flow chart of a method for generating a service processing model provided in Embodiment 3 of the present application. As shown in FIG. 4 , the business process model generation method in this embodiment mainly includes a model file analysis engine and code generation technology, model compilation control technology, and task submission control technology.
首先是设计模型,然后按照模型定义参数信息,并配置解析参数规则,配 置平台即服务(Platform as a Service,Paas)组件连接算子,配置操作算子,配置输出Paas连接组件算子,形成预览模型,并对模型进行编译,将编译后的模型进行发布,配置模型运行参数,形成运行模型。The first is to design the model, then define parameter information according to the model, configure parsing parameter rules, configure platform as a service (Platform as a Service, Paas) component connection operator, configure operation operator, configure output Paas connection component operator, and form a preview model, and compile the model, publish the compiled model, configure model operating parameters, and form an operating model.
下面将对模型文件解析引擎与代码生成技术、模型编译控制技术以及任务提交控制技术作更详细一步的介绍。The following will introduce the model file parsing engine and code generation technology, model compilation control technology and task submission control technology in more detail.
1)模型文件解析与代码生成技术:1) Model file analysis and code generation technology:
模型文件解析与代码生成技术,在模型文件中,是由输入、操作、输出三部分组成。示例性的,输入部分代码:<model framework="spark"type="batch"name="testabsd"><!—数据输入-->。其中,model framework表示模型框架,spark表示框架的具体参数;type表示类型,batch表示类型的具体参数;name表示名称,testabsd表示名称的具体参数。Model file analysis and code generation technology, in the model file, is composed of three parts: input, operation, and output. For example, input part of the code: <model framework="spark" type="batch" name="testabsd"><! -- data entry -->. Among them, model framework represents the model framework, spark represents the specific parameters of the framework; type represents the type, batch represents the specific parameters of the type; name represents the name, and testabsd represents the specific parameters of the name.
模型文件解析引擎实现模型配置文件解析,抽取模型文件内容转变为结构对象,提取操作算子内容并转交给算子进行解析并生成代码。The model file parsing engine implements model configuration file parsing, extracts the content of the model file and transforms it into a structural object, extracts the content of the operator, and transfers it to the operator for parsing and generating code.
图5为本申请实施例三提供的另一种业务处理模型生成方法的流程图。<model>标签以及<inputs>标签均表示预设标签。如图5所示,本实施例中的业务处理模型生成方法包括如下步骤:FIG. 5 is a flow chart of another method for generating a service processing model provided in Embodiment 3 of the present application. Both the <model> tag and the <inputs> tag represent default tags. As shown in Figure 5, the business processing model generation method in this embodiment includes the following steps:
a1、根据采集到的业务需求信息生成模型描述文件,此处生成模型描述文件为Model Document,XML格式,提取结构信息。a1. Generate a model description file according to the collected business requirement information. Here, the generated model description file is Model Document in XML format, and the structural information is extracted.
a2、在模型引擎接收到模型文件之后,首先解析加载模型引擎文件,提取<model>标签中的属性信息,提取计算框架类型、模型类型(流式、离线两类)、模型名称等信息。a2. After the model engine receives the model file, it first parses and loads the model engine file, extracts the attribute information in the <model> tag, and extracts information such as computing framework type, model type (both streaming and offline), and model name.
a3、解析<inputs>标签中的内容,获取所有输入算子配置信息(模型引擎采用微内核架构设计),依次循环输入算子并依据算子名称获取算子实例对象。模型引擎将当前部分算子配置内容转交给算子对象进行文件内容解析生成配置对象,模型引擎通过配置对象实现代码的生成。同时,对于操作算子、输出算子均采用相同的控制实现机制。a3. Analyze the content in the <inputs> tag to obtain all input operator configuration information (the model engine adopts a microkernel architecture design), cycle through input operators in turn, and obtain operator instance objects based on operator names. The model engine transfers the current part of the operator configuration content to the operator object to parse the file content to generate a configuration object, and the model engine realizes code generation through the configuration object. At the same time, the same control implementation mechanism is adopted for the operation operator and the output operator.
a4、处理算子配置并生成代码,并生成尾类信息。a4. Process operator configuration and generate code, and generate tail class information.
通过对模型文件的解析以及控制,最终生成基于不同计算框架实现的源代码。Through the analysis and control of the model file, the source code based on different computing frameworks is finally generated.
2)模型编译控制技术:2) Model compilation control technology:
图6为本申请实施例三提供的又一种业务处理模型生成方法的流程图。其中,maven表示基础工程文件。如图6所示,本实施例中的业务处理模型生成方法包括如下步骤:FIG. 6 is a flow chart of another method for generating a service processing model provided in Embodiment 3 of the present application. Among them, maven represents the basic project file. As shown in Figure 6, the business processing model generation method in this embodiment includes the following steps:
在源代码生成之后,需要进行代码编译,基于分布式模式的考虑,最终采用maven作为项目管理工具并应用mvn命令进行源码编译。流程如下所示:After the source code is generated, code compilation is required. Based on the consideration of distributed mode, maven is finally used as the project management tool and the mvn command is used to compile the source code. The flow is as follows:
b1、首先将完整的maven模板工程复制指定的目录下,并依据模型定义名称修订模板名称,为确保重复编译模型操作产生二外问题,此处采用删除上次已经编译的模型的处理办法。b1. First, copy the complete maven template project to the specified directory, and revise the template name according to the model definition name. In order to ensure that repeated compilation of the model operation will cause secondary problems, here is the method of deleting the last compiled model.
b2、将已经生成的java文件复制到模型源码目录下,并将工程中所有直接依赖的jar包引入到pom.xml文件中。b2. Copy the generated java file to the model source code directory, and import all directly dependent jar packages in the project into the pom.xml file.
b3、随着操作系统的不同,编译命令也不尽相同,例如:windows系统应用cmd命令,而linux操作系统应用sh命令。b3. With different operating systems, the compilation commands are also different. For example, the cmd command is used in the windows system, and the sh command is used in the linux operating system.
b4、依据操作系统检测,动态选择编译执行指令。b4. According to the detection of the operating system, the compilation and execution instructions are dynamically selected.
b5、执行编译操作执行指令,对编码进行编译。b5. Executing the compiling operation and executing the command to compile the code.
3)任务提交控制技术:3) Task submission control technology:
图7为本申请实施例三提供的又一种业务处理模型生成方法的流程图。其中,公共jar包表示公共依赖包。如图7所示,本实施例中的业务处理模型生成方法包括如下步骤:FIG. 7 is a flow chart of another method for generating a service processing model provided in Embodiment 3 of the present application. Wherein, the public jar package represents a public dependency package. As shown in Figure 7, the business processing model generation method in this embodiment includes the following steps:
c1、首先将编译后模型依赖的公共jar包提交到分布式文件系统(Hadoop Distributed File System,hdfs)上,在spark、flink等计算框架中,提交任务分为两种类型,第一种,为将公共依赖包在提交任务时提交,另外一种,先将公共依赖包提交到hdfs上,在每次任务提交时,只提交增量部分内容,公共依赖包 一般都很大,如果每次执行任务再提交,任务启动速度会非常低。c1. First, submit the public jar package that the compiled model depends on to the distributed file system (Hadoop Distributed File System, hdfs). In computing frameworks such as spark and flink, the submitted tasks are divided into two types. The first type is Submit the public dependency package when submitting the task. Another way is to submit the public dependency package to hdfs first. When submitting each task, only submit the incremental content. The public dependency package is generally very large. If you execute it every time If the task is submitted again, the task startup speed will be very low.
c2、检测计算框架,主要是识别计算框架是flink还是spark,在确定计算框架的前提下,选择具体框架的任务提交管理器。c2. Detect the computing framework, mainly to identify whether the computing framework is flink or spark, and select the task submission manager of the specific framework under the premise of determining the computing framework.
c3、依据计算框架检测,实例化具体的任务提交管理器(spark、flink提交任务管理器完全不同)。c3. According to the calculation framework detection, instantiate a specific task submission manager (spark and flink submit task managers are completely different).
c4、在实例化任务提交管理器之后,调用管理器方法正式提交任务。使用任务提交管理器处理公共依赖包以实现业务处理模型的发布。c4. After instantiating the task submission manager, call the manager method to formally submit the task. Use the task submission manager to process the public dependency package to realize the release of the business processing model.
实施例四Embodiment four
图8为本申请实施例四提供的一种业务处理模型生成装置的结构示意图。本实施例所提供的一种业务处理模型生成装置可以通过软件和/或硬件来实现,可配置于服务器中来实现本申请实施例中的一种业务处理模型生成方法。如图8所示,该装置可包括:需求采集模块810、参数识别模块820和模型生成模块830。FIG. 8 is a schematic structural diagram of an apparatus for generating a service processing model provided in Embodiment 4 of the present application. The device for generating a business processing model provided in this embodiment may be realized by software and/or hardware, and may be configured in a server to implement a method for generating a business processing model in the embodiment of the present application. As shown in FIG. 8 , the device may include: a requirement collection module 810 , a parameter identification module 820 and a model generation module 830 .
其中,需求采集模块810,设置为根据采集到的业务需求信息生成模型描述文件。Wherein, the requirement collection module 810 is configured to generate a model description file according to the collected business requirement information.
参数识别模块820,设置为按照预设标签提取所述模型描述文件中的模型配置参数。The parameter identification module 820 is configured to extract the model configuration parameters in the model description file according to preset tags.
模型生成模块830,设置为按照所述模型配置参数和业务基础系统信息选择模型处理文件构成业务处理模型。The model generation module 830 is configured to select a model processing file to form a business processing model according to the model configuration parameters and business basic system information.
本申请实施例所提供的技术方案中,首先需求采集模块根据采集到的业务需求信息生成模型描述文件,使用参数识别模块按照预设标签提取模型描述文件中的模型配置参数,使用模型生成模块按照模型配置参数和业务基础系统信息选择模型处理文件构成业务处理模型。本申请实施例,通过使用预设标签解析模型描述文件,准确获取业务处理模型的生成使用的模型配置参数,可实现业务处理模型的自动化生成,使用模型处理文件构建业务处理模型,减少业务 处理模型生成过程中的重复开发程度,可降低代码冗余程度,在一定程度上减少了模型开发的时间成本,从而提高业务处理效率。In the technical solution provided by the embodiment of the present application, firstly, the requirement collection module generates a model description file according to the collected business requirement information, uses the parameter identification module to extract the model configuration parameters in the model description file according to the preset label, and uses the model generation module according to Model configuration parameters and business basic system information selection model processing files constitute a business processing model. In the embodiment of this application, by using the preset tags to parse the model description file, the model configuration parameters used in the generation of the business processing model can be accurately obtained, so that the automatic generation of the business processing model can be realized, and the business processing model can be constructed using the model processing file, reducing the number of business processing models The degree of repeated development in the generation process can reduce the degree of code redundancy and reduce the time cost of model development to a certain extent, thereby improving the efficiency of business processing.
可选的,在上述各实施例的基础上,需求采集模块810,可以包括:Optionally, on the basis of the foregoing embodiments, the requirement collection module 810 may include:
信息输入单元,设置为在业务需求采集页面监测用户输入的业务需求信息。The information input unit is configured to monitor the business demand information input by the user on the business demand collection page.
文件生成单元,设置为将所述业务需求信息按照所属类型填充到描述文件模板以生成模型描述文件。The file generation unit is configured to fill the description file template with the business requirement information according to its type to generate a model description file.
可选的,在上述各实施例的基础上,参数识别模块820,可以包括:Optionally, on the basis of the foregoing embodiments, the parameter identification module 820 may include:
关键字匹配单元,设置为在所述模型描述文件内匹配所述预设标签的关键字。A keyword matching unit is configured to match keywords of the preset tags in the model description file.
参数提取单元,设置为提取所述关键字后的参数信息作为所述关键字对应类型的模型配置参数。The parameter extraction unit is configured to extract the parameter information after the keyword as a model configuration parameter of the type corresponding to the keyword.
可选的,所述关键字对应类型至少包括:模型、输入、输出、算子。Optionally, the types corresponding to the keywords at least include: model, input, output, and operator.
可选的,在上述各实施例的基础上,模型生成模块830,可以包括:工程文件生成单元,设置为按照所述模型配置参数的模型信息生成基础工程文件。Optionally, on the basis of the above embodiments, the model generation module 830 may include: a project file generation unit configured to generate a basic project file according to the model information of the model configuration parameters.
信息确定单元,设置为检测所述业务处理模型的运行操作系统并确定所述运行操作系统对应的业务基础系统信息。The information determining unit is configured to detect the running operating system of the business processing model and determine the business basic system information corresponding to the running operating system.
处理文件匹配单元,设置为按照所述业务基础系统信息选择匹配的模型处理文件。The processing file matching unit is configured to select a matching model processing file according to the business basic system information.
模型生成单元,设置为将所述模型配置参数按照类型填充到所述模型处理文件以生成所述业务处理模型。A model generation unit configured to fill the model configuration parameters into the model processing file according to type to generate the business processing model.
可选的,所述业务处理模型生成装置,还包括:Optionally, the device for generating a business processing model further includes:
模型编译模块,设置为按照所述业务基础系统信息编译所述业务处理模型。The model compiling module is configured to compile the business processing model according to the business basic system information.
模型发布模块,设置为使用所述模型配置参数发布所述业务处理模型。A model publishing module, configured to use the model configuration parameters to publish the business processing model.
可选的,模型发布模块,还包括:Optionally, the model publishing module also includes:
系统提交单元,设置为将所述业务处理模型编译生成的公共依赖包提交到分布式文件系统。The system submission unit is configured to submit the public dependency package generated by compiling the business processing model to the distributed file system.
计算框架识别单元,设置为识别所述模型配置参数中计算框架,并按照所述计算框架实例化任务提交管理器。The computing framework identifying unit is configured to identify the computing framework in the model configuration parameters, and instantiate the task submission manager according to the computing framework.
发布实现单元,设置为使用所述任务提交管理器处理所述公共依赖包以实现所述业务处理模型的发布。The release implementation unit is configured to use the task submission manager to process the public dependency package to implement the release of the business processing model.
本申请实施例所提供的一种业务处理模型生成装置可执行本申请任意实施例所提供的一种业务处理模型生成方法,具备执行方法相应的功能模块。A service processing model generating device provided in an embodiment of the present application can execute a service processing model generating method provided in any embodiment of the present application, and has corresponding functional modules for executing the method.
实施例五Embodiment five
图9为本申请实施例五提供的一种电子设备的结构示意图,如图9所示,该设备包括处理器910、存储器920、输入装置930和输出装置940;设备中处理器910的数量可以是至少一个,图9中以一个处理器910为例;设备中的处理器910、存储器920、输入装置930和输出装置940可以通过总线或其他方式连接,图9中以通过总线连接为例。FIG. 9 is a schematic structural diagram of an electronic device provided in Embodiment 5 of the present application. As shown in FIG. 9, the device includes a processor 910, a memory 920, an input device 930, and an output device 940; the number of processors 910 in the device can be It is at least one. In FIG. 9, a processor 910 is taken as an example; the processor 910, memory 920, input device 930, and output device 940 in the device can be connected through a bus or in other ways. In FIG. 9, a bus connection is used as an example.
存储器920作为一种计算机可读存储介质,设置为存储软件程序、计算机可执行程序以及模块,如本申请实施例中的一种业务处理模型生成方法对应的程序指令/模块(例如,一种业务处理模型生成装置中的需求采集模块810、参数识别模块820和模型生成模块830。)。处理器910通过运行存储在存储器920中的软件程序、指令以及模块,从而执行设备的各种功能应用以及数据处理,即实现上述的一种业务处理模型生成方法。The memory 920, as a computer-readable storage medium, is configured to store software programs, computer-executable programs and modules, such as program instructions/modules corresponding to a business processing model generation method in the embodiment of the present application (for example, a business Process the requirement acquisition module 810, the parameter identification module 820 and the model generation module 830 in the model generation device.). The processor 910 executes various functional applications and data processing of the device by running software programs, instructions and modules stored in the memory 920, that is, implements the above-mentioned method for generating a service processing model.
存储器920可主要包括存储程序区和存储数据区,其中,存储程序区可存储操作系统、至少一个功能所需的应用程序;存储数据区可存储根据终端的使用所创建的数据等。此外,存储器920可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件、闪存器件、或其他非易失性固态存储器件。在一些实例中,存储器920可包括相对于处理器910远程设置的存储器,这些远程存储器可以通过网络连接至设备。上述网络的实例包括但不限于互联网、企业内部网、局域网、移动通信网及其组合。The memory 920 may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system and an application program required by at least one function; the data storage area may store data created according to the use of the terminal, and the like. In addition, the memory 920 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other non-volatile solid-state storage devices. In some examples, memory 920 may include memory located remotely from processor 910, which remote memory may be connected to the device via a network. Examples of the aforementioned networks include, but are not limited to, the Internet, intranets, local area networks, mobile communication networks, and combinations thereof.
输入装置930设置为接收输入的数字或字符信息,以及产生与设备的用户设置以及功能控制有关的键信号输入。输出装置940可包括显示屏等显示设备。The input device 930 is configured to receive input numbers or character information, and generate key signal input related to user settings and function control of the device. The output device 940 may include a display device such as a display screen.
实施例六Embodiment six
本申请实施例六还提供一种包含计算机可执行指令的存储介质,所述计算机可执行指令在由计算机处理器执行时用于执行一种业务处理模型生成方法,该方法包括:Embodiment 6 of the present application also provides a storage medium containing computer-executable instructions, the computer-executable instructions are used to execute a method for generating a business processing model when executed by a computer processor, and the method includes:
根据采集到的业务需求信息生成模型描述文件;Generate a model description file based on the collected business requirement information;
按照预设标签提取所述模型描述文件中的模型配置参数;Extracting the model configuration parameters in the model description file according to the preset tags;
按照所述模型配置参数和业务基础系统信息选择模型处理文件构成业务处理模型。A model processing file is selected according to the model configuration parameters and business basic system information to form a business processing model.
当然,本申请实施例所提供的一种包含计算机可执行指令的存储介质,其计算机可执行指令不限于如上所述的方法操作,还可以执行本申请任意实施例所提供的一种业务处理模型生成方法中的相关操作。Of course, the storage medium containing computer-executable instructions provided in the embodiments of the present application, the computer-executable instructions are not limited to the method operations described above, and can also execute a business processing model provided in any embodiment of the present application Generate related operations in the method.
通过以上关于实施方式的描述,所属领域的技术人员可以清楚地了解到,本申请可借助软件及必需的通用硬件来实现,当然也可以通过硬件实现。基于这样的理解,本申请的技术方案本质上或者说对相关技术做出贡献的部分可以以软件产品的形式体现出来,该计算机软件产品可以存储在计算机可读存储介质中,如计算机的软盘、只读存储器(Read-Only Memory,ROM)、随机存取存储器(Random Access Memory,RAM)、闪存(FLASH)、硬盘或光盘等,包括若干指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)执行本申请各个实施例所述的方法。Through the above descriptions about the implementation manners, those skilled in the art can clearly understand that the present application can be realized by software and necessary general-purpose hardware, and of course it can also be realized by hardware. Based on this understanding, the essence of the technical solution of this application or the part that contributes to the related technology can be embodied in the form of software products, and the computer software products can be stored in computer-readable storage media, such as computer floppy disks, Read-only memory (Read-Only Memory, ROM), random access memory (Random Access Memory, RAM), flash memory (FLASH), hard disk or optical disc, etc., including several instructions to make a computer device (which can be a personal computer, A server, or a network device, etc.) executes the methods described in various embodiments of the present application.
值得注意的是,上述业务处理模型生成装置的实施例中,所包括的各个单元和模块只是按照功能逻辑进行划分的,但并不局限于上述的划分,只要能够实现相应的功能即可;另外,各功能单元的具体名称也只是为了便于相互区分,并不用于限制本申请的保护范围。It should be noted that, in the above embodiment of the business processing model generation device, the included units and modules are only divided according to functional logic, but are not limited to the above division, as long as the corresponding functions can be realized; in addition , the specific names of the functional units are only for the convenience of distinguishing each other, and are not used to limit the protection scope of the present application.

Claims (10)

  1. 一种业务处理模型生成方法,包括:A method for generating a business processing model, comprising:
    根据采集到的业务需求信息生成模型描述文件;Generate a model description file based on the collected business requirement information;
    按照预设标签提取所述模型描述文件中的模型配置参数;Extracting the model configuration parameters in the model description file according to the preset tags;
    按照所述模型配置参数和业务基础系统信息选择模型处理文件构成业务处理模型。A model processing file is selected according to the model configuration parameters and business basic system information to form a business processing model.
  2. 根据权利要求1所述方法,其中,所述根据采集到的业务需求信息生成模型描述文件,包括:The method according to claim 1, wherein said generating a model description file according to the collected business requirement information comprises:
    在业务需求采集页面监测用户输入的业务需求信息;Monitor the business demand information input by the user on the business demand collection page;
    将所述业务需求信息按照所属类型填充到描述文件模板以生成模型描述文件。The business requirement information is filled into the description file template according to its type to generate a model description file.
  3. 根据权利要求1所述方法,其中,所述按照预设标签提取所述模型描述文件中的模型配置参数,包括:The method according to claim 1, wherein said extracting the model configuration parameters in the model description file according to the preset label comprises:
    在所述模型描述文件内匹配所述预设标签的关键字;matching keywords of the preset tags in the model description file;
    提取所述关键字后的参数信息作为所述关键字对应类型的模型配置参数。The parameter information after the keyword is extracted is used as the model configuration parameter of the type corresponding to the keyword.
  4. 根据权利要求3所述方法,其中,所述关键字对应类型至少包括:模型、输入、输出、算子。The method according to claim 3, wherein the corresponding types of keywords at least include: model, input, output, and operator.
  5. 根据权利要求1所述方法,其中,所述按照所述模型配置参数和业务基础系统信息选择模型处理文件构成业务处理模型,包括:The method according to claim 1, wherein said selecting a model processing file according to said model configuration parameters and business basic system information constitutes a business processing model, comprising:
    按照所述模型配置参数的模型信息生成基础工程文件;Generate a basic engineering file according to the model information of the model configuration parameters;
    检测所述业务处理模型的运行操作系统并确定所述运行操作系统对应的业务基础系统信息;Detecting the running operating system of the business processing model and determining the business basic system information corresponding to the running operating system;
    按照所述业务基础系统信息选择匹配的模型处理文件;Select a matching model to process the file according to the business basic system information;
    将所述模型配置参数按照类型填充到所述模型处理文件以生成所述业务处理模型。Filling the model configuration parameters into the model processing file according to type to generate the business processing model.
  6. 根据权利要求1所述方法,还包括:The method according to claim 1, further comprising:
    按照所述业务基础系统信息编译所述业务处理模型;compiling the business processing model according to the business basic system information;
    使用所述模型配置参数发布所述业务处理模型。Publishing the business processing model using the model configuration parameters.
  7. 根据权利要求6所述方法,其中,所述使用所述模型配置参数发布所述业务处理模型,包括:The method according to claim 6, wherein said publishing said service processing model using said model configuration parameters comprises:
    将所述业务处理模型编译生成的公共依赖包提交到分布式文件系统;Submitting the public dependency package generated by compiling the business processing model to the distributed file system;
    识别所述模型配置参数中计算框架,并按照所述计算框架实例化任务提交管理器;Identify the computing framework in the model configuration parameters, and instantiate a task submission manager according to the computing framework;
    使用所述任务提交管理器处理所述公共依赖包以实现所述业务处理模型的发布。Using the task submission manager to process the public dependency package to implement the release of the business processing model.
  8. 一种业务处理模型生成装置,包括:A business processing model generation device, comprising:
    需求采集模块,设置为根据采集到的业务需求信息生成模型描述文件;The requirement collection module is configured to generate a model description file according to the collected business requirement information;
    参数识别模块,设置为按照预设标签提取所述模型描述文件中的模型配置参数;The parameter identification module is configured to extract the model configuration parameters in the model description file according to the preset tags;
    模型生成模块,设置为按照所述模型配置参数和业务基础系统信息选择模型处理文件构成业务处理模型。The model generation module is configured to select a model processing file to form a business processing model according to the model configuration parameters and business basic system information.
  9. 一种电子设备,包括:An electronic device comprising:
    至少一个处理器;at least one processor;
    存储器,设置为存储至少一个程序,a memory configured to store at least one program,
    当所述至少一个程序被所述至少一个处理器执行,使得所述至少一个处理器实现如权利要求1-7中任一所述的业务处理模型生成方法。When the at least one program is executed by the at least one processor, the at least one processor is made to implement the service processing model generation method according to any one of claims 1-7.
  10. 一种计算机可读存储介质,所述计算机可读存储介质上存储有计算机程序,所述计算机程序被处理器执行时实现如权利要求1-7中任一所述的业务处理模型生成方法。A computer-readable storage medium, where a computer program is stored on the computer-readable storage medium, and when the computer program is executed by a processor, the service processing model generation method according to any one of claims 1-7 is realized.
PCT/CN2022/102183 2021-11-22 2022-06-29 Service processing model generation method and apparatus, and electronic device and storage medium WO2023087721A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202111383654.3 2021-11-22
CN202111383654.3A CN114064026A (en) 2021-11-22 2021-11-22 Business processing model generation method and device, electronic equipment and storage medium

Publications (1)

Publication Number Publication Date
WO2023087721A1 true WO2023087721A1 (en) 2023-05-25

Family

ID=80278810

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2022/102183 WO2023087721A1 (en) 2021-11-22 2022-06-29 Service processing model generation method and apparatus, and electronic device and storage medium

Country Status (2)

Country Link
CN (1) CN114064026A (en)
WO (1) WO2023087721A1 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115169164B (en) * 2022-09-09 2022-11-18 昆仑智汇数据科技(北京)有限公司 Information processing method, device and equipment of industrial model
CN116009851B (en) * 2022-12-20 2024-05-07 浙江凌骁能源科技有限公司 Method, device, computer equipment and storage medium for integrating and publishing target model

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111930441A (en) * 2020-08-10 2020-11-13 上海熙菱信息技术有限公司 Consul-based configuration file management system and method
CN112836033A (en) * 2021-02-25 2021-05-25 平安银行股份有限公司 Business model management method, device, equipment and storage medium
CN113590115A (en) * 2021-07-30 2021-11-02 北京国腾联信科技有限公司 Method and device for automatically generating service system code
CN113641337A (en) * 2021-07-13 2021-11-12 广州三七互娱科技有限公司 Data processing method, data processing device, computer equipment and storage medium

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111930441A (en) * 2020-08-10 2020-11-13 上海熙菱信息技术有限公司 Consul-based configuration file management system and method
CN112836033A (en) * 2021-02-25 2021-05-25 平安银行股份有限公司 Business model management method, device, equipment and storage medium
CN113641337A (en) * 2021-07-13 2021-11-12 广州三七互娱科技有限公司 Data processing method, data processing device, computer equipment and storage medium
CN113590115A (en) * 2021-07-30 2021-11-02 北京国腾联信科技有限公司 Method and device for automatically generating service system code

Also Published As

Publication number Publication date
CN114064026A (en) 2022-02-18

Similar Documents

Publication Publication Date Title
US11526655B2 (en) Machine learning systems and methods for translating captured input images into an interactive demonstration presentation for an envisioned software product
EP3433732B1 (en) Converting visual diagrams into code
US11188319B2 (en) Systems and methods for entry point-based code analysis and transformation
US11436006B2 (en) Systems and methods for code analysis heat map interfaces
US20170192758A1 (en) Method and apparatus for migration of application source code
WO2023087721A1 (en) Service processing model generation method and apparatus, and electronic device and storage medium
US20160357519A1 (en) Natural Language Engine for Coding and Debugging
CA2641941C (en) Legacy software modernization system
US20190243621A1 (en) Systems and methods for code clustering analysis and transformation
CN103262047A (en) Intelligent code differencing using code clone detection
CN110209486A (en) Spark flow of task construction method and computer readable storage medium based on interface
US20120192069A1 (en) Transforming user interface actions to script commands
Mahapatra et al. Graphical spark programming in IoT mashup tools
Altinbas et al. GUI element detection from mobile UI images using YOLOv5
US20070192083A1 (en) Linguistic structure for data flow diagrams
Mahapatra et al. Graphical flow-based spark programming
US11977473B2 (en) Providing a pseudo language for manipulating complex variables of an orchestration flow
US20180032510A1 (en) Automated translation of source code
CN114860221A (en) Workflow engine and implementation method thereof
Fernandez et al. Java2SDG: stateful big data processing for the masses
Sasaki Hands-on machine learning with TensorFlow. Js: a guide to building ml applications integrated with web technology using the TensorFlow. Js library
Radeck et al. Modeling and calculating capabilities of composite web applications for assisted end user development
Duan et al. The Framework and Fundamental Use of ROS
Punyamurthula Dynamic model generation and semantic search for open source projects using big data analytics
Tanmaya et al. Graphical Flow-based Spark Programming

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 22894264

Country of ref document: EP

Kind code of ref document: A1