Getting it into your agent
It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.
git clone --depth 1 https://github.com/marcos-dv/ampl-agentsnpx agentmods add skills/marcos-dv/ampl-agents/ampl-pythonWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/marcos-dv/ampl-agents/ampl-python)<a href="https://agentmods.dev/skills/marcos-dv/ampl-agents/ampl-python"><img src="https://agentmods.dev/badge/skills/marcos-dv/ampl-agents/ampl-python/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/marcos-dv/ampl-agents/ampl-python"><img src="https://agentmods.dev/badge/skills/marcos-dv/ampl-agents/ampl-python.svg" alt="Reviewed on agentmods" width="80" height="20"></a>- NVIDIA SkillSpector pass
What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00075 | $0.03822 |
| Opus 5.5 | $0.00030 | $0.01529 |
| Sonnet 5.5 | $0.00015 | $0.00764 |
| Haiku 4.5 | $0.00007 | $0.00382 |
Grade A, and why
ampl-python scanned grade A with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Makes network callslowCapability
Not a fault in itself. Listed so you know the mod talks to something, and to what.
IF you have internet access (WebFetch, browser, or curl): How it starts
The opening of the file, as written. The whole thing — 498 lines — stays where its author put it; the contents beside it link to each section on GitHub.
AMPL Python (amplpy) Skill
Always-on constraints (verified solve, model structure, session hygiene) live in
rules/and apply whenever this skill is active.
Mission
You write correct, maintainable amplpy code that drives AMPL models. You know the amplpy API, official best practices, and Colab/MO-Book workflow patterns. You keep model structure in .mod files, use Python for data, orchestration, and results, and always verify solves.
You are not a general Python agent — optimization and AMPL session semantics come first.
Code examples convention
This skill is amplpy-first. Every operational pattern shows Preferred: amplpy then Pure AMPL for the same action (solve, options, queries, IIS). Model structure belongs in model.mod.
AMPL installation
From https://amplpy.ampl.com/en/latest/getting-started.html and https://dev.ampl.com/ampl/python/modules.html.
python -m pip install amplpy --upgrade
python -m amplpy.modules install highs gurobi xpress
python -m amplpy.modules activate <license-uuid> # https://ampl.com/ce
python -m amplpy.modules run ampl -vvq
from amplpy import AMPL
ampl = AMPL()
Colab:
%pip install -q amplpy
from amplpy import AMPL, ampl_notebook
ampl = ampl_notebook(
modules=["gurobi", "highs", "xpress"],
license_uuid="default",
)
Ensure deployed code documents required modules and license UUID source (env var, not committed secrets).
Solver classification (commercial vs open-source)
Sources: https://dev.ampl.com/solvers/index.html , https://dev.ampl.com/ampl/python/modules.html
Open-source modules
| Module | Solvers | Use |
|---|---|---|
| highs | HiGHS | LP, MILP |
| cbc | CBC | MILP |
| coin | CBC, Couenne, Ipopt, Bonmin | MIP, MINLP, NLP |
| open | All OSS | MIP, MINLP, NLP |
| scip | SCIP | MIP |
| gcg | GCG | Decomposition |
| gokestrel | NEOS Kestrel | Remote solvers (Colab) |
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 1mo ago First seen · 498 lines · 75 tokens per session scan A 5aace1338dce
ampl-python is a skill published in the GitHub repository marcos-dv/ampl-agents (10 stars, last pushed 1mo ago), licensed MIT. It adds 75 tokens to every session and 3,822 once invoked, about $0.0003 per session on Opus 5.5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other skills, from other repositories
torchtalk-analyzer
Analyze PyTorch internals across Python, C++, and CUDA layers using the TorchTalk MCP server. Use when asked about how PyTorch operators work internally, where functions are implemented, what would break if code is modified, or finding tests for PyTorch operators.
torchtalk-trace
Trace a PyTorch function's cross-language binding chain (Python -> C++ -> CUDA).
fastapi-templates
Create production-ready FastAPI projects with async patterns, dependency injection, and comprehensive error handling. Use when building new FastAPI applications or setting up backend API projects.
temporal-python-testing
Test Temporal workflows with pytest, time-skipping, and mocking strategies. Covers unit testing, integration testing, replay testing, and local development setup. Use when implementing Temporal workflow tests or debugging test failures.
cudaq-importing
Use when porting circuits from another framework (e.g. Qiskit) into CUDA-Q kernels while preserving the source algorithm and validation fidelity.
cuopt-numerical-optimization-api
LP, MILP, and QP (beta) with cuOpt — Python, C, and CLI. Use when the user is solving LP, MILP, or QP with any cuOpt interface.