gradio-assessment

This repo is for the senior frontend engineer assessment

https://github.com/dawoodkhan82/gradio-assessment

Science Score: 26.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
  • Academic publication links
  • Academic email domains
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (14.6%) to scientific vocabulary
Last synced: 10 months ago · JSON representation

Repository

This repo is for the senior frontend engineer assessment

Basic Info
  • Host: GitHub
  • Owner: dawoodkhan82
  • License: apache-2.0
  • Language: HTML
  • Default Branch: main
  • Size: 103 MB
Statistics
  • Stars: 0
  • Watchers: 1
  • Forks: 0
  • Open Issues: 0
  • Releases: 0
Created over 3 years ago · Last pushed over 3 years ago
Metadata Files
Readme Changelog Contributing License Citation Security

README.md

Senior Frontend Engineer Take Home Assessment

Overview

Thanks for taking the time to interview with the Gradio team, the next step in the process includes completing a take-home assessment.

The format of the assessment will consist of: 1. A quick call to help you get setup with your local development environment and answer any questions around the assessment. 2. Spend no more than 4-5 hours on this take home assessment. You can always ask us clarifying questions during this process. Also you can always discuss your approach and how you would've implemented something you didn't have the time for. 3. A final call to explain your submission and approach.

The purpose of this assessment is to create a custom dropdown menu. The dropdown component is an important input component within the Gradio library. It allows developers to enable users to select from a list of options within their demos. This repository currently implements a standard dropdown menu using the html select element:

dropdown_standard

As shown above, the current dropdown is limited in its capabilities and very simplistic design. Your job will be to replace this dropdown with your own custom implementation and add more features, requested by our developers. Use the current dropdown component implementation as a starting point and build a completely custom dropdown within a private fork of this repository. Below is an example of a custom dropdown with extra functionality, don't feel the need to mimic this exact dropdown, we want to see your own unique approach:

210434026-737809ed-5e6c-4b10-97ff-e489bbfe72e4_AdobeExpress_AdobeExpress

Prerequisites

  • First, you will create a private fork of this repository and follow the CONTRIBUTING.md guide in order to setup your local development environment (both client and server side).

    • We will setup an initial call to help with any issues when setting up your local environment. Try to see how far you can get on your own by following the guide. But we expect there to be some hurdles, so don't stress, we'll help get it sorted!

Structure of the Repository

It's helpful to know the overall structure of the repository, although you will only have to work with a couple of files.

  • /gradio: contains the Python source code for the library
    • /gradio/interface.py: contains the Python source code for the core Interface class
    • /gradio/blocks.py: contains the Python source code for the core Blocks class
    • /gradio/components.py: contains the Python source code for the components, you can add your custom components here.
  • /ui: contains the HTML/JS/CSS source code for the library (start here for frontend changes)
  • /test: contains Python unit tests for the library
  • /demo: contains demos that are used in the documentation, you can find Gradio examples over here.
  • /website: contains the code for the Gradio website (www.gradio.app). See the README in the /website folder for more details

  • Below are the files you will need to know about:

    • gradio/ui/packages/app/src/components/Dropdown/Dropdown.svelte
    • This is a simple file that creates a Dropdown component and wraps it in a Block.
    • gradio/ui/packages/form/src/Dropdown.svelte
    • This is the file where the frontend implementation of your custom dropdown will go. Notice how the choices variable is used to create an <option> with the current implementation.
    • https://github.com/dawoodkhan82/gradio-assessment/blob/cb475c1caa0b500461d96582a1085530d28ed2fb/ui/packages/form/src/Dropdown.svelte#L23-L25
    • gradio/gradio/components.py
    • For the extra dropdown features you may want to add, you're going to have to change the python api and add any additional developer facing parameters for the dropdown component. For example, you may want to add a multiselect bool parameter to allow the developer to toggle on the ability to select multiple choices.
    • https://github.com/dawoodkhan82/gradio-assessment/blob/cb475c1caa0b500461d96582a1085530d28ed2fb/gradio/components.py#L1170

What we're looking for

Please don't feel the need to spend too much time on this assessment! To re-iterate: you can always discuss your approach and how you would've implemented something you didn't have the time for. We're mainly looking for how you work and communicate.

Overall:

  • A basic working custom dropdown component
  • Code quality and organization
  • Documentation of how the component works and in-code documentation for any areas of code that may be hard to understand
  • Good design eye
  • Basic unit tests
  • Ability to talk through your implementation
  • Willingness to ask us questions if you reach any issues or have trouble understanding anything

Core Dropdown Features:

  • Allow selection of a single dropdown option
  • Clear the selected option
  • Ability to type and search through the dropdown options
  • Keyboard functionality: enter key to select an option, and arrow key support for navigating options
  • A11Y (accessiblity) adherence

Extra Dropdown Features (Optional):

  • Ability to select multiple dropdown options
  • Section headers in the dropdown to organize options
  • Filter dropdown options by typing in section header name
  • Ability to clear all options and individual options

Owner

  • Name: Dawood Khan
  • Login: dawoodkhan82
  • Kind: user

GitHub Events

Total
Last Year

Issues and Pull Requests

Last synced: over 1 year ago

All Time
  • Total issues: 0
  • Total pull requests: 0
  • Average time to close issues: N/A
  • Average time to close pull requests: N/A
  • Total issue authors: 0
  • Total pull request authors: 0
  • Average comments per issue: 0
  • Average comments per pull request: 0
  • Merged pull requests: 0
  • Bot issues: 0
  • Bot pull requests: 0
Past Year
  • Issues: 0
  • Pull requests: 0
  • Average time to close issues: N/A
  • Average time to close pull requests: N/A
  • Issue authors: 0
  • Pull request authors: 0
  • Average comments per issue: 0
  • Average comments per pull request: 0
  • Merged pull requests: 0
  • Bot issues: 0
  • Bot pull requests: 0
Top Authors
Issue Authors
Pull Request Authors
Top Labels
Issue Labels
Pull Request Labels

Dependencies

.github/workflows/build-pr.yml actions
  • actions/checkout v3 composite
  • actions/setup-node v3 composite
  • actions/setup-python v3 composite
  • actions/upload-artifact v3 composite
  • pnpm/action-setup v2.2.2 composite
.github/workflows/build-version-docs.yml actions
  • actions/checkout v3 composite
  • actions/setup-python v3 composite
  • peter-evans/create-pull-request v4 composite
.github/workflows/check-changelog.yml actions
  • actions/checkout v2 composite
.github/workflows/check-demo-notebooks.yml actions
  • actions/checkout v2 composite
  • actions/upload-artifact v3 composite
.github/workflows/comment-pr.yml actions
  • actions/checkout v3 composite
  • actions/setup-python v3 composite
  • thollander/actions-comment-pull-request v2 composite
.github/workflows/delete-stale-spaces.yml actions
  • actions/checkout v3 composite
  • actions/setup-python v3 composite
.github/workflows/deploy-pr-to-spaces.yml actions
  • actions/checkout v3 composite
  • actions/setup-python v3 composite
  • thollander/actions-comment-pull-request v1 composite
.github/workflows/deploy-pypi.yml actions
  • EndBug/add-and-commit v9 composite
  • actions/checkout v3 composite
  • actions/setup-python v3 composite
  • pnpm/action-setup v2.2.2 composite
  • pypa/gh-action-pypi-publish 27b31702a0e7fc50959f5ad993c78deac1bdfc29 composite
  • softprops/action-gh-release v1 composite
.github/workflows/ui.yml actions
  • actions/checkout v3 composite
  • actions/setup-node v3 composite
  • actions/setup-python v3 composite
  • actions/upload-artifact v3 composite
  • pnpm/action-setup v2.2.1 composite
