get_reference
Fetch COPT example code for LP, MIP, SOCP, or NLP problems in Python to ensure accurate implementation before solving.
Instructions
获取COPT的指定语言接口对应问题的参考示例,推荐在调用COPT解决对应问题前调用
Args: problem_type: 求解问题类型,目前支持的问题类型如下: - "LP": 线性规划(LP) - "MIP": 混合整数规划(MIP) - "SOCP": 二阶锥规划(SOCP) - "NLP": 非线性规划(NLP) language: API接口语言,目前支持的语言如下: - "Python": Python接口
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"problem_type": "<problem_type>",
"language": "<language>"
},
"name": "get_reference"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| language | Yes | API接口语言 | |
| problem_type | Yes | 求解问题类型 |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |