Spaces:
Running
Running
Download workflow.json from hmb/decision-models-comparison: direct link, hf CLI and curl.
- Browser
- Download file 14.6 kB
-
https://huggingface.co/spaces/hmb/decision-models-comparison/resolve/main/workflow.json
- Command line
-
hf download hf://spaces/hmb/decision-models-comparison/workflow.json
-
curl -L -o workflow.json https://huggingface.co/spaces/hmb/decision-models-comparison/resolve/main/workflow.json
14.6 kB
| { | |
| "schema_version": "2", | |
| "name": "Decision Models Comparison", | |
| "references": [ | |
| { | |
| "id": "prompt", | |
| "role": "reference", | |
| "label": "Prompt", | |
| "asset_type": "text", | |
| "inputs": [ | |
| { | |
| "id": "in", | |
| "label": "Text", | |
| "type": "text" | |
| } | |
| ], | |
| "outputs": [ | |
| { | |
| "id": "out", | |
| "label": "Text", | |
| "type": "text" | |
| } | |
| ], | |
| "data": { | |
| "out": "From: GitHub <noreply@github-notifications.com>\nSubject: [GitHub] Action required: unusual OAuth app authorization\n\nHi there,\n\nA third-party OAuth application (\"CI Deploy Helper\") was granted\nfull repo and workflow access to your account from a new device\n(Chrome on Windows, SΓ£o Paulo, BR).\n\nIf you did not authorize this, revoke access within 12 hours to\nprevent your repositories and secrets from being exposed:\n\nhttps://github.com.security-review.app/settings/applications\n\nIf you made this change, you can ignore this email.\n\nThanks,\nThe GitHub Security Team" | |
| }, | |
| "width": 514 | |
| }, | |
| { | |
| "id": "question", | |
| "role": "reference", | |
| "label": "Question + options", | |
| "asset_type": "text", | |
| "inputs": [ | |
| { | |
| "id": "in", | |
| "label": "Text", | |
| "type": "text" | |
| } | |
| ], | |
| "outputs": [ | |
| { | |
| "id": "out", | |
| "label": "Text", | |
| "type": "text" | |
| } | |
| ], | |
| "data": { | |
| "out": "Is this email safe to act on?\nphishing\nlegitimate\nneeds human review" | |
| }, | |
| "width": 200 | |
| } | |
| ], | |
| "operators": [ | |
| { | |
| "id": "fmt", | |
| "role": "operator", | |
| "kind": "fn", | |
| "fn": "format_question", | |
| "label": "Format question", | |
| "inputs": [ | |
| { | |
| "id": "in_question_block", | |
| "label": "Question + options", | |
| "type": "text", | |
| "required": true | |
| } | |
| ], | |
| "outputs": [ | |
| { | |
| "id": "out_0", | |
| "label": "Questions JSON", | |
| "type": "text", | |
| "output_index": 0 | |
| }, | |
| { | |
| "id": "out_1", | |
| "label": "Question", | |
| "type": "text", | |
| "output_index": 1 | |
| }, | |
| { | |
| "id": "out_2", | |
| "label": "Options", | |
| "type": "text", | |
| "output_index": 2 | |
| }, | |
| { | |
| "id": "out_3", | |
| "label": "Decider questions", | |
| "type": "text", | |
| "output_index": 3 | |
| } | |
| ], | |
| "data": { | |
| "out_0": "{\"decision\": {\"type\": \"choice\", \"instructions\": \"Which team should handle this request?\", \"criteria\": {\"billing\": \"billing\", \"technical\": \"technical\", \"sales\": \"sales\", \"shipping\": \"shipping\"}}}", | |
| "out_1": "Which team should handle this request?", | |
| "out_2": "billing\ntechnical\nsales\nshipping", | |
| "out_3": "choice decision: Which team should handle this request?\n- billing\n- technical\n- sales\n- shipping" | |
| }, | |
| "width": 200 | |
| }, | |
| { | |
| "id": "d3", | |
| "role": "operator", | |
| "kind": "space", | |
| "space_id": "vllm-sr/d3-decision-model", | |
| "endpoint": "/decide", | |
| "label": "vllm-sr/d3", | |
| "inputs": [ | |
| { | |
| "id": "state", | |
| "label": "State", | |
| "type": "text", | |
| "required": true | |
| }, | |
| { | |
| "id": "questions", | |
| "label": "Questions", | |
| "type": "text", | |
| "required": true | |
| } | |
| ], | |
| "outputs": [ | |
| { | |
| "id": "result", | |
| "label": "Result", | |
| "type": "json", | |
| "output_index": 1 | |
| } | |
| ], | |
| "data": { | |
| "result": "{\"model\":\"d3\",\"answers\":{\"decision\":{\"type\":\"choice\",\"choice\":\"billing\",\"probabilities\":{\"billing\":0.9989143687405434,\"technical\":0.0005408171024171331,\"sales\":0.0005116921423538015,\"shipping\":0.00003312201468561358},\"confidence\":0.9932392003570076}},\"usage\":{\"input_tokens\":125,\"output_tokens\":0}}" | |
| }, | |
| "width": 296 | |
| }, | |
| { | |
| "id": "clef", | |
| "role": "operator", | |
| "kind": "space", | |
| "space_id": "hugging-apps/clef-decision-model", | |
| "endpoint": "/decide", | |
| "label": "Cloudflare/clef", | |
| "inputs": [ | |
| { | |
| "id": "state", | |
| "label": "State", | |
| "type": "text", | |
| "required": true | |
| }, | |
| { | |
| "id": "questions", | |
| "label": "Questions", | |
| "type": "text", | |
| "required": true | |
| } | |
| ], | |
| "outputs": [ | |
| { | |
| "id": "result", | |
| "label": "Result", | |
| "type": "json", | |
| "output_index": 1 | |
| } | |
| ], | |
| "data": { | |
| "result": "{\"model\":\"clef\",\"answers\":{\"decision\":{\"type\":\"choice\",\"choice\":\"billing\",\"confidence\":0.9871,\"probabilities\":{\"billing\":0.9871,\"technical\":0.0073,\"sales\":0.0029,\"shipping\":0.0028}}},\"usage\":{\"input_tokens\":180,\"output_tokens\":0}}" | |
| }, | |
| "width": 295 | |
| }, | |
| { | |
| "id": "jev", | |
| "role": "operator", | |
| "kind": "space", | |
| "space_id": "hugging-apps/jev-27b-vl", | |
| "endpoint": "/decide", | |
| "label": "autotrust/JEV-27B-VL", | |
| "inputs": [ | |
| { | |
| "id": "state_text", | |
| "label": "State", | |
| "type": "text", | |
| "required": true | |
| }, | |
| { | |
| "id": "images", | |
| "label": "Images", | |
| "type": "json" | |
| }, | |
| { | |
| "id": "kind", | |
| "label": "Kind", | |
| "type": "text" | |
| }, | |
| { | |
| "id": "question", | |
| "label": "Question", | |
| "type": "text", | |
| "required": true | |
| }, | |
| { | |
| "id": "options_text", | |
| "label": "Options", | |
| "type": "text", | |
| "required": true | |
| } | |
| ], | |
| "outputs": [ | |
| { | |
| "id": "result", | |
| "label": "Result", | |
| "type": "text", | |
| "output_index": 2 | |
| } | |
| ], | |
| "data": { | |
| "images": [], | |
| "kind": "choice", | |
| "result": "{\n \"kind\": \"choice\",\n \"question\": \"Which team should handle this request?\",\n \"options\": [\n \"billing\",\n \"technical\",\n \"sales\",\n \"shipping\"\n ],\n \"probabilities\": {\n \"billing\": 0.9998358433869672,\n \"technical\": 4.562085097251872e-05,\n \"sales\": 0.0001183599322252175,\n \"shipping\": 1.758298351067686e-07\n }\n}" | |
| }, | |
| "width": 296 | |
| }, | |
| { | |
| "id": "decider", | |
| "role": "operator", | |
| "kind": "space", | |
| "space_id": "hugging-apps/decider-2b-demo", | |
| "endpoint": "/decide", | |
| "label": "Mapika/decider-2b", | |
| "inputs": [ | |
| { | |
| "id": "state_text", | |
| "label": "State", | |
| "type": "text", | |
| "required": true | |
| }, | |
| { | |
| "id": "questions_text", | |
| "label": "Questions", | |
| "type": "text", | |
| "required": true | |
| }, | |
| { | |
| "id": "temperature", | |
| "label": "Temperature", | |
| "type": "number" | |
| }, | |
| { | |
| "id": "independent", | |
| "label": "Independent", | |
| "type": "boolean" | |
| }, | |
| { | |
| "id": "isolated", | |
| "label": "Isolated", | |
| "type": "boolean" | |
| } | |
| ], | |
| "outputs": [ | |
| { | |
| "id": "result", | |
| "label": "Result", | |
| "type": "text", | |
| "output_index": 1 | |
| } | |
| ], | |
| "data": { | |
| "temperature": 1.3, | |
| "independent": true, | |
| "isolated": true, | |
| "result": "{\n \"model\": \"decider-v10\",\n \"answers\": {\n \"decision\": {\n \"type\": \"choice\",\n \"choice\": \"billing\",\n \"confidence\": 0.9899,\n \"certainty\": 0.9548,\n \"probabilities\": {\n \"billing\": 0.9899,\n \"technical\": 0.0081,\n \"sales\": 0.0011,\n \"shipping\": 0.0009\n }\n }\n },\n \"usage\": {\n \"input_tokens\": 58,\n \"output_tokens\": 0\n }\n}" | |
| }, | |
| "width": 316 | |
| }, | |
| { | |
| "id": "cmp", | |
| "role": "operator", | |
| "kind": "fn", | |
| "fn": "compare_decisions", | |
| "label": "Compare decisions", | |
| "inputs": [ | |
| { | |
| "id": "in_d3", | |
| "label": "d3", | |
| "type": "json" | |
| }, | |
| { | |
| "id": "in_clef", | |
| "label": "clef", | |
| "type": "json" | |
| }, | |
| { | |
| "id": "in_jev", | |
| "label": "jev", | |
| "type": "json" | |
| }, | |
| { | |
| "id": "in_decider", | |
| "label": "decider", | |
| "type": "json" | |
| } | |
| ], | |
| "outputs": [ | |
| { | |
| "id": "out_0", | |
| "label": "Comparison", | |
| "type": "markdown", | |
| "output_index": 0 | |
| } | |
| ], | |
| "data": { | |
| "out_0": "### Decision comparison\n\n| Model | Decision | Confidence | Margin vs 2nd | billing | sales | shipping | technical |\n|---|---|---|---|---|---|---|---|\n| vllm-sr/d3 | **billing** | 99.9% | 99.8% | **99.9%** | 0.1% | 0.0% | 0.1% |\n| Cloudflare/clef | **billing** | 98.7% | 98.0% | **98.7%** | 0.3% | 0.3% | 0.7% |\n| autotrust/JEV-27B-VL | **billing** | 100.0% | 100.0% | **100.0%** | 0.0% | 0.0% | 0.0% |\n| Mapika/decider-2b | **billing** | 99.0% | 98.2% | **99.0%** | 0.1% | 0.1% | 0.8% |\n\n**Votes:** billing: 4/4 (β all models agree)\n\n#### Probabilities\n```\nvllm-sr/d3 billing:ββββββββββ sales:ββββββββββ shipping:ββββββββββ technical:ββββββββββ\nCloudflare/clef billing:ββββββββββ sales:ββββββββββ shipping:ββββββββββ technical:ββββββββββ\nautotrust/JEV-27B-VL billing:ββββββββββ sales:ββββββββββ shipping:ββββββββββ technical:ββββββββββ\nMapika/decider-2b billing:ββββββββββ sales:ββββββββββ shipping:ββββββββββ technical:ββββββββββ\n```" | |
| }, | |
| "width": 200 | |
| } | |
| ], | |
| "subjects": [ | |
| { | |
| "id": "out", | |
| "role": "subject", | |
| "label": "Comparison", | |
| "asset_type": "markdown", | |
| "inputs": [ | |
| { | |
| "id": "in", | |
| "label": "Comparison", | |
| "type": "markdown" | |
| } | |
| ], | |
| "outputs": [ | |
| { | |
| "id": "out", | |
| "label": "Comparison", | |
| "type": "markdown" | |
| } | |
| ], | |
| "data": { | |
| "in": "### Decision comparison\n\n| Model | Decision | Confidence | Margin vs 2nd | billing | sales | shipping | technical |\n|---|---|---|---|---|---|---|---|\n| vllm-sr/d3 | **billing** | 99.9% | 99.8% | **99.9%** | 0.1% | 0.0% | 0.1% |\n| Cloudflare/clef | **billing** | 98.7% | 98.0% | **98.7%** | 0.3% | 0.3% | 0.7% |\n| autotrust/JEV-27B-VL | **billing** | 100.0% | 100.0% | **100.0%** | 0.0% | 0.0% | 0.0% |\n| Mapika/decider-2b | **billing** | 99.0% | 98.2% | **99.0%** | 0.1% | 0.1% | 0.8% |\n\n**Votes:** billing: 4/4 (β all models agree)\n\n#### Probabilities\n```\nvllm-sr/d3 billing:ββββββββββ sales:ββββββββββ shipping:ββββββββββ technical:ββββββββββ\nCloudflare/clef billing:ββββββββββ sales:ββββββββββ shipping:ββββββββββ technical:ββββββββββ\nautotrust/JEV-27B-VL billing:ββββββββββ sales:ββββββββββ shipping:ββββββββββ technical:ββββββββββ\nMapika/decider-2b billing:ββββββββββ sales:ββββββββββ shipping:ββββββββββ technical:ββββββββββ\n```" | |
| }, | |
| "width": 839 | |
| } | |
| ], | |
| "edges": [ | |
| { | |
| "id": "e0", | |
| "from_node_id": "question", | |
| "from_port_id": "out", | |
| "to_node_id": "fmt", | |
| "to_port_id": "in_question_block", | |
| "type": "text" | |
| }, | |
| { | |
| "id": "e1", | |
| "from_node_id": "prompt", | |
| "from_port_id": "out", | |
| "to_node_id": "d3", | |
| "to_port_id": "state", | |
| "type": "text" | |
| }, | |
| { | |
| "id": "e2", | |
| "from_node_id": "prompt", | |
| "from_port_id": "out", | |
| "to_node_id": "clef", | |
| "to_port_id": "state", | |
| "type": "text" | |
| }, | |
| { | |
| "id": "e3", | |
| "from_node_id": "prompt", | |
| "from_port_id": "out", | |
| "to_node_id": "jev", | |
| "to_port_id": "state_text", | |
| "type": "text" | |
| }, | |
| { | |
| "id": "e4", | |
| "from_node_id": "prompt", | |
| "from_port_id": "out", | |
| "to_node_id": "decider", | |
| "to_port_id": "state_text", | |
| "type": "text" | |
| }, | |
| { | |
| "id": "e5", | |
| "from_node_id": "fmt", | |
| "from_port_id": "out_0", | |
| "to_node_id": "d3", | |
| "to_port_id": "questions", | |
| "type": "text" | |
| }, | |
| { | |
| "id": "e6", | |
| "from_node_id": "fmt", | |
| "from_port_id": "out_0", | |
| "to_node_id": "clef", | |
| "to_port_id": "questions", | |
| "type": "text" | |
| }, | |
| { | |
| "id": "e7", | |
| "from_node_id": "fmt", | |
| "from_port_id": "out_1", | |
| "to_node_id": "jev", | |
| "to_port_id": "question", | |
| "type": "text" | |
| }, | |
| { | |
| "id": "e8", | |
| "from_node_id": "fmt", | |
| "from_port_id": "out_2", | |
| "to_node_id": "jev", | |
| "to_port_id": "options_text", | |
| "type": "text" | |
| }, | |
| { | |
| "id": "e9", | |
| "from_node_id": "fmt", | |
| "from_port_id": "out_3", | |
| "to_node_id": "decider", | |
| "to_port_id": "questions_text", | |
| "type": "text" | |
| }, | |
| { | |
| "id": "e10", | |
| "from_node_id": "d3", | |
| "from_port_id": "result", | |
| "to_node_id": "cmp", | |
| "to_port_id": "in_d3", | |
| "type": "text" | |
| }, | |
| { | |
| "id": "e11", | |
| "from_node_id": "clef", | |
| "from_port_id": "result", | |
| "to_node_id": "cmp", | |
| "to_port_id": "in_clef", | |
| "type": "text" | |
| }, | |
| { | |
| "id": "e12", | |
| "from_node_id": "jev", | |
| "from_port_id": "result", | |
| "to_node_id": "cmp", | |
| "to_port_id": "in_jev", | |
| "type": "text" | |
| }, | |
| { | |
| "id": "e13", | |
| "from_node_id": "decider", | |
| "from_port_id": "result", | |
| "to_node_id": "cmp", | |
| "to_port_id": "in_decider", | |
| "type": "text" | |
| }, | |
| { | |
| "id": "e14", | |
| "from_node_id": "cmp", | |
| "from_port_id": "out_0", | |
| "to_node_id": "out", | |
| "to_port_id": "in", | |
| "type": "markdown" | |
| } | |
| ] | |
| } |