website/homepage/Dockerfile docker
  • python 3.8 build
ui/package-lock.json npm
  • 124 dependencies
ui/package.json npm
  • @types/three ^0.138.0 development
  • @gradio/tootils workspace:^0.0.1
  • @playwright/test ^1.27.1
  • @sveltejs/vite-plugin-svelte ^1.0.0-next.44
  • @tailwindcss/forms ^0.5.0
  • @testing-library/dom ^8.11.3
  • @testing-library/svelte ^3.1.0
  • @testing-library/user-event ^13.5.0
  • autoprefixer ^10.4.4
  • babylonjs ^5.17.1
  • babylonjs-loaders ^5.17.1
  • happy-dom ^2.49.0
  • node-html-parser ^5.3.3
  • npm-run-all ^4.1.5
  • playwright ^1.27.1
  • plotly.js-dist-min ^2.10.1
  • polka ^1.0.0-next.22
  • postcss ^8.4.5
  • postcss-nested ^5.0.6
  • prettier ^2.6.2
  • prettier-plugin-svelte ^2.7.0
  • sirv ^2.0.2
  • sirv-cli ^2.0.2
  • svelte ^3.49.0
  • svelte-check ^2.8.0
  • svelte-i18n ^3.3.13
  • svelte-preprocess ^4.10.6
  • tailwindcss ^3.1.6
  • tinyspy ^0.3.0
  • typescript ^4.7.4
  • vite ^2.9.5
  • vitest ^0.12.7
ui/packages/_cdn-test/package.json npm
  • vite ^2.9.9 development
ui/packages/app/package.json npm
  • @gradio/atoms workspace:^0.0.1
  • @gradio/audio workspace:^0.0.1
  • @gradio/button workspace:^0.0.1
  • @gradio/carousel workspace:^0.0.1
  • @gradio/chart workspace:^0.0.1
  • @gradio/chatbot workspace:^0.0.1
  • @gradio/file workspace:^0.0.1
  • @gradio/form workspace:^0.0.1
  • @gradio/highlighted-text workspace:^0.0.1
  • @gradio/html workspace:^0.0.1
  • @gradio/icons workspace:^0.0.1
  • @gradio/image workspace:^0.0.1
  • @gradio/json workspace:^0.0.1
  • @gradio/label workspace:^0.0.1
  • @gradio/markdown workspace:^0.0.1
  • @gradio/model3D workspace:^0.0.1
  • @gradio/plot workspace:^0.0.1
  • @gradio/table workspace:^0.0.1
  • @gradio/tabs workspace:^0.0.1
  • @gradio/theme workspace:^0.0.1
  • @gradio/upload workspace:^0.0.1
  • @gradio/uploadbutton workspace:^0.0.1
  • @gradio/utils workspace:^0.0.1
  • @gradio/video workspace:^0.0.1
  • d3-dsv ^3.0.1
  • mime-types ^2.1.34
  • svelte ^3.25.1
  • svelte-i18n ^3.3.13
ui/packages/atoms/package.json npm
  • @gradio/utils workspace:^0.0.1
ui/packages/audio/package.json npm
  • @gradio/atoms workspace:^0.0.1
  • @gradio/icons workspace:^0.0.1
  • @gradio/upload workspace:^0.0.1
  • extendable-media-recorder ^7.0.2
  • extendable-media-recorder-wav-encoder ^7.0.76
  • svelte-range-slider-pips ^2.0.1
ui/packages/button/package.json npm
  • @gradio/utils workspace:^0.0.1
ui/packages/chart/package.json npm
  • @types/d3-dsv ^3.0.0 development
  • @types/d3-scale ^4.0.2 development
  • @types/d3-shape ^3.0.2 development
  • @gradio/icons workspace:^0.0.1
  • @gradio/theme workspace:^0.0.1
  • @gradio/tooltip workspace:^0.0.1
  • @gradio/utils workspace:^0.0.1
  • d3-dsv ^3.0.1
  • d3-scale ^4.0.2
  • d3-shape ^3.1.0
