Views
No views yet
| Name | Quant method | Size |
|---|---|---|
| ORLM-LLaMA-3-8B.Q2_K.gguf | Q2_K | 2.96GB |
| ORLM-LLaMA-3-8B.IQ3_XS.gguf | IQ3_XS | 3.28GB |
| ORLM-LLaMA-3-8B.IQ3_S.gguf | IQ3_S | 3.43GB |
| ORLM-LLaMA-3-8B.Q3_K_S.gguf | Q3_K_S | 3.41GB |
| ORLM-LLaMA-3-8B.IQ3_M.gguf | IQ3_M | 3.52GB |
| ORLM-LLaMA-3-8B.Q3_K.gguf | Q3_K | 3.74GB |
| ORLM-LLaMA-3-8B.Q3_K_M.gguf | Q3_K_M | 3.74GB |
| ORLM-LLaMA-3-8B.Q3_K_L.gguf | Q3_K_L | 4.03GB |
| ORLM-LLaMA-3-8B.IQ4_XS.gguf | IQ4_XS | 4.18GB |
| ORLM-LLaMA-3-8B.Q4_0.gguf | Q4_0 | 4.34GB |
| ORLM-LLaMA-3-8B.IQ4_NL.gguf | IQ4_NL | 4.38GB |
| ORLM-LLaMA-3-8B.Q4_K_S.gguf | Q4_K_S | 4.37GB |
| ORLM-LLaMA-3-8B.Q4_K.gguf | Q4_K | 4.58GB |
| ORLM-LLaMA-3-8B.Q4_K_M.gguf | Q4_K_M | 4.58GB |
| ORLM-LLaMA-3-8B.Q4_1.gguf | Q4_1 | 4.78GB |
| ORLM-LLaMA-3-8B.Q5_0.gguf | Q5_0 | 5.21GB |
| ORLM-LLaMA-3-8B.Q5_K_S.gguf | Q5_K_S | 5.21GB |
| ORLM-LLaMA-3-8B.Q5_K.gguf | Q5_K | 5.34GB |
| ORLM-LLaMA-3-8B.Q5_K_M.gguf | Q5_K_M | 5.34GB |
| ORLM-LLaMA-3-8B.Q5_1.gguf | Q5_1 | 5.65GB |
| ORLM-LLaMA-3-8B.Q6_K.gguf | Q6_K | 6.14GB |
| ORLM-LLaMA-3-8B.Q8_0.gguf | Q8_0 | 7.95GB |
1Below is an operations research question. Build a mathematical model and corresponding python code using `coptpy` that appropriately addresses the question.
2
3# Question:
4{Question}
5
6# Response:{Question} with any natural language OR question.1--------------------------OR question wrapped in the template--------------------------
2Below is an operations research question. Build a mathematical model and corresponding python code using `coptpy` that appropriately addresses the question.
3
4# Question:
5A lab has 1000 units of medicinal ingredients to make two pills, a large pill and a small pill. A large pill requires 3 units of medicinal ingredients and 2 units of filler. A small pill requires 2 units of medicinal ingredients and 1 unit of filler. The lab has to make at least 100 large pills. However, since small pills are more popular at least 60% of the total number of pills must be small. How many of each should be made to minimize the total number of filler material needed?
6
7# Response:
8--------------------------top-1 completion output by LLaMA-3-8B-ORLM under greedy decoding--------------------------
9## Mathematical Model:
10To solve the lab's pill production problem, we need to construct a linear programming model to minimize the total number of filler material needed while satisfying the production requirements for the pills and the proportion constraint. Here is the model formulation:
11
12### Decision Variables:
13- \(x\): Number of large pills to be made.
14- \(y\): Number of small pills to be made.
15
16### Objective Function:
17- Minimize the total number of filler material needed: \[Z = 2x + y\]
18
19### Constraints:
201. Medicinal ingredient usage constraint: \[3x + 2y \leq 1000\]
212. Large pill production requirement: \[x \geq 100\]
223. Proportion constraint for small pills: \[y \geq 0.6(x + y)\]
234. Non-negativity constraint: \[x, y \geq 0\]
24
25### Integer Constraints:
26- \(x, y\) must be integers, as the number of pills cannot be fractional.
27
28Using this model, we can apply linear programming techniques to find the optimal number of large and small pills to be made, minimizing the total number of filler material needed while satisfying the production requirements for the pills and the proportion constraint. This will provide the lab with an economically efficient pill production strategy.
29
30## Python Code Solution Using `coptpy`:
31Here is a Python script using the `coptpy` library to solve the problem:
32
33\`\`\`python
34import coptpy as cp
35from coptpy import COPT
36
37# Create a COPT environment
38env = cp.Envr()
39
40# Create the model
41model = env.createModel("PillProduction")
42
43# Add decision variables
44x = model.addVar(vtype=COPT.INTEGER, name="x") # Number of large pills
45y = model.addVar(vtype=COPT.INTEGER, name="y") # Number of small pills
46
47# Objective function: Minimize the total number of filler material needed
48model.setObjective(2 * x + y, sense=COPT.MINIMIZE)
49
50# Constraints
51model.addConstr(3 * x + 2 * y <= 1000, name="MaterialLimit")
52model.addConstr(x >= 100, name="LargePillRequirement")
53model.addConstr(y >= 0.6 * (x + y), name="SmallPillProportion")
54
55# Solve the model
56model.solve()
57
58# Output results
59if model.status == COPT.OPTIMAL:
60 print("Minimum total number of filler material needed: {:.0f} units".format(model.objval))
61 print("Number of large pills to be made: {:.0f}".format(x.x))
62 print("Number of small pills to be made: {:.0f}".format(y.x))
63else:
64 print("No optimal solution found.")
65\`\`\`
66
67In this script, we first create a `COPT` environment and model. Then, we add two integer decision variables `x` and `y`, representing the number of large and small pills to be made, respectively.
68
69Next, we set the objective function to minimize the total number of filler material needed, which is `2 * x + y`.
70
71Then, we add three constraints:
721. Medicinal ingredient usage constraint: `3 * x + 2 * y <= 1000`
732. Large pill production requirement: `x >= 100`
743. Proportion constraint for small pills: `y >= 0.6 * (x + y)`
75
76Finally, we solve the model and output the results of the optimal solution, including the minimum total number of filler material needed and the number of large and small pills to be made.
77
78This script provides a complete example of using the `coptpy` library to solve the lab's pill production problem, while satisfying all the constraints mentioned in the problem.| Method | NL4OPT | MAMO EasyLP | MAMO ComplexLP | IndustryOR | Micro Avg | Macro Avg |
|---|---|---|---|---|---|---|
| Methods based on PLMs | ||||||
tag-BART | 47.9%* | - | - | - | - | - |
| Methods based on GPT-3.5 | ||||||
Standard | 42.4%* | - | - | - | - | - |
Reflexion | 50.7%* | - | - | - | - | - |
Chain-of-Experts | 58.9%* | - | - | - | - | - |
| Methods based on GPT-4 | ||||||
Standard | 47.3%* | 66.5%* | 14.6%* | 28.0% | 50.2% | 39.1% |
Reflexion | 53.0%* | - | - | - | - | - |
Chain-of-Experts | 64.2%* | - | - | - | - | - |
OptiMUS | 78.8%* | - | - | - | - | - |
| ORLMs based on open-source LLMs | ||||||
ORLM-Mistral-7B | 84.4% | 81.4% | 32.0% | 27.0% | 68.8% | 56.2% |
ORLM-Deepseek-Math-7B-Base | 86.5% | 82.2% | 37.9% | 33.0% | 71.2% | 59.9% |
ORLM-LLaMA-3-8B | 85.7% | 82.3% | 37.4% | 38.0% | 71.4% | 60.8% |
1@article{tang2024orlm,
2 title={ORLM: A Customizable Framework in Training Large Models for Automated Optimization Modeling},
3 author={Tang, Zhengyang and Huang, Chenyu and Zheng, Xin and Hu, Shixi and Wang, Zizhuo and Ge, Dongdong and Wang, Benyou},
4 journal={arXiv preprint arXiv:2405.17743},
5 year={2024}
6}1@article{llama3modelcard,
2 title={Llama 3 Model Card},
3 author={AI@Meta},
4 year={2024},
5 url = {https://github.com/meta-llama/llama3/blob/main/MODEL_CARD.md}
6}