[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-07 UTC."],[],[],null,["# Class AnnotatedString (0.10.17)\n\nVersion latestkeyboard_arrow_down\n\n- [0.10.17 (latest)](/python/docs/reference/dataqna/latest/google.cloud.dataqna_v1alpha.types.AnnotatedString)\n- [0.10.16](/python/docs/reference/dataqna/0.10.16/google.cloud.dataqna_v1alpha.types.AnnotatedString)\n- [0.9.0](/python/docs/reference/dataqna/0.9.0/google.cloud.dataqna_v1alpha.types.AnnotatedString)\n- [0.8.2](/python/docs/reference/dataqna/0.8.2/google.cloud.dataqna_v1alpha.types.AnnotatedString)\n- [0.7.1](/python/docs/reference/dataqna/0.7.1/google.cloud.dataqna_v1alpha.types.AnnotatedString)\n- [0.6.3](/python/docs/reference/dataqna/0.6.3/google.cloud.dataqna_v1alpha.types.AnnotatedString)\n- [0.5.1](/python/docs/reference/dataqna/0.5.1/google.cloud.dataqna_v1alpha.types.AnnotatedString)\n- [0.4.0](/python/docs/reference/dataqna/0.4.0/google.cloud.dataqna_v1alpha.types.AnnotatedString)\n- [0.3.3](/python/docs/reference/dataqna/0.3.3/google.cloud.dataqna_v1alpha.types.AnnotatedString)\n- [0.2.1](/python/docs/reference/dataqna/0.2.1/google.cloud.dataqna_v1alpha.types.AnnotatedString)\n- [0.1.1](/python/docs/reference/dataqna/0.1.1/google.cloud.dataqna_v1alpha.types.AnnotatedString) \n\n AnnotatedString(mapping=None, *, ignore_unknown_fields=False, **kwargs)\n\nDescribes string annotation from both semantic and formatting\nperspectives. Example:\n\nUser Query:\n\ntop countries by population in Africa\n\n0 4 14 17 28 31 37\n\nTable Data:\n\n- \"country\" - dimension\n- \"population\" - metric\n- \"Africa\" - value in the \"continent\" column\n\ntext_formatted = `\"top countries by population in Africa\"`\n\nhtml_formatted =\n`\"top \u003cb\u003ecountries\u003c/b\u003e by \u003cb\u003epopulation\u003c/b\u003e in \u003ci\u003eAfrica\u003c/i\u003e\"`\n\n::\n\nmarkups = \\[\n{DIMENSION, 4, 12}, // 'countries'\n{METRIC, 17, 26}, // 'population'\n{FILTER, 31, 36} // 'Africa'\n\\]\n\nNote that html formattings for 'DIMENSION' and 'METRIC' are the\nsame, while semantic markups are different.\n\nClasses\n-------\n\n### SemanticMarkup\n\n SemanticMarkup(mapping=None, *, ignore_unknown_fields=False, **kwargs)\n\nSemantic markup denotes a substring (by index and length)\nwith markup information.\n\n### SemanticMarkupType\n\n SemanticMarkupType(value)\n\nSemantic markup types."]]