{ "nbformat": 4, "nbformat_minor": 0, "metadata": { "colab": { "provenance": [], "machine_shape": "hm", "toc_visible": true }, "kernelspec": { "name": "python3", "display_name": "Python 3" }, "language_info": { "name": "python" }, "accelerator": "GPU", "gpuClass": "standard", "widgets": { "application/vnd.jupyter.widget-state+json": { "191b6a790b004003b41bd7a88fc1f94a": { "model_module": "@jupyter-widgets/controls", "model_name": "VBoxModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "VBoxModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "VBoxView", "box_style": "", "children": [], "layout": "IPY_MODEL_6fbc8e4b384343aca4c252722f2be8ce" } }, "a1a0fd41726c433c969736c3f8425671": { "model_module": "@jupyter-widgets/controls", "model_name": "HTMLModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "HTMLModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "HTMLView", "description": "", "description_tooltip": null, "layout": "IPY_MODEL_427b286055494cb1b7306cd5e7d59172", "placeholder": "​", "style": "IPY_MODEL_e176dac9c50d444580f39a95cd37f3fc", "value": "

Copy a token from your Hugging Face\ntokens page and paste it below.
Immediately click login after copying\nyour token or it might be stored in plain text in this notebook file.
" } }, "6932beb012434ec894a532af62fbd0ad": { "model_module": "@jupyter-widgets/controls", "model_name": "PasswordModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "PasswordModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "PasswordView", "continuous_update": true, "description": "Token:", "description_tooltip": null, "disabled": false, "layout": "IPY_MODEL_a55a9420f90e4aaa9ca8065c11016d3b", "placeholder": "​", "style": "IPY_MODEL_2d62d2364f0a4df2bb31dc5eb8d86d28", "value": "" } }, "41d64a9993e84221b8357bef021d25e3": { "model_module": "@jupyter-widgets/controls", "model_name": "CheckboxModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "CheckboxModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "CheckboxView", "description": "Add token as git credential?", "description_tooltip": null, "disabled": false, "indent": true, "layout": "IPY_MODEL_09c497fa25224a13bdb1f4dda36b4a84", "style": "IPY_MODEL_615fc3e533b8409a82f5d3d35a7b20bf", "value": true } }, "293b2363ffe844cb97480a4c18b76159": { "model_module": "@jupyter-widgets/controls", "model_name": "ButtonModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "ButtonModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "ButtonView", "button_style": "", "description": "Login", "disabled": false, "icon": "", "layout": "IPY_MODEL_d14c0a3b8b014349b427dcd5fe268c35", "style": "IPY_MODEL_7395cbf74e2f4102bb9bf3a1057b273d", "tooltip": "" } }, "e344c93aab9745faa58f1f6cf98f9c20": { "model_module": "@jupyter-widgets/controls", "model_name": "HTMLModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "HTMLModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "HTMLView", "description": "", "description_tooltip": null, "layout": "IPY_MODEL_073e843a02c9471490d7cc8b50e22df4", "placeholder": "​", "style": "IPY_MODEL_564b1bbf8f5a4f7895bb8a46a8c7c5e2", "value": "\nPro Tip: If you don't already have one, you can create a dedicated\n'notebooks' token with 'write' access, that you can then easily reuse for all\nnotebooks. " } }, "6fbc8e4b384343aca4c252722f2be8ce": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": "center", "align_self": null, "border": null, "bottom": null, "display": "flex", "flex": null, "flex_flow": "column", "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": "50%" } }, "427b286055494cb1b7306cd5e7d59172": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "e176dac9c50d444580f39a95cd37f3fc": { "model_module": "@jupyter-widgets/controls", "model_name": "DescriptionStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "DescriptionStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "description_width": "" } }, "a55a9420f90e4aaa9ca8065c11016d3b": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "2d62d2364f0a4df2bb31dc5eb8d86d28": { "model_module": "@jupyter-widgets/controls", "model_name": "DescriptionStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "DescriptionStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "description_width": "" } }, "09c497fa25224a13bdb1f4dda36b4a84": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "615fc3e533b8409a82f5d3d35a7b20bf": { "model_module": "@jupyter-widgets/controls", "model_name": "DescriptionStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "DescriptionStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "description_width": "" } }, "d14c0a3b8b014349b427dcd5fe268c35": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "7395cbf74e2f4102bb9bf3a1057b273d": { "model_module": "@jupyter-widgets/controls", "model_name": "ButtonStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "ButtonStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "button_color": null, "font_weight": "" } }, "073e843a02c9471490d7cc8b50e22df4": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "564b1bbf8f5a4f7895bb8a46a8c7c5e2": { "model_module": "@jupyter-widgets/controls", "model_name": "DescriptionStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "DescriptionStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "description_width": "" } }, "6d8abf09e6ee44639c7e0069029dccd0": { "model_module": "@jupyter-widgets/controls", "model_name": "LabelModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "LabelModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "LabelView", "description": "", "description_tooltip": null, "layout": "IPY_MODEL_f50161df513247dfa99f610534a373cb", "placeholder": "​", "style": "IPY_MODEL_9422c5fd9ad24ab59516dff2d7df3251", "value": "Connecting..." } }, "f50161df513247dfa99f610534a373cb": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "9422c5fd9ad24ab59516dff2d7df3251": { "model_module": "@jupyter-widgets/controls", "model_name": "DescriptionStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "DescriptionStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "description_width": "" } }, "a1ce75ee9c4a4edd8750bc6e070b895b": { "model_module": "@jupyter-widgets/controls", "model_name": "HBoxModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "HBoxModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "HBoxView", "box_style": "", "children": [ "IPY_MODEL_c0e1255ddc9e40c39b7a0aec505693f2", "IPY_MODEL_a9779bd208034a698e6046baf7a0ffb8", "IPY_MODEL_4bf71936fd4c4fd1a80accc3c6a2a107" ], "layout": "IPY_MODEL_982c945d1d7d46989831eefeac81c886" } }, "c0e1255ddc9e40c39b7a0aec505693f2": { "model_module": "@jupyter-widgets/controls", "model_name": "HTMLModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "HTMLModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "HTMLView", "description": "", "description_tooltip": null, "layout": "IPY_MODEL_9278efefd12249b4981a5df853ebbe11", "placeholder": "​", "style": "IPY_MODEL_74525c8ac3f340b7953a239a0f893d4e", "value": "Download complete: 100%" } }, "a9779bd208034a698e6046baf7a0ffb8": { "model_module": "@jupyter-widgets/controls", "model_name": "FloatProgressModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "FloatProgressModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "ProgressView", "bar_style": "success", "description": "", "description_tooltip": null, "layout": "IPY_MODEL_b5ef3c635e474a01a524fe85f4a1472e", "max": 1, "min": 0, "orientation": "horizontal", "style": "IPY_MODEL_9f0b4a147c394a41ab0f042999b7c664", "value": 1 } }, "4bf71936fd4c4fd1a80accc3c6a2a107": { "model_module": "@jupyter-widgets/controls", "model_name": "HTMLModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "HTMLModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "HTMLView", "description": "", "description_tooltip": null, "layout": "IPY_MODEL_97308c73bd1048b9950a3e446aaa6bcc", "placeholder": "​", "style": "IPY_MODEL_442f8dd318ad40b3b73231f6ab3d6257", "value": " 4.95G/4.95G [01:12<00:00, 73.0MB/s]" } }, "982c945d1d7d46989831eefeac81c886": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "9278efefd12249b4981a5df853ebbe11": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "74525c8ac3f340b7953a239a0f893d4e": { "model_module": "@jupyter-widgets/controls", "model_name": "DescriptionStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "DescriptionStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "description_width": "" } }, "b5ef3c635e474a01a524fe85f4a1472e": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": "20px" } }, "9f0b4a147c394a41ab0f042999b7c664": { "model_module": "@jupyter-widgets/controls", "model_name": "ProgressStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "ProgressStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "bar_color": null, "description_width": "" } }, "97308c73bd1048b9950a3e446aaa6bcc": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "442f8dd318ad40b3b73231f6ab3d6257": { "model_module": "@jupyter-widgets/controls", "model_name": "DescriptionStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "DescriptionStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "description_width": "" } }, "6db0ef95d5354bf1b96398f6125ae3c1": { "model_module": "@jupyter-widgets/controls", "model_name": "HBoxModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "HBoxModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "HBoxView", "box_style": "", "children": [ "IPY_MODEL_8ab580b6488f4be688373630f70da83d", "IPY_MODEL_207d4750693e4f5d9cfd3770bcd70e8d", "IPY_MODEL_3792f3b706524d959858b1efd799399f" ], "layout": "IPY_MODEL_e4823ca4e6174b8db32489dd421efef1" } }, "8ab580b6488f4be688373630f70da83d": { "model_module": "@jupyter-widgets/controls", "model_name": "HTMLModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "HTMLModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "HTMLView", "description": "", "description_tooltip": null, "layout": "IPY_MODEL_c3715572c44547c8931c0454635a5abd", "placeholder": "​", "style": "IPY_MODEL_3cc63f04e553418e97384fbe03456d90", "value": "Fetching 2 files: 100%" } }, "207d4750693e4f5d9cfd3770bcd70e8d": { "model_module": "@jupyter-widgets/controls", "model_name": "FloatProgressModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "FloatProgressModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "ProgressView", "bar_style": "success", "description": "", "description_tooltip": null, "layout": "IPY_MODEL_64a7b4edf3fd47ed86f12d432eba026e", "max": 2, "min": 0, "orientation": "horizontal", "style": "IPY_MODEL_120c79ba460542a7b094f97c02ae908f", "value": 2 } }, "3792f3b706524d959858b1efd799399f": { "model_module": "@jupyter-widgets/controls", "model_name": "HTMLModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "HTMLModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "HTMLView", "description": "", "description_tooltip": null, "layout": "IPY_MODEL_08cf191d73cd4037a44fe06b06e742dd", "placeholder": "​", "style": "IPY_MODEL_da7583a6e0f84a0f89416d8350d95610", "value": " 2/2 [01:12<00:00, 72.69s/it]" } }, "e4823ca4e6174b8db32489dd421efef1": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "c3715572c44547c8931c0454635a5abd": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "3cc63f04e553418e97384fbe03456d90": { "model_module": "@jupyter-widgets/controls", "model_name": "DescriptionStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "DescriptionStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "description_width": "" } }, "64a7b4edf3fd47ed86f12d432eba026e": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "120c79ba460542a7b094f97c02ae908f": { "model_module": "@jupyter-widgets/controls", "model_name": "ProgressStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "ProgressStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "bar_color": null, "description_width": "" } }, "08cf191d73cd4037a44fe06b06e742dd": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "da7583a6e0f84a0f89416d8350d95610": { "model_module": "@jupyter-widgets/controls", "model_name": "DescriptionStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "DescriptionStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "description_width": "" } }, "f7e17d293810445494b6f546dffebdd4": { "model_module": "@jupyter-widgets/controls", "model_name": "HBoxModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "HBoxModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "HBoxView", "box_style": "", "children": [ "IPY_MODEL_cc3e3de736304ad5b04f10a351fd60ee", "IPY_MODEL_b11fe733ad874276b8a31532529d834d", "IPY_MODEL_6bdd0acb6e284b208b43d25928c78b43" ], "layout": "IPY_MODEL_5e0d2276e72c4477b9f7b166c1c2df24" } }, "cc3e3de736304ad5b04f10a351fd60ee": { "model_module": "@jupyter-widgets/controls", "model_name": "HTMLModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "HTMLModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "HTMLView", "description": "", "description_tooltip": null, "layout": "IPY_MODEL_f0dc1af853974c7da054836d18613d41", "placeholder": "​", "style": "IPY_MODEL_05cf70469b1d4f0b981f3d36ff69102e", "value": "Loading weights: 100%" } }, "b11fe733ad874276b8a31532529d834d": { "model_module": "@jupyter-widgets/controls", "model_name": "FloatProgressModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "FloatProgressModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "ProgressView", "bar_style": "success", "description": "", "description_tooltip": null, "layout": "IPY_MODEL_69b6b87936bc4af5b1d0c96da88f9f64", "max": 164, "min": 0, "orientation": "horizontal", "style": "IPY_MODEL_a8989264bd884c39823961fb530d6dc8", "value": 164 } }, "6bdd0acb6e284b208b43d25928c78b43": { "model_module": "@jupyter-widgets/controls", "model_name": "HTMLModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "HTMLModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "HTMLView", "description": "", "description_tooltip": null, "layout": "IPY_MODEL_abe0a82ba419400594567c34226c7b12", "placeholder": "​", "style": "IPY_MODEL_03a3c56bb72348e2bc2bf6129aaa2dc9", "value": " 164/164 [00:14<00:00,  9.51it/s, Materializing param=model.norm.weight]" } }, "5e0d2276e72c4477b9f7b166c1c2df24": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "f0dc1af853974c7da054836d18613d41": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "05cf70469b1d4f0b981f3d36ff69102e": { "model_module": "@jupyter-widgets/controls", "model_name": "DescriptionStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "DescriptionStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "description_width": "" } }, "69b6b87936bc4af5b1d0c96da88f9f64": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "a8989264bd884c39823961fb530d6dc8": { "model_module": "@jupyter-widgets/controls", "model_name": "ProgressStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "ProgressStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "bar_color": null, "description_width": "" } }, "abe0a82ba419400594567c34226c7b12": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "03a3c56bb72348e2bc2bf6129aaa2dc9": { "model_module": "@jupyter-widgets/controls", "model_name": "DescriptionStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "DescriptionStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "description_width": "" } }, "c414443190e14f99a5697f2250e66f66": { "model_module": "@jupyter-widgets/controls", "model_name": "HBoxModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "HBoxModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "HBoxView", "box_style": "", "children": [ "IPY_MODEL_6f064b9738d04387815495aefaa76a5f", "IPY_MODEL_38ee7f6281004db59ad9178f27c0d4f3", "IPY_MODEL_c33bef74ef8744f3b81fb35decd692ba" ], "layout": "IPY_MODEL_77cf020780d9433c9064beceb6d14ea7" } }, "6f064b9738d04387815495aefaa76a5f": { "model_module": "@jupyter-widgets/controls", "model_name": "HTMLModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "HTMLModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "HTMLView", "description": "", "description_tooltip": null, "layout": "IPY_MODEL_a3fb4e5d8de241fab5212858549ecd2f", "placeholder": "​", "style": "IPY_MODEL_a5fe73a48eb6419d86dd35dfd4239395", "value": "generation_config.json: 100%" } }, "38ee7f6281004db59ad9178f27c0d4f3": { "model_module": "@jupyter-widgets/controls", "model_name": "FloatProgressModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "FloatProgressModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "ProgressView", "bar_style": "success", "description": "", "description_tooltip": null, "layout": "IPY_MODEL_e658ede1b9484f33b64c3f02c60811b7", "max": 137, "min": 0, "orientation": "horizontal", "style": "IPY_MODEL_ce98efa086ad47d9a5d5efb765cbbce0", "value": 137 } }, "c33bef74ef8744f3b81fb35decd692ba": { "model_module": "@jupyter-widgets/controls", "model_name": "HTMLModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "HTMLModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "HTMLView", "description": "", "description_tooltip": null, "layout": "IPY_MODEL_979f024ae7a2454c941deff456913fd3", "placeholder": "​", "style": "IPY_MODEL_1aee6bbddebd4a348a4311b4c7b17506", "value": " 137/137 [00:00<00:00, 14.3kB/s]" } }, "77cf020780d9433c9064beceb6d14ea7": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "a3fb4e5d8de241fab5212858549ecd2f": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "a5fe73a48eb6419d86dd35dfd4239395": { "model_module": "@jupyter-widgets/controls", "model_name": "DescriptionStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "DescriptionStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "description_width": "" } }, "e658ede1b9484f33b64c3f02c60811b7": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "ce98efa086ad47d9a5d5efb765cbbce0": { "model_module": "@jupyter-widgets/controls", "model_name": "ProgressStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "ProgressStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "bar_color": null, "description_width": "" } }, "979f024ae7a2454c941deff456913fd3": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "1aee6bbddebd4a348a4311b4c7b17506": { "model_module": "@jupyter-widgets/controls", "model_name": "DescriptionStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "DescriptionStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "description_width": "" } }, "ca4fbf3c580c4f76bcbeac29d1ffcaeb": { "model_module": "@jupyter-widgets/controls", "model_name": "HBoxModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "HBoxModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "HBoxView", "box_style": "", "children": [ "IPY_MODEL_f02f2ca52d294814bc864fe1794a8372", "IPY_MODEL_ef56ecde5e414164829d33165b822957", "IPY_MODEL_3761dc8fd9c1461e81829aa2f36a935f" ], "layout": "IPY_MODEL_0221fabd48954487b0d7d6d4401f0701" } }, "f02f2ca52d294814bc864fe1794a8372": { "model_module": "@jupyter-widgets/controls", "model_name": "HTMLModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "HTMLModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "HTMLView", "description": "", "description_tooltip": null, "layout": "IPY_MODEL_dc125c845b454f97a0c80ee535e502b3", "placeholder": "​", "style": "IPY_MODEL_1a0f2678fc86484a9a36538216c238de", "value": "tokenizer_config.json: " } }, "ef56ecde5e414164829d33165b822957": { "model_module": "@jupyter-widgets/controls", "model_name": "FloatProgressModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "FloatProgressModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "ProgressView", "bar_style": "success", "description": "", "description_tooltip": null, "layout": "IPY_MODEL_a609482e47814789870e4124ec2201f2", "max": 1, "min": 0, "orientation": "horizontal", "style": "IPY_MODEL_cb96b2131a324d0bb1e1a4fc5e161a0c", "value": 1 } }, "3761dc8fd9c1461e81829aa2f36a935f": { "model_module": "@jupyter-widgets/controls", "model_name": "HTMLModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "HTMLModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "HTMLView", "description": "", "description_tooltip": null, "layout": "IPY_MODEL_8a6e5a4f6b5942b68eda7441cb7e1874", "placeholder": "​", "style": "IPY_MODEL_73a339a5cbc14d2a92e0850674483704", "value": " 34.2k/? [00:00<00:00, 2.48MB/s]" } }, "0221fabd48954487b0d7d6d4401f0701": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "dc125c845b454f97a0c80ee535e502b3": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "1a0f2678fc86484a9a36538216c238de": { "model_module": "@jupyter-widgets/controls", "model_name": "DescriptionStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "DescriptionStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "description_width": "" } }, "a609482e47814789870e4124ec2201f2": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": "20px" } }, "cb96b2131a324d0bb1e1a4fc5e161a0c": { "model_module": "@jupyter-widgets/controls", "model_name": "ProgressStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "ProgressStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "bar_color": null, "description_width": "" } }, "8a6e5a4f6b5942b68eda7441cb7e1874": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "73a339a5cbc14d2a92e0850674483704": { "model_module": "@jupyter-widgets/controls", "model_name": "DescriptionStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "DescriptionStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "description_width": "" } }, "9554d33faa964866ad1025a0b38f7786": { "model_module": "@jupyter-widgets/controls", "model_name": "HBoxModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "HBoxModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "HBoxView", "box_style": "", "children": [ "IPY_MODEL_8a74e93fef85475b8dd7915f7b6c7f00", "IPY_MODEL_672f19dfdbc04928b39be89d0eccbd1f", "IPY_MODEL_63fb7e7dbcd5450691fb126931f83a03" ], "layout": "IPY_MODEL_95547a98247a4b57bea13603b38916dd" } }, "8a74e93fef85475b8dd7915f7b6c7f00": { "model_module": "@jupyter-widgets/controls", "model_name": "HTMLModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "HTMLModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "HTMLView", "description": "", "description_tooltip": null, "layout": "IPY_MODEL_01c3fff3089c4693a39e81b9664ed16b", "placeholder": "​", "style": "IPY_MODEL_f27d22d1b0a34d9d8f0302ea15517eac", "value": "tokenizer.json: 100%" } }, "672f19dfdbc04928b39be89d0eccbd1f": { "model_module": "@jupyter-widgets/controls", "model_name": "FloatProgressModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "FloatProgressModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "ProgressView", "bar_style": "success", "description": "", "description_tooltip": null, "layout": "IPY_MODEL_4b6b680813ea4dcc8631e43e131a2817", "max": 17518497, "min": 0, "orientation": "horizontal", "style": "IPY_MODEL_9e793dda4a8543edbf6ea7a2759b515d", "value": 17518497 } }, "63fb7e7dbcd5450691fb126931f83a03": { "model_module": "@jupyter-widgets/controls", "model_name": "HTMLModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "HTMLModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "HTMLView", "description": "", "description_tooltip": null, "layout": "IPY_MODEL_05d51ca4b0bb4eea96de4582d2b5cb46", "placeholder": "​", "style": "IPY_MODEL_6ff6308192144b7da53f5f5f2403560b", "value": " 17.5M/17.5M [00:01<00:00, 87.4MB/s]" } }, "95547a98247a4b57bea13603b38916dd": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "01c3fff3089c4693a39e81b9664ed16b": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "f27d22d1b0a34d9d8f0302ea15517eac": { "model_module": "@jupyter-widgets/controls", "model_name": "DescriptionStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "DescriptionStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "description_width": "" } }, "4b6b680813ea4dcc8631e43e131a2817": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "9e793dda4a8543edbf6ea7a2759b515d": { "model_module": "@jupyter-widgets/controls", "model_name": "ProgressStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "ProgressStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "bar_color": null, "description_width": "" } }, "05d51ca4b0bb4eea96de4582d2b5cb46": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "6ff6308192144b7da53f5f5f2403560b": { "model_module": "@jupyter-widgets/controls", "model_name": "DescriptionStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "DescriptionStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "description_width": "" } }, "d12551764e8f4d52bd956c8ba26ebcac": { "model_module": "@jupyter-widgets/controls", "model_name": "HBoxModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "HBoxModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "HBoxView", "box_style": "", "children": [ "IPY_MODEL_511e2ec962954d5097b6491d2d45e006", "IPY_MODEL_baeeca20cca94d79b1557848758e81b4", "IPY_MODEL_8ce56b254b9d4ef68c3b3044147ed9c6" ], "layout": "IPY_MODEL_99d60757e2fd4284b327d83ec8c92011" } }, "511e2ec962954d5097b6491d2d45e006": { "model_module": "@jupyter-widgets/controls", "model_name": "HTMLModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "HTMLModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "HTMLView", "description": "", "description_tooltip": null, "layout": "IPY_MODEL_356f968c925745edb3e2f2f7a095f7e3", "placeholder": "​", "style": "IPY_MODEL_d99aa837fb3d4a9aaa54c5cd9e6f090f", "value": "special_tokens_map.json: 100%" } }, "baeeca20cca94d79b1557848758e81b4": { "model_module": "@jupyter-widgets/controls", "model_name": "FloatProgressModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "FloatProgressModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "ProgressView", "bar_style": "success", "description": "", "description_tooltip": null, "layout": "IPY_MODEL_311a5c3ec8b949f08aa364dc296c82e5", "max": 636, "min": 0, "orientation": "horizontal", "style": "IPY_MODEL_5d9fc99356704a92b7bbc0c994f609f1", "value": 636 } }, "8ce56b254b9d4ef68c3b3044147ed9c6": { "model_module": "@jupyter-widgets/controls", "model_name": "HTMLModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "HTMLModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "HTMLView", "description": "", "description_tooltip": null, "layout": "IPY_MODEL_d73edac84fd04a818c450f474732cfd6", "placeholder": "​", "style": "IPY_MODEL_f910709118c8490f9b909d32d3e2f2c8", "value": " 636/636 [00:00<00:00, 39.6kB/s]" } }, "99d60757e2fd4284b327d83ec8c92011": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "356f968c925745edb3e2f2f7a095f7e3": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "d99aa837fb3d4a9aaa54c5cd9e6f090f": { "model_module": "@jupyter-widgets/controls", "model_name": "DescriptionStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "DescriptionStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "description_width": "" } }, "311a5c3ec8b949f08aa364dc296c82e5": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "5d9fc99356704a92b7bbc0c994f609f1": { "model_module": "@jupyter-widgets/controls", "model_name": "ProgressStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "ProgressStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "bar_color": null, "description_width": "" } }, "d73edac84fd04a818c450f474732cfd6": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "f910709118c8490f9b909d32d3e2f2c8": { "model_module": "@jupyter-widgets/controls", "model_name": "DescriptionStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "DescriptionStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "description_width": "" } } } } }, "cells": [ { "cell_type": "markdown", "source": [ "Zero-shot and few-shot learning en un problema de clasificación con instruction-tuned LLM\n", "===================================================================\n", "\n", "Los grandes modelos de lenguaje exhiben grandes habilidades en zero-shot learning. Sin embargo, los resultados dependen mucho de la capacidad del modelo, y de la ténica que utilicemos para resolver el problema.\n", "\n", "En este ejemplo, utizaremos un modelo de lenguaje para resolver el problema de clasificación de tweets sin entrenar ningún modelo (zero-shot)." ], "metadata": { "id": "g4lLoquNL-pk" } }, { "cell_type": "markdown", "source": [ "## Introdución\n", "\n", "Los grandes modelos de lenguaje son capaces de resolver problemas de clasificación al utilizar determinadas estructuras del idioma. Algunos modelos de lenguaje están especificamente entrenados para seguir instrucciones, los cuales los hace muy útiles a la hora de implementar zero-shot or few-shot learning.\n", "\n", "En este ejemplo, veremos como utilizar un modelo de aprendizaje automático entrenado de esta forma para resolver problemas de clasificación." ], "metadata": { "id": "7rNqhA9ZMbfu" } }, { "cell_type": "markdown", "source": [ "### Para ejecutar este notebook\n", "\n", "Para ejecutar este notebook, instale las siguientes librerias:" ], "metadata": { "id": "iMn_2ecENFcP" } }, { "cell_type": "code", "source": [ "!wget https://raw.githubusercontent.com/santiagxf/M72109/master/NLP/Datasets/mascorpus/tweets_marketing.csv \\\n", " --quiet --no-clobber --directory-prefix ./Datasets/mascorpus/\n", "\n", "!pip -q install transformers[torch] accelerate datasets evaluate" ], "metadata": { "colab": { "base_uri": "https://localhost:8080/" }, "id": "Fb1pmFc6JuCO", "outputId": "bb2fdc22-8672-41af-8b64-8a48bb50d7b4" }, "execution_count": 55, "outputs": [ { "output_type": "stream", "name": "stdout", "text": [ "\u001b[?25l \u001b[90m━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\u001b[0m \u001b[32m0.0/84.1 kB\u001b[0m \u001b[31m?\u001b[0m eta \u001b[36m-:--:--\u001b[0m\r\u001b[2K \u001b[90m━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\u001b[0m \u001b[32m84.1/84.1 kB\u001b[0m \u001b[31m6.0 MB/s\u001b[0m eta \u001b[36m0:00:00\u001b[0m\n", "\u001b[?25h" ] } ] }, { "cell_type": "markdown", "source": [ "### Verificando el hardware disponible" ], "metadata": { "id": "-u7dKENbNQDn" } }, { "cell_type": "code", "source": [ "import torch\n", "device = torch.device('cuda') if torch.cuda.is_available() else torch.device('cpu')\n", "\n", "print(\"Este notebook se está ejecutando en\", device)" ], "metadata": { "id": "TRTV_uN7NPkV", "outputId": "beac8237-4079-462b-c41f-c200ce2d1f85", "colab": { "base_uri": "https://localhost:8080/" } }, "execution_count": null, "outputs": [ { "output_type": "stream", "name": "stdout", "text": [ "Este notebook se está ejecutando en cuda\n" ] } ] }, { "cell_type": "markdown", "source": [ "Iniciamos session en HF:" ], "metadata": { "id": "77Ba9zYx2yR1" } }, { "cell_type": "code", "source": [ "from huggingface_hub import notebook_login\n", "\n", "notebook_login()" ], "metadata": { "colab": { "base_uri": "https://localhost:8080/", "height": 17, "referenced_widgets": [ "191b6a790b004003b41bd7a88fc1f94a", "a1a0fd41726c433c969736c3f8425671", "6932beb012434ec894a532af62fbd0ad", "41d64a9993e84221b8357bef021d25e3", "293b2363ffe844cb97480a4c18b76159", "e344c93aab9745faa58f1f6cf98f9c20", "6fbc8e4b384343aca4c252722f2be8ce", "427b286055494cb1b7306cd5e7d59172", "e176dac9c50d444580f39a95cd37f3fc", "a55a9420f90e4aaa9ca8065c11016d3b", "2d62d2364f0a4df2bb31dc5eb8d86d28", "09c497fa25224a13bdb1f4dda36b4a84", "615fc3e533b8409a82f5d3d35a7b20bf", "d14c0a3b8b014349b427dcd5fe268c35", "7395cbf74e2f4102bb9bf3a1057b273d", "073e843a02c9471490d7cc8b50e22df4", "564b1bbf8f5a4f7895bb8a46a8c7c5e2", "6d8abf09e6ee44639c7e0069029dccd0", "f50161df513247dfa99f610534a373cb", "9422c5fd9ad24ab59516dff2d7df3251" ] }, "id": "UPESAn1b2sBT", "outputId": "bf13b217-4a4b-45c1-d8c1-81b1ad50d420" }, "execution_count": 2, "outputs": [ { "output_type": "display_data", "data": { "text/plain": [ "VBox(children=(HTML(value='
' + role + '\\n' + message['content'] | trim + '\\n' }}{% endfor %}{% if add_generation_prompt %}{{'model\\n'}}{% endif %}\"" ], "application/vnd.google.colaboratory.intrinsic+json": { "type": "string" } }, "metadata": {}, "execution_count": 15 } ] }, { "cell_type": "code", "source": [ "messages = [\n", " {\"role\": \"user\", \"content\": \"¿Quién eres?\"},\n", "]\n", "\n", "prompt = gemma.tokenizer.apply_chat_template(messages, tokenize=False, add_generation_prompt=True)\n", "print(\"\\n--- Prompt generado ---\\n\")\n", "print(prompt)\n", "\n", "print(\"\\n--- Respuesta del modelo ---\\n\")\n", "print(gemma(prompt)[0][\"generated_text\"])" ], "metadata": { "colab": { "base_uri": "https://localhost:8080/" }, "id": "J_9wWtlF4sgE", "outputId": "ca8d114d-7992-4620-a5b4-b42411bec47c" }, "execution_count": 17, "outputs": [ { "output_type": "stream", "name": "stderr", "text": [ "Both `max_new_tokens` (=256) and `max_length`(=20) seem to have been set. `max_new_tokens` will take precedence. Please refer to the documentation for more information. (https://huggingface.co/docs/transformers/main/en/main_classes/text_generation)\n" ] }, { "output_type": "stream", "name": "stdout", "text": [ "\n", "--- Prompt generado ---\n", "\n", "user\n", "¿Quién eres?\n", "model\n", "\n", "\n", "--- Respuesta del modelo ---\n", "\n", "user\n", "¿Quién eres?\n", "model\n", "Soy un modelo lingüístico avanzado. Soy un modelo lingüístico que fue diseñada para ayudar a las personas a comprender el lenguaje y a generar lenguaje.\n", "\n", "¿Qué puedo hacer para ayudarte hoy?\n" ] } ] }, { "cell_type": "markdown", "source": [ "### Zero-shot learning\n", "\n", "En general, para resolver cualquier tarea necesitaremos generar un texto o prompt que haga que el modelo genere texto que resuelve el problema de negocio:" ], "metadata": { "id": "aWMay5GFQOUz" } }, { "cell_type": "code", "source": [ "prompt = \"Decide whether the following product review's sentiment is positive, neutral, or negative.\\n\\nProduct review:\\n{}\\nSentiment:\"\n", "print(prompt)\n" ], "metadata": { "id": "bgfDCa41y9Xw", "outputId": "ebda80d0-424a-4632-aa5b-d292e90769ea", "colab": { "base_uri": "https://localhost:8080/" } }, "execution_count": 18, "outputs": [ { "output_type": "stream", "name": "stdout", "text": [ "Decide whether the following product review's sentiment is positive, neutral, or negative.\n", "\n", "Product review:\n", "{}\n", "Sentiment:\n" ] } ] }, { "cell_type": "markdown", "source": [ "Ahora, supongamos que nuestro texto es como sigue:" ], "metadata": { "id": "XfUTA4BAQzb4" } }, { "cell_type": "code", "source": [ "sample = \"The reactivity of your team has been good...ish. However, the overal experience is questionable.\"" ], "metadata": { "id": "u9uDscSpzT6r" }, "execution_count": 19, "outputs": [] }, { "cell_type": "markdown", "source": [ "Podemos generar la respuesta del modelo como sigue:" ], "metadata": { "id": "kw7KxHZEQ5AB" } }, { "cell_type": "code", "source": [ "gemma(prompt.format(sample))" ], "metadata": { "id": "0dPyBeeGzMe5", "outputId": "aaf1b82e-b386-42b9-d050-77e7489a11d3", "colab": { "base_uri": "https://localhost:8080/" } }, "execution_count": 20, "outputs": [ { "output_type": "stream", "name": "stderr", "text": [ "Both `max_new_tokens` (=256) and `max_length`(=20) seem to have been set. `max_new_tokens` will take precedence. Please refer to the documentation for more information. (https://huggingface.co/docs/transformers/main/en/main_classes/text_generation)\n" ] }, { "output_type": "execute_result", "data": { "text/plain": [ "[{'generated_text': \"Decide whether the following product review's sentiment is positive, neutral, or negative.\\n\\nProduct review:\\nThe reactivity of your team has been good...ish. However, the overal experience is questionable.\\nSentiment: Neutral\"}]" ] }, "metadata": {}, "execution_count": 20 } ] }, { "cell_type": "markdown", "source": [ "### Few-shot learning\n", "\n", "En few-shot learning, intentaremos generar un prompt en el cual multiples ejemplos se mencionan antes de solicitarle al modelo que complete el prompt:" ], "metadata": { "id": "-mIntNQ8RVaE" } }, { "cell_type": "code", "source": [ "base_prompt = \"Decide whether the following product reviews' sentiment is positive, neutral, or negative.\"\n", "examples = [\n", " (\n", " \"I love my new chess board!\",\n", " \"positive\"\n", " ),\n", " (\n", " \"Not what I expected but I guess it'll do\",\n", " \"neutral\"\n", " ),\n", " (\n", " \"I'm so disappointed. The product seemed much better on the website\",\n", " \"negative\"\n", " )\n", "]" ], "metadata": { "id": "DFB8c85JzBLO" }, "execution_count": 21, "outputs": [] }, { "cell_type": "markdown", "source": [ "Podemos generar nuestro prompt entonces como sigue:" ], "metadata": { "id": "jykOQBD_RnJd" } }, { "cell_type": "code", "source": [ "def generate_prompt(base_prompt, examples, sample_name, prediction_name, sample=None):\n", " prompt = base_prompt\n", " for example in examples:\n", " prompt += f\"\\n\\n{sample_name}:\\n'{example[0]}'\\n{prediction_name}:\\n{example[1]}\"\n", "\n", " prompt += f\"\\n\\n{sample_name}:\\n'{{}}'\\n{prediction_name}:\\n\"\n", "\n", " if sample:\n", " return prompt.format(sample)\n", " return prompt" ], "metadata": { "id": "a3Sk8nTkRqTU" }, "execution_count": 22, "outputs": [] }, { "cell_type": "code", "source": [ "prompt = generate_prompt(base_prompt, examples, \"Product review\", \"Sentiment\", sample)\n", "print(prompt)" ], "metadata": { "id": "9chi49we0B1r", "outputId": "8a0c52da-77f0-44e5-e1c2-4451cfe14dd9", "colab": { "base_uri": "https://localhost:8080/" } }, "execution_count": 23, "outputs": [ { "output_type": "stream", "name": "stdout", "text": [ "Decide whether the following product reviews' sentiment is positive, neutral, or negative.\n", "\n", "Product review:\n", "'I love my new chess board!'\n", "Sentiment:\n", "positive\n", "\n", "Product review:\n", "'Not what I expected but I guess it'll do'\n", "Sentiment:\n", "neutral\n", "\n", "Product review:\n", "'I'm so disappointed. The product seemed much better on the website'\n", "Sentiment:\n", "negative\n", "\n", "Product review:\n", "'The reactivity of your team has been good...ish. However, the overal experience is questionable.'\n", "Sentiment:\n", "\n" ] } ] }, { "cell_type": "markdown", "source": [ "Podemos ver como funciona el modelo:" ], "metadata": { "id": "6Zf95LEiSg0O" } }, { "cell_type": "code", "source": [ "gemma(prompt, return_full_text=False)" ], "metadata": { "id": "4b7baNqRz8ZO", "outputId": "c2e03919-1f26-4ce8-cc29-1b614f2cad1d", "colab": { "base_uri": "https://localhost:8080/" } }, "execution_count": 25, "outputs": [ { "output_type": "stream", "name": "stderr", "text": [ "You seem to be using the pipelines sequentially on GPU. In order to maximize efficiency please use a dataset\n", "Both `max_new_tokens` (=256) and `max_length`(=20) seem to have been set. `max_new_tokens` will take precedence. Please refer to the documentation for more information. (https://huggingface.co/docs/transformers/main/en/main_classes/text_generation)\n" ] }, { "output_type": "execute_result", "data": { "text/plain": [ "[{'generated_text': 'neutral'}]" ] }, "metadata": {}, "execution_count": 25 } ] }, { "cell_type": "markdown", "source": [ "Podemos ver que en este caso el modelo genero un texto que es bastante mas largo del que esperabamos. Nos interesaria que solo mencione el sentimiento. Podemos mejorar nuestras instrucciones para solicitar al modelo que realize esto, o simplemente buscar especificamente por tokens en particular:" ], "metadata": { "id": "zt3GvXJ3SmBe" } }, { "cell_type": "markdown", "source": [ "#### Utilizando etiquetas\n", "\n", "Primero, utilizaremos el `tokenizer` para generar los IDs correspondiente a los tokens de las etiquetas que disponemos:" ], "metadata": { "id": "bfJcGoTpS4YQ" } }, { "cell_type": "code", "source": [ "target_labels = ['positive', 'neutral', 'negative']\n", "target_token_ids = [gemma.tokenizer.encode(k, add_special_tokens=False)[0] for k in target_labels]" ], "metadata": { "id": "pK65ysbLdHho" }, "execution_count": 26, "outputs": [] }, { "cell_type": "markdown", "source": [ "Generaremos una función que solo obtiene la probabilidad más alta para los tokens que están representados por las etiquetas que tenemos. Esta técnica supone que, a pesar de que el modelo genera un texto diferente, la probabilidad de la clase correcta siempre es más alta a lo largo de todo el texto generado." ], "metadata": { "id": "ClByqurBTkSP" } }, { "cell_type": "code", "source": [ "def generate_for_classification(pipeline, prompt, target_labels, target_token_ids):\n", " input_ids = pipeline.tokenizer(prompt, return_tensors=\"pt\", padding=True).input_ids\n", " with torch.no_grad():\n", " outputs = pipeline.model(input_ids.to(pipeline.model.device))\n", " result = torch.nn.Softmax(dim=-1)(outputs.logits[:, -1, target_token_ids])\n", "\n", " predicted_token_ids = torch.argmax(result, axis=1)\n", " return [target_labels[i] for i in predicted_token_ids], torch.max(result, axis=1)" ], "metadata": { "id": "blSLfOt-z0eo" }, "execution_count": 50, "outputs": [] }, { "cell_type": "markdown", "source": [ "Ejecutamos la función:" ], "metadata": { "id": "EOCCEqetT4In" } }, { "cell_type": "code", "source": [ "predictions, outputs = generate_for_classification(gemma, prompt, target_labels, target_token_ids)" ], "metadata": { "id": "9MdKIShK0nVT" }, "execution_count": 51, "outputs": [] }, { "cell_type": "code", "source": [ "predictions" ], "metadata": { "id": "cmTrA2r-1EPA", "outputId": "6378381c-b223-46ba-9879-f43b0972b488", "colab": { "base_uri": "https://localhost:8080/" } }, "execution_count": 39, "outputs": [ { "output_type": "execute_result", "data": { "text/plain": [ "['neutral']" ] }, "metadata": {}, "execution_count": 39 } ] }, { "cell_type": "markdown", "source": [ "En la función, estamos devolviendo también la variable `result` que contiene la probabilidad de ese token en particular:" ], "metadata": { "id": "puar-R69UDwF" } }, { "cell_type": "code", "source": [ "outputs[0]" ], "metadata": { "id": "n5EUAAlb1GMg", "outputId": "ecf7579c-62e5-4e5e-9006-c3687200b98d", "colab": { "base_uri": "https://localhost:8080/" } }, "execution_count": 53, "outputs": [ { "output_type": "execute_result", "data": { "text/plain": [ "tensor([0.9570], device='cuda:0', dtype=torch.bfloat16)" ] }, "metadata": {}, "execution_count": 53 } ] }, { "cell_type": "markdown", "source": [ "## Resolviendo un problema de clasificación con few-shot learning" ], "metadata": { "id": "4fBw3xtVUdGp" } }, { "cell_type": "markdown", "source": [ "Cargamos el conjunto de datos:" ], "metadata": { "id": "QHS0-NHZUkgo" } }, { "cell_type": "code", "source": [ "import pandas as pd\n", "\n", "tweets = pd.read_csv('Datasets/mascorpus/tweets_marketing.csv')" ], "metadata": { "id": "ccRQQu1D8NJW" }, "execution_count": 56, "outputs": [] }, { "cell_type": "markdown", "source": [ "Trataremos de resolver entonces el mismo problema de clasificación con el que veniamos trabajando: clasificar los tweets dependiendo del sector al que pertenecen. Recordemos que tenemos 7 categorias distintas.\n", "\n", "Mejoraremos un poco los nombres de las categorías:" ], "metadata": { "id": "-Q3vDwCvUv49" } }, { "cell_type": "code", "source": [ "tweets['SECTOR'] = tweets['SECTOR'].map({\n", " \"ALIMENTACION\": \"alimentos\",\n", " \"AUTOMOCION\": \"automobiles\",\n", " \"BANCA\": \"bancos\",\n", " \"BEBIDAS\": \"bebidas\",\n", " \"DEPORTES\": \"deportes\",\n", " \"RETAIL\": \"supermercados\",\n", " \"TELCO\": \"telefonía\"\n", "})" ], "metadata": { "id": "9C5aNalCbA6V" }, "execution_count": 57, "outputs": [] }, { "cell_type": "code", "source": [ "labels = tweets['SECTOR'].unique().tolist()\n", "labels" ], "metadata": { "id": "AZPlYtXJUxVj", "outputId": "52385678-41c6-4e62-dc4e-8ca4719eb93e", "colab": { "base_uri": "https://localhost:8080/" } }, "execution_count": 58, "outputs": [ { "output_type": "execute_result", "data": { "text/plain": [ "['supermercados',\n", " 'telefonía',\n", " 'alimentos',\n", " 'automobiles',\n", " 'bancos',\n", " 'bebidas',\n", " 'deportes']" ] }, "metadata": {}, "execution_count": 58 } ] }, { "cell_type": "markdown", "source": [], "metadata": { "id": "2WFOptXfWXIv" } }, { "cell_type": "code", "source": [ "from sklearn.model_selection import train_test_split\n", "\n", "train, test = train_test_split(tweets, test_size=0.33, stratify=tweets['SECTOR'])" ], "metadata": { "id": "-C44jNRlWXjk" }, "execution_count": 59, "outputs": [] }, { "cell_type": "markdown", "source": [], "metadata": { "id": "cVLXKGldW8GT" } }, { "cell_type": "code", "source": [ "base_prompt = f\"Clasificar los siguientes tweets según el producto o categoría a la que hacen referencia. Las posibles categorías son: {', '.join(labels)}\"" ], "metadata": { "id": "3rhmgotMXHg5" }, "execution_count": 60, "outputs": [] }, { "cell_type": "markdown", "source": [], "metadata": { "id": "RCJfNEu2Yekw" } }, { "cell_type": "code", "source": [ "examples_df = train.groupby('SECTOR').apply(lambda x: x.sample(1)).reset_index(drop=True)\n", "examples = [(row[1]['TEXTO'], row[1]['SECTOR']) for row in examples_df.iterrows()]" ], "metadata": { "id": "kkDJUTreXxxF", "colab": { "base_uri": "https://localhost:8080/" }, "outputId": "7d7f0f5d-af19-46f4-a595-f9e48ea38587" }, "execution_count": 61, "outputs": [ { "output_type": "stream", "name": "stderr", "text": [ "/tmp/ipykernel_647/4046959856.py:1: DeprecationWarning: DataFrameGroupBy.apply operated on the grouping columns. This behavior is deprecated, and in a future version of pandas the grouping columns will be excluded from the operation. Either pass `include_groups=False` to exclude the groupings or explicitly select the grouping columns after groupby to silence this warning.\n", " examples_df = train.groupby('SECTOR').apply(lambda x: x.sample(1)).reset_index(drop=True)\n" ] } ] }, { "cell_type": "code", "source": [ "prompt = generate_prompt(base_prompt, examples, \"Tweet\", \"Categoría\", sample=None)\n", "print(prompt)" ], "metadata": { "id": "JW55zLYiW8c4", "outputId": "89b9ddce-6ce7-49d5-a33c-397d556d790c", "colab": { "base_uri": "https://localhost:8080/" } }, "execution_count": 62, "outputs": [ { "output_type": "stream", "name": "stdout", "text": [ "Clasificar los siguientes tweets según el producto o categoría a la que hacen referencia. Las posibles categorías son: supermercados, telefonía, alimentos, automobiles, bancos, bebidas, deportes\n", "\n", "Tweet:\n", "'Me compré 2 alfajores Milka y uno Pepito😻😏'\n", "Categoría:\n", "alimentos\n", "\n", "Tweet:\n", "'#LigaEndesa #ACB Claves de la Jornada 20 del SuperManager KIA https://t.co/uFmGklRkk1 https://t.co/z5oNtmJhLT'\n", "Categoría:\n", "automobiles\n", "\n", "Tweet:\n", "'700.000 firmas exigen a BBVA que deje de financiar el calentamiento global y la vulneración de derechos humanos https://t.co/dEn6TERs7Y'\n", "Categoría:\n", "bancos\n", "\n", "Tweet:\n", "'me gusta la cruzcampo #Arruinaunacitacon4palabras'\n", "Categoría:\n", "bebidas\n", "\n", "Tweet:\n", "'@MiguuelHerrera @adidas holaaaaa @PUMAmexico'\n", "Categoría:\n", "deportes\n", "\n", "Tweet:\n", "'\"Alcampo, el supermercado online más barato\" \n", "#politicadeprecios \n", "https://t.co/a3wenDb2g8'\n", "Categoría:\n", "supermercados\n", "\n", "Tweet:\n", "'@AfectadosBBS Gracias por vuestro apoyo.\n", "@Movistar @Telefónica me han proporcionado un Samsung Galaxy S5, que ya tengo en mi poder.'\n", "Categoría:\n", "telefonía\n", "\n", "Tweet:\n", "'{}'\n", "Categoría:\n", "\n" ] } ] }, { "cell_type": "markdown", "source": [ "Veamos como funciona con un ejemplo:" ], "metadata": { "id": "PtWDpNO5dy7i" } }, { "cell_type": "code", "source": [ "sample = test.sample(1).iloc[0]" ], "metadata": { "id": "lW593Jo9eKLr" }, "execution_count": 63, "outputs": [] }, { "cell_type": "code", "source": [ "sample['TEXTO']" ], "metadata": { "id": "6_Lvi2qGfinq", "outputId": "d02b2bb1-70cc-41d8-b8c0-8ea5628ec721", "colab": { "base_uri": "https://localhost:8080/", "height": 36 } }, "execution_count": 64, "outputs": [ { "output_type": "execute_result", "data": { "text/plain": [ "'Santander, BBVA y Barclays, líderes en bonos en 2016 https://t.co/LVaV4ic7Fu https://t.co/HZIBdsFSyt'" ], "application/vnd.google.colaboratory.intrinsic+json": { "type": "string" } }, "metadata": {}, "execution_count": 64 } ] }, { "cell_type": "markdown", "source": [ "### Utilizando el modelo generativo" ], "metadata": { "id": "F9Ucjt8cgCtb" } }, { "cell_type": "code", "source": [ "gemma(prompt.format(sample['TEXTO']), return_full_text=False)" ], "metadata": { "id": "PBaEkWazeyAw", "outputId": "1c4e339b-45bf-4151-b1a1-d1462ac76a9a", "colab": { "base_uri": "https://localhost:8080/" } }, "execution_count": 66, "outputs": [ { "output_type": "stream", "name": "stderr", "text": [ "Both `max_new_tokens` (=256) and `max_length`(=20) seem to have been set. `max_new_tokens` will take precedence. Please refer to the documentation for more information. (https://huggingface.co/docs/transformers/main/en/main_classes/text_generation)\n" ] }, { "output_type": "execute_result", "data": { "text/plain": [ "[{'generated_text': 'bancos'}]" ] }, "metadata": {}, "execution_count": 66 } ] } ] }