Local-first prototype for an agentic blog writing workspace.
The app pairs a chat interface with a dynamic workspace:
- Left side: session-based chat with live agent/tool activity.
- Right side: brainstorming plans and generated content drafts.
- Backend agent: tool-calling loop (
create_content_idea,update_content_plan,execute_plan,web_search).
Highlights:
- Onboarding + user/company context memory.
- Session management and persistent message history.
- Tool-driven planning + execution flow.
- SSE live events for chat and tool execution state.
- Manual plan/content edits and delete flows.
- Markdown preview, syntax highlighting, copy, and export (
.md,.txt). - Web search tool integration.
- Automated test coverage for golden flow, route behavior, SSE isolation, and end-to-end journey.
- Frontend: React + TypeScript + Vite + Tailwind CSS
- Backend: Flask + SQLAlchemy + Alembic + Pydantic + OpenAI SDK (for NVIDIA NIM)
- Database: PostgreSQL
- Python 3.11+
- Node.js 20+
- Docker Desktop (optional, recommended)
- PostgreSQL 16+ (only for local non-Docker workflow)
cd backend
copy .env.example .envRequired for AI replies:
- Set
NIM_API_KEYinbackend/.env
Key backend env values:
DATABASE_URLCORS_ORIGINSNIM_MODELWEB_SEARCH_MAX_RESULTS
cd frontend
copy .env.example .envKey frontend env values:
VITE_API_BASE_URL(default:http://localhost:8000)
From repo root:
docker compose up -d --build
docker compose psServices:
- Frontend:
http://localhost:5173 - Backend:
http://localhost:8000 - Swagger UI:
http://localhost:8000/apidocs/ - OpenAPI JSON:
http://localhost:8000/apispec_1.json - Adminer:
http://localhost:8080 - SSE stream:
http://localhost:8000/api/v1/stream
Default Postgres credentials:
- user:
postgres - password:
postgres - database:
manuscriptly_writer
Stop services:
docker compose downReset DB volume:
docker compose down -vcd backend
python -m unittest discover -s tests -p "test_*.py"cd frontend
npm run buildPOST /api/v1/users/onboardingGET /api/v1/users/{user_id}POST /api/v1/sessionsGET /api/v1/sessionsGET /api/v1/sessions/{session_id}/messagesPOST /api/v1/agent/chatGET /api/v1/plansPATCH /api/v1/plans/{plan_id}DELETE /api/v1/plans/{plan_id}GET /api/v1/contentPATCH /api/v1/content/{content_item_id}GET /api/v1/streamPOST /api/v1/stream/test
backend/
app/
api/routes/ # Flask route modules
agent_tools/ # Tool schemas, registry, handlers
services/ # AI, memory, message, web search services
core/ # config, bootstrap, SSE manager
models/ # SQLAlchemy entities
db/ # DB session factory
alembic/ # migrations
tests/ # backend test suite
frontend/
src/
components/ # chat, session, workspace UI
lib/ # API + SSE client helpers
- This is a local development prototype.
- No production deployment hardening is included.
- The focus is golden-flow reliability, testability, and developer ergonomics.