Skip to content
Conduit

mcp server

social-agent

๐Ÿค– AI-powered social media operations framework โ€” automated content creation, cross-platform publishing, trending monitor & analytics for Chinese social platforms

zouyongfu/social-agentcommunitylistedunreviewed

Set up

Runs on your computer. Pick your agent and operating system.

Before you start

  • uv (`curl -LsSf https://astral.sh/uv/install.sh | sh`)
~/Library/Application Support/Claude/claude_desktop_config.json
{
  "mcpServers": {
    "social-agent": {
      "command": "uvx",
      "args": [
        "social-agent"
      ]
    }
  }
}

same format Cursor, GitHub Copilot CLI, Junie, JetBrains AI Assistant, Augment (Auggie CLI), Factory Droid, Kiro, Devin CLI +12

Values in angle brackets are placeholders. Restart Claude Desktop after editing its config.Claude Desktop docs

README

synced Oct 21, 2026

Social Agent

AI-Powered Social Media Operations Framework

Python License: MIT CI Version PRs Welcome

Monitor, create, distribute, and analyze social media content across platforms โ€” all powered by AI.

English | ไธญๆ–‡


What is Social Agent?

Social Agent is an open-source AI framework that automates social media operations across Chinese social platforms. It integrates LLM-powered content generation, multi-platform publishing, trending monitoring, and performance analytics into one unified framework.

Core idea: Write once, publish everywhere. Let AI handle the heavy lifting.

โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚                    Social Agent                          โ”‚
โ”‚                                                          โ”‚
โ”‚  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”  โ”‚
โ”‚  โ”‚ Monitor  โ”‚  โ”‚   Generate   โ”‚  โ”‚    Analyze        โ”‚  โ”‚
โ”‚  โ”‚ Trending โ”‚โ”€โ”€โ”‚   Content    โ”‚โ”€โ”€โ”‚   Performance     โ”‚  โ”‚
โ”‚  โ””โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”˜  โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜  โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜  โ”‚
โ”‚       โ”‚               โ”‚                    โ”‚             โ”‚
โ”‚  โ”Œโ”€โ”€โ”€โ”€โ–ผโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ–ผโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ–ผโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”   โ”‚
โ”‚  โ”‚              Plugin System                         โ”‚   โ”‚
โ”‚  โ”‚  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ” โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ” โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ” โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”  โ”‚   โ”‚
โ”‚  โ”‚  โ”‚ Weibo  โ”‚ โ”‚ Xiaohu  โ”‚ โ”‚Douyin โ”‚ โ”‚ Bilibili  โ”‚  โ”‚   โ”‚
โ”‚  โ”‚  โ”‚ ๅพฎๅš   โ”‚ โ”‚ ๅฐ็บขไนฆ  โ”‚ โ”‚ ๆŠ–้Ÿณ  โ”‚ โ”‚ B็ซ™       โ”‚  โ”‚   โ”‚
โ”‚  โ”‚  โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜  โ”‚   โ”‚
โ”‚  โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜   โ”‚
โ”‚                                                          โ”‚
โ”‚  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”    โ”‚
โ”‚  โ”‚  LLM Layer: OpenAI | Claude | Qwen | GLM | Ollamaโ”‚    โ”‚
โ”‚  โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜    โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜

Features

  • ๐Ÿ”ฅ Trending Monitor โ€” Real-time trending topics from Weibo, Xiaohongshu, Douyin, Bilibili
  • โœ๏ธ AI Content Generation โ€” Generate platform-specific content with style adaptation
  • ๐Ÿ“ค Multi-Platform Publishing โ€” Create once, publish to multiple platforms
  • ๐Ÿ” Content Search โ€” Search across platforms in one unified interface
  • ๐Ÿ“Š Performance Analytics โ€” Track and analyze your social media performance
  • โฐ Scheduled Workflows โ€” Cron-based task scheduling for automated operations
  • ๐Ÿ”Œ Plugin System โ€” Extensible architecture, community plugins welcome
  • ๐Ÿค– Multi-LLM Support โ€” OpenAI, Claude, Qwen, GLM, Ollama, and more

Quick Start

Installation

# Clone the repo
git clone https://github.com/zouyongfu/social-agent.git
cd social-agent

# Install with Weibo support (default)
pip install -e .

# Install with specific platform support
pip install -e ".[weibo]"        # Weibo
pip install -e ".[xiaohongshu]"  # Xiaohongshu
pip install -e ".[bilibili]"     # Bilibili
pip install -e ".[all]"          # All platforms

# For development
pip install -e ".[dev]"

Configuration

Copy the example env file and fill in your credentials:

cp .env.example .env

Edit .env:

# LLM Provider (openai / claude / dashscope / zhipu / ollama)
LLM_PROVIDER=openai
OPENAI_API_KEY=sk-your-key-here

# Or use free Chinese alternatives:
# LLM_PROVIDER=dashscope
# DASHSCOPE_API_KEY=sk-your-key-here

# Weibo cookie (required for reading trending + publishing)
WEIBO_COOKIE=your_weibo_cookie_here

Basic Usage

CLI Commands:

# Check status
social-agent status

# Get trending topics
social-agent trending
social-agent trending --platform weibo --limit 20

# Generate content
social-agent generate --topic "AI tools for productivity" --platform weibo --style casual

# Generate for multiple platforms
social-agent generate -t "Today's tech news" -p weibo -p xiaohongshu

# Search across platforms
social-agent search --keyword "ไบบๅทฅๆ™บ่ƒฝ" --platform weibo

# Publish content
social-agent publish --topic "My thoughts on AI" --platform weibo
social-agent publish -t "AI review" -p weibo -p xiaohongshu --dry-run

Python API:

import asyncio
from social_agent import SocialAgent, Settings

async def main():
    # Initialize agent
    settings = Settings.load()
    agent = SocialAgent(settings)
    await agent.initialize()

    # Monitor trending
    trending = await agent.get_trending(platform="weibo", limit=10)
    for topic in trending:
        print(f"๐Ÿ”ฅ {topic.title} (score: {topic.hot_score})")

    # Generate content for multiple platforms
    contents = await agent.create_content(
        topic="AI makes coding 10x faster",
        platforms=["weibo", "xiaohongshu"],
        style="casual",
        keywords=["AI", "ๆ•ˆ็އ", "็ผ–็จ‹"],
    )

    # Publish to all platforms
    for content in contents:
        result = await agent.publish(
            platform=content.platform,
            text=content.text,
            hashtags=content.hashtags,
        )
        print(f"{'โœ…' if result.success else 'โŒ'} {content.platform}")

    await agent.shutdown()

asyncio.run(main())

Cross-Platform Content Adaptation

# Adapt content from one platform style to another
adapted = await agent.content_engine.adapt(
    content="Original Weibo post text here...",
    from_platform="weibo",
    to_platform="xiaohongshu",
)
print(adapted.text)  # Now in Xiaohongshu style

Scheduled Automated Workflows

# Daily post at 9 AM
agent.schedule_daily_post(
    task_id="morning_post",
    topic="ๆฏๆ—ฅ็ง‘ๆŠ€่ต„่ฎฏ",
    platforms=["weibo"],
    hour=9,
    minute=0,
)

# Monitor trending every 30 minutes
agent.schedule_trending_monitor(
    task_id="trending_alert",
    keywords=["AI", "ๅคงๆจกๅž‹", "GPT"],
    interval_minutes=30,
)

# Start the scheduler loop
await agent.scheduler.start()

Architecture

social-agent/
โ”œโ”€โ”€ src/social_agent/
โ”‚   โ”œโ”€โ”€ __init__.py          # Package init
โ”‚   โ”œโ”€โ”€ agent.py             # Core Agent orchestrator
โ”‚   โ”œโ”€โ”€ config.py            # Configuration management
โ”‚   โ”œโ”€โ”€ content.py           # Content generation engine
โ”‚   โ”œโ”€โ”€ llm.py               # LLM adapter layer
โ”‚   โ”œโ”€โ”€ plugin.py            # Plugin system
โ”‚   โ”œโ”€โ”€ scheduler.py         # Task scheduler
โ”‚   โ”œโ”€โ”€ cli.py               # Command-line interface
โ”‚   โ””โ”€โ”€ plugins/
โ”‚       โ”œโ”€โ”€ weibo/           # Weibo platform plugin
โ”‚       โ””โ”€โ”€ xiaohongshu/     # Xiaohongshu platform plugin
โ”œโ”€โ”€ examples/                # Usage examples
โ”œโ”€โ”€ tests/                   # Test suite
โ”œโ”€โ”€ pyproject.toml           # Project config
โ””โ”€โ”€ .env.example             # Environment template

Key Design Decisions

DesignRationale
Plugin-basedEach platform is a self-contained plugin, easy to add/remove
Async-firstBuilt on asyncio for efficient concurrent operations
Multi-LLMNot locked to any single provider, works with OpenAI/Claude/Qwen/GLM/Ollama
No browser dependencyCore reads via HTTP API, browser automation optional for publishing

Supported Platforms

PlatformRead (Trending/Search)Write (Publish)Status
ๅพฎๅš Weiboโœ…โœ…Full support
ๅฐ็บขไนฆ Xiaohongshuโœ…๐Ÿ”„Read ready, publish via companion
ๆŠ–้Ÿณ Douyin๐Ÿ”„๐Ÿ”„Planned
B็ซ™ Bilibili๐Ÿ”„๐Ÿ”„Planned
็ŸฅไนŽ Zhihu๐Ÿ”„๐Ÿ”„Planned

LLM Providers

ProviderModelsSetup
OpenAIGPT-4o, GPT-4o-miniSet OPENAI_API_KEY
Anthropic ClaudeClaude 3.5 SonnetSet CLAUDE_API_KEY
DashScope (Qwen)Qwen-Plus, Qwen-MaxSet DASHSCOPE_API_KEY, free tier available
Zhipu (GLM)GLM-4-Flash, GLM-4Set ZHIPU_API_KEY, free tier available
Ollama (Local)Any local modelSet OLLAMA_BASE_URL, fully offline

๐Ÿ’ก For Chinese users, DashScope (Qwen) or Zhipu (GLM) offer free tiers and work great out of the box.

Create Your Own Plugin

from social_agent.plugin import BasePlatformPlugin, PluginMeta, PluginType, ActionScope

class DouyinPlugin(BasePlatformPlugin):
    meta = PluginMeta(
        name="douyin",
        version="0.1.0",
        description="Douyin (TikTok China) platform integration",
        plugin_type=PluginType.PLATFORM,
        supported_actions=[ActionScope.READ, ActionScope.WRITE],
        tags=["douyin", "tiktok", "china"],
    )

    async def verify_auth(self) -> bool:
        # Your auth check logic
        return True

    async def get_trending(self, limit: int = 10):
        # Your trending fetch logic
        return [{"title": "...", "hot_score": 1000}]

    async def search(self, keyword: str, limit: int = 20):
        # Your search logic
        return []

    async def publish(self, text: str, **kwargs):
        # Your publish logic
        return {"id": "...", "url": "..."}

Roadmap

  • v0.2 โ€” Douyin plugin, Bilibili plugin
  • v0.3 โ€” MCP Server integration (use with Claude/Cursor)
  • v0.4 โ€” Web dashboard for monitoring and analytics
  • v0.5 โ€” Community plugin marketplace
  • v1.0 โ€” Stable release with full multi-platform support

Contributing

Contributions are welcome! Here's how you can help:

  1. New Platform Plugins โ€” Add support for Douyin, Bilibili, Zhihu, etc.
  2. Content Templates โ€” Share platform-specific content templates
  3. Analyzer Plugins โ€” Build analytics and reporting tools
  4. Documentation โ€” Improve guides, add tutorials
  5. Bug Reports โ€” Found a bug? Open an issue!

Development Setup

pip install -e ".[dev]"
pytest tests/ -v

License

MIT โ€” Free for personal and commercial use.


Made with โค๏ธ by zouyongfu

If you find this project useful, please give it a โญ!


ไธญๆ–‡ไป‹็ป

Social Agent ๆ˜ฏไป€ไนˆ๏ผŸ

Social Agent ๆ˜ฏไธ€ไธชๅผ€ๆบ็š„ AI ็คพไบคๅช’ไฝ“่ฟ่ฅๆก†ๆžถ๏ผŒๆ”ฏๆŒไธ€้”ฎ็›‘ๆŽง็ƒญ็‚นใ€AI ็”Ÿๆˆๅ†…ๅฎนใ€ๅคšๅนณๅฐๅˆ†ๅ‘ใ€ๆ•ฐๆฎๅˆ†ๆžใ€‚

ๆ ธๅฟƒ็†ๅฟต๏ผšๅ†™ไธ€ๆฌก๏ผŒๅ‘ๅˆฐๅค„ใ€‚่ฎฉ AI ๅธฎไฝ ๆžๅฎš็คพไบคๅช’ไฝ“่ฟ่ฅใ€‚

ๆ ธๅฟƒๅŠŸ่ƒฝ

  • ๐Ÿ”ฅ ็ƒญ็‚น็›‘ๆŽง โ€” ๅฎžๆ—ถ่Žทๅ–ๅพฎๅšใ€ๅฐ็บขไนฆใ€ๆŠ–้Ÿณใ€B็ซ™็ƒญๆœ
  • โœ๏ธ AI ๅ†…ๅฎน็”Ÿๆˆ โ€” ๆ นๆฎไธป้ข˜่‡ชๅŠจ็”Ÿๆˆๅนณๅฐ้€‚้…็š„ๅ†…ๅฎน
  • ๐Ÿ“ค ๅคšๅนณๅฐๅ‘ๅธƒ โ€” ไธ€ๆกๅ†…ๅฎน๏ผŒ่‡ชๅŠจ้€‚้…ๅคšไธชๅนณๅฐ้ฃŽๆ ผๅนถๅ‘ๅธƒ
  • ๐Ÿ” ่ทจๅนณๅฐๆœ็ดข โ€” ็ปŸไธ€ๆœ็ดขๆŽฅๅฃ๏ผŒไธ€ๆฌกๆœ็ดข่ฆ†็›–ๆ‰€ๆœ‰ๅนณๅฐ
  • ๐Ÿ“Š ๆ•ฐๆฎๅˆ†ๆž โ€” ่ฟฝ่ธชๅ„ๅนณๅฐ่ฟ่ฅๆ•ฐๆฎ๏ผŒAI ็”Ÿๆˆไผ˜ๅŒ–ๅปบ่ฎฎ
  • โฐ ๅฎšๆ—ถไปปๅŠก โ€” ๅฎšๆ—ถๅ‘ๅšใ€ๅฎšๆ—ถ็›‘ๆŽง็ƒญๆœ
  • ๐Ÿ”Œ ๆ’ไปถๅŒ–ๆžถๆž„ โ€” ๆฏไธชๅนณๅฐ้ƒฝๆ˜ฏ็‹ฌ็ซ‹ๆ’ไปถ๏ผŒ็คพๅŒบๅฏๆ‰ฉๅฑ•
  • ๐Ÿค– ๅคšๆจกๅž‹ๆ”ฏๆŒ โ€” ๆ”ฏๆŒ GPTใ€Claudeใ€้€šไน‰ๅƒ้—ฎใ€ๆ™บ่ฐฑGLMใ€Ollama

ๅฟซ้€ŸไธŠๆ‰‹

git clone https://github.com/zouyongfu/social-agent.git
cd social-agent
pip install -e ".[weibo]"
cp .env.example .env
# ็ผ–่พ‘ .env ๅกซๅ…ฅไฝ ็š„ API Key ๅ’Œ Cookie
social-agent status
social-agent trending

ไฝฟ็”จๅœบๆ™ฏ

  1. ่‡ชๅช’ไฝ“่ฟ่ฅ โ€” AI ่‡ชๅŠจ็”Ÿๆˆๅ†…ๅฎน๏ผŒๅฎšๆ—ถๅ‘ๅธƒๅˆฐๅคšไธชๅนณๅฐ
  2. ๅ“็‰Œ่ฅ้”€ โ€” ็›‘ๆŽงๅ“็‰Œ็›ธๅ…ณ็ƒญๆœ๏ผŒๅฟซ้€Ÿๅ“ๅบ”
  3. ็ซžๅ“ๅˆ†ๆž โ€” ่ฟฝ่ธช็ซžๅ“ๅŠจๆ€๏ผŒๅˆ†ๆž่ฟ่ฅ็ญ–็•ฅ
  4. ไธชไบบๅ“็‰Œ โ€” ไธ€้”ฎๅˆ†ๅ‘๏ผŒๆ‰ฉๅคงๅฝฑๅ“ๅŠ›
  5. ๅ†…ๅฎนๅˆ›ไฝœ โ€” AI ่พ…ๅŠฉๅˆ›ไฝœ๏ผŒๆ้ซ˜ไบงๅ‡บๆ•ˆ็އ
โ†‘โ†“ navigate openesc close