.prompt.mdx examples you can drop into your agentmark/ directory and run with agentmark run-prompt. Each one covers a different generation type and a different AgentMark feature. Pick the closest to what you’re building and adapt.
npm create agentmark bootstraps agentmark.json, an empty agentmark/ directory, and MCP wiring. Copy any example below into agentmark/ to get started.Before you run these
All four examples assume a working local setup:- A client file (
agentmark.client.tsfor TypeScript,agentmark_client.pyfor Python) in your project root.npm create agentmarkdoesn’t create one; ask your coding agent to “Set up AgentMark in this project,” or follow Client setup. Without it, the development server exits withError: agentmark.client.ts not found in current directory. - The development server running in a second terminal:
agentmark dev. - A provider API key in
.env. Every example below uses OpenAI models, so setOPENAI_API_KEY.
- Object (party-planner)
- Text + tools (customer-support)
- Image (animal-drawing)
- Speech (story-teller)
Structured JSON output, schema validation, and a linked dataset with an eval. This is the canonical “extract this shape from text” prompt.Demonstrates:
object_config, JSON schema validation, test_settings.dataset, test_settings.evals (exact_match_json).agentmark/party-planner.prompt.mdx
agentmark/party.jsonl
Run it
Wiring these into your project
Drop the.prompt.mdx file into <your-project>/agentmark/ (the agentmark/ directory npm create agentmark left empty). Drop the .jsonl dataset next to it. Then either run from the CLI as shown in each “Run it” block, or load by name from your SDK client.
If you ran npm create agentmark and then asked your AI tool to “Set up AgentMark in this project,” the setup workflow has proposed the right SDK package and client file for your stack. The recipes above slot into that wiring directly.
Next steps
Create a prompt
Author your own .prompt.mdx files from scratch
Generation types
Reference for text, object, image, and speech configs
Tools and agents
Wire tool implementations into prompts (used in customer-support)
Running experiments
Datasets + evals (used in party-planner)
Have questions?
Reach out any time:
- Email the team at hello@agentmark.co for support
- Schedule an Enterprise Demo to learn about AgentMark’s business solutions