Skip to main content

Workflow Creation Agent

  1. Select "Advanced Agent" (creation steps are the same as creating a regular agent)
    • Build Type
      • Advanced Mode: Quickly build complex workflows to precisely meet business requirements.
      • Application Mode: Create complete, advanced orchestration applications with a user-friendly interface, delivering a seamless small language model experience.

  1. Configure the workflow according to actual business needs:
  • Start, End: Built-in input and output modules, customizable input/output parameters and fields;
  • Model: Select the model to use in this module, input variables obtained from other modules, edit prompts and output messages, and save them as variables;
  • Knowledge Base Retrieval: Retrieve the most matching information from the selected knowledge base based on input variables and return it;
  • Skill: Select one of the skills to perform input/output actions through that skill;
  • Code: Customize and create code functions based on output variables from other modules;
  • Selector: Connect multiple downstream branches; if the set condition is met, only the corresponding branch runs; if none are met, only the "Else" branch runs;
  • Intent Recognition: Used for recognizing user input intent and matching it with preset intent options;
  • Text Formatter: Used to process the format of multiple string-type variables;
  • Data Source: Select data sources to add referable variable content;
  • File Retrieval: Search within uploaded files to find relevant answers based on input questions;
  • Loop: Repeat a set of tasks for each item in a list, with optional parallel processing.

  1. Detailed Introduction of Nodes
  • Start
    • Start Node: The starting node of the workflow, used to set the information required to initiate the workflow.
    • Input: Simply understood as informing the LLM in advance about the basic information (input parameters) needed to complete a task. When in use, the LLM remembers these information requirements and automatically calls these preset parameters once it detects the timing to start the task in the conversation, placing the parameters in the corresponding positions to initiate the entire process.
    • Processing Logic: Direct pass-through (By pass), no processing is done, just passing the user's input content intact to the next node.
    • Output Result: All input content is output directly.

  • Model
    • Model: Calls the large language model, using variables and prompts to generate responses.
    • Input: Dropdown to select an existing model and choose input variable names.
    • Input Parameters: query (String, from upstream or user input)
    • Configuration Parameters:
      • One or more Tools
      • Model
        • GPT (GPT or other models)
        • Temperature: Controls creativity; the higher the value, the more creative and random the response.
        • Top P: Limits the range of selected words through a "probability threshold," controlling response diversity.
        • Max Reply Length: Limits the maximum number of words the AI can reply at once.
      • System Prompt: Hidden instructions given to the AI to control the overall style.
      • User Prompt: User input content or questions.
      • History: Previous conversation turns to maintain context understanding.
    • Processing Logic: Pass the input to the large language model (LLM) for processing; the model generates responses based on configuration.
    • Output Result: Text content generated by the model.