ui/packages/chatbot/package.json npm
  • @gradio/theme workspace:^0.0.1
  • @gradio/utils workspace:^0.0.1
ui/packages/file/package.json npm
  • @gradio/atoms workspace:^0.0.1
  • @gradio/icons workspace:^0.0.1
  • @gradio/upload workspace:^0.0.1
ui/packages/form/package.json npm
  • @gradio/atoms workspace:^0.0.1
  • @gradio/utils workspace:^0.0.1
ui/packages/highlighted-text/package.json npm
  • @gradio/theme workspace:^0.0.1
  • @gradio/utils workspace:^0.0.1
ui/packages/image/package.json npm
  • @gradio/atoms workspace:^0.0.1
  • @gradio/icons workspace:^0.0.1
  • @gradio/upload workspace:^0.0.1
  • @gradio/utils workspace:^0.0.1
  • cropperjs ^1.5.12
  • lazy-brush ^1.0.1
  • resize-observer-polyfill ^1.5.1
ui/packages/label/package.json npm
  • @gradio/utils workspace:^0.0.1
ui/packages/model3D/package.json npm
  • @gradio/atoms workspace:^0.0.1
  • @gradio/icons workspace:^0.0.1
  • @gradio/upload workspace:^0.0.1
  • babylonjs ^4.2.1
  • babylonjs-loaders ^4.2.1
ui/packages/plot/package.json npm
  • @gradio/icons workspace:^0.0.1
  • @gradio/theme workspace:^0.0.1
  • @gradio/utils workspace:^0.0.1
  • @rollup/plugin-json ^5.0.2
  • plotly.js-dist-min ^2.10.1
  • svelte-vega ^1.2.0
  • vega >=5.21.0 <6.0.0
  • vega-lite *
ui/packages/table/package.json npm
  • @gradio/upload workspace:^0.0.1
  • @gradio/utils workspace:^0.0.1
  • @types/d3-dsv ^3.0.0
  • d3-dsv ^3.0.1
  • dequal ^2.0.2
ui/packages/upload/package.json npm
  • @gradio/atoms workspace:^0.0.1
  • @gradio/icons workspace:^0.0.1
ui/packages/upload-button/package.json npm
  • @gradio/utils workspace:^0.0.1
ui/packages/utils/package.json npm
  • @gradio/theme workspace:^0.0.1
ui/packages/video/package.json npm
  • @gradio/atoms workspace:^0.0.1
  • @gradio/icons workspace:^0.0.1
  • @gradio/image workspace:^0.0.1
  • @gradio/upload workspace:^0.0.1
ui/packages/workbench/package.json npm
  • @sveltejs/adapter-auto next development
  • @sveltejs/kit ^1.0.0-next.318 development
  • autoprefixer ^10.4.2 development
  • postcss ^8.4.5 development
  • postcss-load-config ^3.1.1 development
  • svelte-check ^2.2.6 development
  • svelte-preprocess ^4.10.1 development
  • tailwindcss ^3.0.12 development
  • tslib ^2.3.1 development
  • typescript ~4.5.4 development
  • @gradio/atoms workspace:^0.0.1
  • @gradio/audio workspace:^0.0.1
  • @gradio/button workspace:^0.0.1
  • @gradio/carousel workspace:^0.0.1
  • @gradio/chart workspace:^0.0.1
  • @gradio/chatbot workspace:^0.0.1
  • @gradio/file workspace:^0.0.1
  • @gradio/form workspace:^0.0.1
  • @gradio/highlighted-text workspace:^0.0.1
  • @gradio/html workspace:^0.0.1
  • @gradio/image workspace:^0.0.1
  • @gradio/json workspace:^0.0.1
  • @gradio/label workspace:^0.0.1
  • @gradio/markdown workspace:^0.0.1
  • @gradio/model3D workspace:^0.0.1
  • @gradio/plot workspace:^0.0.1
  • @gradio/table workspace:^0.0.1
  • @gradio/tabs workspace:^0.0.1
  • @gradio/theme workspace:^0.0.1
  • @gradio/upload workspace:^0.0.1
  • @gradio/uploadbutton workspace:^0.0.1
  • @gradio/video workspace:^0.0.1
  • svelte >=3.44.0 <4.0.0
ui/pnpm-lock.yaml npm
  • 495 dependencies
website/homepage/package-lock.json npm
  • 178 dependencies
website/homepage/package.json npm
  • @fullhuman/postcss-purgecss ^4.0.3
  • @tailwindcss/forms ^0.5.0
  • @tailwindcss/typography ^0.5.4
  • autoprefixer ^10.4.0
  • cssnano ^5.0.8
  • postcss-cli ^9.0.1
  • postcss-hash ^3.0.0
  • tailwindcss ^3.0.24
demo/Echocardiogram-Segmentation/requirements.txt pypi
  • matplotlib *
  • numpy *
  • torch ==1.6.0
  • torchvision ==0.7.0
  • wget *
demo/altair_plot/requirements.txt pypi
  • altair *
  • vega_datasets *
demo/animeganv2/requirements.txt pypi
  • Pillow *
  • cmake *
  • gdown *
  • numpy *
  • onnxruntime-gpu *
  • opencv-python-headless *
  • scipy *
  • torch *
  • torchvision *
demo/blocks_flag/requirements.txt pypi
  • numpy *
demo/blocks_interpretation/requirements.txt pypi
  • matplotlib *
  • shap *
  • torch *
  • transformers *
demo/blocks_multiple_event_triggers/requirements.txt pypi
  • plotly *
  • pypistats *
demo/blocks_speech_text_sentiment/requirements.txt pypi
  • torch *
  • transformers *
demo/chicago-bikeshare-dashboard/requirements.txt pypi
  • SQLAlchemy *
  • matplotlib *
  • psycopg2 *
demo/clustering/requirements.txt pypi
  • matplotlib >=3.5.2
  • scikit-learn >=1.0.1
demo/color_generator/requirements.txt pypi
  • numpy *
  • opencv-python *
demo/color_picker/requirements.txt pypi
  • Pillow *
demo/dashboard/requirements.txt pypi
  • plotly *
demo/depth_estimation/requirements.txt pypi
  • Pillow *
  • jinja2 *
  • numpy *
  • open3d *
  • torch *
  • transformers add_dpt_redesign
demo/digit_classifier/requirements.txt pypi
  • tensorflow *
demo/english_translator/requirements.txt pypi
  • torch *
  • transformers *
demo/fake_diffusion/requirements.txt pypi
  • numpy *
demo/fraud_detector/requirements.txt pypi
  • pandas *
demo/generate_english_german/requirements.txt pypi
  • torch *
  • transformers *
demo/generate_tone/requirements.txt pypi
  • numpy *
demo/gif_maker/requirements.txt pypi
  • opencv-python *
demo/image_classification/requirements.txt pypi
  • torch *
  • torchvision *
demo/image_classifier/requirements.txt pypi
  • numpy *
  • tensorflow *
demo/image_classifier_2/requirements.txt pypi
  • pillow *
  • torch *
  • torchvision *
demo/image_classifier_interpretation/requirements.txt pypi
  • numpy *
  • tensorflow *
demo/image_segmentation/requirements.txt pypi
  • numpy *
  • scipy *
  • torch *
  • transformers *
demo/lineplot_component/requirements.txt pypi
  • vega_datasets *
demo/live_dashboard/requirements.txt pypi
  • plotly *
demo/main_note/requirements.txt pypi
  • matplotlib *
  • numpy *
  • scipy *
demo/map_airbnb/requirements.txt pypi
  • plotly *
