This is a simple web application based on a multi-modal or multi-AI agent based deliberation system. The architecture involves utilising two different AI models (such as Qwen and Gemini), operating through distinct API providers (e.g., Qwen via Aliyun and Gemini via Google AI Studio), ideally leveraging Open AI based model API support.
The deliberation begins when a user submits an idea, topic, opinion, or question, which prompts both agents to provide simultaneous initial responses. Subsequently, the core process involves the agents exchanging their responses, with each agent tasked to judge and comment on the other's reply. This exchange is structured via a JSON format input/output, which includes critical parameters defining the state of the conversation, such as whether it is ongoing, stopped, or if a final decision has been reached; system prompts also inform both agents of their duties and the presence of the other agent.
The conversation continues until both agents mutually agree upon and arrive at a final decision, which is then presented as the result. Crucially, the system provides live visibility of the ongoing discussion, and the user is permitted to intervene and terminate the exchange using a button action, resulting in the display of the agents' current decisions.
Create .env file and add these information:
# --- Google Gemini API Configuration ---
VITE_GEMINI_API_KEY=""
# --- Aliyun Dashscope (Qwen) API Configuration ---
VITE_DASHSCOPE_API_KEY="sk-"
VITE_DASHSCOPE_BASE_URL="https://dashscope.aliyuncs.com/compatible-mode/v1"
Then install the npm packages and run the application:
npm install
npm run dev
- Ayub Ali Emon
- [email protected]

