Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.profy.cn/llms.txt

Use this file to discover all available pages before exploring further.

Profy uses a Monorepo + dual-layer backend architecture: Web Frontend (Next.js) handles UI rendering and SSE proxying, Core API (Hono + Bun) serves as the business middleware for auth, finance, and task management, and Agent Runtime (services/agent-runtime) runs Experts in declarative sandboxes (E2B/Docker).

Overview

  • Nginx serves as the unified entry point, routing by path to Web or Core API
  • Web Frontend handles page rendering and acts as an SSE proxy bridging users with the Agent Runtime
  • Core API is the hub for all business logic — auth, finance, tasks, marketplace, file management
  • Agent Runtime executes Experts inside isolated declarative sandboxes (E2B/Docker)

Tech Stack

LayerTechnologyNotes
FrontendNext.js 16, TypeScript, Tailwind CSSSSR + CSR, i18n support
BackendHono + BunHigh-performance API, REST + tRPC
ORMDrizzle ORMType-safe database access
AuthBetter Auth + JWTSMS OTP login, single-device policy
DatabaseMySQLPrimary data store
CacheRedisSession cache, OTP storage
StorageMinIO (S3)File uploads and object storage
AgentAgent RuntimeDeclarative sandbox (E2B/Docker) isolation
DeployDocker Compose, NginxSingle-node deploy, blue-green
ToolingBun, Biome, LefthookMonorepo management, code quality

Core Modules

Portal — App Marketplace

A consumer-facing app discovery platform with category browsing, search, favorites, and skill management. Public APIs are accessible without authentication.

Expert workforce — AI Experts & Agent Runtime

Experts (AI expert products) run on the Agent Runtime in declarative sandboxes (E2B/Docker), each with its own filesystem, communicating via SSE for real-time streaming conversations with tool calling and file operations. Projects coordinate multi-expert work; the Marketplace is the creator ecosystem surface.

Core API — Business Middleware

High-performance Hono backend covering all business domains:
DomainCapabilities
AuthSMS OTP login, JWT management, API Key
FinanceCoin system, top-up, WeChat Pay, spending records
TasksCreate, submit, Agent dispatch, paid results
FilesMinIO object storage, upload/download
MarketplaceApp/skill CRUD, categories, favorites

Request Lifecycle

Next Steps

Authentication

SMS login, JWT management, and security

Agent Platform

Agent Runtime and declarative sandbox lifecycle

Marketplace

App browsing, skill search, and favorites

Deployment

Docker Compose deployment and Nginx configuration