smart-bot-factory 0.1.3__py3-none-any.whl → 0.1.5__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of smart-bot-factory might be problematic. Click here for more details.

Files changed (37) hide show
  1. smart_bot_factory/__init__.py +0 -48
  2. smart_bot_factory/admin/admin_logic.py +11 -11
  3. smart_bot_factory/cli.py +299 -106
  4. smart_bot_factory/clients/__init__.py +33 -0
  5. smart_bot_factory/configs/growthmed-october-24/prompts/final_instructions.txt +2 -0
  6. smart_bot_factory/configs/growthmed-october-24/tests/quick_scenarios.yaml +95 -28
  7. smart_bot_factory/core/__init__.py +43 -22
  8. smart_bot_factory/core/bot_utils.py +268 -95
  9. smart_bot_factory/core/conversation_manager.py +542 -535
  10. smart_bot_factory/core/decorators.py +943 -229
  11. smart_bot_factory/core/globals.py +68 -0
  12. smart_bot_factory/core/message_sender.py +6 -6
  13. smart_bot_factory/core/router.py +172 -0
  14. smart_bot_factory/core/router_manager.py +165 -0
  15. smart_bot_factory/creation/__init__.py +1 -2
  16. smart_bot_factory/creation/bot_builder.py +116 -8
  17. smart_bot_factory/creation/bot_testing.py +74 -13
  18. smart_bot_factory/handlers/handlers.py +10 -2
  19. smart_bot_factory/integrations/__init__.py +1 -0
  20. smart_bot_factory/integrations/supabase_client.py +272 -2
  21. smart_bot_factory/utm_link_generator.py +106 -0
  22. smart_bot_factory-0.1.5.dist-info/METADATA +466 -0
  23. {smart_bot_factory-0.1.3.dist-info → smart_bot_factory-0.1.5.dist-info}/RECORD +26 -31
  24. smart_bot_factory/configs/growthmed-helper/env_example.txt +0 -1
  25. smart_bot_factory/configs/growthmed-helper/prompts/1sales_context.txt +0 -9
  26. smart_bot_factory/configs/growthmed-helper/prompts/2product_info.txt +0 -582
  27. smart_bot_factory/configs/growthmed-helper/prompts/3objection_handling.txt +0 -66
  28. smart_bot_factory/configs/growthmed-helper/prompts/final_instructions.txt +0 -232
  29. smart_bot_factory/configs/growthmed-helper/prompts/help_message.txt +0 -28
  30. smart_bot_factory/configs/growthmed-helper/prompts/welcome_message.txt +0 -7
  31. smart_bot_factory/configs/growthmed-helper/welcome_file/welcome_file_msg.txt +0 -16
  32. smart_bot_factory/configs/growthmed-helper/welcome_file//342/225/250/320/267/342/225/250/342/225/241/342/225/250/342/225/221 /342/225/250/342/225/227/342/225/250/342/225/225/342/225/244/320/221/342/225/244/320/222 /342/225/250/342/224/220/342/225/250/342/225/233 152/342/225/250/320/264/342/225/250/320/247 /342/225/250/342/225/225 323/342/225/250/320/264/342/225/250/320/247 /342/225/250/342/224/244/342/225/250/342/225/227/342/225/244/320/237 /342/225/250/342/225/235/342/225/250/342/225/241/342/225/250/342/224/244/342/225/250/342/225/225/342/225/244/320/226/342/225/250/342/225/225/342/225/250/342/225/234/342/225/244/320/233.pdf +0 -0
  33. smart_bot_factory/uv.lock +0 -2004
  34. smart_bot_factory-0.1.3.dist-info/METADATA +0 -126
  35. {smart_bot_factory-0.1.3.dist-info → smart_bot_factory-0.1.5.dist-info}/WHEEL +0 -0
  36. {smart_bot_factory-0.1.3.dist-info → smart_bot_factory-0.1.5.dist-info}/entry_points.txt +0 -0
  37. {smart_bot_factory-0.1.3.dist-info → smart_bot_factory-0.1.5.dist-info}/licenses/LICENSE +0 -0
