Download the PHP package subhashladumor1/larachain without Composer
On this page you can find all versions of the php package subhashladumor1/larachain. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download subhashladumor1/larachain
More information about subhashladumor1/larachain
Files in subhashladumor1/larachain
Package larachain
Short Description LaraChain - LangChain-inspired AI orchestration framework for PHP and Laravel
License MIT
Informations about the package larachain
🏗️ LaraChain (Beta Version)
LaraChain is a LangChain-inspired AI orchestration framework built specifically for Laravel 12. In 2026, building AI apps is no longer just about calling an API—it's about building Stateful Workflows, Agentic Tools, and Modern RAG pipelines. LaraChain provides the primitives to build these with professional-grade elegance and type safety.
🗺️ How LaraChain Works
LaraChain follows a "Runnable" architecture where every component—prompts, models, retrievers, and parsers—can be piped together.
🚀 Key Features
| Feature | Description |
|---|---|
| LCEL-style Piping | Use the .pipe() pattern to chain components like a pro. |
| Smart Agents | ReAct (Reasoning + Acting) agents that use tools and make decisions. |
| Advanced RAG | Document loaders, recursive text splitting, and vector retrieval. |
| Postgres Support | Native pgvector integration for production-ready storage. |
| Memory Drivers | Stateful conversation buffers to maintain context. |
| Laravel 12 Native | Deeply integrated with the Laravel AI SDK and Service Container. |
📂 Folder Structure
📖 Functional API Guide
1. The Pipe Pattern (Recommended)
The hallmark of LaraChain 2026 is the ability to chain components elegantly.
2. Intelligent Agents
An agent can use specialized tools to complete complex tasks.
3. RAG (Postgres + Recursive Chunking)
Handle large documents with state-of-the-art chunking and production storage.
⚖️ LaraChain vs. LangChain (For Laravel)
| Feature | LangChain (Python/JS) | LaraChain (PHP/Laravel) |
|---|---|---|
| Syntax | Pipe Operator (\|) |
Fluent .pipe() Method |
| Integration | Ad-hoc | Native Service Providers / Facades |
| I/O | General | Laravel FileSystem / DB Facades |
| Agents | LangGraph | ReAct / Future LaraGraph |
| Models | Custom Drivers | Laravel AI SDK (Native) |
📈 Use Cases
- Semantic Document Search: Build a "Chat with your PDF" app in minutes using
RecursiveSplitterandPostgresVectorStore. - Autonomous Code Auditor: Use the
FileToolkitandAgentExecutorto scan your repository for security flaws. - Structured Data Extraction: Pipe raw OCR text through a
ChatModelandJsonParserto ingest invoices into your database.
🛠️ Installation & Setup
Refer to LARACHAIN_VERIFICATION_2026.md for detailed verification of all 2026 market features.
🛠️ Multi-Provider Management
LaraChain uses a Driver-based Architecture (similar to Laravel's Database or Mail systems). You can configure and switch between providers at runtime.
1. Configuration (config/larachain.php)
Define multiple LLM, Vector, and Embedding providers:
2. Switching Providers at Runtime
Use the LaraChain facade to swap drivers dynamically:
⚙️ Configuration
Contributions are welcome! Pull requests for new Vector Drivers (Pinecone, Qdrant) are prioritized.
📄 License
The MIT License (MIT). See License File.
All versions of larachain with dependencies
illuminate/support Version ^11.20|^12.0
illuminate/contracts Version ^11.20|^12.0
laravel/ai Version ^0.1.0