No description
Find a file
Ben f0bd374926 Fix critical prompt field error in all marketing tools
## Problem
All 4 marketing tools (contentvariant, subjectlines, platformadapt, factcheck)
were calling prepare_chat_style_prompt() which expects request.prompt field.
This caused "object has no field 'prompt'" errors in Claude Desktop.

## Root Cause
The prepare_prompt() methods were:
1. Building prompt_text string
2. Creating a copy of request
3. Setting request_copy.prompt = prompt_text
4. Calling prepare_chat_style_prompt(request_copy)

But ToolRequest (and subclasses) don't have a 'prompt' field, causing
AttributeError when prepare_chat_style_prompt tries to access it.

## Solution
Changed all prepare_prompt() methods to return the prompt string directly
instead of calling prepare_chat_style_prompt(). This is the correct pattern
for SimpleTool implementations.

## Files Changed
- tools/contentvariant.py: Removed copy() and prepare_chat_style_prompt() call
- tools/subjectlines.py: Removed copy() and prepare_chat_style_prompt() call
- tools/platformadapt.py: Removed copy() and prepare_chat_style_prompt() call
- tools/factcheck.py: Removed copy() and prepare_chat_style_prompt() call

## Testing
- Server startup:  All 7 tools load successfully
- Tool instantiation:  All tools initialize without errors

## Impact
This fixes the schema errors preventing users from using the new Phase 2 tools
in Claude Desktop. All tools should now work correctly.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-07 14:12:19 -04:00
providers Initial commit: Zen-Marketing MCP Server v0.1.0 2025-11-07 11:35:17 -04:00
systemprompts Complete Phase 2: Add three high-priority marketing tools 2025-11-07 14:02:01 -04:00
tools Fix critical prompt field error in all marketing tools 2025-11-07 14:12:19 -04:00
utils Initial commit: Zen-Marketing MCP Server v0.1.0 2025-11-07 11:35:17 -04:00
.env.example Initial commit: Zen-Marketing MCP Server v0.1.0 2025-11-07 11:35:17 -04:00
.gitignore Initial commit: Zen-Marketing MCP Server v0.1.0 2025-11-07 11:35:17 -04:00
CLAUDE.md Clean up tools/__init__.py and add git instructions to CLAUDE.md 2025-11-07 12:34:13 -04:00
config.py Change default model from Gemini 2.5 Pro to Moonshot Kimi K2 Thinking 2025-11-07 13:20:19 -04:00
LICENSE Initial commit: Zen-Marketing MCP Server v0.1.0 2025-11-07 11:35:17 -04:00
PLAN.md Initial commit: Zen-Marketing MCP Server v0.1.0 2025-11-07 11:35:17 -04:00
README.md Initial commit: Zen-Marketing MCP Server v0.1.0 2025-11-07 11:35:17 -04:00
requirements.txt Initial commit: Zen-Marketing MCP Server v0.1.0 2025-11-07 11:35:17 -04:00
run-server.sh Initial commit: Zen-Marketing MCP Server v0.1.0 2025-11-07 11:35:17 -04:00
server.py Complete Phase 2: Add three high-priority marketing tools 2025-11-07 14:02:01 -04:00
SETUP_COMPLETE.md Clean up tools/__init__.py and add git instructions to CLAUDE.md 2025-11-07 12:34:13 -04:00
STATUS.md Complete Phase 2: Add three high-priority marketing tools 2025-11-07 14:02:01 -04:00
test_fixes.py Fix critical security and error handling issues 2025-11-07 13:00:02 -04:00
update_claude_config.py Add Claude Desktop configuration script 2025-11-07 12:20:44 -04:00

Zen-Marketing MCP Server

Status: 🚧 In Development - Phase 1

AI-powered marketing tools for Claude Desktop, specialized for technical B2B content creation, multi-platform campaigns, and content variation testing.

What is This?

A fork of the Zen MCP Server optimized for marketing workflows instead of software development. Provides Claude Desktop with specialized tools for:

  • Content Variation - Generate 5-20 variations for A/B testing
  • Platform Adaptation - Adapt content across LinkedIn, Twitter, newsletters, blogs
  • Style Enforcement - Apply writing guidelines automatically
  • SEO Optimization - WordPress-specific SEO workflows
  • Guest Editing - Edit external content while preserving author voice
  • Fact Verification - Technical accuracy checking via web search
  • Internal Linking - Cross-platform content integration strategy
  • Campaign Planning - Multi-touch campaign mapping

