How rlpalomo25/ragseo-platform works
RAGSEO is a content-production platform that grounds AI-generated content in an ingested doctrine library and supports review, job tracking, and performance learning. Its main workflow is a content request routed through retrieval and agent processing, then exposed as a job result. Separate workflows ingest doctrine and external market data. The README documents hybrid retrieval and optional embedding providers; excerpts show selected ingestion, routing, task, and frontend behavior, so uncertain internal wiring is omitted.
Main entry points: database.py PostgreSQL + pgvector · main.py FastAPI app · doc_ingestion.py Doctrine ingestion · ingest.py Ingest endpoints
Components 27
User interface
- Next.js app
frontend/src/app - Ingest controls
frontend/src/lib/hooks/useIngest.ts - API client
frontend/src/lib/api.ts
API and identity
- FastAPI app
backend/app/main.py - Agent endpoints
backend/app/routers/agents.py - Ingest endpoints
backend/app/routers/ingest.py - Auth endpoints
backend/app/routers/auth.py - Session service
backend/app/services/auth_service.py - Job endpoints
backend/app/routers/jobs.py
Agent workflow
- Celery tasks
backend/app/tasks.py - Job orchestration
backend/app/services/orchestrator.py - Agent runner
backend/app/services/agent_runner.py - Request router
backend/app/services/agents/router.py - Content writer
backend/app/services/agents/writer.py - Content auditor
backend/app/services/agents/auditor.py
Knowledge and data
- Hybrid retrieval
backend/app/services/retrieval.py - Doctrine ingestion
backend/app/services/doc_ingestion.py - Document chunking
backend/app/services/chunking.py - Embedding service
backend/app/services/embeddings.py - Market data import
backend/app/services/external_ingest.py - Performance learning
backend/app/services/learning_loop.py - PostgreSQL + pgvector
backend/app/database.py
External integrations
- Redis / Celery queue
backend/app/celery_app.py - Ollama / Voyage AI
- Anthropic Claude
Other components
- Content user
- Doctrine corpus
Connections 32
- Content user → Next.js app: submits request
- Next.js app → API client: calls API
- API client → FastAPI app: HTTP requests
- FastAPI app → Agent endpoints: mounts routes
- FastAPI app → Ingest endpoints: mounts routes
- FastAPI app → Auth endpoints: mounts routes
- FastAPI app → Job endpoints: mounts routes
- Agent endpoints → Redis / Celery queue: dispatches tasks
- Redis / Celery queue → Celery tasks: runs tasks
- Celery tasks → Agent runner: runs agent
- Celery tasks → Job orchestration: advances job
- Agent runner → Request router: invokes agent
- Request router → Hybrid retrieval: retrieves doctrine
- Request router → Performance learning: loads performance context
- Request router → Anthropic Claude: requests completion
- Content writer → Anthropic Claude: requests completion
- Content auditor → Anthropic Claude: requests completion
- Hybrid retrieval → PostgreSQL + pgvector: searches chunks
- Ingest controls → API client: calls ingest API
- Ingest endpoints → Doctrine ingestion: ingests doctrine
- Doctrine ingestion → Doctrine corpus: reads files
- Doctrine ingestion → Document chunking: creates chunks
- Doctrine ingestion → Embedding service: embeds chunks
- Doctrine ingestion → PostgreSQL + pgvector: writes documents
- Embedding service → Ollama / Voyage AI: requests vectors
- Ingest endpoints → Market data import: imports exports
- Market data import → PostgreSQL + pgvector: stores market data
- Ingest endpoints → Performance learning: snapshots publications
- Performance learning → PostgreSQL + pgvector: reads and writes
- Auth endpoints → Session service: manages sessions
- Session service → PostgreSQL + pgvector: reads and writes
- Job endpoints → PostgreSQL + pgvector: reads job state