| Crates.io | cmf |
| lib.rs | cmf |
| version | 0.1.0 |
| created_at | 2026-01-18 08:19:06.264783+00 |
| updated_at | 2026-01-18 08:19:06.264783+00 |
| description | Conversational Markdown Format - parse and convert LLM conversations |
| homepage | |
| repository | https://github.com/divanvisagie/conversational-markdown-format |
| max_upload_size | |
| id | 2052021 |
| size | 204,562 |
A markdown-based interchange format for LLM conversations. User messages are blockquotes (>), assistant messages are plain markdown.
cargo install --path .
# Detect CMF content and count turns
cmf detect conversation.cmf
# Check conformance (silent on success)
cmf check conversation.cmf
# Convert to OpenAI Chat Completions format
cmf to-openai-chat conversation.cmf
# Convert to OpenAI Responses API format
cmf to-openai-responses conversation.cmf
> @alice: Can you explain the steps?
Yes. First you need to set up your environment.
Second, assistant messages can be multi-paragraph.
> Indent blockquotes to avoid parsing as user lines.
> Thanks!
Glad it helped.
Rules:
> in column 1> @username: prefix > text) to escape them in assistant contentuse cmf::Document;
let doc = Document::parse(input);
for turn in &doc.turns {
println!("User: {}", turn.user.content);
println!("Assistant: {}", turn.assistant);
}
// Convert to OpenAI formats
let chat_messages = doc.to_openai_chat();
let responses_messages = doc.to_openai_responses();
BSD-3-Clause