CtrlK
BlogDocsLog inGet started
Tessl Logo

tessl/npm-gradio--client

JavaScript and TypeScript client library for interacting with Gradio APIs, providing methods to connect to, submit predictions to, and manage connections with Gradio applications.

96

1.11x
Quality

Pending

Does it follow best practices?

Impact

96%

1.11x

Average score across 10 eval scenarios

SecuritybySnyk

Pending

The risk profile of this skill

Overview
Eval results
Files

criteria.jsonevals/scenario-9/

{
  "context": "This criteria evaluates how well the engineer uses the @gradio/client package to handle streaming events and custom event callbacks. The focus is on proper use of the Client.connect() method, submit() for streaming event handling, and event type processing.",
  "type": "weighted_checklist",
  "checklist": [
    {
      "name": "Client Connection",
      "description": "Uses Client.connect() method to establish connection to the Gradio app with the provided appReference parameter",
      "max_score": 15
    },
    {
      "name": "Submit Method Usage",
      "description": "Uses the submit() method rather than predict() to enable streaming event access and monitoring",
      "max_score": 20
    },
    {
      "name": "Event Iteration",
      "description": "Properly iterates through the async iterable returned by submit() using for await...of or similar pattern to process streaming events",
      "max_score": 20
    },
    {
      "name": "Event Type Handling",
      "description": "Correctly identifies and handles different event types (status, data, log, render) by checking the event.type property",
      "max_score": 15
    },
    {
      "name": "Status Event Processing",
      "description": "Captures and tracks status events, extracting status values like 'pending', 'generating', 'complete', or 'error'",
      "max_score": 10
    },
    {
      "name": "Data Event Processing",
      "description": "Captures data events and extracts the final result, accessing event.data appropriately",
      "max_score": 10
    },
    {
      "name": "Event Count Tracking",
      "description": "Maintains counts of different event types throughout the streaming process to provide eventCounts in the return value",
      "max_score": 5
    },
    {
      "name": "Endpoint Parameter",
      "description": "Passes the endpoint parameter correctly to the submit() method as the first argument",
      "max_score": 5
    }
  ]
}

tile.json