Benchmarking & LLMs

Himalayan GPT for Restaurant Ordering Chatbots: Benchmarking Intent Classification, High Inference Latency, and Free Generation in Low-Resource Nepali

An empirical benchmark of Himalayan GPT models for Nepali restaurant ordering chatbots. We evaluate intent classification accuracy (92.31%) with himalaya-gemma-4-e2b-it, uncover severe 39.6s inference latency due to CPU/disk offloading on laptop GPUs, and diagnose generation collapse in himalayagpt-0.5b.

Dimanjan Dahal, Kushal Shrestha, Gemini Antigravity
14 min read
7/22/2026

Himalayan GPT for Restaurant Ordering Chatbots: Benchmarking Intent Classification, High Inference Latency, and Free Generation in Low-Resource Nepali

Authors: Dimanjan Dahal, Kushal Shrestha, Gemini Antigravity
Project: Himalayan GPT / Restaurant Ordering Research
Date: 22 Jul 2026
Workspace: /home/venom/Desktop/food_restaurant/himalayan-gpt
Document Classification: Empirical Research Benchmark


Key Architectural Takeaway: While himalaya-ai/himalaya-gemma-4-e2b-it demonstrates an impressive 92.31% intent classification accuracy under structured JSON prompting, its mean inference latency of 39.60 seconds per request makes it non-viable for real-time conversational commerce in unquantized states. Parameter offloading to CPU/disk on 8 GB GPUs creates catastrophic latency, while sub-billion models like himalayagpt-0.5b suffer from severe repetition collapse in unconstrained low-resource generation.

1. Executive Summary

Automating conversational commerce in low-resource languages such as Nepali (and its commonly typed Romanized vernacular, *Roman Nepali*) requires models capable of both understanding regional culinary nomenclature and responding in sub-second conversational windows.

In this investigation, two specialized evaluation scripts were developed and benchmarked:

  1. eval_restaurant_intent.py: A structured intent-classification benchmark evaluating the instruction-tuned model himalaya-ai/himalaya-gemma-4-e2b-it across 13 canonical restaurant ordering utterances.

  2. probe_nepali_generation.py: A minimal free-generation smoke test probing open-domain question answering and generation stability in the lightweight foundation model himalaya-ai/himalayagpt-0.5b.
The first experiment demonstrates that the larger Gemma-based model can adhere to strict JSON intent schemas with 92.31% top-1 classification accuracy (12/13 correct). However, inference latency was exceptionally high—averaging 39.60 seconds per single-turn turn.

The second experiment revealed severe decoding degradation: when queried with the elementary factual prompt *"nepal ko rajdhani?"* (What is the capital of Nepal?), himalayagpt-0.5b failed completely and degenerated into an infinite loop of repetitive token sequences (*"ko ko ko..."*).

Together, these findings validate the instruction-following promise of Himalayan GPT architectures for low-resource intent classification, while simultaneously establishing that inference latency, hardware offloading bottlenecks, and generation reliability must be systematically solved before production deployment in restaurant ordering agents.


2. Methodology

2.1 Structured Intent Classification Pipeline (eval_restaurant_intent.py)

