feat: route requests to social post writer
This commit is contained in:
1 parent
6d46d2c2e3
commit
7fbaf0d631
2 files changed
+7
-13
No files matched your search
@@ -1,15 +1,14 @@
|
||||
# Social Post Writer Bot — development
|
||||
|
||||
The bot prepares social media posts on explicit request. It uses APInex STT for Russian voice messages and Gemini 3.8 Flash through APInex for intent classification, post writing/revision, and visual reading of post screenshots to infer a personal Tone of Voice.
|
||||
The bot prepares social-media posts only when the user explicitly asks. It transcribes Russian voice notes with APInex STT, classifies intent with an LLM, and uses Gemini 3.8 Flash via APInex to write/revise posts or infer Tone of Voice from a screenshot. A post request/revision returns three separate messages. The bot stores no conversation history.
|
||||
|
||||
- Runtime: Python 3.12, aiogram 3.x
|
||||
- Coolify environment: `development` on `spb-easy-dale`
|
||||
- Gitea branch: `dev`
|
||||
- Runtime variables are configured only in Coolify: `BOT_TOKEN`, `BOT_ENV`, `APINEX_API_KEY`, `APINEX_STT_MODEL`, `APINEX_INTENT_CLASSIFIER_MODEL`, `APINEX_POST_WRITER_MODEL`, `APINEX_IMAGE_TONE_MODEL`, `BOT_DB_PATH`.
|
||||
- Models default to `gemini-3.8-flash`; STT defaults to APInex `nova-2`.
|
||||
- Per-user Tone of Voice is stored in SQLite at `/app/data/social_writer.sqlite3`; mount a persistent Coolify volume at `/app/data`.
|
||||
- Each explicit post request and each reply-edit returns three posts as separate Telegram messages. No conversational history is stored.
|
||||
- Screenshots are sent to vision using inline base64 data URLs; uploaded images and source post texts are not persisted.
|
||||
- Coolify: project `Social Post Writer Bot`, environment `development`, server `spb-easy-dale`
|
||||
- Gitea: `admin/social-post-writer-bot`, branch `dev`
|
||||
- API key and model variables are stored only in Coolify: `APINEX_API_KEY`, `APINEX_STT_MODEL`, `APINEX_INTENT_CLASSIFIER_MODEL`, `APINEX_POST_WRITER_MODEL`, `APINEX_IMAGE_TONE_MODEL`.
|
||||
- LLM model env defaults are `gemini-3.8-flash`; STT model defaults to APInex `nova-2`.
|
||||
- Per-user Tone of Voice lives in SQLite at `/app/data/social_writer.sqlite3`; persistent Coolify storage must be mounted at `/app/data`.
|
||||
- Telegram screenshots are sent to APInex as inline base64 data URLs; images and full source text are not persisted.
|
||||
|
||||
## Local tests
|
||||
|
||||
|
||||
@@ -177,11 +177,6 @@ async def handle_text(message: Message) -> None:
|
||||
await _classify_and_respond(message, message.text)
|
||||
|
||||
|
||||
async def echo(message: Message) -> None:
|
||||
if message.text:
|
||||
await message.answer(message.text)
|
||||
|
||||
|
||||
async def main() -> None:
|
||||
init_db()
|
||||
token = os.environ.get("BOT_TOKEN", "").strip()
|
||||
|
||||
Reference in new issue
Block a user