💡 Tip: You need to connect to the preceding node first to select variables from other nodes as input variables for the current node.

  • Skill (partial examples)

    • Website Reading: Can read static text on web pages (but cannot see dynamically loaded content).
    • Text-to-Image Generation: Converts a piece of text into an image (outputs image URL).
    • Tencent Search: Calls the search engine to return search results.

  • Code
    • Code: Write code to process input variables and generate return values.
    • Input: Used to receive externally passed variables; it is the entry point for data required by the code execution, providing raw data for subsequent code processing.
    • Input Parameters: query (string, code request passed by user or upstream)
    • Configuration Parameters: Settings related to code execution
      • Maximum Runtime
      • Code Content (Code Input)
    • Processing Logic:
      • Run code in a secure sandbox environment (based on RestrictedPython or designated platform)
      • Limit runtime and access permissions to avoid security risks
    • Output Result: After processing input data, the code outputs the result as a specified variable, serving as the exit point of the code processing.

  • Selector

    • Selector: Acts as a conditional judgment in workflow orchestration. It connects multiple downstream branches and decides the execution path based on set conditions.
    • Conditional Branches: Multiple conditions can be set, such as "if - priority 1". By configuring referenced variables, selecting conditions (e.g., equals, greater than, etc.), and comparison values, it judges whether the condition is met. If met, the corresponding branch process runs.
    • Processing Logic: Different paths are taken based on different conditions (if no condition is met, the Else path is taken).
    • Output Result: No direct output; it only determines the direction of the next node.

  • Intent Recognition

    • Intent Recognition: A key part of natural language processing; this module analyzes user input content to determine the true intent and match it with preset options.
    • Model: Select the model used for intent recognition; the model determines the capability and effect of intent recognition.
    • Intent Matching: User intent descriptions can be pre-input as matching criteria, and other intents can be added; the system judges which preset intent the user input matches.
    • Advanced Settings: System prompt content can be set, referencing input variables to optimize prompt effect; the number of history memories can also be set, allowing the model to refer to past conversation information to improve recognition accuracy.
    • Processing Logic: Determine the user's true intent and classify the input into the corresponding category.

  • Knowledge Base Retrieval
    • Input: Provide retrieval keywords and other raw data for knowledge base retrieval by defining variable names and setting parameter values.
    • Processing Logic: Retrieve from the knowledge base based on input and parameters, returning snippets or FAQs.
    • Knowledge Base: Select a specific knowledge base as the retrieval scope; the system searches for matching information within this scope.
    • Maximum Recall Number: Set the maximum number of matching results returned from the knowledge base to avoid returning excessive data.
    • Output: Outputs the matching information retrieved from the knowledge base as specified variables for subsequent workflow use.

  • Text Formatter
    • Text: Mainly used to process the format of string-type variables.
    • Input: Variable names can be defined and parameter values obtained by reference to provide raw string data for subsequent text processing.
    • Processing Logic: Perform simple processing on text
      • String concatenation
      • String splitting
    • String Concatenation: Provides a text editing area where input variables can be referenced by variable names as needed to concatenate multiple strings or perform other formatting.

  • File Retrieval
    • File Retrieval: A functional module for searching and other operations on file content.
    • Input: Provide retrieval keywords and other input information by defining variable names and referencing parameter values, serving as the basis for file content search.
    • File: Files to be processed can be added to this node to determine the scope of retrieval.

  • Data Source
    • Data Source: Select the data source to connect.
    • Processing Logic: Convert natural language into SQL to query the database and return results.
    • Output: Outputs data from the data source to the next node.

  • Loop
    • Loop Node: Used to repeat a set of tasks a specified number of times or over a specified data collection. Different loop modes can be configured to flexibly achieve batch processing or repetitive operations.
    • Loop Types: Supports two modes
      • Use array loop: Execute tasks sequentially for each element in the input array.
      • Use numeric loop: Execute tasks repeatedly according to the set number of times.
    • Loop Number/Array:
      • When "Numeric Loop" is selected, a specific number must be input, e.g., 2, meaning the task will be executed 2 times.
      • When "Array Loop" is selected, an array variable must be provided; the system will take elements from the array one by one as input to execute tasks.
    • Parallel Execution: Optional feature. If enabled, the system processes multiple loop tasks simultaneously to improve efficiency. Users can set the maximum parallel number to control resource usage.

Workflow Example

In this scenario, the workflow function is used to build a complete "Microsoft Support Ticket Issue Analytics" process, with the specific flow as follows:

  1. Start Node
    The starting point of the process, included by default in the system.
  2. Data Source Node
    Used to connect the raw data required for ticket analysis.
  3. Knowledge Base Node
    Connects knowledge documents containing analysis reference materials, serving as theoretical support for AI analysis.
  4. Model Node
    Based on the AI model, combines data source and knowledge base content for comprehensive analysis, generating ticket issue analysis results.
  5. End Node
    The endpoint of the process, outputs the analysis results from the model node. This node is included by default in the system.

The data source node and knowledge base node are configured in parallel, while the model node aggregates and processes information from both to ensure the output results have data basis and theoretical support.

The final effect is as follows:

Note: This example is only a simple application of the advanced orchestration feature to demonstrate its basic workflow effect. Advanced orchestration has powerful flexibility and extensibility, supporting complex business logic and intelligent automation workflows through various node types, and can be widely applied in various practical business scenarios.