Metadata-Version: 2.4
Name: livekit-plugins-minimax
Version: 1.1.5
Summary: LiveKit Agent Plugins for Minimax(海螺AI)
Author-email: wangmengdi <790990241@qq.com>
Keywords: audio,livekit,realtime,video,webrtc
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: Apache Software License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3 :: Only
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Topic :: Multimedia :: Sound/Audio
Classifier: Topic :: Multimedia :: Video
Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
Requires-Python: >=3.9
Requires-Dist: livekit-agents>=1.1.5
Requires-Dist: openai
Requires-Dist: osc-data>=0.1.7.post0
Requires-Dist: pydantic
Description-Content-Type: text/markdown

# LiveKit Plugins Minimax

Agent Framework plugin for services from minimax(海螺AI). currently supports: [TTS](https://platform.minimaxi.com/document/Price?key=66701c7e1d57f38758d5818c), [LLM](https://platform.minimaxi.com/document/%E5%AF%B9%E8%AF%9D?key=66701d281d57f38758d581d0)

## Installation
```python
pip install livekit-plugins-minimax
```

## Pre-requisites

- Minimax environment variable: `MINIMAX_API_KEY`, `MINIMAX_GROUP_ID` you can find [here](https://platform.minimaxi.com/user-center/basic-information/interface-key)

## Usage


This example shows how to use the minimax TTS plugin.

```python
from livekit.agents import Agent, AgentSession, JobContext, cli, WorkerOptions
from livekit.plugins import minimax
from dotenv import load_dotenv


async def entry_point(ctx: JobContext):
    
    await ctx.connect()
    
    agent = Agent(instructions="You are a helpful assistant.")

    session = AgentSession(
        # you can find model and voice id at https://platform.minimaxi.com/document/T2A%20V2?key=66719005a427f0c8a5701643
        stt=minimax.STT(model="xxx", voice_id="xxx"),
        llm=minimax.LLM(model="MiniMax-Text-01")
    )
    
    await session.start(agent=agent, room=ctx.room)


if __name__ == "__main__":
    load_dotenv()
    cli.run_app(WorkerOptions(entrypoint_fnc=entry_point))
```