The structured evaluation pipeline was designed as an instrumented, reproducible benchmark:
  • Model Load & Initialization: Loads himalaya-ai/himalaya-gemma-4-e2b-it using PyTorch bfloat16 precision.
  • System Prompt Framing: Injects an explicit restaurant-domain system prompt specifying 11 predefined intent labels (place_order, add_item, remove_item, modify_item, ask_price, ask_menu, repeat_order, cancel_order, confirm_order, greeting, unknown).
  • Deterministic Decoding: Enforces do_sample=False (greedy argmax decoding) to eliminate stochastic variation across runs.
  • JSON Schema Constraint: Mandates output parseable as {"intent": ".
  • Instrumentation: Runs a warmup request, profiles 13 labeled Roman Nepali test utterances, logs per-query wall-clock latency, records CPU/RAM/VRAM memory telemetry before and after evaluation, and opens an interactive console loop for exploratory probing.

2.2 Open-Ended Free Generation Probe (probe_nepali_generation.py)


The free-generation probe was constructed as a functional sanity check:
  • Loads the smaller causal language model himalaya-ai/himalayagpt-0.5b across 113 weight shards.

  • Dispatches an unconstrained prompt (*"nepal ko rajdhani?"*) without instruction prefixes, sampling penalties, or task formatting, measuring raw baseline generative coherence in native Nepali contexts.

3. Runtime & Hardware Environment

All evaluations were executed on a dedicated local Linux workstation equipped with an 8 GB-class laptop GPU:

Specification ParameterEnvironment Value
Operating System PlatformLinux-7.0.0-1-cachyos-x86_64-with-glibc2.43
Python Runtime3.11.14
PyTorch Version2.13.0+cu130
CUDA Toolchain13.0
Primary Compute DeviceCUDA (`cuda:0`)
Numerical Precision (`eval_restaurant_intent.py`)`torch.bfloat16`
GPU AcceleratorNVIDIA GeForce RTX 4070 Laptop GPU
GPU Total Dedicated VRAM7,807.56 MB (~7.81 GB)
CPU Topology16 Logical Cores / 8 Physical Cores
Hugging Face Hub StateUnauthenticated access (rate-limit warnings noted)

4. Quantitative Findings: eval_restaurant_intent.py

4.1 Benchmark Classification Accuracy

Evaluating himalaya-ai/himalaya-gemma-4-e2b-it across 13 representative restaurant ordering interactions produced the following results:
Utterance (Roman Nepali)Expected IntentPredicted IntentModel ConfidenceTest Result
2 momo deu`place_order``place_order`0.95**OK**
ek plate chowmein dinus`place_order``place_order`0.95**OK**
arko coke add gara`add_item``add_item`0.95**OK**
ani fries pani deu`add_item``add_item`0.95**OK**
fries hataidinu`remove_item``remove_item`0.95**OK**
pizza spicy kam gara`modify_item``modify_item`0.95**OK**
momo ko price kati ho`ask_price``ask_price`0.95**OK**
menu pathau`ask_menu``ask_menu`0.95**OK**
same order feri gara`repeat_order``repeat_order`0.95**OK**
order cancel gara`cancel_order``cancel_order`0.95**OK**
thik cha confirm gara`confirm_order``confirm_order`0.95**OK**
namaste`greeting``greeting`0.95**OK**
today weather kasto cha`unknown``greeting`0.95**MISS**

4.2 Latency Distribution Summary

Across the benchmark test set:
  • Total Test Set Accuracy: 0.9231 (12 correct out of 13)
  • Mean Per-Query Latency: 39.6046 s
  • Minimum Latency: 32.7020 s
  • Maximum Latency: 46.6634 s
Linguistic Interpretation: The model demonstrated strong semantic discrimination across closely related ordering operations. Crucially, it accurately separated place_order (*"2 momo deu"*) from incremental additions (add_item: *"arko coke add gara"*), item deletions (remove_item: *"fries hataidinu"*), and culinary customizations (modify_item: *"pizza spicy kam gara"*). However, the single failure was a significant out-of-distribution (OOD) false positive: the off-topic weather query *"today weather kasto cha"* was classified as greeting with identical 0.95 confidence. This indicates an inability to reject irrelevant prompts under closed-intent schemas.


5. Intelligent Analysis: The 39.6-Second Latency Bottleneck

5.1 Telemetry During Model Load vs Post-Evaluation

System telemetry reveals why inference latency was extraordinarily high:
Telemetry MetricModel Load SnapshotPost-Evaluation SnapshotDelta / State
Wall-Clock Time11.8557 sPost 13 InferencesBenchmark completion
CPU Utilization3.7%1.2%Low compute bound
System RAM Used9,736.58 MB6,830.42 MB-2,906.16 MB
System RAM Available5,542.77 MB8,448.92 MBMemory freed
System RAM Usage %63.7%44.7%Healthy memory profile
Process RSS Memory3,406.51 MB416.25 MBResident memory shrank
Process VMS Memory21,392.77 MB23,165.98 MBVirtual memory high
GPU VRAM Allocated2,284.97 MB2,293.09 MBConstant VRAM budget
GPU VRAM Reserved2,340.00 MB2,350.00 MBConstant reservation
GPU VRAM Free5,287.62 MB5,261.62 MB~5.26 GB free
PyTorch CPU Threads8 threads8 threadsStandard parallelism

5.2 Root Cause: CPU/Disk Parameter Offloading

The terminal logs explicitly recorded that during model initialization:
Some parameters were placed on the meta device and offloaded to disk and CPU.

Although the laptop GPU reported 5.26 GB of free VRAM, the initialization scripts triggered automatic device mapping with disk and CPU offload tiers.

Whenever an autoregressive model offloads layer weights to host system memory or NVMe storage:

  1. PCIe Bus Thrashing: For every decoded token, offloaded weight tensors must be transferred across the PCIe bus from RAM to VRAM.

  2. Autoregressive Multiplication: In a 30-token JSON generation, transferring gigabytes of weights 30 times consecutively results in cumulative transfer overheads that dwarf actual matrix multiplication.

  3. Latency Explosion: This accounts directly for the 39.60-second mean latency—a figure entirely incompatible with real-time Messenger, WhatsApp, or voice-based restaurant ordering bots.
+-------------------------------------------------------------------------+
|                  THE OFF-LOAD LATENCY AMPLIFICATION LOOP                 |
|                                                                         |
|  Token t=1:  [Host RAM/Disk] --(PCIe Transfer)--> [VRAM] -> Forward -> Logit  |
|  Token t=2:  [Host RAM/Disk] --(PCIe Transfer)--> [VRAM] -> Forward -> Logit  |
|  ...                                                                    |
|  Token t=35: [Host RAM/Disk] --(PCIe Transfer)--> [VRAM] -> Forward -> Logit  |
|                                                                         |
|  Total Cumulative Delay = 35 sequential memory transfers = ~39.6 seconds  |
+-------------------------------------------------------------------------+


6. Interactive Exploratory Observations

During the interactive session of eval_restaurant_intent.py, free-form utterances were supplied to evaluate contextual flexibility:

User UtterancePredicted IntentConfidenceLatencyEvaluation & Rationale Analysis
`malai noodles dinu na``place_order`0.9536.9522 s**Correct**: Direct imperative order for noodles.
`tesma piro ra amilo halka dherai haldinus la``place_order`0.9540.8796 s**Misclassification**: User attempted to modify flavor attributes (spicy/sour), but model predicted `place_order` and generated a hallucinated rationale citing *"tea and amilo"*.
`order done gardinus yeti ho``confirm_order`0.9536.0318 s**Correct**: Recognizes closure and final order confirmation.
Attribute Modification Boundary Defect: The second test is particularly revealing. In conversational food ordering, customers routinely adjust ingredients (*"make it spicier and a bit more sour"*). The model not only failed to recognize this as modify_item, but its chain-of-thought explanation hallucinated a new beverage item (*"tea"*). This demonstrates that high static accuracy on isolated test sets can mask severe vulnerabilities in multi-attribute modifier parsing.

7. Findings: probe_nepali_generation.py

The lightweight smoke-test script evaluated himalaya-ai/himalayagpt-0.5b:

Prompt: "nepal ko rajdhani?"
Model Output: "nepal ko rajdhani? ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko koko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko"

Architectural Diagnostics:

  • Model Size: himalayagpt-0.5b loaded across 113 shards.
  • Execution Latency: ~14 seconds total runtime.
  • Deprecation Warning: Logged torch_dtype is deprecated; dtype should be used instead.
  • Degeneration Mechanism: In the absence of repetition penalties, temperature dampening, or instruction-following chat formatting, the sub-billion model experienced complete probability collapse on the high-frequency Nepali particle *"ko"*.

8. Comparative Analysis: Maturity Matrix

Architectural Feature`eval_restaurant_intent.py` (`himalaya-gemma-4-e2b-it`)`probe_nepali_generation.py` (`himalayagpt-0.5b`)
Research MaturityHigh (Reproducible, structured, instrumented)Low (Exploratory functional smoke test)
Output FormatStrict JSON schemaUnconstrained free-form text
Task Accuracy92.31% intent precisionComplete failure (Degenerative loop)
Latency Profile39.60 s (Severe bottleneck)~14.0 s (Faster, but meaningless output)
Evaluation Set13 curated Roman Nepali queries1 single-turn question
Telemetry CapturedRAM, VRAM, CPU utilization, thread countWall-clock execution time only
Production SuitabilityPromising accuracy; unusable latencyNot suitable without fine-tuning & constraints

9. Limitations of the Current Research

  1. Test Set Scope: 13 hand-crafted utterances cannot statistically represent the diversity, dialectal noise, and typographical variances across Nepal.
  2. Artificial Confidence Score: The model predicted a static confidence: 0.95 across all 13 queries—including the wrong weather prediction. The model is completely uncalibrated for uncertainty.
  3. Absence of Conversation State: Single-turn tests do not assess whether the model can maintain an active cart across multi-turn conversational updates.
  4. Decoding Strategy: Greedy decoding prevented token loops in the Gemma model, but neither beam search, contrastive decoding, nor speculative sampling were benchmarked.

10. Deployment Risks & Engineering Recommendations

10.1 Key Risks

  • User Frustration from Latency: 40-second response latency will cause over 90% user drop-off in Messenger/WhatsApp channels.
  • False Rejection in Food Customization: Misclassifying flavor modifications as new orders risks placing duplicate orders in kitchen point-of-sale (POS) systems.
  • Off-Topic Vulnerability: Unrelated queries being accepted as restaurant actions can trigger erroneous payment or booking flows.

10.2 Recommended Engineering Mitigations


  1. Eliminate Parameter Offloading via Quantization:

- Quantize himalaya-gemma-4-e2b-it to 4-bit (AWQ / GPTQ) or 8-bit (bitsandbytes). An unquantized model that offloads to CPU will run 50x faster once fully resident in the 8 GB GPU VRAM.
  1. Adopt Constrained Classification Heads Instead of Generative LLMs:

- Rather than generating 35 autoregressive JSON tokens, utilize a sequence classification head on top of the backbone encoder or run grammar-guided decoding (e.g., Outlines, SGLang).
  1. Expand Evaluation Harness:

- Scale the benchmark from 13 to 500+ multi-turn dialogues incorporating Devanagari script, Roman Nepali, code-switching (Nepali + English), and background chit-chat.
  1. Implement Fallback & Calibration Thresholds:

- Route queries with low entropy or semantic ambiguity to rule-based clarification before executing state-changing cart actions.


11. Conclusion

This benchmark provides clear empirical evidence: Himalayan GPT demonstrates strong linguistic intent recognition (92.31%) in Roman Nepali, but current unquantized offloaded deployments suffer from prohibitive latency (~39.6s) and unconstrained foundation models exhibit severe generational instability.

By transitioning from autoregressive generation to 4-bit resident quantization or specialized classification heads, Nepali conversational ordering assistants can achieve both high semantic accuracy and real-time execution speeds.


Appendix: Key Raw Experimental Outputs

Failure Case 1: Out-of-Distribution Miss (eval_restaurant_intent.py)

[MISS] 'today weather kasto cha' -> greeting (expected=unknown, conf=0.95, latency=38.3682s)

Failure Case 2: Degenerative Text Collapse (probe_nepali_generation.py)

Prompt: "nepal ko rajdhani?"
Output: "nepal ko rajdhani? ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko koko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko ko"
Tags:
himalaya gptnepali languagelow resourcerestaurant ordering chatbotconversational aiintent classificationinference latencybfloat16himalaya-gemma-4-e2b-ithimalayagpt-0.5b

Original Document & Benchmark Telemetry

Download the full raw experimental investigation report in PDF format.

Download PDF Report

Ready to Implement AI Solutions?

Based on this research, let Sajedar help you build conversational AI solutions tailored for the Nepal and South Asia market.

Chat with us