@@ -1,126 +0,0 @@
1
- Metadata-Version: 2.4
2
- Name: smart-bot-factory
3
- Version: 0.1.3
4
- Summary: Библиотека для создания умных чат-ботов
5
- Author-email: Kopatych <kopatych@example.com>
6
- License: MIT
7
- License-File: LICENSE
8
- Keywords: chatbot,cli,openai,supabase,telegram
9
- Classifier: Development Status :: 4 - Beta
10
- Classifier: Environment :: Console
11
- Classifier: Framework :: AsyncIO
12
- Classifier: Intended Audience :: Developers
13
- Classifier: License :: OSI Approved :: MIT License
14
- Classifier: Operating System :: OS Independent
15
- Classifier: Programming Language :: Python :: 3
16
- Classifier: Programming Language :: Python :: 3.9
17
- Classifier: Programming Language :: Python :: 3.10
18
- Classifier: Programming Language :: Python :: 3.11
19
- Classifier: Programming Language :: Python :: 3.12
20
- Classifier: Topic :: Communications :: Chat
21
- Classifier: Topic :: Software Development :: Libraries :: Python Modules
22
- Requires-Python: >=3.9
23
- Requires-Dist: aiofiles>=23.0.0
24
- Requires-Dist: aiogram>=3.4.1
25
- Requires-Dist: click>=8.0.0
26
- Requires-Dist: openai>=1.12.0
27
- Requires-Dist: project-root-finder>=1.9
28
- Requires-Dist: python-dotenv>=1.0.1
29
- Requires-Dist: pytz>=2023.3
30
- Requires-Dist: pyyaml>=6.0.2
31
- Requires-Dist: supabase>=2.3.4
32
- Description-Content-Type: text/markdown
33
-
34
- # Smart Bot Factory
35
-
36
- Библиотека для создания умных чат-ботов с использованием OpenAI, Telegram и Supabase.
37
-
38
- ## Установка
39
-
40
- ```bash
41
- pip install smart-bot-factory
42
- ```
43
-
44
- ## Быстрый старт
45
-
46
- 1. Создайте нового бота:
47
- ```bash
48
- sbf create my-bot
49
- ```
50
-
51
- 2. Настройте конфигурацию в `bots/my-bot/.env`
52
-
53
- 3. Запустите бота:
54
- ```bash
55
- sbf run my-bot
56
- ```
57
-
58
- ## Возможности
59
-
60
- - 🤖 Интеграция с OpenAI GPT для умных ответов
61
- - 📱 Поддержка Telegram Bot API через aiogram
62
- - 💾 Хранение данных в Supabase
63
- - 🔄 Система событий и обработчиков
64
- - ⏰ Планировщик задач
65
- - 🧪 Встроенная система тестирования
66
- - 📝 Управление промптами
67
- - 🛠️ Удобный CLI интерфейс
68
-
69
- ## CLI команды
70
-
71
- ```bash
72
- # Создать нового бота
73
- sbf create my-bot
74
-
75
- # Запустить бота
76
- sbf run my-bot
77
-
78
- # Показать список ботов
79
- sbf list
80
-
81
- # Управление промптами
82
- sbf prompts my-bot --list
83
- sbf prompts my-bot --edit welcome_message
84
- sbf prompts my-bot --add new_prompt
85
-
86
- # Запустить тесты
87
- sbf test my-bot
88
- ```
89
-
90
- ## Пример использования
91
-
92
- ```python
93
- from smart_bot_factory import BotBuilder, event_handler, schedule_task
94
-
95
- # Обработчик события
96
- @event_handler("book_appointment", "Запись на прием")
97
- async def handle_booking(user_id: int, event_data: dict):
98
- # Логика обработки записи на прием
99
- return {"status": "success"}
100
-
101
- # Запланированная задача
102
- @schedule_task("send_reminder", "Отправка напоминания")
103
- async def send_reminder(user_id: int, message: str):
104
- # Логика отправки напоминания
105
- return {"status": "sent"}
106
-
107
- # Запуск бота
108
- async def main():
109
- bot = BotBuilder("my-bot")
110
- await bot.build()
111
- await bot.start()
112
-
113
- if __name__ == "__main__":
114
- asyncio.run(main())
115
- ```
116
-
117
- ## Требования
118
-
119
- - Python 3.9+
120
- - OpenAI API ключ
121
- - Telegram Bot Token
122
- - Supabase проект
123
-
124
- ## Лицензия
125
-
126
- MIT