Initial commit
This commit is contained in:
@@ -0,0 +1,19 @@
|
||||
<?php
|
||||
require 'vendor/autoload.php';
|
||||
$app = require_once 'bootstrap/app.php';
|
||||
$app->make('Illuminate\Contracts\Console\Kernel')->bootstrap();
|
||||
|
||||
$ingestionService = app(App\Services\DocumentIngestionService::class);
|
||||
$filePath = storage_path('app/private/temp/tiny_test.pdf');
|
||||
$originalName = 'tiny_test.pdf';
|
||||
|
||||
// Let's get the chatbot ID from the slug
|
||||
$chatbot = App\Models\Chatbot::where('slug', 'dtegdcabm')->first();
|
||||
if (!$chatbot) {
|
||||
echo "Chatbot not found!\n";
|
||||
exit(1);
|
||||
}
|
||||
|
||||
echo "Ingesting tiny_test.pdf for chatbot ID: " . $chatbot->id . "\n";
|
||||
$success = $ingestionService->ingestPdf($filePath, $originalName, (string) $chatbot->id, false);
|
||||
var_dump($success);
|
||||
Reference in New Issue
Block a user