Skip to main content

The only B2B astrology API with AI-powered chatbot queries

Project description

Vedika Python SDK

Official Python SDK for the Vedika Astrology API - The only B2B astrology API with AI-powered chatbot queries.

PyPI version Python Versions License: MIT

🌟 What Makes Vedika Unique?

Vedika is the ONLY B2B astrology API that offers:

  • AI-Powered Chatbot Queries (conversational astrology questions)
  • Multi-Agent Swarm Intelligence (6 specialized AI agents)
  • 108+ Traditional Features (birth charts, dashas, yogas, doshas, compatibility)
  • 97.2% Prediction Accuracy (vs 51% industry average)
  • 99.9% Uptime (3-tier ephemeris fallback)
  • 22 Language Support (including 11 Indian languages)

In summary: All the features of traditional astrology APIs, PLUS conversational AI capabilities no other provider has.

🚀 Quick Start

Installation

pip install vedika-sdk

Basic Usage

from vedika import VedikaClient

# Initialize client
client = VedikaClient(api_key="vk_test_your_api_key_here")

# Ask a conversational astrology question (UNIQUE to Vedika!)
response = client.ask_question(
    question="What are my career prospects for this year?",
    birth_details={
        "datetime": "1990-06-15T14:30:00+05:30",
        "latitude": 28.6139,
        "longitude": 77.2090,
        "timezone": "Asia/Kolkata"
    },
    language="en"  # Supports 22 languages!
)

print(response.answer)
print(f"Confidence: {response.confidence}")
print(f"Credits used: {response.credits_used}")

Output Example

Answer: Based on your birth chart analysis, this year shows strong career potential...
[Detailed astrological insights from 6 AI agents]

Confidence: 0.972
Credits used: 450
Processing time: 28.7 seconds

📚 Features

🤖 AI Chatbot Queries (Unique Feature!)

# Conversational astrology - No other API has this!
response = client.ask_question(
    question="When should I start my new business?",
    birth_details=birth_info,
    language="hi"  # Ask in Hindi!
)

📊 Birth Chart Analysis

# Generate complete birth chart
chart = client.get_birth_chart(
    datetime="1990-06-15T14:30:00+05:30",
    latitude=28.6139,
    longitude=77.2090,
    ayanamsa="lahiri"  # 8 ayanamsa systems supported
)

print(chart.planets)
print(chart.houses)
print(chart.ascendant)

🔮 Dasha Periods

# Get Vimshottari Dasha periods
dashas = client.get_dashas(birth_details=birth_info)

for dasha in dashas.mahadashas:
    print(f"{dasha.planet}: {dasha.start_date} to {dasha.end_date}")

💑 Compatibility Analysis

# Ashtakoota matching for marriage compatibility
compatibility = client.check_compatibility(
    person1_details=birth_info_1,
    person2_details=birth_info_2
)

print(f"Total score: {compatibility.total_score}/36")
print(f"Compatibility: {compatibility.compatibility_level}")

🌟 Yoga Detection

# Detect 300+ astrological yogas
yogas = client.detect_yogas(birth_details=birth_info)

print(f"Found {len(yogas.yogas)} yogas:")
for yoga in yogas.yogas:
    print(f"- {yoga.name}: {yoga.description}")

⚠️ Dosha Analysis

# Check for Kaal Sarp, Mangal, Sade Sati doshas
doshas = client.analyze_doshas(birth_details=birth_info)

if doshas.kaal_sarp_dosha.present:
    print("Kaal Sarp Dosha detected")
    print(f"Type: {doshas.kaal_sarp_dosha.type}")
    print(f"Remedies: {doshas.kaal_sarp_dosha.remedies}")

🎯 Muhurtha (Auspicious Timing)

# Find auspicious times for important events
muhurtha = client.get_muhurtha(
    date="2025-11-01",
    location={"latitude": 28.6139, "longitude": 77.2090},
    event_type="wedding"
)

print(f"Auspicious times: {muhurtha.good_times}")
print(f"Inauspicious times: {muhurtha.bad_times}")

🔢 Numerology

# 37 numerology calculations
numerology = client.get_numerology(
    name="John Doe",
    birth_date="1990-06-15"
)

print(f"Life Path Number: {numerology.life_path}")
print(f"Expression Number: {numerology.expression}")
print(f"Soul Urge Number: {numerology.soul_urge}")

🌍 Multi-Language Support

Vedika supports 22 languages:

# Ask in Hindi
response = client.ask_question(
    question="मेरी कुंडली में कौन से योग हैं?",
    birth_details=birth_info,
    language="hi"
)

# Ask in Tamil
response = client.ask_question(
    question="என் ஜாதகத்தில் என்ன யோகங்கள் உள்ளன?",
    birth_details=birth_info,
    language="ta"
)

Supported languages:

  • 🇮🇳 Indian: Hindi, Bengali, Telugu, Tamil, Gujarati, Kannada, Malayalam, Marathi, Punjabi, Odia, Assamese
  • 🌍 International: English, Spanish, French, German, Italian, Portuguese, Russian, Japanese, Korean, Chinese, Arabic

🎨 Advanced Features

Streaming Responses (Real-Time)

# Stream responses for better UX
for chunk in client.ask_question_stream(
    question="What are my career prospects?",
    birth_details=birth_info
):
    print(chunk.text, end="", flush=True)

Batch Processing

# Process multiple queries efficiently
queries = [
    {"question": "Career prospects?", "birth_details": birth1},
    {"question": "Marriage timing?", "birth_details": birth2},
    {"question": "Business success?", "birth_details": birth3}
]

results = client.batch_process(queries)

Caching (90% Cost Savings!)

# Vedika automatically caches repeated queries
# First query: Full cost
response1 = client.ask_question(question, birth_info)  # $0.52

# Subsequent queries with same birth details: 90% savings!
response2 = client.ask_question(another_question, birth_info)  # $0.05

📖 Complete Documentation

💰 Pricing

Token-based pricing - pay only for what you use:

Query Type Cost Tokens
Simple (daily horoscope) $0.19 ~500
Standard (birth chart) $0.35 ~800
Complex (comprehensive) $0.65 ~1,500

Free sandbox: Test with 65 mock endpoints at vedika.io/sandbox — no signup required. Production starts at $12/month.

See full pricing: https://vedika.io/pricing.html

🔧 Configuration

Environment Variables

export VEDIKA_API_KEY="vk_test_your_api_key_here"
export VEDIKA_API_URL="https://api.vedika.io"  # Optional

Client Options

client = VedikaClient(
    api_key="vk_test_...",
    timeout=60,  # Request timeout in seconds
    max_retries=3,  # Retry failed requests
    cache_enabled=True,  # Enable prompt caching for cost savings
    language="en"  # Default language for responses
)

🧪 Testing

# Install dev dependencies
pip install -e ".[dev]"

# Run tests
pytest

# Run tests with coverage
pytest --cov=vedika

# Run specific test
pytest tests/test_chatbot.py::test_ask_question

📝 Examples

Check out the examples/ directory:

  • basic_chatbot.py - Simple conversational astrology bot
  • birth_chart_analysis.py - Complete birth chart generation
  • compatibility_checker.py - Marriage compatibility analysis
  • dosha_detector.py - Comprehensive dosha analysis
  • muhurtha_finder.py - Find auspicious times
  • multi_language.py - Multi-language support demo
  • streaming_example.py - Real-time streaming responses
  • flask_app.py - Flask web application example
  • django_integration.py - Django integration example

🤝 Contributing

We welcome contributions! See CONTRIBUTING.md.

Development Setup

# Clone repository
git clone https://github.com/vedika-intelligence/vedika-sdk-python.git
cd vedika-sdk-python

# Create virtual environment
python -m venv venv
source venv/bin/activate  # On Windows: venv\Scripts\activate

# Install in development mode
pip install -e ".[dev]"

# Run tests
pytest

🐛 Troubleshooting

"Invalid API Key"

Make sure you're using a valid API key from https://vedika.io/dashboard.html

Keys start with:

  • vk_test_ for testing
  • vk_live_ for production

"Insufficient Credits"

Add credits to your account: https://vedika.io/dashboard.html

"Request Timeout"

For complex queries, increase timeout:

client = VedikaClient(api_key="...", timeout=120)  # 2 minutes

"Rate Limit Exceeded"

You're sending too many requests. Wait a moment or upgrade your plan.

📊 Performance

  • Average response time: 2.14 seconds (simple queries)
  • Complex queries: 28-36 seconds (multi-agent processing)
  • Uptime: 99.9% (3-tier ephemeris fallback)
  • Accuracy: 97.2% prediction accuracy

🔒 Security

  • ✅ API keys encrypted in transit (HTTPS)
  • ✅ GDPR compliant
  • ✅ No data retention (unless explicitly enabled)
  • ✅ Security score: 95/100 (A grade)

📜 License

MIT License - see LICENSE file

🌐 Links

⭐ Support

If you find this SDK helpful, please:

  • ⭐ Star this repository
  • 🐛 Report issues on GitHub
  • 💬 Join our community discussions
  • 📧 Contact support@vedika.io for help

🎯 Why Choose Vedika?

Vedika vs Traditional Astrology APIs

Feature Vedika Others
AI Chatbot Queries ✅ YES (UNIQUE!) ❌ No
Birth Charts ✅ Yes ✅ Yes
Dashas ✅ Yes ✅ Yes
Compatibility ✅ Yes ✅ Yes
300+ Yogas ✅ Yes ⚠️ Limited
Dosha Analysis ✅ Complete ⚠️ Basic
Multi-Agent AI ✅ 6 Agents ❌ No
22 Languages ✅ Yes ❌ English only
Streaming ✅ Yes ❌ No
Uptime 99.9% ~99%
Security Score 95/100 (A) Unknown
Unique Value Traditional + AI Traditional only

Bottom line: Vedika provides everything other astrology APIs offer, PLUS the only conversational AI chatbot capability in the market.


Built with ❤️ by Vedika Intelligence

The only B2B astrology API with AI-powered chatbot queries.

Get started: https://vedika.io

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

vedika_sdk-1.5.0.tar.gz (33.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

vedika_sdk-1.5.0-py3-none-any.whl (16.4 kB view details)

Uploaded Python 3

File details

Details for the file vedika_sdk-1.5.0.tar.gz.

File metadata

  • Download URL: vedika_sdk-1.5.0.tar.gz
  • Upload date:
  • Size: 33.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.7

File hashes

Hashes for vedika_sdk-1.5.0.tar.gz
Algorithm Hash digest
SHA256 bd35c0ef6d62242d2385e5734197dfdaf709ad25983e390a8ae06558bcf1ea78
MD5 6d7a4a680cc291455c917d6bad157085
BLAKE2b-256 88b4336d37e8a21a871f8e1c1a164f287a78d0b857bf90faccb74cbf671f93a7

See more details on using hashes here.

File details

Details for the file vedika_sdk-1.5.0-py3-none-any.whl.

File metadata

  • Download URL: vedika_sdk-1.5.0-py3-none-any.whl
  • Upload date:
  • Size: 16.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.7

File hashes

Hashes for vedika_sdk-1.5.0-py3-none-any.whl
Algorithm Hash digest
SHA256 34c399f26485a9ae07c39d51851d6e498c9198248fb2519f16c9fa2a44ac7d17
MD5 9e7150010489e14cae4895944ad6adc6
BLAKE2b-256 4a91c2fb91f2d41cb3e78c88c1bbacac3b0031308eafd458c052f1235201a8f7

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page