demo/musical_instrument_identification/requirements.txt pypi
  • gdown *
  • librosa ==0.9.2
  • torch ==1.12.0
  • torchaudio ==0.12.0
  • torchvision ==0.13.0
demo/native_plots/requirements.txt pypi
  • vega_datasets *
demo/neon-tts-plugin-coqui/requirements.txt pypi
  • neon-tts-plugin-coqui ==0.4.1a9
demo/ner_pipeline/requirements.txt pypi
  • torch *
  • transformers *
demo/outbreak_forecast/requirements.txt pypi
  • altair *
  • bokeh *
  • matplotlib *
  • numpy *
  • plotly *
demo/pictionary/requirements.txt pypi
  • gdown *
  • torch *
demo/plot_component/requirements.txt pypi
  • matplotlib *
  • numpy *
demo/progress/requirements.txt pypi
  • datasets *
  • tqdm *
demo/sales_projections/requirements.txt pypi
  • matplotlib *
  • numpy *
  • pandas *
demo/same-person-or-different/requirements.txt pypi
  • torchaudio *
demo/scatterplot_component/requirements.txt pypi
  • vega_datasets *
demo/sentiment_analysis/requirements.txt pypi
  • nltk *
demo/sine_curve/requirements.txt pypi
  • plotly *
demo/spectogram/requirements.txt pypi
  • matplotlib *
  • numpy *
  • scipy *
demo/stable-diffusion/requirements.txt pypi
  • diffusers *
  • ftfy *
  • nvidia-ml-py3 *
  • torch *
  • transformers *
demo/stock_forecast/requirements.txt pypi
  • matplotlib *
  • numpy *
demo/streaming_stt/requirements.txt pypi
  • deepspeech ==0.9.3
demo/streaming_wav2vec/requirements.txt pypi
  • torch *
  • transformers *
demo/text_analysis/requirements.txt pypi
  • spacy *
demo/text_generation/requirements.txt pypi
  • gradio *
  • torch *
demo/timeseries-forecasting-with-prophet/requirements.txt pypi
  • pandas *
  • plotly *
  • prophet ==1.1
  • pypistats *
demo/titanic_survival/requirements.txt pypi
  • numpy *
  • pandas *
  • scikit-learn *
demo/translation/requirements.txt pypi
  • gradio *
  • torch *
demo/unispeech-speaker-verification/requirements.txt pypi
  • torchaudio *
demo/white_noise_vid_not_playable/requirements.txt pypi
  • opencv-python *
demo/xgboost-income-prediction-with-explainability/requirements.txt pypi
  • datasets *
  • matplotlib *
  • pandas *
  • shap *
  • xgboost *
requirements.txt pypi
  • Jinja2 *
  • aiohttp *
  • altair >=4.2.0
  • fastapi *
  • ffmpy *
  • fsspec *
  • httpx *
  • markdown-it-py *
  • markupsafe *
  • matplotlib *
  • numpy *
  • orjson *
  • pandas *
  • pillow *
  • pycryptodome *
  • pydantic *
  • pydub *
  • python-multipart *
  • pyyaml *
  • requests *
  • typing_extensions *
  • uvicorn *
  • websockets >=10.0
test/requirements.in pypi
  • IPython * test
  • altair * test
  • asyncio * test
  • black * test
  • comet_ml * test
  • coverage * test
  • fastapi >=0.87.0 test
  • flake8 * test
  • httpx * test
  • huggingface_hub * test
  • isort * test
  • mlflow * test
  • pydantic * test
  • pytest * test
  • pytest-asyncio * test
  • pytest-cov * test
  • respx * test
  • scikit-image * test
  • shap * test
  • torch * test
  • tqdm * test
  • transformers * test
  • vega_datasets * test
  • wandb * test
test/requirements.txt pypi
  • 130 dependencies
website/homepage/requirements.txt pypi
  • huggingface_hub *
  • jinja2 *
  • markdown2 *
  • requests *