Skip to content
Questa pagina non è ancora disponibile nella tua lingua. Viene mostrata la versione in inglese.

Passwordless Login

Quick annotation studies और testing के लिए सरलीकृत authentication।

Passwordless Login

Potato low-stakes annotation tasks के लिए passwordless authentication का समर्थन करता है जहाँ पहुँच की आसानी से security कम महत्वपूर्ण है। यह annotators को केवल username के साथ, password की आवश्यकता के बिना login करने की अनुमति देता है।

अवलोकन

Passwordless login उपयोगी है जब:

  • Volunteers के साथ quick annotation studies चलाना
  • Internal team annotation sessions करना
  • Annotation configurations test करना
  • Crowdsourcing platforms के साथ काम करना जो authentication externally संभालते हैं
  • Classroom exercises या demos चलाना

कॉन्फ़िगरेशन

require_password: false सेट करके passwordless login सक्षम करें:

yaml
require_password: false
 
# Optional: Specify authentication method
authentication:
  method: in_memory  # Default

Authentication Methods

Potato तीन authentication backends का समर्थन करता है, सभी passwordless mode के साथ compatible:

In-Memory (Default)

Users केवल memory में संग्रहीत हैं। Server restart पर Data खो जाता है।

yaml
require_password: false
authentication:
  method: in_memory

Database

Users एक database में persist किए जाते हैं:

bash
export POTATO_DB_CONNECTION="sqlite:///users.db"
yaml
require_password: false
authentication:
  method: database

Clerk SSO

Enterprise single sign-on के लिए Clerk के साथ एकीकरण:

bash
export CLERK_API_KEY="your_api_key"
export CLERK_FRONTEND_API="your_frontend_api"
yaml
authentication:
  method: clerk

यह कैसे काम करता है

Passwordless सक्षम होने पर

  1. User login page पर जाता है
  2. User केवल अपना username दर्ज करता है
  3. System password verification के बिना user को create या authenticate करता है
  4. User annotation की ओर proceed करता है

User Registration

Passwordless mode में:

  • नए users पहले login पर स्वचालित रूप से registered हो जाते हैं
  • केवल username आवश्यक है
  • Additional user data (यदि configure किया गया हो) अभी भी एकत्र किया जाता है

सुरक्षा संबंधी विचार

Passwordless mode न्यूनतम सुरक्षा प्रदान करता है:

  • कोई identity verification नहीं: कोई भी कोई भी username claim कर सकता है
  • Session hijacking: Sessions आसानी से impersonate किए जा सकते हैं
  • No audit trail integrity: User actions को cryptographically verify नहीं किया जा सकता

अनुशंसित उपयोग:

  • Internal team annotation
  • Classroom exercises
  • Quick prototyping
  • External authentication वाले Platforms (Prolific, MTurk)

अनुशंसित नहीं:

  • Sensitive data annotation
  • Medical या legal annotation tasks
  • Verified annotator identity की आवश्यकता वाले tasks
  • Incentives के साथ long-running studies

User Configuration File

Passwordless mode में भी, आप users pre-register कर सकते हैं:

yaml
authentication:
  user_config_path: users.jsonl

users.jsonl:

json
{"username": "annotator1"}
{"username": "annotator2"}
{"username": "admin", "role": "admin"}

Migration

Password-Required से Passwordless पर

  1. Configuration update करें:
    yaml
    require_password: false
  2. मौजूदा users अपने password के साथ या बिना login कर सकते हैं

Passwordless से Password-Required पर

  1. Configuration update करें:
    yaml
    require_password: true
  2. मौजूदा passwordless users को password के साथ register करना होगा

पूर्ण उदाहरण

yaml
annotation_task_name: "Quick Annotation Task"
 
# Enable passwordless login for easy access
require_password: false
 
# Use database backend to persist users
authentication:
  method: database
 
# Task configuration
data_files:
  - data/instances.json
 
item_properties:
  id_key: id
  text_key: text
 
annotation_schemes:
  - name: sentiment
    annotation_type: radio
    labels: [Positive, Negative, Neutral]
    description: "Select the sentiment"

समस्या निवारण

Users Login नहीं कर सकते

जांचें कि:

  1. Configuration में require_password: false सेट है
  2. Authentication backend ठीक से initialized है
  3. कोई conflicting authentication settings नहीं हैं

User Data Persist नहीं हो रहा

यदि in_memory backend का उपयोग कर रहे हैं:

  • Server restart पर User data खो जाता है
  • Persistence के लिए database backend पर switch करें

Duplicate Username Errors

Passwordless mode में, किसी existing username के साथ register करने की कोशिश करने वाले users को simply उस user के रूप में logged in किया जाता है। यह उपयोग में आसानी के लिए design किया गया है।

आगे पढ़ें

कार्यान्वयन विवरण के लिए, source documentation देखें।