Official Agent Index for LobeChat, featuring community-contributed high-quality prompts and AI assistant roles via index.json, covering programming, writing, translation, academic, and more.
Project Positioning#
LobeChat Agent Index is a core component of the LobeChat ecosystem, serving as the backend data source for the "GPTs Store." It maintains an index.json file containing extensive predefined Agent metadata and related configuration files. The LobeChat frontend accesses this index to display available Agents to users.
Problems Solved#
- Discovery & Distribution: Addresses the challenge of sharing and discovering high-quality prompts across users, building a standardized distribution channel
- Configuration Standardization: Standardizes Agent metadata including name, description, tags, and system prompts through
agent-templatestructure - Crowdsourced Maintenance: Utilizes GitHub PR mechanism for community-driven Agent content maintenance
Core Features#
Agent Index Aggregation#
Maintains index.json, aggregating all indexed Agent metadata for LobeChat clients to fetch. Covers programming development, academic writing, multilingual translation, mental health, legal consultation, gaming, and more.
Standardized Templates#
Provides agent-template.json and agent-template-full.json for standardized submission formats. The createAt field is automatically generated after PR merge.
Automated i18n#
Leverages LobeChat's capabilities to automatically translate Agent prompts into multiple languages.
Typical Agent Examples#
| Agent Name | Domain | Description |
|---|---|---|
| Academic Writing Assistant | Academic Writing | Expert in academic research paper writing and formal documentation |
| Programming Development Assistant | Programming | Skilled in development, debugging, and code issue resolution |
| Multilingual Translator | Translation | Professional translation between Chinese, English, and Japanese |
| Mental Health Counselor | Counseling | Psychological counselor providing listening and support |
| Python Development Master | Python | Python development expert emphasizing security and maintainability |
Architecture Design#
Adopts Data Repository pattern - code as data.
Data Definition Layer (src/ directory)#
Each Agent is stored as an independent JSON file in the src/ directory. Filename typically corresponds to the Agent's unique identifier. Structure includes: author, name, description, tags, config (containing systemRole), etc.
Index Build Layer#
Project includes build scripts (Bun scripts) that scan all JSON files in the src/ directory and aggregate them into the root index.json file. Includes format script utilizing OpenAI API for translation or content formatting.
Consumption Layer#
LobeChat frontend application periodically or on-demand fetches the repository's index.json via HTTP requests, parses and renders the "Agent Market" interface.
Usage#
Local Development & Contribution#
# Clone repository
git clone https://github.com/lobehub/lobe-chat-agents.git
cd lobe-chat-agents
# Install dependencies
bun install
# Format & validate (requires OPENAI_API_KEY)
bun run format
Steps to Submit Agent#
- Fork this repository
- Copy
agent-template.jsonoragent-template-full.jsontemplate - Fill in Agent description, tags, and other metadata, then rename
- Move file to
srcdirectory - Submit PR, await review and merge
Environment Variables#
| Variable | Required | Description |
|---|---|---|
OPENAI_API_KEY | Yes | OpenAI API key |
OPENAI_PROXY_URL | No | OpenAI API proxy URL |
One-Click Deploy Private Market#
Supports "Deploy to Vercel" button for quick deployment of private Agent index service. After deployment, point to the deployment address in LobeChat's custom settings to use the private market.