Skip to main content

Prerequisites

  • Make sure your assets exist in CDF.
  • Check for SHX text embedded in the diagram file. If present, set configuration.annotationExtract = True to override overlapping OCR text. For more information, see API documentation.
  • Ensure the asset names (or any other fields in use) match the tags in the file. If they don’t match, do the following:
    • Create an alias for the asset name to better match the tags in the file.
    • Set partialMatch and minTokens.

Tags are recognized incorrectly

  • I is recognized as T. For example, PI/TI is recognized as PT/TT PI/TI tags often don’t exist in the asset hierarchy; if they do, PT/TT tags may be their closest relatives. By default, we correct I to T if misread. Use configuration substitutions to turn this off.
  • Wildcard tags are being linked to multiple tags Add aliases to tags during diagram detection. For example, if 11-V-6x66 should link to both 11-V-6166 and 11-V-6666, add 11-V-6x66 as an alias. The entities field looks like this:
  • Only a subset of the tag is recognized Follow the steps in Tags are not recognized section to resolve this issue.
  • Large bounding box with widely spaced characters causes incorrect detection Set connectionFlags= ["natural_reading_order", "no_text_inbetween"]. See API documentation for more information.
  • Short false positives Set configuration.customizeFuzziness.minChars. See API documentation for more information.

Tags are not recognized

Use the OCR endpoint to see the raw OCR detection results. For more information, see the existing OCR API endpoint. Currently, the SDK is not available. Use the Python code below in the Cognite Jupyter Notebook.
When the tags are not recognized, the characters in the text are misread, or there are unexpected leading or trailing characters, allow character substitutions in the Detect annotations in engineering diagrams endpoint > Request > configuration. For example, if there are unexpected leading or trailing characters, replace the leading or trailing characters with an empty string “”.
Last modified on April 23, 2026