Skip to content

Fix module usage#2

Merged
clems4ever merged 7 commits into
clems4ever:mainfrom
lein3000zzz:lein3000zzz
Feb 6, 2026
Merged

Fix module usage#2
clems4ever merged 7 commits into
clems4ever:mainfrom
lein3000zzz:lein3000zzz

Conversation

@lein3000zzz

Copy link
Copy Markdown
Contributor

This PR is mostly about addressing the issue #1.

  1. Removed Git LFS for the model file
    The Go module system does not fetch Git LFS objects and instead downloads only pointer files. As a result, the model worked only when cloning the repository directly, which is not the intended usage.
    Since GitHub supports files up to 100 MB without LFS, the model is now stored directly in the repository, avoiding Git LFS entirely and fixing module-based usage.

  2. Added NewModelBare() constructor
    Introduces a constructor that does not implicitly initialize the ONNX Runtime environment, preventing unexpected panics in larger projects where the environment lifecycle is managed explicitly.

  3. Updated dependencies
    Updated dependencies, in particular the tokenizer, which now includes fixes that were previously only available in the custom fork used earlier.

  4. Removed ort.DestroyEnvironment from model.Close()
    Avoids implicit management of the ONNX Runtime environment and leaves lifecycle control to the caller.

@clems4ever clems4ever merged commit dc75c8d into clems4ever:main Feb 6, 2026
@clems4ever

Copy link
Copy Markdown
Owner

Thanks for the fix @lein3000zzz !

@lein3000zzz lein3000zzz mentioned this pull request Feb 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants