Skip to content

اشکال در مثال ها #365

@webnegar

Description

@webnegar

به نظر می رسد مثال ها قدیمی هستند

===============================

Sentence embedding

===============================

sent_embedding = SentEmbedding.load(repo_id='roshan-research/hazm-sent-embedding', model_filename='./models/sent2vec-naab.model')
sentence_similarity = sent_embedding.similarity('او شیر میخورد','شیر غذا می‌خورد')
print(sentence_similarity) # 0.4643607437610626


AttributeError Traceback (most recent call last)
Cell In[43], line 4
1 # ===============================
2 # Sentence embedding
3 # ===============================
----> 4 sent_embedding = SentEmbedding.load(repo_id='roshan-research/hazm-sent-embedding', model_filename='./models/sent2vec-naab.model')
5 sentence_similarity = sent_embedding.similarity('او شیر میخورد','شیر غذا می‌خورد')
6 print(sentence_similarity) # 0.4643607437610626

AttributeError: type object 'SentEmbedding' has no attribute 'load'

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions