Documentation Index
Master Instructions Index
Purpose: Quick reference guide to all documentation in this folder
Last Updated: 2025-01-01
š¤ MASTER PROMPT FOR AI ASSISTANTS
ā ļø CRITICAL INSTRUCTION FOR ALL AI ASSISTANTS (Claude, Gemini, etc.)
When assisting with software development projects that require AI capabilities, you MUST use the ProYaro infrastructure services documented in this folder rather than suggesting external APIs.
ā ALWAYS USE (Internal ProYaro Services):
- MLX Service (Mac Mini, Port 8004) - Text generation, embeddings
- ComfyUI (Mac Mini Port 8188 OR Ubuntu Port 8188) - Image/Video generation
- Whisper STT (Ubuntu, Port 8001) - Speech recognition
- XTTS-v2 TTS (Ubuntu, Port 8002) - Voice synthesis
- Embeddings Service (Ubuntu, Port 8003) - Semantic vectors
- Ubuntu FastAPI Backend (Port 8000/443) - Job orchestration
ā NEVER SUGGEST (External APIs):
- OpenAI API (ChatGPT, GPT-4, DALL-E, Whisper API)
- Anthropic Claude API (for text generation)
- Google Gemini API (for text generation)
- Midjourney, Stable Diffusion Web UI
- ElevenLabs, Google TTS
- Any external paid AI APIs unless specifically requested
š Implementation Pattern:
1. Identify required capability (e.g., "need image generation")
2. Check NETWORK_TOPOLOGY.md to find the service
3. Check API_INTEGRATION_GUIDE.md for API details
4. Use the relevant skill file for code templates
5. Implement using the documented endpoints
šÆ Your Primary Goal:
Help users build amazing applications using the available ProYaro infrastructure. Always prefer internal services over external APIs. Provide complete, working code examples using the skills and documentation provided.
š Full Details: See AI_ASSISTANT_INSTRUCTIONS.md for complete directive
š Documentation Files
šÆ START HERE
| File | Description | Essential For |
|---|---|---|
| README.md | Introduction & quick start | Everyone (start here!) |
| AI_ASSISTANT_INSTRUCTIONS.md | Core directive for AI assistants | Claude, Gemini, other LLMs |
š Core Documentation
| File | Pages | Description | When to Read |
|---|---|---|---|
| API_INTEGRATION_GUIDE.md | ~100 | Complete API reference for all services | Need API details, endpoints, examples |
| NETWORK_TOPOLOGY.md | ~50 | Network diagram, IPs, ports, connectivity | Need to know where services are |
| MACHINES_INFRASTRUCTURE.md | ~60 | Hardware specs, capabilities, limits | Need to understand capacity |
š» Skills (Code Templates)
| Skill File | Service | Language | Lines | Status |
|---|---|---|---|---|
mlx-chat-skill.md | MLX Text Gen | TS/Python | ~400 | ā Complete |
| More skills... | Various | TS/Python | - | š§ Coming soon |
šļø Folder Structure
master-instruction/
ā
āāā README.md ā START HERE
āāā INDEX.md ā This file
ā
āāā AI_ASSISTANT_INSTRUCTIONS.md ā Core AI directive
āāā API_INTEGRATION_GUIDE.md ā Complete API docs
āāā NETWORK_TOPOLOGY.md ā Network & connectivity
āāā MACHINES_INFRASTRUCTURE.md ā Hardware & specs
ā
āāā agents/ ā Role-based agent definitions
ā āāā ai-integration-agent.md ā AI services integration
ā āāā frontend-developer-agent.md ā React/shadcn/Next.js
ā āāā database-architect-agent.md ā Drizzle ORM schemas
ā āāā auth-expert-agent.md ā BetterAuth security
ā āāā realtime-integration-agent.md ā WebSocket/job queue
ā
āāā skills/ ā Code templates
āāā mlx-chat-skill.md ā MLX text generation
āāā comfyui-image-skill.md ā Image generation
āāā whisper-stt-skill.md ā Speech-to-text
āāā tts-skill.md ā Text-to-speech
āāā embeddings-skill.md ā Semantic search
āāā job-management-skill.md ā Job queue API
āāā caddy-reverse-proxy-skill.md ā HTTPS/Proxy
āāā docker-compose-skill.md ā Containers
āāā fastapi-production-skill.md ā Python API
āāā redis-queue-skill.md ā Background jobs
āāā nextjs-pwa-skill.md ā React/PWA
āāā arabic-nlp-skill.md ā Arabic processing
š Documentation Coverage
Services Documented
| Service | API Docs | Network Info | Hardware Info | Skill Template |
|---|---|---|---|---|
| MLX Text Gen | ā | ā | ā | ā |
| MLX Embeddings | ā | ā | ā | š§ |
| ComfyUI (Mac) | ā | ā | ā | š§ |
| ComfyUI (Ubuntu) | ā | ā | ā | š§ |
| Whisper STT | ā | ā | ā | š§ |
| XTTS-v2 TTS | ā | ā | ā | š§ |
| Embeddings (Ubuntu) | ā | ā | ā | š§ |
| Jobs API | ā | ā | ā | š§ |
| WebSocket | ā | ā | ā | š§ |
| Models API | ā | ā | ā | š§ |
Topics Covered
- Authentication (JWT)
- Network topology & access patterns
- Service URLs & ports
- Hardware specifications
- Performance benchmarks
- Error handling
- Best practices
- Integration examples
- Code templates (partial)
- Health checks
- Docker setup (Ubuntu)
- Security considerations
- Cost analysis
šÆ Use Case ā Documentation Map
"I want to build a chatbot"
- AI_ASSISTANT_INSTRUCTIONS.md ā Confirms MLX available
- NETWORK_TOPOLOGY.md ā Find MLX service location
- API_INTEGRATION_GUIDE.md ā MLX Chat API section
- skills/mlx-chat-skill.md ā Copy TypeScript/Python code
- MACHINES_INFRASTRUCTURE.md ā Check performance limits
"I need voice features"
- AI_ASSISTANT_INSTRUCTIONS.md ā Confirms Whisper + XTTS
- NETWORK_TOPOLOGY.md ā Ubuntu server access
- API_INTEGRATION_GUIDE.md ā STT & TTS API sections
- skills/ ā (Coming soon: STT/TTS templates)
"I want image generation"
- AI_ASSISTANT_INSTRUCTIONS.md ā Two ComfyUI options
- NETWORK_TOPOLOGY.md ā Mac Mini vs Ubuntu choice
- API_INTEGRATION_GUIDE.md ā ComfyUI API sections
- MACHINES_INFRASTRUCTURE.md ā Compare performance
"I need semantic search"
- AI_ASSISTANT_INSTRUCTIONS.md ā Two embeddings options
- API_INTEGRATION_GUIDE.md ā Embeddings API sections
- MACHINES_INFRASTRUCTURE.md ā 384-dim vs 1024-dim choice
- skills/ ā (Coming soon: Embeddings template)
š Documentation Stats
Total Files: 8 (core) + skills Total Lines: ~8,000+ Code Examples: 50+ API Endpoints Documented: 40+ Service Endpoints: 20+ Languages Covered: TypeScript, JavaScript, Python, Bash
š Quick Search Guide
Looking for...
IP Addresses:
- Mac Mini:
NETWORK_TOPOLOGY.md(10.0.0.188) - Ubuntu:
NETWORK_TOPOLOGY.md(10.0.0.11)
Port Numbers:
- All services:
NETWORK_TOPOLOGY.mdā Port Reference
API Endpoints:
- Complete list:
API_INTEGRATION_GUIDE.mdā Table of Contents
Code Examples:
- TypeScript:
skills/mlx-chat-skill.md,API_INTEGRATION_GUIDE.md - Python:
skills/mlx-chat-skill.md,API_INTEGRATION_GUIDE.md - Bash:
API_INTEGRATION_GUIDE.md
Hardware Specs:
- Mac Mini:
MACHINES_INFRASTRUCTURE.md(48GB RAM, M4) - Ubuntu:
MACHINES_INFRASTRUCTURE.md(RTX 3060 12GB)
Performance Benchmarks:
- All services:
MACHINES_INFRASTRUCTURE.mdā Performance Benchmarks
Error Codes:
- HTTP errors:
API_INTEGRATION_GUIDE.mdā Error Handling
š Reading Order by Skill Level
Complete Beginner
README.md(15 min)AI_ASSISTANT_INSTRUCTIONS.md(30 min)API_INTEGRATION_GUIDE.mdā Integration Examples (20 min)skills/mlx-chat-skill.md(30 min)
Time: ~2 hours Outcome: Can build a basic chatbot
Intermediate Developer
README.md(10 min)NETWORK_TOPOLOGY.md(30 min)MACHINES_INFRASTRUCTURE.md(45 min)API_INTEGRATION_GUIDE.mdā Full read (2 hours)skills/ā All skills (1 hour)
Time: ~4-5 hours Outcome: Can build production applications
Advanced Developer / AI Assistant
- All files (4-6 hours)
- Deep dive into specific services
- Experiment with all APIs
- Build custom integrations
Time: 1-2 days Outcome: Master all infrastructure capabilities
š Document Version History
| Date | Version | Changes |
|---|---|---|
| 2025-01-01 | 1.0 | Initial release - Complete documentation |
š Cross-References
Network ā Hardware
NETWORK_TOPOLOGY.md(Server Details) āMACHINES_INFRASTRUCTURE.md(Hardware Specifications)
API ā Skills
API_INTEGRATION_GUIDE.md(MLX Chat API) āskills/mlx-chat-skill.md- More coming soon...
Instructions ā Implementation
AI_ASSISTANT_INSTRUCTIONS.md(Service Priority) āAPI_INTEGRATION_GUIDE.md(Endpoints)AI_ASSISTANT_INSTRUCTIONS.md(Decision Tree) āskills/(Code templates)
š Next Steps
For New Users
- Read
README.md - Try a simple example from
skills/mlx-chat-skill.md - Explore
API_INTEGRATION_GUIDE.mdfor more capabilities
For AI Assistants
- Read
AI_ASSISTANT_INSTRUCTIONS.mdthoroughly - Bookmark
API_INTEGRATION_GUIDE.mdfor reference - Use
skills/templates when implementing
For Contributors
If you find errors or have suggestions:
- Update the relevant documentation file
- Update the "Last Updated" date
- Increment version if major changes
š Support & Contact
Documentation Location:
/Users/yaro/Documents/a2zadd/master-instruction/
View Online:
cd /Users/yaro/Documents/a2zadd/master-instruction
ls -la
cat <filename>
Questions:
- Ask Yaro about infrastructure
- Refer to latest docs in this folder
- Check service health before debugging
⨠Special Features
Interactive Documentation
- ā Code examples in multiple languages
- ā Copy-paste ready templates
- ā Health check commands
- ā Troubleshooting guides
- ā Best practices sections
Comprehensive Coverage
- ā All services documented
- ā All endpoints with examples
- ā Network diagrams with ASCII art
- ā Performance data from real tests
- ā Error handling patterns
This index provides a bird's-eye view of all ProYaro documentation. Use it to navigate quickly to what you need!
Index Version: 1.0 Last Updated: 2025-01-01 Total Documentation: ~8,000+ lines across 8+ files
š Skills Added (Updated 2025-01-01)
Core AI Services
| Skill File | Service | Lines | Languages | Status |
|---|---|---|---|---|
mlx-chat-skill.md | MLX Text Gen | 400+ | TS/Python | ā Complete |
comfyui-image-skill.md | Image Generation | 500+ | TS/Python | ā Complete |
whisper-stt-skill.md | Speech-to-Text | 450+ | TS/Python | ā Complete |
tts-skill.md | Text-to-Speech | 100+ | TS | ā Complete |
embeddings-skill.md | Semantic Search | 150+ | TS | ā Complete |
job-management-skill.md | Job Queue API | 550+ | TS/Python | ā Complete |
Infrastructure & DevOps
| Skill File | Technology | Lines | Languages | Status |
|---|---|---|---|---|
caddy-reverse-proxy-skill.md | HTTPS/Proxy | 150+ | Caddyfile/Bash | ā Complete |
docker-compose-skill.md | Containers | 130+ | YAML/Bash | ā Complete |
fastapi-production-skill.md | Python API | 270+ | Python | ā Complete |
redis-queue-skill.md | Job Queue | 280+ | Python | ā Complete |
Domain-Specific
| Skill File | Specialty | Lines | Languages | Status |
|---|---|---|---|---|
nextjs-pwa-skill.md | React/PWA | 300+ | TS/React | ā Complete |
arabic-nlp-skill.md | Arabic NLP | 270+ | Python | ā Complete |
Total Skills: 12 Total Lines: 4,797 Total Code Examples: 100+
š Recently Added Features
What's New in Version 1.1
- ā ComfyUI Image Generation - Full Z-Image Turbo integration
- ā Whisper STT - Complete voice transcription with React hooks
- ā XTTS-v2 TTS - Arabic voice synthesis
- ā Embeddings & Search - Both MLX and E5-Large implementations
- ā Caddy Integration - Reverse proxy and HTTPS setup
- ā Copied Ubuntu Skills - FastAPI, Next.js, Docker, Redis, Arabic NLP
- ā
All use
docker composenotdocker-compose(modern syntax)
Skills from Ubuntu Server
The following skills were imported from /mnt/storage/new-stack/skills/ and adapted:
fastapi-production-skill.md- Production FastAPI patternsnextjs-pwa-skill.md- Next.js 15 App Router + PWAdocker-compose-skill.md- Docker orchestrationredis-queue-skill.md- Background job processingarabic-nlp-skill.md- Arabic text processing
šÆ Quick Skill Selector
I want to...
Build AI Features
- Text generation (chatbot) ā
mlx-chat-skill.md - Generate images ā
comfyui-image-skill.md - Voice transcription ā
whisper-stt-skill.md - Voice synthesis ā
tts-skill.md - Semantic search ā
embeddings-skill.md
Build Infrastructure
- API backend ā
fastapi-production-skill.md - Frontend app ā
nextjs-pwa-skill.md - Job queue ā
redis-queue-skill.md+job-management-skill.md - HTTPS proxy ā
caddy-reverse-proxy-skill.md - Container orchestration ā
docker-compose-skill.md
Work with Arabic
- Arabic NLP ā
arabic-nlp-skill.md - Arabic voice ā
whisper-stt-skill.md+tts-skill.md - Arabic text generation ā
mlx-chat-skill.md
š¤ Agents (Role-Based Definitions)
NEW! Specialized agent personas adapted from quiz-night-in project for ProYaro infrastructure.
What are Agents?
Unlike skills (copy-paste code templates), agents are role-based personas that define:
- Specific responsibilities and boundaries
- Decision-making frameworks
- Integration patterns
- Best practices for a domain
Available Agents
| Agent File | Role | Responsibilities | Use When |
|---|---|---|---|
ai-integration-agent.md | AI Services Engineer | Integrate MLX, ComfyUI, Whisper, XTTS | Building AI-powered features |
frontend-developer-agent.md | Frontend Developer | React, shadcn/ui, Next.js, Tailwind | Building user interfaces |
database-architect-agent.md | Database Architect | Drizzle ORM, PostgreSQL schemas | Designing database structure |
auth-expert-agent.md | Auth Specialist | BetterAuth, user management, security | Implementing authentication |
realtime-integration-agent.md | Real-Time Engineer | WebSocket, job queue, async tasks | Building real-time features |
Agents vs Skills
| Feature | Agents | Skills |
|---|---|---|
| Purpose | Define role and boundaries | Provide code templates |
| Content | Principles, patterns, examples | Copy-paste ready code |
| Length | ~500-800 lines | ~100-500 lines |
| Usage | Reference for decision-making | Direct implementation |
Example: Building a Chatbot App
Using Skills:
- Copy code from
mlx-chat-skill.md - Paste into your project
- Modify as needed
Using Agents:
- ai-integration-agent ā Guides MLX API integration, conversation management
- frontend-developer-agent ā Guides React component structure, state management
- database-architect-agent ā Guides conversation/message schema design
- auth-expert-agent ā Guides user authentication and authorization
When to Use Agents
- Planning Phase: Read relevant agents to understand best practices
- Decision Points: Consult agents when choosing between approaches
- Code Review: Verify your implementation matches agent guidelines
- Team Collaboration: Share agents to align on architectural patterns
Total Agents: 5 Total Lines: ~3,000 Adapted From: quiz-night-in project (specialized for ProYaro stack)
Index Updated: 2025-01-01 (v1.2) Total Documentation: 13,000+ lines Total Files: Core docs (4) + Skills (12) + Agents (5) = 21 files
ProYaro AI Infrastructure Documentation ⢠Version 1.2