Skip to content
HALOWERK

Denkwerk

page cited summary

Extracts the text layer of every PDF page with pdfjs-dist (or takes pages as text, or text split by form feeds), removes lines repeated on most pages (headers, footers), joins hyphenated line breaks and splits sentences with Intl.Segmenter plus abbreviation rules. Sentences of 5 to 80 words are ranked with LexRank (Erkan and Radev 2004: TF-IDF cosine graph, damping 0.85); an optional query boosts sentences containing its terms, and near-duplicates (cosine above 0.6) of already chosen.

POST https://denk.halowerk.com/v1/page-cited-summary

Inputs

Fields of the published input schema
FieldTypeRequiredDescription
pdf_base64stringNoPDF file as base64 (max. 15 MB).
pagesarrayNo
textstringNoText with pages separated by form feed (\f), as produced by pdftotext.
sentencesintegerNo
querystringNoOptional focus terms.
languagestringNo
Show full input schema
{
  "type": "object",
  "additionalProperties": false,
  "properties": {
    "pdf_base64": {
      "type": "string",
      "maxLength": 20000000,
      "description": "PDF file as base64 (max. 15 MB)."
    },
    "pages": {
      "type": "array",
      "minItems": 1,
      "maxItems": 2000,
      "items": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "text"
        ],
        "properties": {
          "page": {
            "type": [
              "string",
              "integer"
            ],
            "description": "Page label; default position."
          },
          "text": {
            "type": "string",
            "maxLength": 200000
          }
        }
      }
    },
    "text": {
      "type": "string",
      "maxLength": 5000000,
      "description": "Text with pages separated by form feed (\\f), as produced by pdftotext."
    },
    "sentences": {
      "type": "integer",
      "minimum": 1,
      "maximum": 50,
      "default": 6
    },
    "query": {
      "type": "string",
      "maxLength": 300,
      "description": "Optional focus terms."
    },
    "language": {
      "type": "string",
      "enum": [
        "en",
        "de"
      ],
      "default": "en"
    }
  }
}

Open original schema

Published input example

{
  "pages": [
    {
      "page": 1,
      "text": "The pilot started in March. The battery reduced peak load by 23 percent."
    },
    {
      "page": 2,
      "text": "Costs fell accordingly."
    }
  ],
  "sentences": 2
}

Result & documentation

Machine-readable documentation of this hub

Source of this page: the published HALOWERK catalog. Updated: 2026-11-17 UTC.

More endpoints in this hub

All endpoints in this hub โ†’