Skip to content

Error during chat completion: TypeError: Cannot read properties of undefined (reading 'dims') #1329

Open
@jayasooryantm

Description

@jayasooryantm

System Info

transformerjs@latest
os: ubuntu
browser: chrome

Environment/Platform

  • Website/web-app
  • Browser extension
  • Server-side (e.g., Node.js, Deno, Bun)
  • Desktop app (e.g., Electron)
  • Other (e.g., VSCode extension)

Description

I have fine-tuned Xenova/distilgpt2 with corporate dataset (100 lines of corporate conversation). successfully fine-tuned and output was good in kaggle. I have used transformerjs convert python file to convert it to onnx format. with quantization, the model loaded in the browser but thrown an error while predicting: Error during chat completion: TypeError: Cannot read properties of undefined (reading 'dims'), what did I do wrong? below is the command I ran to convert the model:
python3 convert.py --quantize --model_id path/to/distilgpt2-corporate --output_parent_dir output/path/to/distilgpt2-corporate/models --task text-generation

Reproduction

jayasooryansd/distilgpt-corporate

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions