---
title: "Chat With Ai"
method: POST
path: "/api/v1/tbpi/chat"
tags: ["TBPI Analysis"]
---

# Chat With Ai

`POST /api/v1/tbpi/chat`

## Request

- Base URL: `https://app.perlucem.ai` (the document declares no server; this is the origin it was published from)
- URL: `https://app.perlucem.ai/api/v1/tbpi/chat`
- Auth: HTTP bearer

Chat with AI about bank data and analyses using Expert AI Analysts.

Features:
- Auto-selects persona based on pillar context
- Retrieves TBPI framework context from Bedrock Knowledge Base
- Includes completed TBPI analyses as context
- Maintains conversation history for follow-up questions
- Uses persona's system prompt, temperature, and model settings
- Supports streaming responses (stream=true)
- Optional chart data for visualizations
- Returns sources for transparency

## Request body

- ChatRequest: Request body for chat message
  - `rssd_id` string, required: Bank RSSD ID
  - `message` string, required: User's chat message
  - `pillar` string, nullable: Current pillar context for persona selection
  - `stream` boolean, nullable: Enable streaming response
  - `include_chart_data` boolean, nullable: Include chart data if relevant
  - `chat_session_id` string, nullable: Existing chat session ID to continue conversation
  - `deep_analysis` boolean, nullable: Enable deep analysis mode (Opus 4.5 with higher thinking budget)

## Response `200`

Successful Response

- unknown

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/perlucem/apis/perlucem-ai-backend.md) · [All operations](https://skmtc.dev/perlucem/apis/perlucem-ai-backend/llms.txt) · [OpenAPI document](https://skmtc.dev/perlucem/apis/perlucem-ai-backend/revisions/e1830fb27394?raw)
