Skip to main content

ReMIP Server

This directory contains the ReMIP FastAPI server, which provides a RESTful API for solving Mixed-Integer Programming (MIP) problems.

Running the Server

To run the server, you need to have the dependencies installed (e.g., via uv pip install -e . from this directory). Then, you can start the server using the remip command:

uv run remip --host 0.0.0.0 --port 8000

The server will automatically find an open port if 8000 is in use, unless a specific port is provided.

API Endpoints

GET /solver-info

Returns information about the underlying MIP solver.

  • Method: GET
  • Success Response: 200 OK
  • Response Body Example:
    {
      "solver": "SCIP",
      "version": "x.y.z"
    }
    

POST /solve

Solves a MIP problem. It can return the solution directly or stream solver events using Server-Sent Events (SSE).

  • Method: POST
  • Query Parameters:
    • timeout (float, optional): Maximum time in seconds to allow the solver to run.
    • stream (string, optional): If set to sse, the server will stream solver events.
  • Request Body: A JSON object representing the MIPProblem.
  • Success Response: 200 OK

Request Body (MIPProblem)

The request body must be a JSON object with the following structure:

{
  "parameters": {
    "name": "MyProblem",
    "sense": 1,
    "status": 0,
    "sol_status": 0
  },
  "objective": {
    "name": "TotalProfit",
    "coefficients": [
      { "name": "x1", "value": 10 },
      { "name": "x2", "value": 15 }
    ]
  },
  "variables": [
    { "name": "x1", "cat": "Binary" },
    { "name": "x2", "cat": "Binary" }
  ],
  "constraints": [
    {
      "name": "ResourceA",
      "sense": -1,
      "coefficients": [
        { "name": "x1", "value": 2 },
        { "name": "x2", "value": 5 }
      ],
      "constant": 10
    }
  ],
  "solver_options": {
    "limits/time": 60
  }
}

Standard Response (MIPSolution)

If the stream parameter is not set, the response will be a JSON object with the solution:

{
  "name": "MyProblem",
  "status": "optimal",
  "objective_value": 25.0,
  "variables": {
    "x1": 1.0,
    "x2": 1.0
  }
}

Streaming Response (SSE)

If stream=sse is specified, the response will be a text/event-stream. The client will receive a sequence of events, such as log, metric, result, and end.

Example Event:

event: metric
data: {"timestamp":"...","objective_value":25.0,"gap":0.0,"iteration":10,"sequence":5}

Metadata

Release files for remip 0.3.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for remip 0.3.3
File Size Uploaded Provenance Actions
remip-0.3.3.tar.gz 12.9 kB With provenance Details for remip-0.3.3.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for remip 0.3.3
File Interpreter ABI Platform Actions
remip-0.3.3-py3-none-any.whl Python 3 none any Details for remip-0.3.3-py3-none-any.whl

Total release size: 22.9 kB

Release files / remip-0.3.3.tar.gz

Download URL remip-0.3.3.tar.gz
Size 12.9 kB
Tags Source
SHA-256 checksum
How to use checksums
8be90e677fb2a7b29f511a5043620d4ef8fb984299e9c503f7d6c0bed906622c
BLAKE2b-256 checksum
How to use checksums
6ebe7fab1cac41adba2b70a3b76a09f7de5cf9ecea64a7ceaceb9671c2ad9845
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 29, 2025.

Transparency log

Release files / remip-0.3.3-py3-none-any.whl

Download URL remip-0.3.3-py3-none-any.whl
Size 10.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
f595b5650afdbecf19cf6eb90114de196659ae01c22aa2808a3d775f04aad25e
BLAKE2b-256 checksum
How to use checksums
0341ba65bd0620ef44a6d0e47c9e7aecd2474edfeec03e3cba4c7725663580b7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 29, 2025.

Transparency log

Security for remip 0.3.3

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for remip-0.3.3.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 29, 2025.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.3.3 This release

2 release files Full provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page