# elizaOS Development Discord - 2025-04-16

## Overall Discussion Highlights

### ElizaOS v1 to v2 Migration
- Users are actively migrating from v1 to v2, with several reporting challenges during the transition
- The monorepo structure in v2 requires different approaches for plugin integration and development
- Several v1 plugins are yet to be migrated to v2, including the Discord plugin
- Clients are handled differently in v2 compared to v1, with some users seeking guidance on implementation

### Database and Infrastructure
- Discussion about database options with Postgres, Supabase, and Neon being considered
- Supabase emerged as a preferred solution for many developers
- Hidden Forces reported switching to Postgres and v2 for their project

### Agent Inference and API Configuration
- Detailed discussions about plugin order behavior affecting which models are registered and used first
- Issues with agent crashes when switching between local-AI and cloud providers like OpenAI and Anthropic
- System appears to default to Anthropic even when OpenAI keys are provided
- API key configuration in .env files was a common troubleshooting topic

### PDF Processing Challenges
- PDF handling is problematic in both older versions (0.25.x) and newer v2/projects mode
- Users experiencing errors like "Invalid array length" when using PDFs as knowledge sources
- Ruby suggested workarounds including manual PDF addition and custom processing pipelines
- Custom solution using GPT-4's PDF reading capabilities combined with embedding pipeline was proposed

## Key Questions & Answers

**Q: Do you use pglite or postgres? Which eliza version v1 or v2?**  
A: Hidden Forces indicated switching to Postgres and v2 for their project

**Q: How do I fix my agent crashing when typing to it in localhost?**  
A: 0xbbjoker explained it was due to local-ai plugin issues and recommended removing ~/.eliza directory and ensuring proper API keys in .env

**Q: How do I specify the OpenAI key or is it better to go with Anthropic?**  
A: DeFine suggested using Anthropic for now and adding the key to .env file

**Q: How do I import a local plugin in monorepo for use in defaultCharacter?**  
A: 0xbbjoker explained the process of adding plugins in monorepo, building, and linking

**Q: Where can I find the Discord V2 plugin?**  
A: Nisita explained V2 plugins are yet to be migrated but the v2-develop version works with beta

**Q: Any good tutorial on how to create a client?**  
A: standard explained clients aren't in v2 anymore and suggested checking Auto-client and direct-client in v1

**Q: Isn't PDF processing natively supported by Eliza knowledge?**  
A: Yes, Eliza should handle PDF parsing natively through the knowledge pipeline, but there are issues with the implementation.

**Q: Where is the knowledge directory in the new version?**  
A: In v2, check the config/projects folder for the default path, or specify a custom knowledge_path in agent config.

**Q: For production, is it better to use multiple projects for each character or just one?**  
A: Depends on use case - multiple projects provide better isolation and control, single project is simpler but requires careful namespacing.

**Q: Does the project version have an API to upload knowledge?**  
A: Not yet - knowledge upload via API is still in development. Files must be added manually to project directories for now.

## Community Help & Collaboration

### Agent Troubleshooting
- **0xbbjoker helped Cocaine** with agent crashes in local environment by explaining it was due to local-ai plugin issues, suggesting removal of ~/.eliza directory and proper API key configuration
- **0xbbjoker provided Cocaine** with detailed explanation of plugin order behavior and how it affects model selection
- **DeFine assisted Cocaine** with agent crashes by explaining the need to add Anthropic API key as the system defaults to Anthropic

### Plugin and Development Support
- **0xbbjoker guided standard** through importing local plugins in monorepo with step-by-step instructions for adding, building, and linking plugins
- **standard helped LemonS** understand client creation by explaining clients aren't in v2 and suggesting combining Auto-client and direct-client from v1

### PDF Processing Solutions
- **Ruby helped mindxploit** diagnose PDF parsing errors, identifying corrupted file structure as the likely cause
- **Ruby provided mindxploit** with code example using LangChain components to create a custom PDF processing pipeline compatible with 0.25.9
- **Ruby explained to mindxploit** the basics of creating separate knowledge directories for each agent in v2

## Action Items

### Technical
- Remove ~/.eliza directory when switching from local-ai to cloud providers (Mentioned by 0xbbjoker)
- Fix bug where system errors when Anthropic API key is missing even when OpenAI key is provided (Mentioned by DeFine)
- Add Livepeer as inference provider for Vtuber plugin (Mentioned by DeFine)
- Implement custom PDF processing using GPT-4's PDF reader and custom embedding pipeline (Mentioned by Ruby)
- Check PDF file structure integrity to resolve "Invalid array length" error (Mentioned by Ruby)
- Break large PDF documents into chunks for better processing (Mentioned by Ruby)

### Documentation
- Create clearer documentation on plugin order behavior and API key configuration (Mentioned by 0xbbjoker)
- Provide tutorial for creating custom clients in v1 (Mentioned by LemonS)
- Improve documentation on setting up multiple agents with their own knowledge bases in v2 (Mentioned by mindxploit)

### Feature
- Add joystram integration to Eliza (Mentioned by Yemmii)
- Migrate v1 plugins to v2 architecture (Mentioned by Nisita)
- Implement endless conversations between two AI agents (Mentioned by desu)
- Add PDF upload support in v2 and projects mode (Mentioned by mindxploit)
- Develop API endpoints for knowledge management including file uploads (Mentioned by Ruby)