The Prompt Engineer's Markdown     Discord |   Docs |   VSCode |   TemplateDX |   Puzzlet   Overview AgentMa

Search code, repositories, users, issues, pull requests...

submited by
Style Pass
2024-12-31 00:30:13

The Prompt Engineer's Markdown Discord | Docs | VSCode | TemplateDX | Puzzlet Overview AgentMark is a declarative, extensible, and composable approach for developing LLM applications using Markdown and JSX. AgentMark files enhance readability by displaying the exact inputs sent to the LLM, while providing lightweight abstractions for developers. AgentMark is built on top of the templating language, TemplateDX, and inspired by MDX. Getting Started Below is a basic example to help you get started with AgentMark: example.prompt.mdx --- name : basic-prompt metadata : model : name : gpt-4o-mini test_settings : props : num : 3 --- <System >You are a math expert</System > <User >What's 2 + { props .num } ?</User > Features AgentMark supports: Markdown: 📝 JSX components, props, & plugins: 🧩 Unified model config: 🔗 Custom Models: 🛠️ Streaming: 🌊 Loops, Conditionals, and Filter Functions: ♻️ Type Safety: 🛡️ Agents: 🕵️ Observability: 👀 Read our docs to learn more. Models By default, AgentMark doesn't support any model providers. Instead, support must be added through our plugins. Here's a list of currently supported plugins you can start using. Built-In Model Plugins Provider Model Supported @puzzlet/all-models OpenAI gpt-4o ✅ Supported ✅ OpenAI gpt-4o-mini ✅ Supported ✅ OpenAI gpt-4-turbo ✅ Supported ✅ OpenAI gpt-4 ✅ Supported ✅ OpenAI o1-mini ✅ Supported ✅ OpenAI o1-preview ✅ Supported ✅ OpenAI gpt-3.5-turbo ✅ Supported ✅ Anthropic claude-3-5-haiku-latest ✅ Supported ✅ Anthropic claude-3-5-sonnet-latest ✅ Supported ✅ Anthropic claude-3-opus-latest ✅ Supported ✅ Meta ALL ✅ Supported 🧩 Only Custom any ✅ Supported 🧩 Only Google ALL ⚠️ Coming Soon N/A Grok ALL ⚠️ Coming Soon N/A Want to add support for another model? Open an issue. Custom Model Plugins Refer to our docs to learn how to add custom model support. Language Support We plan on providing support for AgentMark across a variety of languages. Language Support Status TypeScript ✅ Supported Python ⚠️ Coming Soon Java ⚠️ Coming Soon Others Need something else? Open an issue Running AgentMark You can run AgentMark using one of the following methods: 1. VSCode Extension Run .prompt.mdx files directly within your VSCode editor. Note: This allows you to run test_settings in your prompts. Download the VSCode Extension 2. Node.js Run AgentMark directly in your Node.js environment. Below is a sample implementation: import { runInference , ModelPluginRegistry , load } from "@puzzlet/agentmark" ; import AllModelPlugins from '@puzzlet/all-models' ; // Note: Registering all latest models for demo/development purposes. // In production, you'll likely want to selectively load these, and pin models. ModelPluginRegistry . registerAll ( AllModelPlugins ) ; const run = async ( ) => { const props = { name : "Emily" } ; const Prompt = await load ( './example.prompt.mdx' ) ; const result = await runInference ( Prompt , props ) ; console . log ( result ) ; } run ( ) ; 3. Webpack Loader Integrate AgentMark with your webpack workflow using our loader. AgentMark Webpack Loader import { runInference , ModelPluginRegistry } from "@puzzlet/agentmark" ; import AllModelPlugins from '@puzzlet/all-models' ; import MyPrompt from './example.prompt.mdx' ; // Note: Registering all latest models for demo/development purposes. // In production, you'll likely want to selectively load these, and pin models. ModelPluginRegistry . registerAll ( AllModelPlugins ) ; const run = async ( ) => { const props = { name : "Emily" } ; const result = await runInference ( MyPrompt , props ) ; console . log ( result ) } run ( ) ; Contributing We welcome contributions! Please check out our contribution guidelines for more information. Community Join our community to collaborate, ask questions, and stay updated: Discord Issues Discussions License This project is licensed under the MIT License.

AgentMark is a declarative, extensible, and composable approach for developing LLM applications using Markdown and JSX. AgentMark files enhance readability by displaying the exact inputs sent to the LLM, while providing lightweight abstractions for developers.

Leave a Comment