For Whom?

Solo marketing professionals managing:

  • Technical newsletters and educational content
  • Multi-platform social media campaigns
  • WordPress blogs with SEO requirements
  • Guest contributor content
  • A/B testing and content experimentation
  • B2B SaaS or technical product marketing

Key Differences from Zen Code

Zen Code Zen Marketing
Code review, debugging, testing Content variation, SEO, style guide
Software architecture analysis Campaign planning, voice analysis
Development workflows Marketing workflows
Technical accuracy for code Technical accuracy for content
GitHub/git integration WordPress/platform integration

Tools (Planned)

Simple Tools (Fast, Single-Shot)

  • contentvariant - Generate 5-20 variations for testing
  • platformadapt - Cross-platform content adaptation
  • subjectlines - Email subject line generation
  • factcheck - Technical fact verification

Workflow Tools (Multi-Step)

  • styleguide - Writing style enforcement
  • seooptimize - WordPress SEO optimization
  • guestedit - Guest content editing
  • linkstrategy - Internal linking strategy
  • voiceanalysis - Voice extraction and validation
  • campaignmap - Campaign planning

Kept from Zen

  • chat - General brainstorming
  • thinkdeep - Deep strategic thinking
  • planner - Project planning

Models

Primary Models:

  • Gemini 2.5 Pro - Analytical and strategic work
  • Gemini Flash - Fast bulk generation
  • Minimax M2 - Creative content generation

Fallback:

  • OpenRouter (if configured)

Quick Start

Note: Not yet functional - see PLAN.md for implementation roadmap

# Clone and setup
git clone [repo-url]
cd zen-marketing
./run-server.sh

# Configure Claude Desktop (~/.claude.json)
{
  "mcpServers": {
    "zen-marketing": {
      "command": "/home/ben/mcp/zen-marketing/.venv/bin/python",
      "args": ["/home/ben/mcp/zen-marketing/server.py"],
      "env": {
        "GEMINI_API_KEY": "your-key",
        "OPENROUTER_API_KEY": "your-key",
        "DEFAULT_MODEL": "gemini-2.5-pro"
      }
    }
  }
}

# Restart Claude Desktop

Example Usage

# Generate subject line variations
"Use zen-marketing contentvariant to generate 15 subject lines for an HVAC newsletter about PCB diagnostics. Test angles: technical curiosity, contrarian, knowledge gap, urgency."

# Adapt content across platforms
"Use zen-marketing platformadapt to take this blog post intro and create versions for LinkedIn (1300 chars), Twitter (280), Instagram (2200), and newsletter."

# Enforce writing style
"Use zen-marketing styleguide to check this draft for em-dashes, 'This isn't X, it's Y' constructions, and ensure direct affirmative statements."

# SEO optimize
"Use zen-marketing seooptimize to create SEO title under 60 chars, excerpt under 156 chars, and suggest WordPress tags for this article about HVAC voltage regulation."

Development Status

Phase 1: Foundation (Current)

  • Create directory structure
  • Write implementation plan
  • Create development guide
  • Copy core architecture from zen-mcp-server
  • Configure minimax provider
  • Test basic functionality

Phase 2: Simple Tools (Next)

  • Implement contentvariant
  • Implement subjectlines
  • Implement platformadapt
  • Implement factcheck

See PLAN.md for complete roadmap.

Documentation

Architecture

Based on Zen MCP Server's proven architecture:

  • Conversation continuity via continuation_id
  • Multi-model orchestration (Gemini, Minimax, OpenRouter)
  • Simple tools for fast iteration
  • Workflow tools for multi-step processes
  • Web search integration for current information
  • File handling for content and brand assets

License

Apache 2.0 License (inherited from Zen MCP Server)

Acknowledgments

Built on the foundation of:


Status: Planning phase complete, ready for implementation Next: Start new Claude session in ~/mcp/zen-marketing/ to begin Phase 1