laravel google bard
v1.1.1
แพ็คเกจ Laravel สำหรับ Google Bard AI Chatbot
composer require adityadees/laravel-google-bard
php artisan vendor:publish --tag=laravel-bard
laravel-bard.php
จะถูกสร้างขึ้นภายใต้โฟลเดอร์ config
bard_token
ด้วยโทเค็นของคุณ ไปที่ https://bard.google.com/ ไปที่เครื่องมือสำหรับนักพัฒนาซอฟต์แวร์หรือกด F12 Application → Cookies → คัดลอกค่าของคุกกี้ __Secure-1PSID
$ bard = ( new LaravelBard ())-> get_answer ( ' type_your_text_here ' );
# to get the reply just access this array
$ bard [ " content " ];
# you can access others array like this
$ bard [ " conversation_id " ];
$ bard [ " response_id " ];
$ bard [ " factualityQueries " ];
$ bard [ " textQuery " ];
$ bard [ " choices " ];
$ bard = ( new LaravelBard ())-> get_answer ( ' hello whats your name ' );
dd ( $ bard [ " content " ]);
รู้สึกอิสระที่จะช่วยปรับปรุงแพ็คเกจนี้
หมายเหตุ: แพ็คเกจประกอบด้วยทรัพยากรจากพื้นที่เก็บข้อมูล https://github.com/dsdanielpark/Bard-API