Skip to main content

Module demo

Module demo 

Source
Expand description

End-to-end demo infrastructure for Qwen2-0.5B WASM demo (spec §J) End-to-End Demo Module

Provides verification infrastructure for the Qwen2-0.5B WASM demo.

§QA Verification (Section J: 15 points)

  • J1: Qwen2-0.5B imports from HF
  • J2: INT4 quantization completes
  • J3: Quantized perplexity <15% degradation
  • J4: WASM compilation succeeds
  • J5: Browser loads model <5s
  • J6-J15: See tests below

§Reference Model

Qwen2-0.5B-Instruct (Apache 2.0):

  • Parameters: 0.5B
  • INT4 Size: ~300MB
  • Context: 32K tokens
  • HF: Qwen/Qwen2-0.5B-Instruct

§References

  • Bai et al. (2023). “Qwen Technical Report”
  • HuggingFace Transformers Documentation

Modules§

reliable
Reliable Demo Best Practices (Part IX of chat-template-improvement-spec v1.4.0)

Structs§

BrowserCompatibility
Browser compatibility checker
DemoMetrics
Demo metrics for verification
PerplexityChecker
Perplexity degradation checker
Qwen2Config
Model configuration for Qwen2-0.5B-Instruct
Qwen2Tokenizer
Tokenizer configuration for Qwen2
SpecialTokens
Special tokens for instruction format

Enums§

QuantizationType
Quantization configuration