Replace single report type with composable analysis: depth levels (basic/standard/full) + focus area multi-select (psychology, business, marketing, content, audience, sentiment). Multi-step inline keyboard flow guides users through selection. - i18n: English + Russian, auto-detect from Telegram, /lang override - AI providers: Anthropic + OpenRouter via AIClient abstraction - Telegram Stars payments with per-depth pricing and free trial - SQLite (aiosqlite) for users, analyses, payments tracking - User middleware for auto-registration and language detection - Report persistence: save .md locally, offer file download - New commands: /features, /prices, /lang - Composable prompt system: depth modifiers + focus area fragments
19 lines
951 B
Python
19 lines
951 B
Python
from bot.models import Depth
|
|
|
|
DEPTH_CHUNK_MODIFIERS: dict[Depth, str] = {
|
|
Depth.BASIC: "Provide a brief, high-level summary. Focus on the most important points only. Be concise.",
|
|
Depth.STANDARD: "Provide a structured summary with moderate detail. Cover key patterns and notable examples.",
|
|
Depth.FULL: (
|
|
"Provide an exhaustive, detailed analysis. Include specific examples, quotes, "
|
|
"numerical data, and subtle patterns. Leave nothing significant out."
|
|
),
|
|
}
|
|
|
|
DEPTH_SYNTHESIS_MODIFIERS: dict[Depth, str] = {
|
|
Depth.BASIC: "Keep the report concise and actionable. Use short sections with bullet points.",
|
|
Depth.STANDARD: "Provide a well-structured report with moderate depth. Balance brevity and detail.",
|
|
Depth.FULL: (
|
|
"Produce a comprehensive, in-depth report. Include detailed analysis, specific evidence, "
|
|
"data-backed observations, and strategic recommendations. Be thorough."
|
|
),
|
|
}
|