Implementation method for packaging VXML protocol based on frame tag taglib
By encapsulating the VXML protocol into a basic tag library using taglib, the business logic and presentation layer are decoupled, solving the problem of coupling between VXML and Java code in IVR platform development. This enables an efficient and readable IVR development process, improving development efficiency and system flexibility.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-01-20
- Publication Date
- 2026-05-08
AI Technical Summary
In the development of existing IVR platforms, the VXML protocol and Java code are tightly coupled, requiring developers to master both VXML protocol and Java programming. This results in complex and inefficient development, and the business logic cannot be completely decoupled from platform characteristics, leading to poor stability and robustness.
By encapsulating the VXML protocol into a basic tag library using taglib, configuring tag input and output parameters, and calling tags using custom names in JSP pages, the business logic and presentation layer are decoupled, generating XML documents that conform to the VXML protocol.
It improves the reusability and readability of IVR business logic, reduces development difficulty, enhances development efficiency and code quality, broadens the talent pool, and strengthens the system's flexibility and scalability.
Smart Images

Figure FT_1 
Figure FT_2
Abstract
Description
Technical Field
[0001] This invention relates to the field of communication technology, and specifically to an implementation method for encapsulating the VXML protocol based on a tag library (taglib). Background Technology
[0002] Interactive voice response systems are widely used in customer service. VXML is a standardized markup language for providing voice dialogue services for IVR systems, aiming to decouple business logic from platform implementation.
[0003] However, in actual industry practice, the current situation is far from ideal. Although VXML is considered an international recommendation, IVR platform vendors often adopt a "use what's beneficial, discard what's not" strategy based on their own interests, resulting in a large number of non-standard and fragmented VXML development processes. This makes it impossible to completely separate business logic from platform characteristics, requiring developers to have in-depth knowledge of the development details of specific IVR platforms. Due to the varying levels of understanding of different platforms among developers and the inconsistent quality of their development tools, the resulting IVR applications exhibit significant differences in stability and robustness, leading to unreliable deployment quality and making customers' businesses dependent on specific IVR platforms.
[0004] Existing technical solutions typically rely on the VXML 2.0 protocol, where the IVR business system directly writes Java code logic within a JSP page to dynamically concatenate VXML tags through Java code checks. The IVR platform then accesses the JSP page via HTTP to retrieve the generated VXML document. This approach has significant drawbacks: developers must possess in-depth knowledge of both the VXML protocol and Java programming; the tight coupling between business logic and view rendering (VXML generation) leads to complex code modifications, high redundancy, poor readability, and ultimately, low development efficiency. Summary of the Invention
[0005] The purpose of this invention is to overcome the shortcomings of existing technologies and provide an implementation method for encapsulating the VXML protocol based on the taglib framework. This method uses taglib to parse and encapsulate the VXML protocol into reusable JSP tags, thereby improving the reusability and readability of IVR business logic and reducing development difficulty.
[0006] To achieve the above objectives, the present invention adopts the following technical solution: a method for encapsulating the VXML protocol based on the taglib framework, comprising the following steps: Step S1: Based on the VXML protocol, a basic tag library is formed by encapsulating the tag library. The basic tag library is used to implement IVR service functions. Step S2: Configure the input and output parameters of each tag in the basic tag library; Step S3: Set a custom name for each tag in the basic tag library; Step S4: Import the basic tag library into the JSP page, call the corresponding tag by custom name, assemble the tag, and form an executable JSP page structure that conforms to the business logic; Step S5: In response to the business request from the IVR service platform, execute the JSP page by executing the assembled tags, generate an XML document conforming to the VXML protocol and return it to the IVR service platform, which then parses the XML document and executes the corresponding call actions.
[0007] Furthermore, in step S1, based on the VXML protocol, a basic tag library is formed by encapsulating the tags using taglib, specifically including: Retrieve the contents of the VXML protocol file; Use the taglib tool to parse the file structure of the VXML protocol; Based on the parsed VXML elements and logic, a basic tag library based on taglib is encapsulated.
[0008] Further, in step S2, the input and output parameters of each tag in the basic tag library are configured, specifically as follows: Iterate through all tags in the base tag library, and define the input and output parameters for each tag.
[0009] Furthermore, in step S3, a custom name is set for each tag in the basic tag library, specifically as follows: Iterate through the base tag library with configured input and output parameters, set a custom name for each tag, and record the mapping relationship between the custom name and the tag entity.
[0010] Further, in step S4, tag assembly is performed, specifically as follows: Include the configured basic tag library in the header of the target JSP page. Based on business requirements, call the corresponding tag with a custom name at the corresponding location on the JSP page and pass in the corresponding input parameters to complete the tag assembly.
[0011] Furthermore, the IVR service functions implemented by the tags encapsulated in the basic tag library include at least one of the following: playback, key rewind, queuing, call transfer, and call termination.
[0012] Furthermore, the specific application of the method is as follows: In the scenario of call request initialization, the IVR service platform triggers a business request to the IVR application platform that carries the JSP page through an HTTP interface request. In the business process assembly scenario, the IVR application platform, based on the business process, calls the corresponding tags and assembles the data to generate an XML document and returns it to the IVR service platform to respond to business requests. In the business parsing and execution scenario, the IVR service platform parses the received XML document and drives the underlying communication resources to perform corresponding call actions.
[0013] The present invention also provides a computer device, comprising: at least one processor, at least one memory, and computer program instructions stored in the memory, which implement the above-described method when executed by the processor.
[0014] The present invention also provides a computer-readable storage medium having stored thereon computer program instructions that, when executed by a processor, implement the above-described method.
[0015] Compared with the prior art, the present invention has the following beneficial effects: 1. Decoupling and Reusability: By encapsulating the complex VXML protocol and business logic in an independent tag library, the business logic and presentation layer are decoupled. Developers do not need to deeply understand the details of VXML; they can build complex processes using simple tags, greatly improving code reusability.
[0016] 2. Improved development efficiency and readability: JSP pages consist of concise and clear custom tags, rather than a mixture of lengthy Java code and VXML tags. This makes the code easier to write, read, and maintain, thereby significantly improving development efficiency and quality.
[0017] 3. Lowering the technical threshold: Application developers only need basic Java and JSP knowledge to develop IVR business applications, reducing the dependence on proficiency in specific IVR platforms and VXML protocols and broadening the talent pool.
[0018] 4. Flexibility and scalability: By managing tag attributes in a configuration-based manner and defining frequently used variables as constants or placing them in the cache, it is easier to adjust business rules and enhances the flexibility and scalability of the system. Attached Figure Description
[0019] Figure 1 This is a flowchart of the implementation method of encapsulating the VXML protocol based on the frame tag library provided in the embodiments of the present invention; Figure 2This is a schematic diagram of the system architecture and interaction provided in the embodiments of the present invention. Detailed Implementation
[0020] The present invention will be further described below with reference to the accompanying drawings and embodiments.
[0021] It should be noted that the following detailed descriptions are exemplary and intended to provide further explanation of this application. Unless otherwise specified, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application pertains.
[0022] It should be noted that the terminology used herein is for the purpose of describing particular embodiments only and is not intended to limit the exemplary embodiments according to this application. As used herein, the singular form is intended to include the plural form as well, unless the context clearly indicates otherwise. Furthermore, it should be understood that when the terms "comprising" and / or "including" are used in this specification, they indicate the presence of features, steps, operations, devices, components, and / or combinations thereof.
[0023] like Figure 1 As shown, this embodiment provides a method for encapsulating the VXML protocol based on the taglib framework, including the following steps: Step S1: Based on the VXML protocol, a basic tag library is formed by encapsulating the tags using taglib. This basic tag library is used to implement IVR service functions. Specifically, it includes: Step S11: Obtain the content of the VXML protocol file; Step S12: Use the taglib tool to parse the file structure of the VXML protocol; Step S13: Based on the parsed VXML elements and logic, encapsulate them to form a basic tag library based on taglib.
[0024] The IVR service functions implemented by the tags encapsulated in the basic tag library include at least one of the following: playback, key rewind, queuing, transfer, and hang-up.
[0025] Step S2: Configure the input and output parameters of each tag in the basic tag library. Specifically: Iterate through all tags in the basic tag library, and define the input parameters (such as tag name and key content) and output parameters (such as key value) for each tag.
[0026] Step S3: Set a custom name for each tag in the basic tag library. Specifically: Iterate through the base tag library with configured input and output parameters, set a custom name for each tag, and record the mapping relationship between the custom name and the tag entity.
[0027] Step S4: Import the basic tag library into the JSP page, call the corresponding tags by custom names, assemble the tags, and form an executable JSP page structure that conforms to the business logic. Specifically: Include the configured basic tag library in the header of the target JSP page. Based on business requirements, call the corresponding tag with a custom name at the corresponding location on the JSP page and pass in the corresponding input parameters to complete the tag assembly.
[0028] Step S5: In response to the business request from the IVR service platform, execute the JSP page by executing the assembled tags, generate an XML document conforming to the VXML protocol and return it to the IVR service platform, which then parses the XML document and executes the corresponding call actions.
[0029] like Figure 2 As shown, the specific application of the method and the interaction process between the IVR service platform and the IVR application platform are as follows: 1) In the call request initialization scenario, after the IVR service platform receives the incoming call (telephone information), it triggers a business request to the IVR application platform that carries the JSP page through an HTTP interface request.
[0030] 2) In the business process assembly scenario, the IVR application platform locates the corresponding JSP page according to the requested URL, and then the business process is assembled by calling the corresponding tags. Finally, a complete XML document (encapsulated component) conforming to the VXML protocol is generated and returned to the IVR service platform as a response to the business request.
[0031] 3) In the business parsing and execution scenario, the IVR service platform parses the received XML document and drives the underlying communication resources to perform corresponding call actions (playback, key rewind, queuing, transfer, hang-up, etc.).
[0032] As can be seen from the above embodiments, the present invention frees developers from the tedious and error-prone manual writing of VXML tags, and enables complex functions to be achieved by simply configuring tag attributes, which greatly improves development efficiency, code quality and maintainability.
[0033] This embodiment also provides a computer device, including: at least one processor, at least one memory, and computer program instructions stored in the memory, which implement the above-described method when executed by the processor.
[0034] This embodiment also provides a computer-readable storage medium storing computer program instructions that, when executed by a processor, implement the above-described method.
[0035] Those skilled in the art will understand that embodiments of this application can be provided as methods, systems, or computer program products. Therefore, this application can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, this application can take the form of a computer program product embodied on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0036] This application is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of this application. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart... Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.
[0037] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.
[0038] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.
[0039] The above description is merely a preferred embodiment of the present invention and is not intended to limit the invention in any other way. Any person skilled in the art may make changes or modifications to the above-disclosed technical content to create equivalent embodiments. However, any simple modifications, equivalent changes, and modifications made to the above embodiments based on the technical essence of the present invention without departing from the scope of the present invention shall still fall within the protection scope of the present invention.
Claims
1. A method for encapsulating the VXML protocol based on the taglib framework, characterized in that, Includes the following steps: Step S1: Based on the VXML protocol, a basic tag library is formed by encapsulating the tag library. The basic tag library is used to implement IVR service functions. Step S2: Configure the input and output parameters of each tag in the basic tag library; Step S3: Set a custom name for each tag in the basic tag library; Step S4: Import the basic tag library into the JSP page, call the corresponding tag by custom name, assemble the tag, and form an executable JSP page structure that conforms to the business logic; Step S5: In response to the business request from the IVR service platform, execute the JSP page by executing the assembled tags, generate an XML document conforming to the VXML protocol and return it to the IVR service platform, which then parses the XML document and executes the corresponding call actions.
2. The implementation method of encapsulating the VXML protocol based on the frame tag library according to claim 1, characterized in that, In step S1, based on the VXML protocol, a basic tag library is formed by encapsulating the tags using taglib, specifically including: Retrieve the contents of the VXML protocol file; Use the taglib tool to parse the file structure of the VXML protocol; Based on the parsed VXML elements and logic, a basic tag library based on taglib is encapsulated.
3. The implementation method of encapsulating the VXML protocol based on the frame tag library according to claim 1, characterized in that, In step S2, the input and output parameters of each tag in the basic tag library are configured, specifically as follows: Iterate through all tags in the base tag library, and define the input and output parameters for each tag.
4. The implementation method of encapsulating the VXML protocol based on the frame tag library according to claim 1, characterized in that, In step S3, a custom name is set for each tag in the basic tag library, specifically as follows: Iterate through the base tag library with configured input and output parameters, set a custom name for each tag, and record the mapping relationship between the custom name and the tag entity.
5. The implementation method of encapsulating the VXML protocol based on the frame tag library according to claim 1, characterized in that, In step S4, tag assembly is performed, specifically as follows: Include the configured basic tag library in the header of the target JSP page. Based on business requirements, call the corresponding tag with a custom name at the corresponding location on the JSP page and pass in the corresponding input parameters to complete the tag assembly.
6. The implementation method of encapsulating the VXML protocol based on the frame tag library according to claim 1, characterized in that, The IVR service functions implemented by the tags encapsulated in the basic tag library include at least one of the following: playback, key rewind, queuing, transfer, and hang-up.
7. The implementation method of encapsulating the VXML protocol based on the frame tag library according to claim 1, characterized in that, The specific application of the method is as follows: In the scenario of call request initialization, the IVR service platform triggers a business request to the IVR application platform that carries the JSP page through an HTTP interface request. In the business process assembly scenario, the IVR application platform, based on the business process, calls the corresponding tags and assembles the data to generate an XML document and returns it to the IVR service platform to respond to business requests. In the business parsing and execution scenario, the IVR service platform parses the received XML document and drives the underlying communication resources to perform corresponding call actions.
8. A computer device, characterized in that, include: At least one processor, at least one memory, and computer program instructions stored in the memory, which, when executed by the processor, implement the method as described in any one of claims 1-7.
9. A computer-readable storage medium having computer program instructions stored thereon, characterized in that, When the computer program instructions are executed by a processor, the method described in any one of claims 1-7 is implemented.