Idiomark CLI Reference
Complete reference for all Idiomark CLI commands.
Installation
npm install -g @idiomark/cli
Commands
idiomark extract
Extract personality data from text samples you provide.
idiomark extract text --input <text-or-file> [options]
Options:
| Flag | Alias | Description | Default |
|---|---|---|---|
--input | -i | Text samples to analyze (inline text or file path) | - |
--output | -o | Output file path | entity.idiomark |
--sample-size | -s | Amount of text to analyze | 1000 |
--verbose | -v | Verbose output | false |
Examples:
# Extract from inline text samples
idiomark extract text --input "your-writing-samples-here" -o me.idiomark
# Custom sample size
idiomark extract text --input ./writing-samples.txt --sample-size 5000 -o me.idiomark
# Verbose output for debugging
idiomark extract text --input "samples" -v -o me.idiomark
Output:
🎭 Idiomark Extractor
✅ Personality blueprint saved to me.idiomark
📊 Extraction Summary:
────────────────────────────────────
Sources: text-samples
Sample size: 1000
Confidence: 87.5%
────────────────────────────────────
🎭 Personality Preview:
────────────────────────────────────
Primary tone: casual
Formality: 0.30
Humor: 0.80
Enthusiasm: 0.70
────────────────────────────────────
idiomark validate
Validate a Idiomark file against the protocol schema.
idiomark validate <file> [options]
Arguments:
| Argument | Description |
|---|---|
file | Path to .idiomark file to validate |
Options:
| Flag | Alias | Description | Default |
|---|---|---|---|
--strict | -s | Enable strict validation mode | false |
Examples:
# Basic validation
idiomark validate me.idiomark
# Strict validation (checks all fields)
idiomark validate me.idiomark --strict
Output:
✓ Idiomark Validator
✅ Valid Idiomark file
📋 File Details:
────────────────────────────────────
Version: 1.0.0
Entity ID: idiomark_abc123
Created: 2026-02-10T00:00:00Z
Sources: text-samples
────────────────────────────────────
✅ All checks passed!
Error Output:
❌ Validation failed
Errors found:
────────────────────────────────────
• Missing required field: personality.voice.tone
Field: personality.voice.tone
• Confidence must be between 0 and 1
Field: personality.voice.tone.confidence
────────────────────────────────────
idiomark serve
Start a local inference server with a personality.
idiomark serve <file> [options]
Arguments:
| Argument | Description |
|---|---|
file | Path to .idiomark file to serve |
Options:
| Flag | Alias | Description | Default |
|---|---|---|---|
--port | -p | Port to listen on | 3000 |
--model | -m | AI model to use | gpt-4 |
Examples:
# Start server on default port
idiomark serve me.idiomark
# Custom port
idiomark serve me.idiomark --port 8080
# Use different model
idiomark serve me.idiomark --model claude-3-opus
Output:
🚀 Idiomark Inference Server
Server starting...
🌐 Server Details:
────────────────────────────────────
URL: http://localhost:3000
Model: gpt-4
Personality: casual
────────────────────────────────────
📝 API Endpoints:
POST /generate Generate response with personality
GET /health Health check
GET /personality View loaded personality
💡 Example:
curl -X POST http://localhost:3000/generate \
-H "Content-Type: application/json" \
-d '{"message": "Hello!"}'
✅ Server ready at http://localhost:3000
idiomark info
Display detailed information about a Idiomark file.
idiomark info <file>
Arguments:
| Argument | Description |
|---|---|
file | Path to .idiomark file to inspect |
Examples:
idiomark info me.idiomark
Output:
📋 Idiomark File Info
📄 Metadata:
────────────────────────────────────
Version: 1.0.0
ID: idiomark_demo_example
Created: 2026-02-10T00:00:00Z
Last Updated: 2026-02-10T00:00:00Z
────────────────────────────────────
👤 Entity:
────────────────────────────────────
Name: Demo Developer
Type: human
Sources: text-samples
────────────────────────────────────
🎭 Personality:
────────────────────────────────────
Voice:
Tone: casual (87%)
Formality: 25%
Humor: 75%
Sarcasm: 55%
Enthusiasm: 82%
Directness: 65%
Emoji Usage: high
Top Emojis: 🚀 💻 🔥 ✨ 👀
────────────────────────────────────
📚 Domains:
────────────────────────────────────
• javascript (95%)
• typescript (89%)
• react (86%)
────────────────────────────────────
💭 Values:
────────────────────────────────────
✓ open_source (90%)
✓ developer_experience (88%)
✓ type_safety (82%)
✗ over_engineering (71%)
────────────────────────────────────
Global Options
| Flag | Description |
|---|---|
--version, -V | Show version number |
--help, -h | Show help |
Exit Codes
| Code | Meaning |
|---|---|
0 | Success |
1 | Error |
2 | Validation failed |
Configuration
Idiomark can be configured via environment variables:
# API key for inference
export IDIOMARK_API_KEY="your-key-here"
# Default model
export Idiomark_MODEL="gpt-4"
# Default port for serve command
export Idiomark_PORT="3000"
Or via config file at ~/.idiomarkrc:
{
"model": "gpt-4",
"port": 3000,
"outputDir": "~/.idiomark"
}