local-test

Validate Lift Wing KServe-style model servers locally with Docker Compose and curl prediction requests.

4|Updated May 12, 2021
One-click install
npx skills add https://github.com/wikimedia/machinelearning-liftwing-inference-services --skill local-test-wikimedia
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: local-test
Source: https://github.com/wikimedia/machinelearning-liftwing-inference-services/tree/main/.claude/skills/local-test
Command: npx skills add https://github.com/wikimedia/machinelearning-liftwing-inference-services --skill local-test-wikimedia

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Local-test helps you verify a Lift Wing inference model server works correctly before committing by providing a repeatable way to build, run, and send a real prediction request.

Core Features & Use Cases

  • Build and run via Docker Compose: Uses a specified compose service to start the correct model server configuration for local development and debugging.
  • Curl-based smoke testing: Sends a POST request to the model server’s prediction endpoint using the service’s configured model name to confirm input/output behavior.
  • Model-path configuration with .env: Ensures the model files referenced by each service are available locally by wiring the expected PATH_TO_<MODEL>_MODEL values.
  • Troubleshooting guidance: Includes common fixes for ARM Macs, port conflicts, and locating the server code for the expected input schema (src/models/<service>/model_server/model.py).

Quick Start

Build and start the target service with Docker Compose, then send a curl POST to /v1/models/<model-name>:predict using a JSON body that matches the input schema in src/models/<service>/model_server/model.py.

Frequently Asked Questions about local-test

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I test a KServe inference server locally with Docker Compose?

To test a KServe inference server locally, build and start the target service via Docker Compose, configure the model file path in a .env file, and send a curl POST request to the /v1/models/<model-name>:predict endpoint.

What is the correct JSON payload format for a KServe model prediction request?

The correct JSON payload format for a KServe model prediction request must match the input schema defined in the service's model.py file, located at src/models/<service>/model_server/model.py.

Do I need a .env file to run local model testing for Lift Wing services?

Yes, you need a .env file to provide the expected PATH_TO_<MODEL>_MODEL values, ensuring the model files referenced by each Docker Compose service are available locally.

Why does my local Docker Compose model server fail to accept prediction requests?

Your local Docker Compose model server may fail to accept prediction requests due to port conflicts, ARM Mac architecture issues, or an incorrect JSON payload that does not match the model.py input schema.

Can I run a curl smoke test against a Lift Wing model server before committing code?

Yes, you can run a curl smoke test against a Lift Wing model server before committing by building the Docker Compose service and posting a prediction request to validate input and output behavior.