kambo-1st / langchain-php Goto Github PK
View Code? Open in Web Editor NEW⚡ Building applications with LLMs through composability in PHP ⚡
License: MIT License
⚡ Building applications with LLMs through composability in PHP ⚡
License: MIT License
Hellow @kambo-1st, I wanted to inquire on the possibility of contributing some new functionalities to the package.
Recently, I've released a PHP package that integrates ChromaDB within PHP applications. I'm keen on extending this support to the package and additionally adding compatibility for other vector stores like Pinecone, Milvus, among others, to broaden the options available for users.
Before diving into the implementation, I wanted to inquire about the current activity and maintenance status of repo. Are new contributions welcomed? Is any active development still going on?
N/A
N/A
8.2
No response
No response
use in laravel 9
<?php
namespace App\Http\Controllers;
use App\Http\Controllers\Controller;
use Illuminate\Http\Request;
use Kambo\Langchain\LLMs\OpenAI;
use Kambo\Langchain\LLMs\OpenAIChat;
class TestController extends Controller
{
public function webhook(Request $request)
{
$llm = new OpenAIChat([
'temperature' => 0.9,
'openai_api_key' => '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',
]);
$text = "hello";
echo $llm($text);
//return response()->json($result, 200)->setEncodingOptions(JSON_UNESCAPED_UNICODE);
}
}
not work
notice: You exceeded your current quota, please check your plan and billing details. this is a free account
"kambo/langchain": "0.2.0-alpha",
8.2.6
macOS, Linux
No response
cant install and run with php 7.4.2
try to install and run with php 7.4.2
1
7.4.2
Windows
that is i just want to know if the package could be made to run in older php versions
When trying to use this port of Langchain for PHP I find that the main file Langchain.php is not located in the root of the namespace /src.
Only one version is present in /src/Exceptions, which causes errors when trying to load the class.
Please consider moving the file to the expected location in /src/Langchain.php so that the library can be used properly.
Also validate that the version in Exceptions is complete and correct for general use.
Thank you for your work on this unofficial port. It would be very useful to have a stable and well-implemented version of Langchain for PHP.
Best regards
Clone the Langchain repository for PHP:
git clone https://github.com/kambo-1st/langchain-php
Install dependencies with Composer:
composer install
Create an index.php file with the following code:
Do we need SQLite in order to use the vector store?
Do we need SQLite in order to use the vector store?
master
8.1
macOS
No response
All of these links are failing:
Ask a question
Request a feature
Report a security issue
Click on the links above
n/a
n/a
macOS
I want to discuss creating a vectorstore with this -> https://github.com/pgvector/pgvector-php.
It's a postgresql extension which allows you to query vectors which makes it a pretty good candidate for many php users.
Final classes make it harder for developers to extend package functionality in their own projects. What's the benefit that you see?
No response
No response
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.