Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FEATURE] Get Workflow API #170

Closed
Tracked by #88
amitgalitz opened this issue Nov 15, 2023 · 1 comment
Closed
Tracked by #88

[FEATURE] Get Workflow API #170

amitgalitz opened this issue Nov 15, 2023 · 1 comment
Assignees
Labels
enhancement New feature or request

Comments

@amitgalitz
Copy link
Member

Is your feature request related to a problem?

We should have a get workflow API for a specific workflow to complement the search workflows API we currently have

What solution would you like?

The API path should be /_plugins/_flow_framework/workflow/yfRsposBMbAFAhZEJ1qE/ and should return the entire template object stored in the global context index. The response should be similar to the original template given:

{
  "name": "create-connector-register-deploy-model",
  "description": "test case",
  "use_case": "TEST_CASE",
  "version": {
    "template": "1.0.0",
    "compatibility": [
      "2.12.0",
      "3.0.0"
    ]
  },
  "workflows": {
    "provision": {
      "nodes": [
        {
          "id": "workflow_step_1",
          "type": "create_connector",
          "user_inputs": {
            "name": "OpenAI Chat Connector",
            "description": "The connector to public OpenAI model service for GPT 3.5",
            "version": "1",
            "protocol": "http",
            "parameters": {
              "endpoint": "api.openai.com",
              "model": "gpt-3.5-turbo"
            },
            "credential": {
              "openAI_key": "123"
            },
            "actions": [
              {
                "action_type": "predict",
                "method": "POST",
                "url": "https://${parameters.endpoint}/v1/chat/completions"
              }
            ]
          }
        },
        {
          "id": "workflow_step_2",
          "type": "register_model",
          "previous_node_inputs": {
            "workflow_step_1": "connector_id"
          },
          "user_inputs": {
            "name": "openAI-gpt-3.5-turbo",
            "function_name": "remote",
            "description": "test model"
          }
        }
      ],
      "edges": [
        {
          "source": "workflow_step_1",
          "dest": "workflow_step_2"
        }
      ]
    }
  }
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants