Catalog PyPI
PACKAGE EXPLORERView in registry

ai-influencer

PyPI

Create and manage AI-powered Instagram influencers programmatically

aiautomationinfluencerinstagramsocial-media
Versions collected1
Direct dependencies10From release 0.1.0
Last observed21 Oct, 11:02 UTC

README

Version 0.1.0 documentation

ai-influencer

Create and manage AI-powered Instagram influencers programmatically.

pip install ai-influencer

What it does

ai-influencer lets you spin up a fully automated AI Instagram influencer with a single Python file. Give it a persona (name, niche, reference photo) and it will:

  • 🎨 Generate images of your influencer using Kie.ai (GPT Image 2) with reference-image consistency
  • 🎬 Generate Reels via a two-step pipeline: scene image → Grok image-to-video (15s, 720p)
  • 🖼️ Generate carousels where every slide looks visually consistent (same outfit, same setting)
  • ✍️ Write captions via OpenRouter (on-brand, with hashtags)
  • 📸 Post to Instagram automatically via the Meta Graph API
  • ⏰ Schedule posts for a future date/time

Quick start

from influencer_ai import Influencer

# 1. Initialize (reads from .env automatically)
kai = Influencer()

# 2. Define the influencer's identity
kai.set_persona(
    name="Kai",
    gender="female",
    age=24,
    niche="fitness & lifestyle",
    tone="energetic and motivating",
    # Local file or HTTPS URL — auto-uploaded to Cloudinary
    sample_images=["path/to/reference_photo.jpg"],
)

# 3. Post a Reel (full AI pipeline)
kai.post_reel(
    prompt="Morning yoga on the beach at golden hour",
    caption="auto",
    hashtags=["#yoga", "#morningvibes"],
    improve_prompt=True,
    duration=15,
    resolution="720p",
)

# 4. Post an image
kai.post_image(
    prompt="Sitting in a cosy café, warm sunlight, candid smile",
    caption="auto",
)

# 5. Post a carousel (consistent theme across all slides)
kai.post_carousel(
    prompts=[
        "At the entrance of Taj Mahal at sunrise, excited, white salwar kameez",
        "Selfie with Taj Mahal in background, same white outfit",
        "Walking along the reflecting pool, golden hour, same outfit",
    ],
    caption="auto",
    hashtags=["#tajmahal", "#travel"],
)

# 6. Schedule a future post
kai.post_image(
    prompt="Sunset beach yoga",
    schedule="2025-12-01 07:00",
)

Environment variables

Create a .env file in your project root:

KIE_API_KEY=...
INSTAGRAM_ACCESS_TOKEN=...
INSTAGRAM_USER_ID=...
OPENROUTER_API_KEY=...        # optional — enables prompt enhancement & captions
CLOUDINARY_CLOUD_NAME=...
CLOUDINARY_API_KEY=...
CLOUDINARY_API_SECRET=...

Or pass them directly to Influencer(kie_api_key=..., ...).


How it works

prompt
  └─► OpenRouter (enhance_prompt)
        └─► Kie.ai GPT Image 2 (scene image with reference photos)
              └─► Kie.ai Grok image-to-video (15s, 720p)
                    └─► Cloudinary (permanent hosting)
                          └─► Meta Graph API (Instagram publish)

Visual consistency: The last 5 generated posts are automatically used as reference images for future generations, keeping your influencer's appearance consistent across content.


Services required

ServicePurposeFree tier
Kie.aiAI image & video generationCredits-based
CloudinaryPermanent media hosting25 GB free
OpenRouterCaption & prompt enhancementPay per token
Meta Graph APIInstagram publishingFree

License

MIT

Downloads & popularity

Awaiting observations

No metric observations yet

Download counts and popularity will appear here as the collector receives them.

Versions 1

Collected releases
VersionPublishedDirect dependenciesOpen version
0.1.021 May 202610

Package advisories

0
No matching advisories collected

This describes our collected data; it is not a security assessment.

Repository

PENDING
yourusername/influencer-ai

Shared repository data · GitHub

License detected in repository
Not collected

Metadata history

Meaningful changes
Current collected state Current

Observed since 21 Oct, 11:02 UTC

No superseded metadata states collected. Unchanged observations do not create new revisions.

Record identity

package:745f0d6d65e5992d58cef85b40b92b1598682a678a39cd9622896febba777fcf