1from apify_client import ApifyClient
2
3
4
5client = ApifyClient("<YOUR_API_TOKEN>")
6
7
8run_input = {
9 "source": {
10 "mode": "url_list",
11 "urls": ["https://example.com/"],
12 "maxPages": 1000,
13 },
14 "ownership_attestation": True,
15 "chunking": {
16 "strategy": "semantic",
17 "maxTokens": 512,
18 "overlapTokens": 64,
19 },
20 "extractSchema": { "fields": [{
21 "name": "product_name",
22 "type": "string",
23 "instruction": "The product name stated on the page; null if absent.",
24 }] },
25 "aeo": { "assets": [
26 "faq_pair",
27 "answer_block",
28 "llms_txt",
29 ] },
30}
31
32
33run = client.actor("awesome_highboy/aeo-rag-ready-content-structurer").call(run_input=run_input)
34
35
36print("💾 Check your data here: https://console.apify.com/storage/datasets/" + run["defaultDatasetId"])
37for item in client.dataset(run["defaultDatasetId"]).iterate_items():
38 print(item)
39
40