Skip to content

Commit

Permalink
📄 Add example
Browse files Browse the repository at this point in the history
  • Loading branch information
asim-shrestha committed Oct 17, 2024
1 parent 67fa3dc commit bef253e
Show file tree
Hide file tree
Showing 2 changed files with 71 additions and 1 deletion.
44 changes: 43 additions & 1 deletion static/examples.json
Original file line number Diff line number Diff line change
Expand Up @@ -37164,7 +37164,8 @@
"description": "Single field but the required value is a text node within the element.",
"tags": [
"synthetic",
"text-nodes"
"text-nodes",
"regression"
],
"evals": [
{
Expand All @@ -37174,5 +37175,46 @@
}
}
]
},
{
"id": "mN7cQ2wP9xLfRzTh5DjBv",
"url": "https://www.test.com",
"source": "html",
"category": "synthetic",
"subcategory": "synthetic",
"type": "listing_detail",
"goal": "Extract all the contact information on the page",
"schema_": {
"name": {
"type": "string"
},
"address": {
"type": "string"
},
"phone": {
"type": "string"
},
"fax": {
"type": "string"
}
},
"description": "Long address field with un-necessary ('Get Directions') text at the end of it",
"tags": [
"synthetic",
"text-nodes"
],
"evals": [
{
"type": "json_match",
"expected": [
{
"name": "Sunshine Valley Medical Center",
"address": "Sunshine Valley Hospital\n5678 Healing Lane\n3rd Floor\nMeadowbrook, CA 90210",
"phone": "555.123.4567",
"fax": "555.987.6543"
}
]
}
]
}
]
28 changes: 28 additions & 0 deletions static/mN7cQ2wP9xLfRzTh5DjBv/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Some center</title>
</head>
<body>
<header>
<h1>Sunshine Valley Medical Center</h1>
</header>
<main>
<section id="location-info">
<h2>Location Information</h2>
<address>
Sunshine Valley Hospital<br>
5678 Healing Lane<br>3rd Floor
<br>Meadowbrook, CA 90210
<br><a href="http://maps.google.com/maps?q=Sunshine%20Valley%20Medical%20Center,5678%20Healing%20Lane,Meadowbrook,CA,90210" target="_blank">Get Directions</a>
</address>
<div>
<p>Phone: <a href="tel:555.123.4567">555.123.4567</a></p>
<p>Fax: 555.987.6543</p>
</div>
</section>
</main>
</body>
</html>

0 comments on commit bef253e

Please sign in to comment.