PHP code example of north-foundry / voyager-page-map-php
1. Go to this page and download the library: Download north-foundry/voyager-page-map-php library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
north-foundry / voyager-page-map-php example snippets
$pageContext = $pageMap->toText();
$prompt = <<<PROMPT
You are given a semantic map of a web page.
Identify the email field.
Return only its @e reference.
$pageContext
PROMPT;
// Pass $prompt to the LLM client or prompt pipeline of your choice.