app:
  description: Use conventional large language models to simulate o1's chain of thought, providing stronger reasoning capabilities.
  icon: 🍓
  icon_background: '#D1E0FF'
  mode: advanced-chat
  name: llm→o1.en
  use_icon_as_answer_icon: true
kind: app
version: 0.1.2
workflow:
  conversation_variables: []
  environment_variables: []
  features:
    file_upload:
      image:
        enabled: false
        number_limits: 3
        transfer_methods:
        - local_file
        - remote_url
    opening_statement: ''
    retriever_resource:
      enabled: true
    sensitive_word_avoidance:
      enabled: false
    speech_to_text:
      enabled: false
    suggested_questions: []
    suggested_questions_after_answer:
      enabled: false
    text_to_speech:
      enabled: false
      language: ''
      voice: ''
  graph:
    edges:
    - data:
        sourceType: start
        targetType: llm
      id: 1727186697955-llm
      selected: false
      source: '1727186697955'
      sourceHandle: source
      target: llm
      targetHandle: target
      type: custom
    - data:
        isInIteration: false
        sourceType: llm
        targetType: parameter-extractor
      id: llm-source-1727188958486-target
      selected: false
      source: llm
      sourceHandle: source
      target: '1727188958486'
      targetHandle: target
      type: custom
      zIndex: 0
    - data:
        isInIteration: true
        iteration_id: '1727189041788'
        sourceType: iteration-start
        targetType: code
      id: 1727189041788start-source-1727189052583-target
      selected: false
      source: 1727189041788start
      sourceHandle: source
      target: '1727189052583'
      targetHandle: target
      type: custom
      zIndex: 1002
    - data:
        isInIteration: true
        iteration_id: '1727189041788'
        sourceType: code
        targetType: llm
      id: 1727189052583-source-1727189055973-target
      selected: false
      source: '1727189052583'
      sourceHandle: source
      target: '1727189055973'
      targetHandle: target
      type: custom
      zIndex: 1002
    - data:
        isInIteration: false
        sourceType: iteration
        targetType: template-transform
      id: 1727189041788-source-1727189088392-target
      selected: false
      source: '1727189041788'
      sourceHandle: source
      target: '1727189088392'
      targetHandle: target
      type: custom
      zIndex: 0
    - data:
        isInIteration: false
        sourceType: template-transform
        targetType: llm
      id: 1727189088392-source-1727189151263-target
      selected: false
      source: '1727189088392'
      sourceHandle: source
      target: '1727189151263'
      targetHandle: target
      type: custom
      zIndex: 0
    - data:
        isInIteration: false
        sourceType: llm
        targetType: answer
      id: 1727189151263-source-answer-target
      selected: false
      source: '1727189151263'
      sourceHandle: source
      target: answer
      targetHandle: target
      type: custom
      zIndex: 0
    - data:
        isInIteration: false
        sourceType: parameter-extractor
        targetType: iteration
      id: 1727188958486-source-1727189041788-target
      selected: false
      source: '1727188958486'
      sourceHandle: source
      target: '1727189041788'
      targetHandle: target
      type: custom
      zIndex: 0
    nodes:
    - data:
        desc: ''
        selected: false
        title: Start
        type: start
        variables: []
      height: 54
      id: '1727186697955'
      position:
        x: -468.24076313347575
        y: 267.1704432399898
      positionAbsolute:
        x: -468.24076313347575
        y: 267.1704432399898
      selected: false
      sourcePosition: right
      targetPosition: left
      type: custom
      width: 244
    - data:
        context:
          enabled: false
          variable_selector: []
        desc: ''
        memory:
          role_prefix:
            assistant: ''
            user: ''
          window:
            enabled: false
            size: 10
        model:
          completion_params:
            temperature: 0.7
          mode: chat
          name: gpt-4o
          provider: openai
        prompt_template:
        - edition_type: basic
          id: 0d040cf5-7c6e-4bdc-bf09-96a5c17bc3fa
          role: system
          text: You are an AI assistant capable of detailed, step-by-step thinking. When you receive a question, don't give an immediate answer. Instead, break down the problem-solving process into corresponding steps through step-by-step reasoning. Only provide the names and task descriptions for the steps, without solving them yourself. Ensure there are at least 3 steps.
        selected: false
        title: Task Breakdown
        type: llm
        variables: []
        vision:
          configs:
            detail: high
          enabled: true
      height: 98
      id: llm
      position:
        x: -468.24076313347575
        y: 378.7262570149305
      positionAbsolute:
        x: -468.24076313347575
        y: 378.7262570149305
      selected: true
      sourcePosition: right
      targetPosition: left
      type: custom
      width: 244
    - data:
        answer: '## Problem Analysis Steps

          {{#1727189088392.output#}}


          ##  Final Answer

          {{#1727189151263.text#}}'
        desc: ''
        selected: false
        title: Direct Reply
        type: answer
        variables: []
      height: 141
      id: answer
      position:
        x: 370.6430517887744
        y: 488.1130054358871
      positionAbsolute:
        x: 370.6430517887744
        y: 488.1130054358871
      selected: false
      sourcePosition: right
      targetPosition: left
      type: custom
      width: 244
    - data:
        desc: ''
        instruction: "Extract the array of steps from the content, example as follows: \n[ \n\t{ \n\t\t\"name\": \"Step Name\", \n\t\t\"content\": \"Task Description\" \n\t}, \n\t{\n\t\t\"name\": \"Step Name\", \n\t\t\"content\": \"Task Description\"\n\t}, \n\t... \n]"
        model:
          completion_params:
            temperature: 0.7
          mode: chat
          name: gpt-4o-mini
          provider: openai
        parameters:
        - description: Extract the array of steps from the content
          name: steps
          required: true
          type: array[object]
        query:
        - llm
        - text
        reasoning_mode: prompt
        selected: false
        title: Task Extraction
        type: parameter-extractor
        variables: []
      height: 98
      id: '1727188958486'
      position:
        x: -468.24076313347575
        y: 535.3490014915617
      positionAbsolute:
        x: -468.24076313347575
        y: 535.3490014915617
      selected: false
      sourcePosition: right
      targetPosition: left
      type: custom
      width: 244
    - data:
        desc: ''
        height: 365
        iterator_selector:
        - '1727188958486'
        - steps
        output_selector:
        - '1727189055973'
        - text
        output_type: array[string]
        selected: false
        start_node_id: 1727189041788start
        title: Iterate Tasks
        type: iteration
        width: 416
      height: 365
      id: '1727189041788'
      position:
        x: -138.53115933482604
        y: 267.1704432399898
      positionAbsolute:
        x: -138.53115933482604
        y: 267.1704432399898
      selected: false
      sourcePosition: right
      targetPosition: left
      type: custom
      width: 416
      zIndex: 1
    - data:
        desc: ''
        isInIteration: true
        selected: false
        title: ''
        type: iteration-start
      draggable: false
      height: 44
      id: 1727189041788start
      parentId: '1727189041788'
      position:
        x: 24
        y: 68
      positionAbsolute:
        x: -114.53115933482604
        y: 335.1704432399898
      selectable: false
      sourcePosition: right
      targetPosition: left
      type: custom-iteration-start
      width: 44
      zIndex: 1002
    - data:
        code: "\ndef main(step) -> dict:\n    # Clean to get a dictionary containing only step name and content\n    step_name = step['name']\n    step_content = step['content']\n    return {\n        'name': step_name,\n        'content': step_content\n    }\n"
        code_language: python3
        desc: ''
        isInIteration: true
        iteration_id: '1727189041788'
        outputs:
          content:
            children: null
            type: string
          name:
            children: null
            type: string
        selected: false
        title: Parse Task
        type: code
        variables:
        - value_selector:
          - '1727189041788'
          - item
          variable: step
      height: 54
      id: '1727189052583'
      parentId: '1727189041788'
      position:
        x: 95.12571749609936
        y: 83.8283582426188
      positionAbsolute:
        x: -43.40544183872669
        y: 350.99880148260866
      selected: false
      sourcePosition: right
      targetPosition: left
      type: custom
      width: 244
      zIndex: 1002
    - data:
        context:
          enabled: true
          variable_selector:
          - '1727189041788'
          - index
        desc: ''
        isInIteration: true
        iteration_id: '1727189041788'
        model:
          completion_params:
            temperature: 0.7
          mode: chat
          name: gpt-4o
          provider: openai
        prompt_template:
        - edition_type: basic
          id: 11ed350b-43a1-4b4b-a66f-c72e12615276
          role: system
          text: '## Question

            """{{#sys.query#}}"""


            ## Task Background

            This is a step in the workflow. The previous workflow process will break down the problem into N steps.


            ## Task

            Based on the steps broken down from the problem, answer the task for the specified step. The current task name: {{#1727189052583.name#}}, task description: {{#1727189052583.content#}}


            ## Initialization

            No need to answer the entire question, just analyze and answer the question for this step.


            ## Output

            Use Markdown to output the answer, example as follows:

            - {{#1727189052583.name#}}: [Step Answer]'
        selected: false
        title: Execute Task
        type: llm
        variables: []
        vision:
          configs:
            detail: high
          enabled: true
      height: 98
      id: '1727189055973'
      parentId: '1727189041788'
      position:
        x: 94.73421283035361
        y: 225.97858189606833
      positionAbsolute:
        x: -43.79694650447243
        y: 493.1490251360582
      selected: false
      sourcePosition: right
      targetPosition: left
      type: custom
      width: 244
      zIndex: 1002
    - data:
        desc: ''
        selected: false
        template: '{{ step_answer | join("\n")}}'
        title: Merge Results
        type: template-transform
        variables:
        - value_selector:
          - '1727189041788'
          - output
          variable: step_answer
      height: 54
      id: '1727189088392'
      position:
        x: 370.6430517887744
        y: 267.1704432399898
      positionAbsolute:
        x: 370.6430517887744
        y: 267.1704432399898
      selected: false
      sourcePosition: right
      targetPosition: left
      type: custom
      width: 244
    - data:
        context:
          enabled: false
          variable_selector: []
        desc: ''
        model:
          completion_params:
            temperature: 0.7
          mode: chat
          name: gpt-4o
          provider: openai
        prompt_template:
        - edition_type: basic
          id: e6416010-f755-4c0b-9aa9-f3727bf28ca4
          role: system
          text: '## Original Question

            """{{#sys.query#}}"""


            ## Task

            Review the original question and summarize the following analysis (please note there might be errors, correct them if found), then provide the final answer to the question. The answer should be concise.

            {{#1727189088392.output#}}'
        selected: false
        title: Summarize Answer
        type: llm
        variables: []
        vision:
          configs:
            detail: high
          enabled: true
      height: 98
      id: '1727189151263'
      position:
        x: 370.6430517887744
        y: 356.79597592747405
      positionAbsolute:
        x: 370.6430517887744
        y: 356.79597592747405
      selected: false
      sourcePosition: right
      targetPosition: left
      type: custom
      width: 244
    viewport:
      x: 21.432651797610276
      y: -203.0067787013104
      zoom: 1.2799680131746822
