Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.agentmark.co/llms.txt

Use this file to discover all available pages before exploring further.

Create prompts as .prompt.mdx files in your editor, or use the visual editor in the Dashboard — both produce the same format and are fully interchangeable. Run them via SDK, CLI, or the Dashboard Playground.

What are AgentMark prompts?

AgentMark prompts are .prompt.mdx files that combine the readability of Markdown with the power of JSX templating. They provide a structured, version-controllable way to define LLM prompts with type safety and reusability.
  • Readable — Human-friendly syntax that’s easy to review and understand
  • Reusable — Share components across prompts and use variables for dynamic content
  • Type-Safe — Full TypeScript support for props and outputs
  • Version-Controlled — Store prompts in git alongside your code
  • Testable — Run experiments with datasets and automated evaluations

Basic structure

Every AgentMark prompt consists of two parts:

1. Frontmatter (YAML)

Defines the prompt’s metadata and configuration:
example.prompt.mdx
---
name: example
text_config:
  model_name: gpt-4o-mini
  temperature: 0.7
---

2. Template content

The actual prompt using message tags and dynamic content:
<System>
You are a helpful assistant.
</System>

<User>
Summarize the following text: {props.text}
</User>

Creating prompts

Use the Dashboard’s visual editor to create and edit prompts — no coding or git knowledge required.Creating a prompt in the Dashboard visual editorThe visual editor shows the frontmatter and message-tag body, a model selector, input-variable fields, and a streaming output pane — the same UI features available to someone editing the .prompt.mdx file locally.
  • Write and edit prompts with syntax highlighting
  • Test prompts directly in the editor
  • Configure model settings through visual controls
  • Preview outputs in real-time
Step-by-step guide →

Key features

Message tags

Structure conversations with role tags:
  • <System> — System-level instructions
  • <User> — User messages
  • <Assistant> — Assistant responses (for few-shot examples)

Dynamic variables

Access runtime data using props:
<User>
Hello {props.userName}, you have {props.messageCount} new messages.
</User>
Learn about Props →

Conditional logic and loops

<User>
  <If condition={props.isPremium}>
    You have access to premium features.
  </If>

  Products:
  <ForEach arr={props.products}>
    {(product) => (
      <>- {product.name}: ${product.price}</>
    )}
  </ForEach>
</User>
With props.isPremium = true and props.products = [{ name: "Widget", price: 10 }, { name: "Gadget", price: 20 }], the <User> message renders as:
You have access to premium features.

Products:
- Widget: $10
- Gadget: $20
Learn about TemplateDX syntax →

Generation types

AgentMark supports multiple output formats:
  • Text — Natural language responses
  • Object — Structured JSON with schema validation
  • Image — Image generation
  • Speech — Audio generation
Explore Generation Types →

Advanced features

Next steps

Running Prompts

Execute prompts in your application via SDK

Generation Types

Explore text, object, image, and speech generation

Tools & Agents

Build multi-step agents with function calling

TemplateDX Syntax

Learn the full template syntax

Have Questions?

We’re here to help! Choose the best way to reach us: