Turn draft contest ideas into ready-to-judge problem packages. The agent takes a rough statement and returns a refined statement, IO specification, constraints, test generator, validator, reference solution, and more.
- Python CLI – feed a draft statement and receive Markdown + JSON output
- Web UI – paste the draft in an interactive interface, configure your API key, and generate results
- Mock mode – experiment without an API key using bundled sample output
- Configurable backend – supply your own OpenAI-compatible base URL, model and organization
pip install -e .Create a .env file or export environment variables with your API credentials:
OPENAI_API_KEY=sk-your-key
CP_AGENT_MODEL=gpt-4o-mini
OPENAI_BASE_URL=https://api.openai.com/v1cp-agent path/to/draft.txt --output package.mdArguments:
--model– override the model per run--tags tag1 tag2– hint topical tags--difficulty– target difficulty label--notes– additional free-form instructions--mock-response samples/mock_response.json– bypass API calls for dry-runs
The CLI writes a Markdown summary to --output (or stdout) and a matching JSON file next to it.
flask --app app run --debugOpen http://127.0.0.1:5000. Fill in the form, provide an API key (or use the mock response), and hit Generate Package.
- Formatters:
blackandisort - HTTP client:
httpx - Front-end is a single static page (
templates/index.html) with vanilla JS (static/app.js)
Contributions and issue reports are welcome!